mirror of
https://github.com/bmad-code-org/BMAD-METHOD.git
synced 2026-09-01 15:09:07 +08:00
refactor(bmad-review): rename edge-case lens to edge-case-hunter
Rename the lens code and reference file (lens-edge-case.md -> lens-edge-case-hunter.md), add explicit when = "always" to the shipped lenses, and tighten the lens-selection wording in SKILL.md.
This commit is contained in:
@@ -22,7 +22,7 @@ Review content through independent lenses — each a distinct method and stance
|
||||
|
||||
1. **Resolve customization:** `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`. On failure, read `{skill-root}/customize.toml` directly and use defaults.
|
||||
2. **Load the content.** If it is empty or cannot be decoded as text: when the caller expects the raw findings JSON array (e.g. the legacy edge-case forwarder), return `[{"location":"N/A","trigger_condition":"Input empty or undecodable","guard_snippet":"Provide valid content to review","potential_consequence":"Review skipped — no analysis performed"}]` (no `lens` field) and stop; otherwise say what's wrong and ask for reviewable content. Identify the content type — diff, file, function, document — since scope rules and lens applicability depend on it.
|
||||
3. **Select lenses** from `{workflow.lenses}`. A lens with an empty `instruction` is disabled. If the user or caller named lenses, run exactly those. Otherwise run every enabled lens whose `when` fits the content (empty `when` = always fits).
|
||||
3. **Select lenses** from `{workflow.lenses}`. A lens with an empty `instruction` is disabled. If the user or caller named lenses, run exactly those only. Otherwise run every enabled lens whose `when` applies.
|
||||
4. **Run each selected lens independently** — each sees the content and `also_consider`, never another lens's findings. Follow each lens's `instruction`; the shipped lenses load their reference file just-in-time, so load only what runs. When subagents are available, spawn one per lens in parallel: give it the lens `instruction` with `{skill-root}` and paths resolved absolute, the content or where to read it, any `also_consider` areas, and the constraint "Return ONLY the findings JSON array — no other output." Otherwise run the lenses sequentially yourself, completing one before starting the next.
|
||||
5. **Assemble and present** per Output below. Keep every lens's findings — overlap between lenses is signal, not duplication; note it in the markdown report rather than deduping.
|
||||
|
||||
|
||||
@@ -40,12 +40,14 @@ report_path = ""
|
||||
[[workflow.lenses]]
|
||||
code = "adversarial"
|
||||
name = "Adversarial"
|
||||
when = "always"
|
||||
instruction = "Load `references/lens-adversarial.md` from the skill root and follow it."
|
||||
|
||||
[[workflow.lenses]]
|
||||
code = "edge-case"
|
||||
code = "edge-case-hunter"
|
||||
name = "Edge-Case Hunter"
|
||||
instruction = "Load `references/lens-edge-case.md` from the skill root and follow it."
|
||||
when = "always"
|
||||
instruction = "Load `references/lens-edge-case-hunter.md` from the skill root and follow it."
|
||||
|
||||
[[workflow.lenses]]
|
||||
code = "verification-gap"
|
||||
|
||||
Reference in New Issue
Block a user