Skip to content

Entity Naming Guide

Naming conventions for semantic IDs, positions, routes, and zones. Follow these patterns so that agents, choreographies, and bindings can reference scene elements consistently.

Semantic IDs (actor names)

The semanticId is how choreographies and agents target an entity. It's the entity's role, not its type.

Pattern: role-qualifier

Use kebab-case. The first segment is the role category, the second segment qualifies it.

PatternExampleWhen to use
roleagentSingle entity with that role in the scene
role-qualifieragent-mainMultiple entities of the same role
role-locationdoor-kitchenEntity defined by where it is
role-functionindicator-statusEntity defined by what it does
role-Nguard-1, guard-2Numbered instances of the same role

Role categories

Common role prefixes and their intent:

Role prefixDescriptionExamples
agentAI agent representationagent, agent-main, agent-research
workerTask executor (NPC-like)worker, worker-forge, worker-1
doorOpenable passagedoor-kitchen, door-main, door-vault
indicatorStatus displayindicator-status, indicator-progress, indicator-error
machineProcess/toolmachine-forge, machine-press, machine-scanner
panelInformation displaypanel-dashboard, panel-log, panel-chat
lightLight source entitylight-forge, light-entrance, light-alarm
npcNon-player characternpc-merchant, npc-guard, npc-guide
fxVisual effectfx-spark, fx-smoke, fx-glow
propInteractive objectprop-lever, prop-chest, prop-switch

Rules

  • kebab-case onlyagent-main, not agentMain or Agent_Main
  • Role first — the role is more important than the qualifier: door-kitchen not kitchen-door
  • Unique per scene — each semanticId must be unique. Multiple entities can share the same semanticId for group targeting: a choreography step targeting a shared ID will animate all instances simultaneously.
  • No entity type — use the role, not the sprite name: worker not peon, machine-forge not building-forge-sprite
  • Short and scannable — 2 segments max. If you need 3, reconsider: agent-main-backupbackup-agent

Decoration (no semanticId)

Passive elements that don't participate in choreographies have no semanticId. They are placed for visual richness:

  • Trees, grass, rocks, fences
  • Background buildings
  • Floor tiles, wall segments
  • Ambient particles

Use list_entities(filter: 'decoration') to see them, list_entities(filter: 'actors') to skip them.


Positions (waypoints)

Positions are named locations on the scene that choreographies reference as movement targets.

Pattern: area-role or descriptive noun

PatternExampleWhen to use
nounforge, entrance, exitUnique landmark
area-functionkitchen-counter, lab-benchPosition within a zone
spawn-qualifierspawn-agent, spawn-npcEntry points
idle-qualifieridle-agent, idle-workerDefault rest positions
queue-Nqueue-1, queue-2Ordered waiting spots

Type hints

Every position has a typeHint that signals its purpose:

typeHintNaming conventionExamples
spawnspawn-*spawn-agent, spawn-worker, spawn-fx
destinationdescriptive nounforge, workstation, exit
waypointvia-* or route contextvia-corridor, via-bridge
genericanycenter, stage-left, balcony

Routes (paths)

Routes are named paths that entities follow during choreographed movement.

Pattern: from-to or descriptive-path

PatternExampleWhen to use
from-toentrance-to-forgeClear A→B route
descriptivepatrol-perimeterLoop or abstract path
role-pathworker-commutePath tied to a specific role

Rules

  • Routes link to positions via fromPositionId and toPositionId when applicable
  • Bidirectional routes (bidirectional: true) don't need from-to naming — use a descriptive name
  • Use sharp corner style for indoor/structured paths, smooth for organic/outdoor paths

Zones (spatial regions)

Zone types define semantic regions of the scene.

Built-in zone types

Zone typeDescriptionUse
CommandDecision-making areaAgent headquarters, control rooms
ProductionWork/processing areaForges, workshops, labs
PerimeterBoundary areaWalls, fences, patrol paths
StorageResource holding areaWarehouses, shelves, inventories
TransitMovement corridorHallways, bridges, roads

Custom zone types

Follow the same pattern: capitalized singular noun with a short description.


Choreography naming

Choreographies don't have explicit names in the MCP tool (they get a UUID), but the on field (trigger signal type) and the when filter effectively name the behavior.

Pattern: signal type + filter = behavior identity

on: "tool_call"                          → general tool-call choreography
on: "tool_call", when: { toolName: "Read" } → specific Read-tool choreography
on: "agent_state_change"                 → agent state transitions
on: "task_dispatch"                      → new task arrival animation

When describing choreographies to other agents or in documentation, use the pattern: signal-type → entity-role → behavior

Example: "tool_call → agent → walk-to-workstation-and-flash"


Quick reference

ElementConventionExample
semanticIdkebab-case, role-firstagent-main, door-kitchen
Position namedescriptive noun or area-functionforge, spawn-agent
Route namefrom-to or descriptiveentrance-to-forge, patrol-loop
Zone typeCapitalized singular nounCommand, Production
Signal typesnake_casetool_call, task_dispatch
Choreography actioncamelCasemove, setAnimation, playSound
Entity type (entityId)kebab-casepeon, building-townhall

Key files

  • packages/mcp-server/src/tools/place-entity.ts — entity placement with semanticId
  • packages/mcp-server/src/tools/list-entities.ts — entity roster (actors vs decoration)
  • tools/scene-builder/src/types.ts — PlacedEntity, ScenePosition, SceneRoute types
  • packages/mcp-server/src/tools/update-entity.ts — entity property updates
  • packages/mcp-server/src/tools/set-entity-state.ts — animation state shortcut