Skip to main content
Glama

davinci_generation_roots

Find generated-code output directories from DaVinci project settings, returning candidates with source, confidence, and existence evidence; returns empty instead of guessing paths.

Instructions

从工程设置里找出生成代码的输出目录,并给出每条结论的证据。

不传 dirs 时按三层取证:工程设置显式字段(.dvjson / Settings/*.json / .dpa 内条目) → 该版本 DaVinci 的默认布局(Appl/GenData / Output)→ 目录名推断。 每条结果带 source / confidence / exists;找不到就返回空,不猜路径。

Args: project: .dvjson 或 .dpa 工程文件。 dirs: 额外指定的候选目录,会与工程设置里的候选合并。 include_missing: 是否返回「设置里写了但目录还不存在」的候选(默认 true), 可用于判断是不是还没生成过。 allow_outside: 允许扫描 DAVINCI_MCP_ROOTS 之外的目录(工程设置指向外部输出目录时用)。 DAVINCI_MCP_STRICT_PATHS=true 时该参数无效。

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": {
      "project": "<project>"
    },
    "name": "davinci_generation_roots"
  }
}

Input Schema

NameRequiredDescriptionDefault
dirsNo
projectYes
allow_outsideNo
include_missingNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.13.0

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 the resolution strategy, that each result carries source/confidence/exists, and that it returns empty rather than guessing paths — a meaningful failure-mode disclosure. It also documents an environment-variable override (DAVINCI_MCP_STRICT_PATHS disables allow_outside). It never states explicitly that the tool is read-only or whether the exists check touches the filesystem, which keeps it from a 5.

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?

Front-loaded purpose sentence, then the evidence tiers, then a compact per-argument block; nothing is padded. The Args list repeats parameter names already in the schema, but each entry adds new meaning, so it earns its space. Slightly dense prose but well ordered.

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?

No output schema exists, and the description compensates by naming the returned fields (source/confidence/exists) and the empty-result case. No annotations, and the description supplies the safety-relevant context itself (path scoping via DAVINCI_MCP_ROOTS, strict-paths override). Minor gaps remain on result shape details such as whether paths are absolute or whether the exists check is a live filesystem probe.

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

Parameters5/5

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

Schema description coverage is 0%, so the description must compensate, and it does for all four parameters. project is constrained to .dvjson/.dpa files, dirs is described as merged with settings-derived candidates, include_missing gets both a default and a use case, and allow_outside gets its purpose plus its interaction with the strict-paths env var.

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 opening sentence states a specific verb and resource: locate the code-generation output directory from project settings, with evidence per conclusion. The three-tier evidence chain (explicit settings fields, version default layout, name inference) makes the scope concrete. It stops short of naming a sibling (e.g. davinci_generated_files) as the alternative for listing generated artifacts, so an agent must infer the boundary.

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?

Conditional guidance is present and specific: when dirs is omitted it runs the three-tier evidence chain, include_missing is useful 'to judge whether generation has not happened yet', and allow_outside is for projects whose settings point at an external output directory. What is missing is an explicit statement of when NOT to use it, or which sibling handles the downstream task of enumerating generated files.

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