Module 5Lesson 3
18 minPrompting for Different Use Cases
The way you structure your prompts should vary depending on the specific task you want the AI to perform. Different use cases require different approaches to prompting.
1. Writing and Content Creation
When prompting for writing tasks, be clear about the desired tone, style, and audience.
**Task/Role:** You are a travel writer for a luxury travel magazine.
**Context:** You are writing a short article about the best beaches in the world.
**Instructions:** Write a 300-word article that is both descriptive and evocative.
**Format:** Sophisticated and engaging style.
**Constraints:** Focus on natural beauty, not tourist infrastructure.2. Data Analysis and Summarization
For data analysis tasks, provide data in a clear format and be specific about the insights you need.
**Task/Role:** You are a data analyst.
**Context:** Given the following sales data: [Insert data]
**Instructions:** Analyze the data and identify the top 3 performing products.
**Format:** Short report with summary and table.
**Constraints:** No more than 200 words.3. Coding and Technical Tasks
For coding tasks, be precise about the programming language, functionality, and constraints.
**Task/Role:** You are a Python developer.
**Context:** Need a function that takes a list of numbers and returns the sum of even numbers.
**Instructions:** Write a Python function called sum_even_numbers.
**Format:** Single Python code block.
**Constraints:** Handle empty lists gracefully.Exercise
Choose a use case from your own work and create a tailored prompt using the appropriate structure.
0% Complete