Skip to main content
Glama

cache_design_with_source

Stores a design file in the cache with its OpenSCAD source code and generation prompt, so you can re-generate or tweak the model later.

Instructions

Cache a design file alongside its parametric source code.

        Stores the STL/3MF file in the design cache and attaches the
        OpenSCAD source code and generation prompt so the design can
        be re-generated or tweaked later.

        Args:
            file_path: Path to the design file (STL, 3MF, etc.).
            scad_source: OpenSCAD source code that produced this file.
            generation_prompt: The prompt used to generate the design.
            provider: Generation provider name (e.g. "openscad", "gemini").
            tags: Optional tags for search.
            filament_type: Material type (e.g. "PLA", "PETG").
        

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "file_path": "<file_path>",
      "scad_source": "<scad_source>"
    },
    "name": "cache_design_with_source"
  }
}

Input Schema

NameRequiredDescriptionDefault
tagsNoOptional tags for search.
providerNoGeneration provider name (e.g. "openscad", "gemini"). Default: "openscad".
file_pathYesPath to the design file (STL, 3MF, etc.).
scad_sourceYesOpenSCAD source code that produced this file.
filament_typeNoMaterial type (e.g. "PLA", "PETG").
generation_promptNoThe prompt used to generate the design. Default: "".

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed6 schema fields changedv1.5.1
    • addedInput schema / properties / filament_type / description
      Added value: +"Material type (e.g. \"PLA\", \"PETG\")."
    • addedInput schema / properties / file_path / description
      Added value: +"Path to the design file (STL, 3MF, etc.)."
    • changedInput schema / properties / generation_prompt / description
      Previous value: -"Default: \"\"."New value: +"The prompt used to generate the design. Default: \"\"."
    • changedInput schema / properties / provider / description
      Previous value: -"Default: \"openscad\"."New value: +"Generation provider name (e.g. \"openscad\", \"gemini\"). Default: \"openscad\"."
    • addedInput schema / properties / scad_source / description
      Added value: +"OpenSCAD source code that produced this file."
    • addedInput schema / properties / tags / description
      Added value: +"Optional tags for search."
  2. Changed6 schema fields changedv1.5.0
    • removedInput schema / properties / filament_type / default
      Removed value: -null
    • removedInput schema / properties / generation_prompt / default
      Removed value: -""
    • addedInput schema / properties / generation_prompt / description
      Added value: +"Default: \"\"."
    • removedInput schema / properties / provider / default
      Removed value: -"openscad"
    • addedInput schema / properties / provider / description
      Added value: +"Default: \"openscad\"."
    • removedInput schema / properties / tags / default
      Removed value: -null
  3. First observedv0.1.0

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=false, destructiveHint=false, and openWorldHint=false, so the agent knows this is a local, non-destructive write. The description adds what gets stored (STL/3MF plus SCAD source and prompt) and why, but is silent on overwrite/dedup behavior if the same design is cached twice, and on what identifier or result comes back.

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

Conciseness3/5

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

The opening two sentences are well front-loaded, but the six-line Args list restates the input schema word for word and earns no place in the description. Trimming it would remove roughly half the text with no information loss.

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?

For a six-parameter local write with full schema coverage and annotations, the description covers what is stored and why. The one real omission is the return value or cache key, which matters because retrieval happens via siblings like get_cached_design, but with no output schema this is a moderate rather than severe gap.

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 Args block reproduces each parameter description nearly verbatim, adding no new meaning. Baseline 3 applies since the schema carries the parameter semantics on its own.

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

Purpose4/5

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

The description names a specific verb and resource: caching a design file together with its parametric source. The phrase 'so the design can be re-generated or tweaked later' clarifies intent beyond a plain store operation. It does not, however, distinguish this tool from the sibling 'cache_design' or 'cache_model', which an agent would need to disambiguate.

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

Usage Guidelines3/5

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

Usage context is implied by the rationale of preserving source for later regeneration, but there is no explicit 'use this when X, use cache_design when Y' guidance nor any mention of prerequisites such as the file existing locally or having been generated by a tracked provider. With several near-identical caching siblings, this is a meaningful gap.

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

Deploy Server

Other Tools