Skip to main content
Glama

import_takeoff

Loads a prior takeoff_canvas.v1 export into the current session, merging conditions and shapes under the app's tested import rules so you can resume or audit an existing takeoff.

Instructions

The way BACK IN (#151): load an "opentakeoff.takeoff_canvas.v1" file — a prior export_takeoff, or the app's own save — into this session, through the SAME tested merge rules as the app's Sheet-menu import: finish-tag identity joins imported conditions onto this session's own (their knobs win), new ids append, duplicate ids skip (re-import is idempotent), and THIS session's calibration wins per sheet. An uncalibrated empty session adopts the file wholesale. New dimensional shapes refuse atomically if their source scale differs from the session calibration or is missing; align scales and re-export, or use a fresh session. Counts and duplicate IDs are exempt. Legacy agent traces without review flags arrive reviewed:false. Resume yesterday's work, extend a takeoff a human already reviewed (their ink stays ink — reviewed shapes arrive untouchable by agent verbs), or audit someone else's export with list_shapes/takeoff_summary. Requires a loaded plan; shapes referencing OTHER files ride along and count in totals but can't be viewed against this document — the reply's unknown_files names them. Approval marks ride the file too — transport, not minting: an estimator seal arriving by import stays estimator ink, listable but untouchable here. undo_last removes the imported SHAPES as one step; adopted conditions, scales, annotations, and approval marks stay.

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": {
      "path": "<path>"
    },
    "name": "import_takeoff"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYesPath to a takeoff_canvas.v1 JSON file on disk

Output Schema

NameRequiredDescriptionDefault
fileYesBasename of the imported file
noteYes
replacedYestrue = the session was empty and adopted the file wholesale
shapes_addedYes
shapes_totalYes
unknown_filesYesFiles referenced by imported shapes that this document doesn't have — they count in totals but can't be viewed here
rules_importedYesCorrection rules (#88) that arrived with the file — apply_rules re-runs them
scales_adoptedYesSheets whose calibration came from the file (this session's own always wins)
shapes_pendingYesOf the added shapes, how many are unreviewed machine pencil
conditions_addedYes
conditions_mergedYesImported conditions that joined an existing finish tag (its knobs won)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed15 schema fields changedv0.1.31
    • removedInput schema / additionalProperties
      Removed value: -false
    • addedOutput schema / properties / conditions_added / maximum
      Added value: +9007199254740991
    • addedOutput schema / properties / conditions_added / minimum
      Added value: +-9007199254740991
    • addedOutput schema / properties / conditions_merged / maximum
      Added value: +9007199254740991
    • addedOutput schema / properties / conditions_merged / minimum
      Added value: +-9007199254740991
    • addedOutput schema / properties / rules_imported / maximum
      Added value: +9007199254740991
    • addedOutput schema / properties / rules_imported / minimum
      Added value: +-9007199254740991
    • addedOutput schema / properties / scales_adopted / maximum
      Added value: +9007199254740991
    • addedOutput schema / properties / scales_adopted / minimum
      Added value: +-9007199254740991
    • addedOutput schema / properties / shapes_added / maximum
      Added value: +9007199254740991
    • addedOutput schema / properties / shapes_added / minimum
      Added value: +-9007199254740991
    • addedOutput schema / properties / shapes_pending / maximum
      Added value: +9007199254740991
    • addedOutput schema / properties / shapes_pending / minimum
      Added value: +-9007199254740991
    • addedOutput schema / properties / shapes_total / maximum
      Added value: +9007199254740991
    • addedOutput schema / properties / shapes_total / minimum
      Added value: +-9007199254740991
  2. Changed2 schema fields changedv0.1.15
    • addedOutput schema / properties / rules_imported
      Added value: +{
      +  "description": "Correction rules (#88) that arrived with the file — apply_rules re-runs them",
      +  "type": "integer"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "file",
      -  "replaced",
      -  "shapes_added",
      -  "shapes_pending",
      -  "conditions_merged",
      -  "conditions_added",
      -  "scales_adopted",
      -  "unknown_files",
      -  "shapes_total",
      -  "note"
      -]New value: +[
      +  "file",
      +  "replaced",
      +  "shapes_added",
      +  "shapes_pending",
      +  "conditions_merged",
      +  "conditions_added",
      +  "scales_adopted",
      +  "unknown_files",
      +  "rules_imported",
      +  "shapes_total",
      +  "note"
      +]
  3. Addedv0.1.9

TDQS

A4.7/5.0
Behavior5/5

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

With no annotations, the description carries the full burden and does so: it discloses the merge rules (finish-tag joins, their knobs win, new ids append, duplicate ids skip, idempotent re-import), that this session's calibration wins per sheet, that uncalibrated empty sessions adopt wholesale, and that scale-mismatched dimensional shapes refuse atomically while counts and duplicate IDs are exempt. It also spells out post-import semantics: approval marks are transported not minted, imported shapes are untouchable by agent verbs, and undo_last removes the shapes but leaves adopted conditions, scales, annotations, and marks.

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 action is front-loaded, but the body is one dense paragraph dense with parentheticals and asides ("#151", "transport, not minting") that make it harder to scan than the content warrants. Almost every clause carries information, but the framing and embedded editorializing cost readability.

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?

For a high-stakes import with destructive-adjacent side effects, the description covers prerequisites, merge semantics, refusal conditions, and undo scope; with an output schema present it needn't describe return shape, yet it still flags that unknown_files in the reply names shapes referencing other files. Nothing an agent needs before calling is missing.

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

Parameters4/5

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

The single parameter is fully documented in the schema, so the baseline is 3; the description adds real meaning by identifying what the file actually is (a prior export or the app's own save, in the takeoff_canvas.v1 format). It does not add path syntax, relative-vs-absolute rules, or size expectations, so it falls short of a 5.

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?

States a specific verb and resource: load an "opentakeoff.takeoff_canvas.v1" file into this session, and names its origin (a prior export_takeoff or the app's own save). This clearly separates it from the export_takeoff sibling and from list_shapes/takeoff_summary, which it explicitly frames as audit tools.

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?

Gives three concrete use cases (resume yesterday's work, extend a human-reviewed takeoff, audit someone else's export) plus a stated prerequisite (a loaded plan) and an exclusion with the remedy: if source scales mismatch, align scales and re-export or use a fresh session. Alternatives are named rather than implied.

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