Skip to main content
Glama

Export Solution as Markdown

export_markdown
DestructiveIdempotent

Render a cached C# solution analysis session as AI-Builder Markdown, optionally writing to a file to avoid oversized MCP responses.

Instructions

Render the cached analysis of a session as AI-Builder Markdown. No re-analysis - instant. NOTE: this renders the WHOLE solution - on a large codebase that is many megabytes, and an answer over the server's message ceiling (16,000,000 bytes as JSON unless AICB_MCP_MAX_RESPONSE_BYTES says otherwise) is not sent: the call is refused with its size, because MCP clients drop larger messages. Pass outputPath for anything but a small solution. For a bounded view prefer architecture_overview (whole-solution orientation, structural-only, no per-type source) or get_context / explain_symbol (one symbol's world). When the server has a config DB (the default: a plain 'aicb mcp' resolves the standard one), the active MCP profile drives the render: the chosen facet's template (detail presets, graphs, line numbers, quality metrics) is used; otherwise the full default render is used. Returns the Markdown; if outputPath is given it writes the file and returns a short confirmation (not the full content), so a large render does not flood the response.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
facetNoOptional facet to render through - the task axis of this call: General (default), Exploration, Refactoring, Debugging, Review, Testing, Documentation, Architecture, or Performance. The facet picks the active MCP profile's matching template and appends a short work-style trailer with suggested next tools. Unknown/empty falls back to General; a facet whose slot has no template assigned falls back to the active context template. (The former name 'slot' is still accepted.)
formatNoOptional inner notation of the rendered Markdown: 'tag' (the established AI-Builder tag format) or 'yaml' (idiomatic YAML - a lossless re-notation, not a different selection of content). Pick whichever notation you parse more reliably. When given, this explicit value wins; when omitted, the active MCP profile's OutputFormat is used (profile-aware path), else yaml (the DB-free default). The .md branding is unchanged. Any other value counts as omitted: the profile's format (else yaml) applies, and the response starts with a note naming the ignored value.
sessionIdYesThe session_id returned by analyze_solution. Also takes an absolute .sln/.slnx/.slnf path, analyzed on first use.
outputPathNoOptional absolute path to write the Markdown to (UTF-8, no BOM). When given, the tool writes the file and returns a short confirmation (path + size) instead of the full markdown - so a large (whole-solution) render does not flood the response.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.5.46514
    • changedInput schema / properties / format / description
      Previous value: -"Optional inner notation of the rendered Markdown: 'tag' (the established AI-Builder tag format) or 'yaml' (idiomatic YAML - a lossless re-notation, not a different selection of content). Pick whichever notation you parse more reliably. When given, this explicit value wins; when omitted, the active MCP profile's OutputFormat is used (profile-aware path), else yaml (the DB-free default). The .md branding is unchanged; an unrecognized explicit value falls back to tag."New value: +"Optional inner notation of the rendered Markdown: 'tag' (the established AI-Builder tag format) or 'yaml' (idiomatic YAML - a lossless re-notation, not a different selection of content). Pick whichever notation you parse more reliably. When given, this explicit value wins; when omitted, the active MCP profile's OutputFormat is used (profile-aware path), else yaml (the DB-free default). The .md branding is unchanged. Any other value counts as omitted: the profile's format (else yaml) applies, and the response starts with a note naming the ignored value."
  2. Changed1 schema field changedv0.5.46513
    • changedInput schema / properties / sessionId / description
      Previous value: -"The session_id returned by analyze_solution."New value: +"The session_id returned by analyze_solution. Also takes an absolute .sln/.slnx/.slnf path, analyzed on first use."
  3. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations declare readOnlyHint=false, destructiveHint=true, and idempotentHint=true, so the write profile is already partly known; the description still adds real value by disclosing the 16,000,000-byte response ceiling, the refusal-with-size behavior, the profile-driven rendering path, and the file-vs-inline return difference. The main gap is that it never warns that writing outputPath overwrites an existing file, which is exactly the behavior destructiveHint=true implies.

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?

It is front-loaded with purpose before constraints, and the long size-ceiling and profile-fallback sentences each carry operational information. It is on the verbose side and could be tightened, but nothing is pure filler.

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

Completeness4/5

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

With no output schema, the description correctly explains return values (Markdown content vs a short confirmation when outputPath is set) and covers defaults, fallbacks, size limits, and alternatives. Only the overwrite/destructive side of writing outputPath is left implicit, which matters given destructiveHint=true.

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%, so the schema already documents facet, format, sessionId, and outputPath in detail (including fallbacks and accepted path forms). The description mostly restates those semantics ('the chosen facet's template ... is used'), adding only the practical hint to use outputPath for anything but a small solution, so baseline 3 is appropriate.

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 gives a specific verb and resource ('Render the cached analysis of a session as AI-Builder Markdown') and immediately adds the distinguishing trait 'No re-analysis - instant.' It also names the sibling tools that serve adjacent needs (architecture_overview, get_context, explain_symbol), so an agent can separate this from other export/overview tools without opening a schema.

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?

It states explicit routing conditions: 'Pass outputPath for anything but a small solution', and 'For a bounded view prefer architecture_overview ... or get_context / explain_symbol'. When-not conditions are also covered via the size-ceiling refusal for whole-solution renders.

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