What Is an AI Character Card? Fields, Formats and a V2 Example

By Updated 9 min read

An AI character card is a file that tells a chat app who to play. It stores the character's name, profile, scenario, first message and example dialogue as JSON, often inside a PNG portrait. Apps like SillyTavern import the file. In apps with character text fields, you can copy the same text into the boxes instead.

A glowing card with a speech bubble tops a fan of blank cards floating above your open palm in violet light.
Illustration generated with AI

Key takeaways

  • A character card is text about a character in a shared JSON format. It isn't a model, and the standard fields don't include your chats.
  • Besides the name, the basic fields do four jobs: character profile (description and personality), scenario, first message and example dialogue.
  • In SillyTavern, the profile and scenario go with every request, the first message is added once at the start, and example dialogue is dropped first when space runs out.
  • A PNG card is an ordinary portrait with the card's JSON stored in a text chunk. Re-saving or converting the image can silently strip it.
  • V1 has six fields, V2 adds greetings, a lorebook and creator notes, and V3 adds assets and the CHARX archive. Where an app can't import cards, copy the text of each field.
Contents
  1. What is a character card?
  2. What's inside a character card?
  3. What do the profile, scenario, first message and example dialogue do?
  4. What does a V2 character card example look like?
  5. What's the difference between V1, V2 and V3 cards?
  6. How does a PNG character card store the data?
  7. How do you use a character card?
  8. Is a character card the same as a definition or a persona?
  9. Bottom line

What is a character card?

A character card is a character's description saved in a shared file format that AI roleplay apps can read. The app opens the file, sorts the text into its own fields (who the character is, how they behave, where the scene starts, what the first line is) and uses it to build the prompt it sends to a language model along with your messages.

You may also see "Tavern card." SillyTavern, an open-source app that reads these files, began in February 2023 as a fork of TavernAI 1.2.8, according to its own documentation.

What a card is not:

  • Not a model. A card is text. The replies come from whatever model the app connects to. Apps can use different models, settings and prompt layouts, which is why the same card can feel different in two of them.
  • Not a chat export. The standard card fields describe the character. Neither the V2 nor the V3 spec has a field for conversations, so exporting a card doesn't export your story.

What's inside a character card?

A card is a set of named fields. The names below come from the open Character Card V2 and V3 specs. What matters as much as the content is when the model sees it, and that's up to the app. SillyTavern's documentation splits fields into permanent ones, included with every request, and temporary ones.

Field What goes in it When SillyTavern normally sends it
name The character's name Every request
description Who they are: age, job, looks, history, key facts Every request
personality A short summary of their character Every request
scenario The situation: where you are, what's going on Every request
first_mes The first message of the chat Added once at chat start; stays visible while it fits in the context
mes_example Example dialogue Only while there's room in the context

With SillyTavern's usual settings, example dialogue is the first to go: its docs say example blocks are only inserted if there's free space and drop out block by block as the chat grows. So a fact the character must keep belongs in the description, not in the examples. If you've wondered why a long chat drifts, why AI chatbots forget explains the context window behind it.

V2 cards add more fields:

  • alternate_greetings: extra opening messages you can pick from in a compatible app. The spec asks apps to offer them as "swipes."
  • character_book: a lorebook built into the card, which can hold entries that fire on keywords. The spec says it stacks with your own world book.
  • creator_notes: notes for people. The spec says they must not be used in prompts.
  • system_prompt and post_history_instructions: card-specific instructions for the model. In an app that honors them, a nonempty system_prompt replaces the usual system prompt. If an imported card behaves oddly, check these two fields.
  • tags, creator, character_version: catalog info, not part of the character.
  • extensions: app-specific data that editors aren't supposed to delete.

You'll often see {{char}} and {{user}} in the text. Apps that support these placeholders swap them for the character's name and yours. If you move the text somewhere that doesn't, replace them with the names you use in the chat.

What do the profile, scenario, first message and example dialogue do?

Besides the name, the six basic fields do four jobs. Here's each one, using a character invented for this article: Odile Marsh, a 42-year-old perfumer.

Character profile (description and personality). The permanent core: facts and behavior. "Odile, 42, runs a tiny perfume shop. Refuses rush jobs. Warms up when someone brings her an unusual scent." Concrete behavior gives the model something to act on, and gives you something to check in replies. "Mysterious" doesn't.

Scenario. The situation right now, in a sentence or two: "A rainy evening, ten minutes before closing. You walk in with a nearly empty bottle." Janitor AI's help center describes its Scenario box the same way: setting, time period and a short note on how the character relates to you.

First message. The opening scene, written as the character. SillyTavern's Character Design page says the model is more likely to pick up style and length from the first message than from anything else, so write it at the length you want replies to be. Our AI character greeting examples show openings by genre.

Example dialogue. A few sample exchanges that show how the character talks. In SillyTavern, each example block starts with a <START> line. Keep them short, since they're the first thing dropped in a long chat.

Writing these well is its own skill. The step-by-step version is in how to write an AI character, and if you just want blanks to fill in, grab the character definition template.

What does a V2 character card example look like?

Here's a minimal V2 card for Odile. Save it as odile.json for an app that accepts V2 JSON files. Odile is fictional and an adult, and the description says so.

{
  "spec": "chara_card_v2",
  "spec_version": "2.0",
  "data": {
    "name": "Odile Marsh",
    "description": "Odile Marsh, 42, perfumer. Runs a tiny shop on a side street, shelves of brown glass bottles. Reading glasses on a cord. Trained in a fragrance lab, left to work alone.",
    "personality": "Dry and precise. Refuses rush jobs and says so plainly. Asks many questions about where a scent came from. Warms up and talks at length only about unusual ingredients.",
    "scenario": "A rainy evening, ten minutes before closing. {{user}} brings in a nearly empty bottle of a discontinued perfume.",
    "first_mes": "*Odile doesn't look up from her scale.* We close in ten minutes. If it's a gift, come back tomorrow.",
    "mes_example": "<START>\n{{user}}: Can you have it by Friday?\n{{char}}: No. Good perfume takes weeks to settle. Ask me again in a month.",
    "creator_notes": "",
    "system_prompt": "",
    "post_history_instructions": "",
    "alternate_greetings": [],
    "tags": ["slice of life"],
    "creator": "",
    "character_version": "1.0",
    "extensions": {}
  }
}

Inside a JSON string, write a quote as \" and a line break as \n, and don't leave a comma after the last item. A JSON validator will catch syntax errors, though it won't tell you whether an app accepts the card.

What's the difference between V1, V2 and V3 cards?

The format grew in steps, and you'll still meet all three versions. Check which ones your app accepts. Exporting to an older version can drop fields it doesn't support, so keep the original file.

Version How to spot it What it adds
V1 Flat JSON, no spec field Six fields: name, description, personality, scenario, first message, example dialogue
V2 "spec": "chara_card_v2", fields inside data Alternate greetings, lorebook, creator notes, system prompts, tags, extensions
V3 "spec": "chara_card_v3" Assets, group-chat greetings, multilingual notes, dates, CHARX

The V3 additions in plain words:

  • nickname: if set, it's used instead of the name wherever {{char}} appears.
  • group_only_greetings: openings used only in group chats.
  • assets: references to resources such as the avatar, backgrounds or sounds.
  • creator_notes_multilingual: creator notes in several languages.
  • creation_date and modification_date: timestamps.

V3 also defines CHARX, a zip archive with card.json at its root plus any bundled assets. And if a V3 card has a spec_version newer than an app knows, the spec asks the app to warn you and import it anyway, even if some new features won't work.

How does a PNG character card store the data?

A PNG card looks like a normal character portrait. But the PNG format, as defined by the W3C, allows tEXt chunks inside the file: a keyword, a separator and some text. That's where the card goes.

  1. The app encodes the card's JSON as UTF-8, then as Base64.
  2. It stores that string in a tEXt chunk under the keyword chara (legacy and V2) or ccv3 (V3).
  3. The pixels don't change. A photo viewer shows the portrait and ignores the text.

SillyTavern's source code looks for ccv3 first and uses chara if there isn't one. When it saves a card, it normally writes both chunks, so older apps can still read the file. The V3 spec says the same about priority: if both are present, use ccv3.

That's the appeal of PNG: one file carries the face and the whole character. It's also the weak spot, because the text can disappear without anyone noticing.

Why won't a PNG character card import?

Often the card data is simply gone from the file. SillyTavern's FAQ gives two reasons:

  • The data was stripped. Some programs and file managers drop embedded data when they save an image. The FAQ's advice: use the raw PNG exactly as it was shared.
  • It isn't really a PNG. The file is a WebP with a .png name. Try renaming it to .webp before importing, or find a true PNG.

There's a third, simpler case: a portrait or preview image that never had a card in it. Get the card file itself, not the picture shown on a page. And to keep cards intact, don't convert them to JPG or WebP, don't re-save them in an image editor, and send them in messaging apps as files, not photos.

How can you check a PNG card yourself?

If you have a computer with Python, this script uses only the standard library. It reports whether the file has a card chunk and prints the decoded JSON. Save it as read_card.py and run python3 read_card.py your_file.png.

import sys, struct, base64, json

data = open(sys.argv[1], 'rb').read()
if not data.startswith(b'\x89PNG\r\n\x1a\n'):
    sys.exit('Not a PNG: maybe a WebP or JPG with the wrong extension.')

pos, found = 8, {}
while pos + 12 <= len(data):
    size, kind = struct.unpack('>I4s', data[pos:pos + 8])
    if pos + size + 12 > len(data):
        break
    body = data[pos + 8:pos + 8 + size]
    if kind == b'tEXt' and b'\x00' in body:
        key, _, text = body.partition(b'\x00')
        found[key.decode('latin-1').lower()] = text
    if kind == b'IEND':
        break
    pos += size + 12

key = 'ccv3' if 'ccv3' in found else 'chara' if 'chara' in found else None
if key is None:
    sys.exit('No chara or ccv3 chunk found: this is a plain image.')
try:
    card = json.loads(base64.b64decode(found[key]).decode('utf-8'))
except ValueError:
    sys.exit(f'Found a {key} chunk, but it is unreadable.')
print(json.dumps(card, ensure_ascii=False, indent=2))

If it prints JSON, the embedded text is readable. Then check the card's version and whether your app supports it. If it says "plain image," look for the original file. The script doesn't validate the whole PNG or the card's structure.

SillyTavern's source code accepts PNG, JSON, YAML, CHARX and BYAF files on import and exports PNG or JSON.

How do you use a character card?

That depends on whether your app reads card files.

In SillyTavern, the Characters panel has two import paths:

  • Import Character loads a card from a file.
  • External Import takes a URL, but according to the source code it only works with supported sites and domains allowed in the server configuration. If a link fails, download the card file and use the first option.

Export character saves it back out. After importing, glance at the token count. SillyTavern's docs say it turns red when the character's text takes more than half of the model's context. Nothing breaks, but there's less room left for earlier messages.

In apps without card import, use the card as source text. Many chat apps build characters from boxes on a create page, so copy each field into the matching box: profile, scenario, greeting, examples. If the app has fewer boxes, put the profile, scenario and examples into the main description, and replace the placeholders with names. Skip creator notes and tags. The character definition template maps the parts for Character.AI, Janitor AI and SillyTavern. Field names shift between apps: Janitor AI's help page, for example, lists Personality, Scenario and Initial Message boxes and suggests putting dialogue examples inside Personality.

On aimy.chat, the text of a ready card can be pasted into the character description by hand (with PRO); there is no PNG or JSON file import, so move a card like Odile's over as text: a long text fits into the character description (with PRO, up to 2,000 characters per field). So Odile's description, personality, scenario and examples can go in together. For the opening line, the chat opens with a greeting the character writes itself from its description, and creator beta testers with PRO can also write the first message by hand, which is where her first_mes goes. Paste Odile's text into a new character on aimy.

Use Odile's first_mes as her greeting. The scene below gives you a line to send back:

If her replies come out too chatty, make the personality stricter or add one more terse example exchange. Free: 100 messages a day and your first AI character of your own. Create your own character and play the first scene.

One rule for cards written by other people: don't repost them as your own. If you like a character, invent your own version with a different history, voice and setting. Need a starting point? Try our roleplay character ideas, then take your version into an AI roleplay chat.

Is a character card the same as a definition or a persona?

Not quite. A card is the file. A definition is text about the character. In SillyTavern, a persona is you.

  • Definition. On Character.AI, the definition is the long text that describes the character, roughly what a card's profile and example dialogue cover, in one block. The character definition template shows how to fill one.
  • Persona. SillyTavern's docs describe a persona as the identity you use to take part in chats: your display name, avatar and an optional description. The card describes the character you talk to.

You'll also see names like W++ and PList. Those are ways of writing the text inside a description field, not file formats; a card can hold plain prose or any of them.

If your destination has no suitable file import, you can transfer the character by hand and resume the story with a short recap.

Bottom line

A character card is a character's text in a shared JSON format: name, description, personality, scenario, first message and example dialogue, plus optional extras like a lorebook. It travels as a JSON file, inside a PNG portrait or in a CHARX archive. In SillyTavern, the profile and scenario go with every request, the first message sets the tone, and example dialogue is the first thing dropped when space runs out. If a PNG won't import, the data was usually stripped, the file is really a WebP, or it never had a card in it. Where an app can't read card files, the text still works: copy it into the app's own boxes.

Build your own character — the same steps as above

Looks, personality, voice · one-click sign-in

Free: 100 messages a day and your first AI character of your own

Or with

400,000+ sign-ups · 18+

By continuing, you agree to the Terms and Privacy Policy.

FAQ

Are character cards free to use?

The format is an open specification, so you can write your own card for free. Apps set their own access terms, and a card someone else wrote is still their work: don't repost it as yours. If you want to share a character, write your own.

What's the difference between a character card and a bot?

The card supplies the character data. The bot is what you get when an app combines that text with a language model and starts a chat. The same card can feel different in two apps because they can use different models, settings and prompt layouts.

Can I open a character card on my phone?

A JSON card opens in any text editor app. A PNG card shows up as a normal portrait in a photo viewer, which doesn't display the stored text, so it's easier to inspect on a computer.

Do character cards include chat history?

No. Neither the V2 nor the V3 specification has a field for chats. Apps store conversations separately, so a standard card export isn't a chat-history export.

Why does my imported character talk differently than expected?

Check the first message and the example dialogue first: the model tends to copy their style and length. If the style still seems wrong, check whether the card supplies its own instructions in the system prompt fields.

Sources

  1. Character Card V2 Specification — GitHub
  2. Character Card V3 Specification — GitHub
  3. Character Design — SillyTavern documentation
  4. Characters — SillyTavern documentation
  5. Frequently Asked Questions — SillyTavern documentation
  6. endpoints/content-manager.js — SillyTavern source code on GitHub
  7. Personas — SillyTavern documentation
  8. SillyTavern Documentation (home) — SillyTavern documentation
  9. character-card-parser.js — SillyTavern source code on GitHub
  10. endpoints/characters.js — SillyTavern source code on GitHub
  11. The Basics: The Character Creation Page Overview — Janitor AI Help Center
  12. Portable Network Graphics (PNG) Specification (Third Edition) — W3C
What changed
  • — First version. Added confirmed product facts: character card import from PNG or JSON.

What next

What nextHow to Write an AI Character for Chat, With a Full Example

Related articles

All articles

Continue in aimy

Free: 100 messages a day and your first AI character of your own

Or with

400,000+ sign-ups · 18+

By continuing, you agree to the Terms and Privacy Policy.