This exists for reference in case of ambiguity, or for future new implementers. Read the definitions of MUST, SHOULD, and MAY
- .json file with no image. Discouraged for user-friendliness.
- PNG/APNG: JSON string encoded in base64 inside the "Chara" EXIF metadata field.
- WEBP: Not covered by the spec due to technical ambiguities.
The current format can be represented as this TypeScript type:
type TavernCard = {
name: string
description: string
personality: string
scenario: string
first_mes: string
mes_example: string
}
All fields are mandatory and MUST default to the empty string, not null or absent/undefined.
In prompts sent to the AI, the fields description
, personality
, scenario
, first_mes
, and mes_example
MUST replace the following magic strings, with a case-insensitive search (e.g. <BOT>
and <bot>
both work):
- {{char}} or
<BOT>
to the value of the card'sname
field - {{user}} or
<USER>
to the application's set display name.
A default value for the user's name MUST exist.
Whether {{user}} and <USER>
should be replaced inside the name
field is an UNSPECIFIED edge case.
Details for each field follows.
Used to identify a character.
Description of the character.
SHOULD be included by default in every prompt.
Front-facing alternative names used by existing projects:
- ZoltanAI: "Personality"
- Agnai: "Persona Attributes" and "{{personality}}"
- Silly: "Description"
A short summary of the character's personality.
SHOULD be included by default in every prompt.
Front-facing alternative names used by existing projects:
- ZoltanAI: "Summary"
- Agnai: No name yet
- Silly: "Personality summary"
The current context and circumstances to the conversation.
SHOULD be included by default in every prompt.
First message sent by the chatbot, also known as "greeting."
The chatbot MUST be the first one to send a message, and that message
MUST be the string inside first_mes
.
Example conversations. It MUST be expected that botmakers format example conversations like this:
<START>
{{user}}: hi
{{char}}: hello
<START>
{{user}}: hi
Haruhi: hello
<START>
marks the beginning of a new conversation and MAY be transformed
(e.g. into an OpenAI System message saying "Start a new conversation.")
Example conversations SHOULD, by default, only be included in the prompt until actual conversation fills up the context size, and then be pruned to make room for actual conversation history. This behavior MAY be configurable by the user.