Declarative
declarative
Versioned, frontend-independent declarative tool contracts.
DeclarativeTool
Common AXMTool adapter, unavailable without an explicit host binding.
Source code in packages/axm/src/axm/tools/declarative.py
name
property
Canonical name shared by CLI, nodes and MCP.
execute(**kwargs)
Validate and invoke the host binding, never an ambient view.
Source code in packages/axm/src/axm/tools/declarative.py
DeclarativeToolDefinition
dataclass
Immutable tool metadata; schemas are detached on every access.
Source code in packages/axm/src/axm/tools/declarative.py
input_schema
property
Detached JSON Schema for functional arguments, without routing fields.
output_schema
property
Detached JSON Schema for successful ToolResult.data.
validate_input(arguments)
Reject malformed/non-JSON arguments before contacting any view.
Source code in packages/axm/src/axm/tools/declarative.py
validate_result(result)
Validate successful data; failures retain their structural signal.
Source code in packages/axm/src/axm/tools/declarative.py
DeclarativeToolManifest
dataclass
One addon bundle's closed tool declarations.
Source code in packages/axm/src/axm/tools/declarative.py
| Python | |
|---|---|
load_declarative_manifest(raw)
Validate a JSON manifest from a trusted installed package.
Extra fields, remote schema references, versions and collisions are refused. This validates metadata only: the host verifies the mounted bundle.
Source code in packages/axm/src/axm/tools/declarative.py
tool_scope_sha256(names)
Fingerprint a positive tool list; no provider-specific spelling.
Source code in packages/axm/src/axm/tools/declarative.py
validate_declarative_schema(schema)
Return a detached object schema validated offline for tools or snapshots.
Only the supported 2020-12 dialect and local references are accepted. Remote IDs/vocabularies and legacy recursive dialect keywords cannot weaken it.