Best practices
This guide will cover how to write effective prompts, how to configure a persona (custom instructions), and a high-level look at Retrieval-Augmented Generation (RAG) โ what it excels at and where its limits are.
Understanding Retrieval-Augmented Generation (RAG)
CustomGPT.ai utilizes Retrieval-Augmented Generation (RAG) under the hood to make your agent smarter with your data. RAG might sound technical, but at a high level itโs simply a way of combining a knowledge search with AIโs natural language generation. RAG enables the AI to fetch information from your provided content or knowledge base and then generate an answer using that information.
The goal is to have an AI that doesnโt guess when it can instead look up the facts. For example, if someone asks your CustomGPT.ai agent a question thatโs answered in your uploaded company handbook, the RAG system will pull the specific answer from the handbook and include it in the response.
What RAG does well
- Provides domain-specific knowledge: RAG allows agents to use your data (e.g. product manuals, knowledge base articles, PDFs you uploaded) when answering questions. Answers contain real, up-to-date details from your content. Itโs like giving the agent a custom library to draw from, so it can handle niche questions that a generic model might not know.
- Improves accuracy and reduces hallucinations: Because agent checks actual sources before answering, itโs far less likely to make up facts. Every response will be backed by real data from your knowledge base.
- Maintains contextual relevance: RAG helps the agent focus on relevant info. Even if you have a large database of information, the response will be based on just the most relevant pieces.
What are RAG limitations
- It needs contextual data: CustomGPT.ai agents are built and instructed to minimize hallucinations. If user prompts something that doesn't exist in agent's knowledge base, it will inform user that it doesn't know the answer instead of making it up. If you would prefer different behavior, you can enable your agent to use general LLM knowledge, but this is not recommended!
- It needs to stay up to date: RAG is only as good as the data you provide. If your knowledge base is incomplete, outdated, or contains errors, the agent's answers will reflect that. Enable auto-sync feature for your agents to ensure they are always up to date.
- Spreadsheets: RAG relies on semantic search when retrieving your data, and this can be difficult for spreadsheets that are not formatted in RAG-friendly way. If you are not having expected results with uploaded spreadsheet, don't hesitate to contact our support team to help you out.
- Broader context: CustomGPT.ai agents have a general high-level understanding of their knowledge base, and are capable of responding to questions about it, but they work best when prompted a specific question rather than trying to cross-reference different segments of their knowledge. For example, instead of asking โHow does this product compare to competitors?โ, youโll get a more accurate and useful response by asking separate, focused questions like โWhat are the key differentiators between our product and Competitor X?โ
Writing effective prompts
Crafting clear prompts is the first step to guiding your AI agent. A well-crafted prompt ensures the AI understands exactly what you need. Here are some prompting best practices:
- Be specific with your prompts: Include details like context, constraints, or desired focus. For example: Instead of asking โCreate a list of activities for young kids,โ try โCreate a list of outdoor activities for six kids ages 5โ8, considering we have a large yard and a nearby nature trail.โ
- Provide sufficient context: Always give background information if needed, as the AI doesnโt have the same context you do. For example: Instead of โWrite an outline for a report on improving access to healthcare,โ you could prompt โI work for a nonprofit focused on rural healthcare access. I need an outline for a report about our programs to present to local government leaders.โ
By following these prompt guidelines โ being specific, giving context, assigning a role, defining style, and format โ you set your CustomGPT.ai agent up for success.
Use custom instructions - Persona
Generally, you want your AI to maintain a consistent persona or follow certain guidelines in every response. This is where Custom Instructions (the Persona feature) comes in - they help you set agent's baseline behavior, tone, and role across all interactions.
What are Custom Instructions? They are background directives that shape how the AI behaves. Custom instructions are essential for tailoring agent interactions, helping you guide tone, behavior, and focus to suit specific goals. In practice, this means you can tell the AI things like the level of detail to use, what style or tone to maintain, what not to do, and so on โ and these rules will persist. For example, you might set a custom instruction that says: โYou should always respond in a friendly, encouraging tone and use simple language a high school student could understand.โ
How to Configure a Persona: Your CustomGPT.ai will come with automatically prepared persona which should serve a basic purpose. If you want more advanced functionality, you can follow our guide about setting up the Persona. This might include the AIโs role (e.g. โYou are an expert financial advisorโฆโ), its style (formal and technical, or casual and witty), and any rules or disclaimers it should always keep in mind.
Best Practices:
- Keep Persona clear and relevant
- Define the most important aspects of your AIโs behavior, but avoid contradictions.
- It helps to break instructions into sections (e.g. Role, Tone, Dos and Donโts) for clarity.
- AIs generally respond better to positive (e.g. "Do this") than negative (e.g. "Don't do this") instructions.
Updated about 16 hours ago