Skip to main content
Glama

myco_graft

List, validate, or explain plugins to debug loading issues and audit registrations. Uses --list, --validate, --explain, and --list-substrates modes.

Instructions

Introspect the substrate's plugin surface: list every loaded dimension / adapter / schema_upgrader / overlay_verb with (kind, name, source, scope), validate plugins by re-importing under isolation, or explain a single plugin (source path + docstring). Scope classifies each plugin as 'kernel' (shipped with myco package) or 'substrate' (loaded from /.myco/plugins/).

Use this when: debugging "why is my plugin not loading", auditing what's actually registered, or listing substrates across the machine (--list-substrates mode, reads ~/.myco/substrates.yaml). Do NOT confuse with myco_immune's dimension-listing mode — graft inspects plugin binaries, immune inspects findings.

Side effects: none. Pure read. --validate mode does re-import plugins, which executes their init.py; the execution occurs in an isolated module namespace and is idempotent — safe even for plugins that register into global registries.

Returns (by mode). --list: { exit_code, mode:'list', plugins: [...], count }. --validate: { exit_code, mode: 'validate', errors: [...] }. --explain: { exit_code, mode: 'explain', name, kind, source, scope, docstring }. --list-substrates: { exit_code, mode:'list-substrates', substrates: [...], count, live_count, stale_count }.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
listNoWhen true, enumerate every plugin currently loaded in this substrate's registry (kernel + substrate-local). Returns one row per plugin with kind + name + source (file path) + scope (kernel|substrate). Mutually exclusive with validate / explain / list-substrates.
validateNoWhen true, re-import every substrate-local plugin in isolation and collect any exceptions. Used to sanity-check plugins after editing. Mutually exclusive with list / explain / list-substrates.
explainNoWhen set, return the source path + docstring + kind for the named plugin. Pass the plugin's registered name (e.g. 'M1' for a dimension, 'UrlFetcher' for an adapter). Unknown names raise UsageError. Mutually exclusive with list / validate / list-substrates.
list_substratesNov0.5.16: list every substrate registered on this machine (reads ~/.myco/substrates.yaml), sorted by last-seen-at. Returns stale entries (exists=false) whose on-disk path no longer has a _canon.yaml for cleanup insight. Mutually exclusive with list / validate / explain.
project_dirNoAbsolute path of the workspace / project whose Myco substrate this call targets. Overrides auto-discovery. When omitted, Myco resolves via MCP roots/list, then MYCO_PROJECT_DIR, then cwd — the substrate_pulse field in every response echoes which source answered.
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so description bears full burden. It declares 'Side effects: none. Pure read.' and explains validate mode's idempotent re-import with isolated namespace. Return shapes per mode are specified.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Well-structured with clear sections and bullet-point returns. Slightly long but every part adds value. A small trim could be possible but current form is effective.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given 5 parameters, no output schema, and 4 modes, the description covers side effects, safety, and all return types. Scope classification is explained. Highly complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% and the description does not add significant new meaning beyond what the schema already provides. The description summarizes mode behavior but is largely redundant with schema comments.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with 'Introspect the substrate's plugin surface' and lists specific plugin types. It distinguishes from sibling tool myco_immune. The verb+resource is highly specific.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly states use cases: debugging plugin loading, auditing registrations, listing substrates. Includes a clear warning not to confuse with myco_immune, providing strong differentiation.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Battam1111/Myco'

If you have feedback or need assistance with the MCP directory API, please join our Discord server