Class: Rigor::CLI::SkillDescribe
- Inherits:
-
Object
- Object
- Rigor::CLI::SkillDescribe
- Defined in:
- lib/rigor/cli/skill_describe.rb
Overview
Builds the rigor skill describe report (ADR-73): a ProjectStateProbe snapshot, a recommended next skill, and
the live catalogue of bundled skills with their current frontmatter descriptions. Extracted from SkillCommand so
the command stays a thin dispatcher and this — the "live brain" — owns the routing.
Constant Summary collapse
- ENTRY_POINT_SKILL =
The entry-point SKILL itself — excluded from the catalogue because it is the skill being run, not a destination.
"rigor-next-steps"- CATALOG_ORDER =
Adoption-journey order for the catalogue and the order the recommendation decision tree walks.
rigor-asksits last: it is the journey-agnostic "answer a question about Rigor" companion the agent can offer at any point, never a presence-recommended step. %w[ rigor-project-init rigor-rbs-setup rigor-ci-setup rigor-baseline-reduce rigor-monkeypatch-resolve rigor-editor-setup rigor-mcp-setup rigor-protection-uplift rigor-plugin-tune rigor-plugin-author rigor-upgrade rigor-doctor rigor-ask ].freeze
Instance Method Summary collapse
-
#initialize(skills:, root: Dir.pwd) ⇒ SkillDescribe
constructor
A new instance of SkillDescribe.
-
#render ⇒ String
The full describe report.
Constructor Details
#initialize(skills:, root: Dir.pwd) ⇒ SkillDescribe
Returns a new instance of SkillDescribe.
145 146 147 148 |
# File 'lib/rigor/cli/skill_describe.rb', line 145 def initialize(skills:, root: Dir.pwd) @skills = skills @root = root end |
Instance Method Details
#render ⇒ String
Returns the full describe report.
151 152 153 154 155 156 157 158 159 160 161 162 |
# File 'lib/rigor/cli/skill_describe.rb', line 151 def render catalog = catalog_skills state = ProjectStateProbe.new(@root).to_h recommendation = recommend(state, catalog) [ title, state_section(state), recommendation_section(recommendation), catalog_section(catalog), agent_prompt(recommendation) ].join("\n") end |