Documentation
¶
Overview ¶
Package view aggregates everything known about one requirement — tokens, files, tests, dependencies, spec/plan, diagrams, ticket link — into one bounded, agent-friendly answer. CANARY: REQ=CBIN-204; FEATURE="RequirementView"; ASPECT=CLI; STATUS=TESTED; TEST=TestCANARY_CBIN_204_BuildView; UPDATED=2026-08-28
Index ¶
Constants ¶
const DefaultViewLimit = 10
DefaultViewLimit bounds list sections (files, diagrams) by default; agents raise it with --limit when they need the full list.
Variables ¶
This section is empty.
Functions ¶
func CreateViewCommand ¶
CreateViewCommand returns the `canary view` command.
Types ¶
type View ¶
type View struct {
ReqID string `json:"req_id"`
Source string `json:"source,omitempty"`
TicketURL string `json:"ticket_url,omitempty"`
Statuses map[string]int `json:"statuses"` // status -> token count
Completion int `json:"completion_pct"` // TESTED+BENCHED tokens / total
Features []string `json:"features"` // "Feature (ASPECT, STATUS)"
Files []string `json:"files"` // capped at limit
FilesTotal int `json:"files_total"`
Tests []string `json:"tests"`
Benches []string `json:"benches,omitempty"`
DependsOn []string `json:"depends_on,omitempty"`
Blocks []string `json:"blocks,omitempty"`
RelatedTo []string `json:"related_to,omitempty"`
SpecPath string `json:"spec_path,omitempty"`
PlanPath string `json:"plan_path,omitempty"`
Diagrams []string `json:"diagrams,omitempty"` // "file:line"
DiagramsTotal int `json:"diagrams_total,omitempty"`
}
View is the aggregate answer for one requirement: everything an agent or a human needs to orient on CANARY tokens, files, tests, dependencies, spec/plan location, diagram refs, and (when configured) the owning ticket system — in one bounded call.