an.mcp.tools#
The curated MCP tools: plain functions over the vocabulary, the capability registry and a project.
ADR 0003 decision 6: the MCP surface is a curated list, not all of
_dispatch_funcs. Each tool here is an ordinary function with simple,
JSON-shaped arguments and results (so py2mcp can project it, and a test
can call it without any MCP stack):
queries —
vocabulary(),vocabulary_entry(),scene_schema(),validate_scene(),describe_character(),applicable_methods(),why_not_method();edits —
apply_patch(), a typed JSON-pointer patch (thean iteratepatch shape), validated before anything is written,dry_runby default;long work as jobs —
start_render()returns a job id at once andjob_status()polls it; nothing blocks a client for minutes. The benchstays CLI-only.
Every tool loads the installed genres first (explicit discovery, ADR 0001 decision 3): their presets, methods and analysers are part of the answer.
>>> any(e["id"] == "action.tween" for e in vocabulary(kind="action"))
True
Module Attributes
The curated surface, in the order a client lists it. |
Functions
|
The methods of |
|
Apply typed JSON-pointer patches to the scene, validated before anything is written. |
|
What a character affords, and per aspect the default method, the applicable ones, and the missing capabilities (with remedies) of the rest. |
|
A job's state: |
|
The JSON Schema of a document: |
|
Start rendering the project to an mp4; returns |
|
Validate the project's scene (schema and semantics): |
|
Every registered vocabulary entry (presets, kinds, easings, camera moves, methods, IR fields). |
|
One vocabulary entry by id ( |
|
What the character lacks for |
- an.mcp.tools.TOOLS: tuple = (<function vocabulary>, <function vocabulary_entry>, <function scene_schema>, <function validate_scene>, <function describe_character>, <function applicable_methods>, <function why_not_method>, <function apply_patch>, <function start_render>, <function job_status>)#
The curated surface, in the order a client lists it.
- an.mcp.tools.applicable_methods(aspect, project_dir, name)[source]#
The methods of
aspect(locomotion,speech, …) that apply to the character.
- an.mcp.tools.apply_patch(project_dir, patches, dry_run=True)[source]#
Apply typed JSON-pointer patches to the scene, validated before anything is written.
patchesare{op: set|append|delete, path: "timeline/0/duration", value: …}(thean iteratepatch shape). The patched scene is validated (schema and semantics); withdry_run=Falseand a passing validation it is saved through the scenes store (scene.mdandir/scene.jsonstay in step) and the edit is recorded in the decisions log.
- an.mcp.tools.describe_character(project_dir, name)[source]#
What a character affords, and per aspect the default method, the applicable ones, and the missing capabilities (with remedies) of the rest.
- an.mcp.tools.job_status(job)[source]#
A job’s state:
running,done(with itsresult) orfailed(with itserror).
- an.mcp.tools.scene_schema(document='scene')[source]#
The JSON Schema of a document:
scene(the scene IR) orcharacter(a descriptor).
- an.mcp.tools.start_render(project_dir, strict_assets=False, output_name='main')[source]#
Start rendering the project to an mp4; returns
{job}at once — polljob_status().
- an.mcp.tools.validate_scene(project_dir)[source]#
Validate the project’s scene (schema and semantics):
{passed, findings}.
- an.mcp.tools.vocabulary(kind='', owner='')[source]#
Every registered vocabulary entry (presets, kinds, easings, camera moves, methods, IR fields).
Each entry: id, kind, name (how a document spells it), version, title, description, accepted spectrum levels, params (JSON Schema with defaults), examples, requires.
kindfilters (motion_preset,method, …),ownerfilters by who registered it (an, a genre).