2 - Prompt Engineering For Power BI.pdf

Document Details

University of Manitoba

2020

Tags

prompt engineering power BI analytics business intelligence

Full Transcript

Prompt Engineering for Power BI IDM 2020 Farhan Islam umanitoba.ca/asper Objective Overview of LLMs Prompt Components Prompt Principles/Tips When to use LLM for Power BI and Analytics? Let’s exper...

Prompt Engineering for Power BI IDM 2020 Farhan Islam umanitoba.ca/asper Objective Overview of LLMs Prompt Components Prompt Principles/Tips When to use LLM for Power BI and Analytics? Let’s experiment! umanitoba.ca/asper Large Language Models Let’s not get too technical Huge amount of text data as training dataset. Algorithms (e.g., Transformer for GPT) sample these text (after tokenized) and try to imitate word sequences in the training dataset. So, this means by default, ChatGPT wants to be “average” or representative of answers of varying qualities, but you can leverage prompt techniques to direct it to sample more from data of higher quality (more later!) Finetuning, Reward Modeling, RLHF… to direct GPT to certain tasks… umanitoba.ca/asper umanitoba.ca/asper Prompt Components Finetune your prompts through them INSTRUCTIONS PRIMARY CONTENT EXAMPLES (YEAH, YOU CUE (JUMPSTART THE (SIMPLE OR (E.G., TEXT YOU WANT CAN TEACH LLMS RESPONSE; NEXT SLIDE COMPLEX) AN LLM TO WHILE USING THEM) FOR EXAMPLES) AND SUMMARIZE) SUPPORTING CONTENT umanitoba.ca/asper umanitoba.ca/asper umanitoba.ca/asper Principles Be clear, specific, and descriptive. Condition on good performance: “Assume you are an expert with IQ of 120” (not too good though, or LLM will run out of enough data to sample from) Clarify the context: “This assignment is for a university Business Analytics course”. Tool use and plugins: Direct LLM to use tools for tasks they are not good at (e.g., math) Constraint prompting: ”Output a JSON (JavaScript Object Notation) file in the following format…” umanitoba.ca/asper Principles Let LLMs “think” Chain of thought: “Let’s think step by step”, few-shot prompting Ask for reflection: “Are you sure?” Double down: repeat your instructions before and after the primary content. Tips Order matters Give the model an “out”: “Respond ‘not found’ if the answer is not present”. umanitoba.ca/asper When to use LLMs for Power BI Analytics? Along the CRISP-DM process? Clarify business understanding and brainstorming business problems. Ask about data sources. Ask for data cleaning techniques. Ask for data visualization methods and DAX. Interpretation of the visuals? Writing report. umanitoba.ca/asper

Use Quizgecko on...
Browser
Browser