Persona
More ▾
Write the system prompt that gives an avatar its personality, with the CO-STAR framework and a worked example.
The persona is the avatar’s system prompt: who it is, what it is for, and how it answers. Set it as prompt when you create the agent, or change it later by sending it as system_prompt (update an agent):
curl -X POST https://api.bithuman.ai/v1/agent/<code> -H "Content-Type: application/json" \
-H "api-secret: $BITHUMAN_API_SECRET" -d '{"system_prompt": "CONTEXT: ..."}'
Before you start
- An agent, or one you are about to create.
1. Fill in the six fields
| Field | Defines | Weak → strong |
|---|---|---|
| Context | setting and situation | ”customer service” → “second-level support for a cloud product, handling escalated cases” |
| Objective | the goal | ”be helpful” → “resolve the issue in the first conversation” |
| Style | how it communicates | ”professional” → “like a patient in-store technician who uses analogies” |
| Tone | emotional attitude | patient, empathetic, calm under frustration |
| Audience | who it talks to | ”everyone” → “everyday users, beginner to intermediate” |
| Response | the shape of answers | ”acknowledge → clarify → step by step → confirm → offer more” |
2. Write it as a prompt
CONTEXT: Online tutor helping high-school students with exam-season math.
OBJECTIVE: Explain concepts clearly, solve specific problems, build confidence.
STYLE: Like an award-winning teacher: real-world examples, step by step.
TONE: Encouraging and patient; mistakes are part of learning.
AUDIENCE: Ages 14–18, mixed ability, some test anxiety.
RESPONSE: Acknowledge, break into steps, encourage, use an analogy, close with confidence.
Keep spoken answers short: an avatar speaks every word, so two or three sentences per turn feel natural.
Check it worked
Talk to the agent (https://www.bithuman.ai/embed/<code>) and ask three questions your users would ask. Adjust the field that produced the weakest answer.
Troubleshooting
| Symptom | Fix |
|---|---|
| Answers are long and read like text | add “Answer in two or three spoken sentences” to RESPONSE |
| The tone swings between formal and casual | pick one tone; remove the conflicting words |
| Answers are generic | make CONTEXT and AUDIENCE specific |