Assignment Introduction: Creating a Virtual Agent with LLMs
Assignment Overview
-
Objective:
- The purpose of this assignment is to apply the knowledge from the module by designing and developing a virtual assistant within a domain and use case of the student’s choice.
- Goal: Students will demonstrate their understanding of LLM-based virtual agents by selecting a domain, defining a use case, and designing prompts to shape the agent’s responses.
-
Assignment Requirements:
- Choose a Domain: Select an industry or field where a virtual assistant could be useful. Examples: healthcare, customer service, education, finance.
- Define a Use Case: Determine a specific function for the virtual assistant within the chosen domain (e.g., customer support, student helpdesk, FAQ assistant).
- Create a Persona and Target Audience: Define who the assistant will serve, what it will help them with, and the desired tone or personality.
- Build Prompts: Design effective system prompts and user prompts to shape the assistant’s responses in alignment with the use case and audience.
- Develop and Test: Implement and iterate on the virtual assistant using the techniques covered in the module, such as role-playing and prompt engineering.
Step 1: Selecting a Domain and Use Case
-
Suggested Domains:
- Banking: Virtual assistant for banking FAQs (e.g., loan inquiries, account assistance).
- Education: Study helper or tutor for specific subjects.
- Healthcare: Appointment scheduler or basic health information provider.
- Real Estate: Property information assistant for prospective buyers or renters.
- Project Management: Assistant for filling out project appraisal forms or guiding users through project setup.
-
Example Use Cases:
- Customer Support Assistant for an online shopping platform, answering inquiries about orders, returns, and shipping.
- Student Research Helper that provides summaries of research topics for students.
- HR Policy Guide that answers employee questions about company policies and benefits.
- Project Appraisal Form Guide that assists users in completing appraisal forms for project evaluation.
Step 2: Creating the Virtual Agent’s Persona and Target Audience
-
Persona Development:
- Define Characteristics: Outline traits such as professionalism, friendliness, formality, and patience based on the assistant’s purpose.
- Example Personas:
- Customer Support Assistant: Friendly and helpful, addressing users in a conversational tone.
- Research Helper: Knowledgeable and informative, providing concise explanations.
- HR Policy Guide: Professional and direct, focusing on clarity and accuracy.
- Project Appraisal Assistant: Step-by-step, instructional tone to ensure users complete forms accurately.
-
Target Audience Considerations:
- Determine who will interact with the virtual assistant (e.g., customers, employees, students).
- Specify their needs and expectations, such as clarity in responses, tone of communication, and level of formality.
Step 3: Initial Prompt Design and Examples
-
System Prompt: Create a system prompt that defines the assistant’s role and behavior.
- Example: “You are a friendly customer support assistant for an online retail platform. Respond to customer questions about orders, returns, and product availability in a helpful and empathetic manner.”
-
User Prompts: Develop example user prompts that will guide the LLM in responding to typical user inquiries.
- Examples:
- “How can I check the status of my order?”
- “What’s the return policy for electronics?”
- “I need help finding properties under $500,000 in New York.”
- Examples:
-
Iterative Prompt Refinement:
- Adjust prompts as needed based on output quality, incorporating more context or changing tone to improve responses.
- Encourage students to experiment with different prompts to see how slight changes affect the assistant’s responses.
Deliverables for the Assignment
-
Report:
- Details of Domain and Use Case: Explain why the domain and use case were chosen.
- Approach and Techniques Used: Describe the prompt engineering techniques used and explain the rationale behind specific prompt choices.
- Data Sources: Outline any datasets or information sources the assistant relies on (e.g., common FAQs, internal policies).
- Final System Prompt: Include the final system prompt for the virtual assistant in the report.
-
Presentation:
- Video: 5–10 minute video covering the assistant’s purpose, persona, and domain.
- Sample Conversations: Demonstrate two sample interactions:
- Happy Path: Show the assistant responding as expected.
- Jailbreak Attempt: Attempt to prompt the assistant with an unusual or challenging question, demonstrating how it responds under different conditions.
Key Tips for Success
- Creativity in Use Case Selection: Encourage students to choose unique or personal use cases that they feel passionate about or find interesting.
- Attention to Audience Needs: Remind students to tailor the assistant’s responses to meet the specific needs and preferences of the target audience.
- Experimentation with Prompts: Prompt refinement is key to achieving high-quality responses; students should iterate and improve prompts as they test their assistant.