Character consistency

From event4u-app/agent-config · View interactive version

Character consistency is an AI agent skill from the GitHub repository event4u-app/agent-config. Use when a character must stay visually identical across AI video scenes — locks identity tokens (silhouette, palette, wardrobe, prop) in JSON. Triggers 'character lock', 'same character'.

How to use this skill

Skill file

character-consistency

Lock a character's visual identity into

agents/reference/ai-video/<project>/characters/<id>.json so every scene

reuses the exact same tokens verbatim. Downstream skills

(CODE0,

CODE0,

CODE0) read

this file and never paraphrase. The verbatim tokens are the control:

no script compares rendered frames against the reference frame, and a

pixel-similarity threshold would be the wrong measure if one did — a pose,

framing or lighting change moves most pixels while the identity holds.

When to use

once — Character Lock is mandatory before the second scene drafts.

scenes) — re-lock and rerun the affected scenes.

Do NOT use when:

entity) — use a style.json lock pattern in the project's notes

instead. Recurring creatures, vehicles, and hero objects DO get a

real lock — pick the matching subject_class below.

Procedure

Step 0: Inspect

  1. Check agents/reference/ai-video/<project>/characters/ — if a lock already

exists for this id, read it, do not redraft. Edits require an

explicit revision note (and a by-eye re-review of the scenes that used

the old version — see Gotcha).

  1. Confirm the character will appear in ≥ 2 scenes; one-shot → skip.

Step 1: Draft identity tokens

Emit a JSON file at

agents/reference/ai-video/<project>/characters/<character-id>.json with the

following fields. Every field is mandatory; missing field → fail

the lock.

{
  "id": "kebab-case-id",
  "name": "Display Name",
  "subject_class": "humanoid | creature | vehicle | abstract | object",
  "silhouette": "one-line read of the body shape from 30m",
  "palette": ["#hex1", "#hex2", "#hex3"],
  "wardrobe": "garment list, materials, era",
  "signature_prop": "the one object that travels with them",
  "posture_default": "how they stand when not acting",
  "eye_behavior": "blink rhythm, glance habit",
  "face": "age band, skin tone, hair (length / color / texture), distinguishing marks",
  "voice_note": "timbre + cadence for native-audio adapters; null if N/A",
  "reference_frame": "scenes/<id>/frames/<n>.png or null",
  "version": 1
}
Subject-class token matrix

Field NAMES are fixed (downstream consumers extract them verbatim);

their SEMANTICS shift per subject_class. Missing subject_class →

humanoid (back-compat with existing locks). The blueprint layer

stays subject-agnostic on purpose — it only consumes the rendered

SUBJECT string; class semantics live here, in the one file the

drafting agent reads.

| Field | humanoid | creature | vehicle | abstract | object |

|---|---|---|---|---|---|

| silhouette | body shape from 30m | body shape + locomotion read | hull/body outline | dominant form | outline + scale cue |

| wardrobe | garments, materials, era | integument: fur / scales / skin texture + markings | body panels, livery, decals, wear | motif / texture field | surface finish, material, wear |

| signature_prop | the object that travels with them | anatomical signature (horn, tail tuft, scar) | hood ornament / aerial / charm | recurring sub-form | defining attachment or mark |

| posture_default | how they stand | gait + resting stance | stance / ride attitude | motion signature | resting pose / orientation |

| eye_behavior | blink rhythm, glance habit | eye/ear behavior | lighting signature (headlights, dash glow) | pulse / emission rhythm | highlight + reflection behavior |

| face | age band, skin, hair, marks | head anatomy (muzzle, eyes, dentition) | front fascia (grille, lights) | focal form | defining front / face side |

| voice_note | timbre + cadence | vocalization | engine / motion sound | sound signature | interaction sound |

Universal slots (id, name, palette, reference_frame,

version) keep one meaning across all classes.

Worked example — creature:

{
  "id": "moor-wyrm",
  "name": "Moor Wyrm",
  "subject_class": "creature",
  "silhouette": "low six-limbed serpentine bulk, head held below shoulder line",
  "palette": ["#2e4a3f", "#c9b458", "#1a1a1a"],
  "wardrobe": "moss-green plated scales, gold-flecked underbelly, mud-matted ridge fur",
  "signature_prop": "broken left tusk capped with a brass ring",
  "posture_default": "coiled low, weight on forelimbs, tail tip always moving",
  "eye_behavior": "slow horizontal nictitating blink; ears flatten before lunges",
  "face": "blunt muzzle, four-nostril ridge, amber eyes with horizontal pupils",
  "voice_note": "sub-bass rumble with clicking overtones; null if scenes are scored only",
  "reference_frame": null,
  "version": 1
}

Step 2: Reference frame

  1. After the first scene renders, copy the highest-quality frame

showing the character full-face and full-body to

agents/reference/ai-video/<project>/characters/<id>.ref.png.

  1. Update reference_frame in the JSON to point at it.
  2. The reference frame is what a reviewer holds each later scene

against, side by side, by eye. Nothing runs that comparison

automatically, and no pixel threshold stands in for it: a ≥ 95 %

ImageMagick compare would fail on any change of pose and pass a

changed prop at the same pose, so it is not a check of identity.

Step 3: Validate

  1. JSON parses (jq . characters/<id>.json exits 0).
  2. All mandatory fields present and non-empty.
  3. subject_class (when present) is one of `humanoid | creature |

vehicle | abstract | object`; each field reads per the matrix row

for that class — a creature lock with a garment list in wardrobe

is a drafting error, not a style choice.

  1. Palette has ≥ 2 and ≤ 5 hex values.
  2. Downstream skills cite this file by path, never paraphrase its

contents.

Output format

  1. agents/reference/ai-video/<project>/characters/<id>.json — locked

identity tokens, schema above.

  1. agents/reference/ai-video/<project>/characters/<id>.ref.png —

reference frame (added after first render).

  1. agents/reference/ai-video/<project>/characters/CHANGELOG.md — one

line per revision: v<n> · YYYY-MM-DD · reason · scenes-to-rerun.

Gotcha

downstream — the lock is structurally weaker and nobody can tell.

Always set the class for non-humanoid subjects.

this is the silent drift failure. Tokens are immutable until a

revision note bumps version.

closed set (2–5 hex).

the schema validator.

not before — bootstrap scenes have no reference and only the

JSON locks them.

the old version to be reviewed again against the new reference —

by a reviewer; nothing reruns it on its own.

Do NOT

copy verbatim or break the lock.

adding a CHANGELOG line.

side-by-side review has nothing to compare against.

Policies

Paths, enforcement model, and the full set: the

media policy preamble.

When a character lock would identify or render a real person, consult before emitting the JSON:

Refuse-and-surface the file path; do not silently sanitise the prompt.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.