#[allow(clippy::wildcard_imports)]
use super::*;
#[allow(clippy::too_many_lines)]
pub(super) fn descriptors() -> Vec<ToolDescriptor> {
vec![
ToolDescriptor {
name: "health_scope",
description: "One scope's health: the state, its layer, the policy version, the derived rollup with its contributors, the audit entries and every diagnostic with its remedy. Name exactly one of `issue` (a selector, as `tix health show`) or `scope` (a canonical spelling: `issue:42`, `cycle:2026-10`, `milestone:m1`).",
input_schema: json!({
"type": "object",
"additionalProperties": false,
"properties": {
"issue": { "type": ["string", "integer"], "description": "Issue selector (number or slug), as `tix health show`." },
"scope": { "type": "string", "description": "Canonical scope spelling, e.g. `issue:42`, `cycle:2026-10`." }
}
}),
},
ToolDescriptor {
name: "health_history",
description: "The append-only health History entries about a scope (`tix health history`), oldest first. Read-only.",
input_schema: json!({
"type": "object",
"additionalProperties": false,
"required": ["scope"],
"properties": {
"scope": { "type": "string", "description": "Canonical scope spelling, e.g. `issue:42`." }
}
}),
},
ToolDescriptor {
name: "health_record",
description: "Record an issue's health state (`tix health set`), or layer an override over its derived value (`tix health override`). One append-only History entry carries the actor, the date and the rationale, written in the same step as the frontmatter value, or neither is written. **`override: true` requires `confirm: true`.**",
input_schema: json!({
"type": "object",
"additionalProperties": false,
"required": ["issue", "state", "rationale"],
"properties": {
"issue": { "type": ["string", "integer"], "description": "Issue selector (number or slug)." },
"state": { "type": "string", "enum": ["unknown", "on_track", "needs_attention", "at_risk"], "description": "One of the four states." },
"rationale": { "type": "string", "description": "Why — required: a health change nobody can explain is not recorded." },
"actor": { "type": "string", "description": "Who is making the change (defaults to the configured git identity)." },
"date": { "type": "string", "description": "When, as `YYYY-MM-DD` (defaults to today)." },
"override": { "type": "boolean", "description": "Layer an override over the derived value instead of recording the issue's own state." },
"confirm": { "type": "boolean", "description": "Required with `override: true`: an override is an explicit act about a whole scope." }
}
}),
},
]
}