/logic-fix-all
Autonomous repository-wide audit-and-fix pipeline: health → review → locate/explain → fix → diff-verify → iterate until clean. Starts with a mandatory consent prompt (token-intensive); after consent runs hands-free. Trigger when the user wants ALL logic issues found and fixed —
$ npx -y skills add hyhmrright/logic-lens --skill logic-fix-all --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
- Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.
- You can call itInvoke it directly when you want it.
- Slash command
/logic-fix-all
Context preview
The summary Claude sees to decide when to auto-load this skill.
Autonomous repository-wide audit-and-fix pipeline: health → review → locate/explain → fix → diff-verify → iterate until clean. Starts with a mandatory consent prompt (token-intensive); after consent runs hands-free. Trigger when the user wants ALL logic issues found and fixed —
SKILL.md
logic-fix-all.SKILL.mdname: logic-fix-all
description: >
Autonomous repository-wide audit-and-fix pipeline: health → review →
locate/explain → fix → diff-verify → iterate until clean. Starts with a
mandatory consent prompt (token-intensive); after consent runs hands-free.
Trigger when the user wants ALL logic issues found and fixed — "fix
everything", "fix all logic issues", "fix all logic issues in this
code", "clean up all logic issues", "audit and fix the whole repo",
"fix all bugs automatically", or frustration with recurring bugs
wanting a one-shot pass.
SCOPE RULE: repo-wide by default; also trigger for a pasted code
snippet when the user says "fix all" — produce the full Fix Report
(Fix Log, before/after Logic Score). Analysis-only requests use
logic-health or logic-review. Single failure uses logic-locate. Two
versions uses logic-diff. One path explanation uses logic-explain.
Do NOT trigger for: analysis-only ("show me the bugs"),
style/lint/format concerns, or fixing a single named finding.Logic-Lens — Logic Fix All
Setup
Use phase-gated lazy loading per `../_shared/common.md` §13: 1. Before consent, read only `../_shared/common.md` for language, scope routing, fix-all header fields, config fields, and loading budget; then read `logic-fix-all-guide.md` through the phase map and `guide-phases-0-2-consent-scope-health.md` through Phase 0. 2. After consent, read each phase file only when entering that phase. 3. Load `../_shared/logic-risks.md`, `../_shared/semiformal-guide.md`, `../_shared/semiformal-checklist.md`, `../_shared/report-template.md`, and the other skill guides on demand when that phase invokes their methodology.
Process
**Step 0. Language + scope routing.** Detect language per `common.md` §1. Default scope is the repo root; honor a user-named subpath or pasted snippet. For a pasted snippet, skip the consent prompt and run the fix pipeline directly. Read `.logic-lens.yaml` for `ignore:`, `custom_risks`, `severity:`, `focus:`, and `fix_all.max_iterations`.
**Step 1. Consent + scope enumeration** (guide Phase 0–1) — for repo/directory scope: mandatory consent prompt displaying scope / method / cost / iteration cap; on consent, enumerate runtime-affecting files (source / config / constraint / doc), exclude `.git` and build artifacts, classify by risk tier. For a pasted snippet: skip consent, enumerate the snippet's functions directly.
**Step 2. Health pass** (guide Phase 2) — apply logic-health methodology to map per-module Logic Scores and L-code patterns.
**Step 3. Deep review** (guide Phase 3) — apply logic-review per file to collect full Premises → Trace → Divergence findings.
**Step 4. Conditional clarification** (guide Phase 4–5) — apply logic-locate where concrete failures exist; apply logic-explain when a finding's path is unclear (call depth > 3, cross-module, or async).
**Step 5. Fix queue + remedy** (guide Phase 6) — sort by severity; write a paste-ready Remedy per finding; route cross-file contradictions to the correct edit target (code / constraint / config / doc).
**Step 6. Apply + verify** (guide Phase 7) — apply each fix, then apply logic-diff methodology comparing original vs. fixed code. Expected verdict: `⚠️ Conditionally Equivalent` where the differing condition is exactly the bug scenario. Revert if verdict is `✅ Semantically Equivalent` (fix had no effect) or shows new divergences outside the bug scenario (regression). Retry up to 3×.
**Step 7. Iterate + report** (guide Phase 8–9) — re-run health + review on modified files and their consumers; Criticals loop without cap; Warning/Suggestion rounds capped by `fix_all.max_iterations` with user-escalation prompt at the cap. Output the Fix Report.
**Mode line in report:** `Logic Fix All` (Chinese: `逻辑全修`).
**Fix-report additions** (appended after the standard Summary; localize all labels):
## Scope
| Role (source/config/constraint/doc) | Files scanned | Tier H/M/L | Truncated? |
|-------------------------------------|---------------|------------|------------|
## Skill Invocations
logic-health: N · logic-review: N · logic-locate: N · logic-explain: N · logic-diff: N
## Iteration History
| Round | Severity class | New findings | Action |
## Fix Log
| # | File | Lines | Finding | Risk | Severity | Fix Applied (one-line edit or diff summary) | Status (resolved/unresolved/reverted) |
## Resolved by Clarification
[Findings the Phase-5 logic-explain pass revealed as false positives. Empty if none.]
## Unresolved Findings
[Include reason per entry: "conflicting constraints", "user stopped iteration at round N",
"hard iteration ceiling reached", "ambiguous spec", "unclear whether spec or consumer is wrong".
Empty if all resolved.]
**Report header fields** (replace the standard single-line header per `common.md` §5):
**Logic Score (before):** XX/100
**Logic Score (after):** YY/100
**Findings fixed:** N (Critical: n1 · Warning: n2 · Suggestion: n3)
**Findings unresolved:** M
Read more
name: logic-fix-all
description: >
Autonomous repository-wide audit-and-fix pipeline: health → review →
locate/explain → fix → diff-verify → iterate until clean. Starts with a
mandatory consent prompt (token-intensive); after consent runs hands-free.
Trigger when the user wants ALL logic issues found and fixed — "fix
everything", "fix all logic issues", "fix all logic issues in this
code", "clean up all logic issues", "audit and fix the whole repo",
"fix all bugs automatically", or frustration with recurring bugs
wanting a one-shot pass.
SCOPE RULE: repo-wide by default; also trigger for a pasted code
snippet when the user says "fix all" — produce the full Fix Report
(Fix Log, before/after Logic Score). Analysis-only requests use
logic-health or logic-review. Single failure uses logic-locate. Two
versions uses logic-diff. One path explanation uses logic-explain.
Do NOT trigger for: analysis-only ("show me the bugs"),
style/lint/format concerns, or fixing a single named finding.Logic-Lens — Logic Fix All
Setup
Use phase-gated lazy loading per `../_shared/common.md` §13: 1. Before consent, read only `../_shared/common.md` for language, scope routing, fix-all header fields, config fields, and loading budget; then read `logic-fix-all-guide.md` through the phase map and `guide-phases-0-2-consent-scope-health.md` through Phase 0. 2. After consent, read each phase file only when entering that phase. 3. Load `../_shared/logic-risks.md`, `../_shared/semiformal-guide.md`, `../_shared/semiformal-checklist.md`, `../_shared/report-template.md`, and the other skill guides on demand when that phase invokes their methodology.
Process
**Step 0. Language + scope routing.** Detect language per `common.md` §1. Default scope is the repo root; honor a user-named subpath or pasted snippet. For a pasted snippet, skip the consent prompt and run the fix pipeline directly. Read `.logic-lens.yaml` for `ignore:`, `custom_risks`, `severity:`, `focus:`, and `fix_all.max_iterations`.
**Step 1. Consent + scope enumeration** (guide Phase 0–1) — for repo/directory scope: mandatory consent prompt displaying scope / method / cost / iteration cap; on consent, enumerate runtime-affecting files (source / config / constraint / doc), exclude `.git` and build artifacts, classify by risk tier. For a pasted snippet: skip consent, enumerate the snippet's functions directly.
**Step 2. Health pass** (guide Phase 2) — apply logic-health methodology to map per-module Logic Scores and L-code patterns.
**Step 3. Deep review** (guide Phase 3) — apply logic-review per file to collect full Premises → Trace → Divergence findings.
**Step 4. Conditional clarification** (guide Phase 4–5) — apply logic-locate where concrete failures exist; apply logic-explain when a finding's path is unclear (call depth > 3, cross-module, or async).
**Step 5. Fix queue + remedy** (guide Phase 6) — sort by severity; write a paste-ready Remedy per finding; route cross-file contradictions to the correct edit target (code / constraint / config / doc).
**Step 6. Apply + verify** (guide Phase 7) — apply each fix, then apply logic-diff methodology comparing original vs. fixed code. Expected verdict: `⚠️ Conditionally Equivalent` where the differing condition is exactly the bug scenario. Revert if verdict is `✅ Semantically Equivalent` (fix had no effect) or shows new divergences outside the bug scenario (regression). Retry up to 3×.
**Step 7. Iterate + report** (guide Phase 8–9) — re-run health + review on modified files and their consumers; Criticals loop without cap; Warning/Suggestion rounds capped by `fix_all.max_iterations` with user-escalation prompt at the cap. Output the Fix Report.
**Mode line in report:** `Logic Fix All` (Chinese: `逻辑全修`).
**Fix-report additions** (appended after the standard Summary; localize all labels):
## Scope | Role (source/config/constraint/doc) | Files scanned | Tier H/M/L | Truncated? | |-------------------------------------|---------------|------------|------------| ## Skill Invocations logic-health: N · logic-review: N · logic-locate: N · logic-explain: N · logic-diff: N ## Iteration History | Round | Severity class | New findings | Action | ## Fix Log | # | File | Lines | Finding | Risk | Severity | Fix Applied (one-line edit or diff summary) | Status (resolved/unresolved/reverted) | ## Resolved by Clarification [Findings the Phase-5 logic-explain pass revealed as false positives. Empty if none.] ## Unresolved Findings [Include reason per entry: "conflicting constraints", "user stopped iteration at round N", "hard iteration ceiling reached", "ambiguous spec", "unclear whether spec or consumer is wrong". Empty if all resolved.]
**Report header fields** (replace the standard single-line header per `common.md` §5):
**Logic Score (before):** XX/100 **Logic Score (after):** YY/100 **Findings fixed:** N (Critical: n1 · Warning: n2 · Suggestion: n3) **Findings unresolved:** M
Logic-first AI code review via semi-formal execution tracing (Premises → Trace → Divergence → Trigger → Remedy). Catches behavioral bugs, type-contract breaches & async hazards that linters miss. Six skills · Claude Code · Codex CLI · Gemini CLI.
Repo: hyhmrright/logic-lens
Other skills on logic-lens.
- /bump-version
Bump the Logic-Lens version across all six metadata locations at once (package.json, the four plugin manifests, and the README badge), then validate. Use when cutting a release or when `npm run validate` reports a version mismatch.
Open skill - /iterate-skill
Run the Logic-Lens skill-improvement loop end to end — baseline → diagnose failures → edit → sync cache → re-eval → verify net gain → iterate until clean. Use whenever the goal is to RAISE a skill's eval score or fix a failing eval mode: "improve logic-review", "the format
Open skill - /new-skill
Scaffold a new logic-* skill in the Logic-Lens repo and wire it into every place a skill must be registered, so no step is missed. Use when adding a seventh (or later) skill to Logic-Lens.
Open skill - /run-iteration-eval
Run the Logic-Lens content-eval pipeline for one iteration and produce a scored summary.json — use to measure a skill change. Wraps scripts/run-content-evals.sh (runner, costs tokens) and scripts/grade-iteration.py (grader, free, re-runnable). ALWAYS sync the plugin cache first.
Open skill - /sync-skill-cache
Sync the Logic-Lens working-copy skills/ into the installed plugin cache so content-evals test the EDITED skill, not the last published one. ALWAYS run this after editing any skills/**/SKILL.md or guide/_shared file and BEFORE running content-evals — otherwise the eval silently
Open skill - /logic-diff
Compare two code versions for semantic equivalence via semi-formal tracing of both versions side-by-side. Trigger when the user shares a refactor, rewrite, migration, or A/B implementation and wants to confirm behavior is unchanged — "did I break anything", "is this equivalent",
Open skill

