Skip to main content
Glama

Link files to a task or a note

link_files

Attach file paths or URLs to a task or note so todox can track them, warn when linked files on this machine change, and find the task or note from any path.

Instructions

Attach file paths to a task (task_id) or a note (context_id), one or the other -- the files the work touches, and the plan it follows, wherever that lives: a path outside the repository is fine and a URL (a claude.ai artifact, say) is kept as written. todox can then warn when a linked file on this machine changes (a URL is never checked), and get_file_context can find the task or note from the path.

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": {
      "paths": "<paths>"
    },
    "name": "link_files"
  }
}

Input Schema

NameRequiredDescriptionDefault
modelNoYour model id, e.g. 'claude-opus-5'.
pathsYes
task_idNo
context_idNoAttach the files to a context note instead of a task. Pass one or the other.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed8 schema fields changedv0.1.8
    • addedInput schema / properties / context_id / anyOf
      Added value: +[
      +  {
      +    "maximum": 9007199254740991,
      +    "minimum": -9007199254740991,
      +    "type": "integer"
      +  },
      +  {
      +    "pattern": "^\\d{1,15}$",
      +    "type": "string"
      +  }
      +]
    • removedInput schema / properties / context_id / maximum
      Removed value: -9007199254740991
    • removedInput schema / properties / context_id / minimum
      Removed value: --9007199254740991
    • removedInput schema / properties / context_id / type
      Removed value: -"integer"
    • addedInput schema / properties / task_id / anyOf
      Added value: +[
      +  {
      +    "maximum": 9007199254740991,
      +    "minimum": -9007199254740991,
      +    "type": "integer"
      +  },
      +  {
      +    "pattern": "^\\d{1,15}$",
      +    "type": "string"
      +  }
      +]
    • removedInput schema / properties / task_id / maximum
      Removed value: -9007199254740991
    • removedInput schema / properties / task_id / minimum
      Removed value: --9007199254740991
    • removedInput schema / properties / task_id / type
      Removed value: -"integer"
  2. First observedv0.1.4

TDQS

A4.2/5.0
Behavior4/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 substantial work: it discloses that paths outside the repository are accepted, that URLs are preserved verbatim and never change-checked, that linking triggers change warnings on this machine, and that `get_file_context` can reverse-resolve a path. It leaves unstated whether repeated calls duplicate links, whether the referenced task/note must already exist, and what is returned — meaningful gaps for a mutation tool.

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?

It is a single packed sentence chain with parentheticals and em-dashes; the core action is front-loaded, but the clause 'the files the work touches, and the plan it follows, wherever that lives' is diffuse and forces re-reading to extract the actual constraint.

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 four-parameter mutation tool with no annotations and no output schema, the description covers purpose, target selection, accepted path forms, and the observable downstream side effect (change warnings, reverse lookup). It stops short of explaining the return value or error conditions, both of which an agent calling blind would want.

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?

At 50% schema coverage the description must compensate, and it does for the two most consequential parameters: `task_id` vs `context_id` targets and the alternate-target rule, plus the accepted value space for `path` (filesystem paths outside the repo, URLs kept as written). The `model` parameter and the nested `paths[].note` field receive no mention in either the description or the schema, which keeps it from 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?

The opening clause states a specific verb and resource — 'Attach file paths to a task (`task_id`) or a note (`context_id`)' — and immediately names the two target parameters, so an agent can distinguish this write operation from siblings like `unlink_file` or `add_context` from the first line alone.

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

Usage Guidelines4/5

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

It gives clear context for when to call it ('the files the work touches') and an explicit mutual-exclusivity constraint ('one or the other'), which is the main selection decision for this tool. It does not, however, name the removal counterpart (`unlink_file`) or state what happens if both IDs are supplied, so the exclusions are implied rather than spelled out.

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