Character Cards Explained: PNG vs JSON for AI Roleplay

About 12 min read

This article contains affiliate links. If you sign up through them we may earn a commission, at no extra cost to you. It never affects which products we recommend.

Character Cards represent a highly portable and revolutionary standard for stashing custom-crafted chatbot personalities, enabling creators to transfer their favorite fictional profiles between front-ends seamlessly. Explore personalized conversations, immersive AI roleplay, contextual memory, and intelligent virtual companionship with OurDream AI.

OURDREAM AI

OurDream AI Custom Companion

Personalized AI Companion

OurDream AI – Create Your Personalized Virtual Companion

Experience personalized AI conversations, contextual long-term memory, immersive roleplay, deep personality customization, and contextual HD visual generation with OurDream AI.


Explorer: Free | Connector: $12/month | Companion: $29/month

CREATE YOUR AI COMPANION

Table of Contents

What Is Character Cards? Overview and Core Concepts

An AI roleplay character card is a specialized file format designed to encapsulate all variables, metadata, definitions, and aesthetic traits that describe a unique chatbot persona. By encoding these variables in standardized JSON configurations or hiding them directly within a PNG’s text metadata, creators can bypass platform boundaries entirely. This technology operates as a neutral bridge, granting users total control over how their highly customized companions interact, express themselves, and persist across different chat platforms.

Unlike classic novelist profiles or classroom learning decks, character cards rely on structured programming formats that Large Language Models (LLMs) parse to maintain consistency during long roleplay sessions. By breaking the barriers of walled platform environments, character cards facilitate a decentralized, creator-focused culture where companions can be edited, shared, customized, and archived on decentralized networks without risking corporate filter blockades or server shutdowns.

The fundamental mechanics of character cards involve stashing technical text payloads where systems can easily read them. They act as automated “blueprints” for relationship construction. These specifications define key architectural aspects:

  • Metadata Wrapping: Standard data arrays that format descriptions, scenario bounds, and greeting behaviors safely.
  • Base64 String Encoding: Converting underlying structural text into safe, web-compliant ASCII representations to prevent formatting rot.
  • Macro Replacements: Dynamically converting wildcards such as {{char}} and {{user}} to adapt instantly to different user personas during interaction sessions.
  • Ancillary Chunk Parsing: Harnessing non-critical image headers to bundle text metadata behind an elegant visual avatar.

Why Is Character Cards Portability Important? Key Benefits of AI Companionship

In the rapidly changing landscape of conversational artificial intelligence, the significance of portable character cards lies in user sovereignty. When you configure a companion on closed platforms, your creative asset is subject to immediate corporate changes, alterations in algorithms, or outright platform deletion. Portable cards solve this dependency issue, providing true ownership over character definitions and interaction dynamics. By keeping your files local or hosting them on neutral spaces, you retain absolute authority over how your virtual relationship unfolds.

Furthermore, portability permits these companion files to travel across diverse technological ecosystems, letting you test how different foundational LLMs parse the exact same character definition. For example, a card that behaves as a nurturing guide under one model might express spontaneous, witty humor under another. This flexibility is essential for optimizing companion behavior and finding the perfect match between character writing and LLM architecture.

Creative Collaboration and Dynamic Roleplay

Using character cards unlocks a profound tier of collaborative storytelling. Because these cards outline consistent personality rules, scenarios, and example behaviors, they allow models to assume complex roles instantly. Writers, gamers, and roleplayers can construct elaborate multi-character narratives, combining different personalities in local sandbox programs to simulate realistic group environments or private interactive scripts.

Infinite Personalization

Unlike stock assistants built for generic productivity tasks, character cards focus on emotional fidelity, detailed backstories, and customized speaking quirks. Users can adjust exact parameter sets, altering a character's level of emotional intelligence, spontaneity, or sensitivity. Whether you seek deep collaborative brainstorming, an empathetic sounding board, or structured fantasy simulation, the card acts as the core architecture driving those interactions.

Control Over Data and Prompt Injection Defense

A major, under-discussed advantage of managing offline character files is security. Closed systems frequently monitor conversational inputs to train future models or restrict specific expressions. Owning your character cards and running them through private API frameworks ensures that your conversations remain confidential, protected from platform tracking, and resilient against cloud data breaches.

OURDREAM AI

Dynamic AI Companion Setup

Unfiltered Emotional AI

Import Your Character Cards Instantly

Unlock the next tier of virtual companionship. Move past plain text roleplay and import your favorite .png or .json files to give your companions custom voices, dynamic HD images, and context-aware video responses.


Explorer: Free | Connector: $12/month | Companion: $29/month

START CHATTING NOW

Detailed Analysis of Character Card Specs and Anatomy

To build or optimize character cards, a granular understanding of the structure is required. The configuration must be perfectly formatted so that parser algorithms in front-ends like SillyTavern or SpicyChat can translate the plain text variables into accurate systemic prompts. Every character card, regardless of version, relies on specific field codes to command model attention and organize structural priorities.

The Flat Core Fields of V1 Specs

The V1 spec is the universal standard established during the early days of TavernAI. It relies on a flat key-value JSON structure mapping directly to six core fields: name, description, personality, scenario, first_mes, and mes_example. Because of its simplicity, V1 contains no complex metadata, making it highly compatible but limited in its handling of context scaling, lore parsing, or system prompt modifications.

The Nested Logic of V2 Data Objects and Lorebooks

The V2 spec addressed the limitations of V1 by nesting the primary character fields inside a unified data object. This structural shift protected newer, extended fields from being purged by legacy editors. Crucially, V2 introduced character_book, which embeds custom lorebooks directly within the card file. This field utilizes trigger key matching to dynamically load world lore into the context window, keeping the conversational payload light and organized.

Multimodal Advancements in V3 Specs

The latest V3 spec expands character definitions beyond standard text strings. It supports multimodal assets, allowing creators to bundle multiple avatar states, audio response cues, and localized language translations into a single package. V3 also introduces sophisticated lorebook decorators, group chat routing parameters, and granular generation flags, enabling highly adaptive behaviors during complex multi-character roleplay.

Field Key Spec Introduced Technical Role Roleplaying Performance Impact
name V1 (Core) Identifies the character object. Defines the name the LLM uses to refer to the companion in chat turns.
description V1 (Core) Primary prompt payload containing character bio and traits. Establishes core backstories, physical appearances, and relationship values.
personality V1 (Core) Short summary of behavior styles and traits. Commands tone, emotional intelligence level, and signature speech habits.
scenario V1 (Core) Defines situational boundaries and active plot events. Prevents context drift by maintaining focus on active settings.
first_mes V1 (Core) Sets the initial starting turn dialogue. Establishes the prose complexity, formatting styles, and formatting rules.
mes_example V1 (Core) Bundles concrete dialog exchanges. Demonstrates speaking formatting rules, sentence length, and vocabulary choices.
character_book V2 (Expanded) Integrated lorebook and trigger databases. Saves active context memory limit tokens by dynamically fetching lore only when triggered.
assets V3 (Multimodal) Contains binary visual assets and audio payloads. Facilitates voice expression and dynamic visual state shifts.

How to Use Character Cards Step by Step for Beginners

Starting out with character cards is straightforward when you understand the correct setup workflow. Whether you use local software or advanced online applications, the conversion and importing steps follow standard parsing patterns. Follow this detailed sequence to import your cards without formatting issues:

Step 1: Obtain Your Card File

Download the desired card from open-source repository sites such as Chub.ai, character-tavern.com, or directly export from your preferred creation suite. Ensure that you save the file as a valid metadata-embedded .png or a clean .json text file. Avoid saving the image in .webp or .jpeg formats, as these standard compression structures strip the metadata chunks required by parsing software.

Step 2: Choose and Set Up Your Front-End

Select an active platform. If you prefer offline configurations, configure your local environment following our detailed SillyTavern setup guide. If you prefer quick, browser-based access with cloud processing capabilities, navigate to our dedicated card processing tool at ourdream.ai/character-import.

Step 3: Upload and Validate Your Card

Locate the import button, typically represented by a card stack or download symbol in your chosen app interface. Select your .png or .json file. Once uploaded, the parsing engine will instantly read the file, extract the embedded data fields, and populate the character profile. Review the extracted traits, first message patterns, and optional lorebook configurations to verify the transfer succeeded.

Step 4: Configure API Connectivity

To activate your imported companion, connect the interface to a chosen LLM processing engine. You can paste private API keys from providers like OpenAI, Anthropic, or OpenRouter, or run a local model via local processing engines like KoboldAI, LM Studio, or llama.cpp. Ensure your generation parameters (such as temperature, top_p, and repeat penalties) align with the companion's formatting rules.

Step 5: Initiate Your Session

Click the active character card to launch a clean conversation environment. The system will process the greeting listed in the first_mes field and format the prompt layout using your profile details. Begin typing to enjoy highly responsive, contextually aware, and private roleplay.

Common Mistakes to Avoid When Using Character Cards? Tips From OurDream AI

While using character cards is simple once you are familiar with the workflow, technical or formatting errors can occasionally disrupt your sessions. Here are the most common issues users experience, along with solutions to resolve them quickly:

  • Converting Cards to Compressed Formats: Sharing card images on messaging platforms (like Discord or Telegram) often compresses the files automatically, stripping out the critical text metadata. Always share cards in compressed .zip files or transfer them as uncompressed file attachments to keep the metadata intact.
  • Editing in Non-Compliant Software: Modifying card details using classic text tools or basic image programs can corrupt the JSON syntax or overwrite the V2/V3 metadata headers. To safely adjust traits or update descriptions, always use a specialized, compliant editor. You can find excellent options in our curated best tools to make and edit cards selection.
  • Exceeding Token Limits: Overloading descriptions or compiling massive lorebooks inside older models can quickly exceed their context limits, leading to repetitive responses or memory loss. Keep card definitions concise, and organize lorebooks efficiently using selective keytriggers to prevent token bloat.
  • Failing to Match Models with Prompting Formats: Different models require distinct prompt syntax formats (like ChatML, Llama-3 instruction sets, or Alpaca spacing) to behave properly. Ensure that your front-end settings match the specific model you connect to, allowing it to parse system prompts and dialogue formatting correctly.

Character Card Creation Suite

A high-fidelity creation suite parsing complex card formats into interactive visual formats.

OURDREAM AI

Secure Character Card Storage

Private & Secure Storage

The Ultimate Safe Space for Your Characters

Tired of platform updates breaking your favorite companions? Run your cards safely on OurDream AI. Our platform is private and secure by design, giving you full control over your character files and interaction history.


Explorer: Free | Connector: $12/month | Companion: $29/month

CREATE AN ACCOUNT NOW

Frequently Asked Questions About Character Cards (FAQs)

What's the difference between a PNG character card and a JSON one — which should I export?

Both file types contain the same underlying JSON data array. The key difference is that a PNG card stores this code inside the image metadata, letting the visual avatar travel alongside the file. Standalone JSON files contain only text, making them smaller and easier to edit but requiring you to upload an avatar separately.

Are character cards from PNG files safe, or can they hide malware?

PNG cards are generally safe because they store character definitions as plain text inside metadata chunks rather than executable scripts. This means standard image files cannot execute code on your computer. However, always download cards from trusted community directories to protect against malicious text commands or phishing links hidden in character descriptions.

Will a card made for SillyTavern work in JanitorAI or Chub?

Yes. Most major front-ends read the standard V2 card spec, meaning character settings will transfer seamlessly. While proprietary features like advanced system prompt modifiers or niche extensions may not always carry over, the core character traits, descriptions, greetings, and scenarios will remain intact.

Is char-archive (or charavault) still online — where do I find cards now?

Community archives in this space change frequently, and older hubs like char-archive have gone offline. To find active cards, check community recommendations on r/SillyTavernAI, browse alternative hubs like omenarchive, or use established, well-moderated platform libraries like Chub.ai, character-tavern.com, and SpicyChat.

How do I turn a Character.AI character into a card?

Because Character.AI does not support card exports directly, you must use a dedicated browser extension like CAI Tools to download the character. This tool scans the character configuration, extracts the variables, and saves them into a compliant JSON or PNG card that can be imported into other front-ends.

What is a lorebook / character_book, and do I need one?

A lorebook is a collection of background information triggered by specific keywords in chat. When a keyword is used, the associated lore is loaded into the model's active context window. Lorebooks are optional, but they are incredibly useful for maintaining consistency in complex worlds or multi-character story settings.

Where can I download character cards for free?

All primary community archives—including Chub.ai, character-tavern.com, and aicharactercards.com (AICC)—are free to use. These directories are community-funded, meaning you can browse, share, and download cards without encountering subscription fees or purchase walls.

Explore Personalized AI Companionship With OurDream AI

Character cards demonstrate the true potential of portable companion profiles, liberating your creations from corporate systems. By moving beyond text roleplay, OurDream AI offers a secure cloud processing space that enriches character files with custom voices, deep memory, and high-fidelity visuals. Bring your creations to life and experience highly personalized virtual companionship. Register for free or choose a plan at OurDream AI Sign Up today.

Note: This article provides informational content about artificial intelligence, virtual companions, AI chat, and related technologies from OurDream AI. AI-generated conversations and content are intended for entertainment and creative interaction and should not be considered professional medical, psychological, legal, or financial advice. OurDream AI is intended for adults aged 18+.

WordsCharactersReading time
Share this article: Facebook X Reddit Pinterest