agentleFS
chellehonikerchellehoniker/claude-code-storytelleros/skills/mentions/SKILL.md

mentions

Skill1 starsChanged 13 days agoMITView on GitHub

Use when the user wants to link scene prose to Codex entries (characters, locations, lore): adding @-mentions explicitly, auto-detecting which characters appear in a scene, or asking "where does X show up in this book?" Triggers on "tag Quinn in this scene", "auto-detect characters", "find every scene the lighthouse appears in", "which characters are in chapter 3", "re-run mention detection".

The file

We split this skill into the rules it gives an agent

5 rules. About 0 are common, 2 are distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Every scene carries a list of mentions — typed pointers from the scene to a Codex entry (character / location / lore / event).

    line 10
  2. Distinctive:

    Call this after the writer edits the scene prose, or backfill across an existing manuscript by looping over every scene in a title.

    line 59
  3. Very specific:

    If the writer removed an @-chip, delete its row by id.

    line 67
  4. Very specific:

    Forgetting aliases: If a character is "Quinn O'Hara" in the Codex but the prose calls her "Quinn", the detector won't match unless aliases …

    line 81
  5. Very specific:

    Mixing source in stos_mentions_create: Leave source as the default manual.

    line 84

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Mentions

What this is

Every scene carries a list of mentions — typed pointers from the scene to a Codex entry (character / location / lore / event). Two sources:

SourceHow it's createdWhen the detector touches it
manualThe writer placed an @-chip in the editor, or this skill called it.Never — manual wins.
auto-detectedThe server alias-matched the scene's prose against the Codex.Rewritten every detect run.

The detector also skips any entity that already has a manual mention in the same scene — so a character explicitly tagged once stays tagged exactly once, even if the prose says their name twenty times.

Aliases drive detection. A character "Quinn O'Hara" with aliases: ['Quinn', 'Q', 'Captain Quinn'] will match all four spellings; word-boundary regex (so "Quinn" doesn't match "Quinnipiac"). Set aliases via stos_characters_update({ id, fields: { aliases: [...] } }) (same for locations and lore).

Flow: list mentions for a scene

stos_mentions_list({ sceneId })

Returns each mention with entity_type, entity_id, text_position, matched_text, source.

Flow: list every scene a character appears in

stos_mentions_list({ entityId: characterId, entityType: 'character' })

Useful for "which scenes does Quinn appear in" or building a per-character timeline.

Flow: create a manual mention

stos_mentions_create({
  scene_id: '...',
  entity_type: 'character',
  entity_id: '...',
  text_position: 1284,           // optional — char offset into the draft
  matched_text: 'Quinn',         // optional — the literal text the chip points at
})

source defaults to manual. The mention is unique per (scene_id, entity_type, entity_id, text_position) so calling twice at the same offset is a no-op.

Flow: run alias detection for a scene

stos_mentions_detect({ scene_id })

Wipes the scene's existing auto-detected rows, re-runs alias matching against the scoped Codex (characters in this series + locations/lore in this series or this title), and writes a fresh set. Manual mentions are untouched. Returns { scene_id, detected: <count>, mentions: [...] }.

Call this after the writer edits the scene prose, or backfill across an existing manuscript by looping over every scene in a title.

Flow: delete a mention

stos_mentions_delete({ id })

If the writer removed an @-chip, delete its row by id. To clear all auto-detected rows for a scene, run stos_mentions_detect after wiping aliases — easier than batch-deleting.

When to use this vs. worldbuilding

SituationSkill
Add a new character / location / lore entryworldbuilding
Set or update aliases on an existing entryworldbuilding
Tag an entry inside a scenementions
Re-scan a scene's prose for entity referencesmentions
"Where does Quinn appear?"mentions

Anti-patterns

  • Forgetting aliases. If a character is "Quinn O'Hara" in the Codex but the prose calls her "Quinn", the detector won't match unless aliases includes Quinn. Add the alias once via stos_characters_update and re-run detect.
  • Running detect on every keystroke. The detector wipes and rewrites; debounce ~800ms client-side, or batch on save.
  • Tagging an event and expecting auto-detect. Events have no aliases column today. Manual mentions work; auto-detect skips them.
  • Mixing source in stos_mentions_create. Leave source as the default manual. The auto-detected source is reserved for the detector; setting it manually muddies the "manual wins" rule.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.