Skip to main content
Glama

estimate_from_context

Read-onlyIdempotent

Classify a free-text task, issue, or PR description into task type and complexity, then generate a reference-class time estimate with provenance signals so you can judge how far to trust it.

Instructions

Classify a free-text task description and delegate to reference-class estimation.

Classifies task_type and complexity from free text (issue body, PR/diff description, or task summary) using a LOCAL, deterministic keyword/signal heuristic — no LLM call (see src/lib/context-estimate.ts). Caller-supplied task_type/complexity hints always override the classification. Delegates the resolved inputs to the same reference-class-forecasting path used by reference_class_estimate, and returns classification provenance (classified_task_type, classified_complexity, confidence, signals) alongside the estimate so callers can judge how much to trust it.

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": {
      "context": "<context>"
    },
    "name": "estimate_from_context"
  }
}

Input Schema

NameRequiredDescriptionDefault
contextYesFree-text context describing the task to estimate — issue body, PR/diff description, or task summary. Will be used to classify task_type and complexity and delegate to reference_class_estimate / PERT correction once classification logic ships (Phase 5).
team_idNoOptional team identifier to scope historical data once classification logic ships.
task_typeNoOptional pre-classified task type hint; used once classification logic ships.
complexityNoOptional pre-assessed complexity hint (1-5); used once classification logic ships.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.8.0

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the annotations (readOnly, idempotent, closed-world, non-destructive), the description discloses the mechanism (local deterministic keyword/signal heuristic, no LLM call, referencing src/lib/context-estimate.ts), the override precedence for caller hints, and the return of provenance fields so callers can judge trust. That is exactly the kind of context annotations cannot carry.

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

Conciseness5/5

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

The summary sentence is front-loaded, and the following paragraph adds mechanism, precedence, and return shape without repetition. The parenthetical file reference and the provenance field list are dense but each earns its place by answering a distinct caller question.

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 compensates by naming the returned fields (classified_task_type, classified_complexity, confidence, signals) alongside the estimate, which is what an agent needs to decide how much to trust the result. Minor gaps remain: no mention of failure modes or what happens with a context string that matches no signals, and the 'Phase 5' mismatch with the schema leaves the current maturity of the feature ambiguous.

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?

Schema coverage is 100%, so the baseline is 3; the description earns an extra point by stating the precedence rule that caller-supplied task_type/complexity hints always override the classification, which the schema does not say. There is a mild tension with the schema text claiming those hints are only 'used once classification logic ships (Phase 5)', while the description implies classification is live now — worth flagging but not an annotation contradiction.

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 sentence gives a concrete verb pair and resource: classify a free-text task description, then delegate to reference-class estimation. It also distinguishes itself from the sibling reference_class_estimate by naming it as the downstream path and clarifying that this tool sits in front of it as a classifier. An agent can tell the two apart without opening either schema.

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 states the input conditions clearly (issue body, PR/diff description, or task summary) and explains the routing relationship to reference_class_estimate. What is missing is an explicit 'when not to use this' rule — e.g. if the caller already has a task_type and complexity, going straight to reference_class_estimate is presumably cheaper, but the description only implies that via the override sentence.

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