agentleFS
lowtidebuildlowtidebuild/second-review-agent/.claude/skills/known-issues-manager/SKILL.md

known-issues-manager

Skill1 starsChanged 7 months agoApache-2.0View on GitHub

Match review findings against known recurring patterns and manage the known-issues registry. 4. Post-Delivery Trigger Protocol (automatic after Step 8) - After Step 8 (quality-gate) completes, automatically scan for recurring patterns: 1. Load current review's issue-registry.json 2. Normalize findings and append occurrence events to the ledger, if configured 3. Group findings by (dimension, defect_type) — if defect_type absent, use description keyword extraction 4. Count distinct matter_ids from occurrence-ledger.jsonl, keyed by pattern_id or match_signature 5. If the ledger is missing, scan…

The file

We split this skill into the rules it gives an agent

11 rules. About 0 are common, 7 are distinctive, and 4 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈7

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 4

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Use library/known-issues/{agent-name}.index.json when present and current to narrow candidate patterns

    line 9
  2. Distinctive:

    After each review, scan findings for potential new patterns

    line 20
  3. Distinctive:

    Never auto-add patterns without user approval

    line 23
  4. Distinctive:

    After Step 8 (quality-gate) completes, automatically scan for recurring patterns:

    line 26
  5. Very specific:

    If the ledger is missing, scan prior review outputs as fallback: a.

    line 31
  6. Distinctive:

    If total distinct matters ≥ 3 → propose new pattern to user

    line 35
  7. Distinctive:

    Check generated artifact status without writing:

    line 48
  8. Very specific:

    Prefer index candidates in this order: exact match_signature, same dimension + document_type, same dimension

    line 85
  9. Distinctive:

    Add pattern note to review comment

    line 89
  10. Very specific:

    Update pattern's frequency and last_seen

    line 90
  11. Distinctive:

    Use document language for the proposal.

    line 117

≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

known-issues-manager Skill

Match review findings against known recurring patterns and manage the known-issues registry.

Capabilities

  1. Pattern Matching (WF1 Step 6)
    • Compare each finding against library/known-issues/{agent-name}.json
    • Use library/known-issues/{agent-name}.index.json when present and current to narrow candidate patterns
    • Match by: dimension + document_type + pattern description similarity
    • Tag matches as [Recurring: {pattern_id}] in issue registry
    • Include pattern's recommended_fix in the review comment
  2. Frequency Tracking (post-delivery)
    • On pattern match: auto-increment frequency and update last_seen
    • Count distinct matters only (same matter re-reviews don't increase count)
    • Append normalized finding events to library/known-issues/occurrence-ledger.jsonl when ledger tracking is enabled
  3. New Pattern Proposal (post-delivery)
    • After each review, scan findings for potential new patterns
    • Criteria: similar finding has appeared ≥3 times across distinct matters
    • Present proposed pattern to user for confirmation before adding
    • Never auto-add patterns without user approval
  4. Post-Delivery Trigger Protocol (automatic after Step 8)
    • After Step 8 (quality-gate) completes, automatically scan for recurring patterns:
      1. Load current review's issue-registry.json
      2. Normalize findings and append occurrence events to the ledger, if configured
      3. Group findings by (dimension, defect_type) — if defect_type absent, use description keyword extraction
      4. Count distinct matter_ids from occurrence-ledger.jsonl, keyed by pattern_id or match_signature
      5. If the ledger is missing, scan prior review outputs as fallback: a. $SECOND_REVIEW_PRIVATE_DIR/output/*/round_*/working/issue-registry.json b. Count distinct matter_ids where similar findings appeared c. Two findings are "similar" if they share the same dimension AND (defect_type matches OR description keyword overlap > 50%)
      6. If total distinct matters ≥ 3 → propose new pattern to user
    • This runs automatically; no user invocation required

When to Use

  • WF1 Step 6: check findings against existing patterns
  • Post-delivery: propose new patterns if criteria met
  • WF4 /library known-issues: view, add, or edit patterns

Maintenance Commands

  • Rebuild indexes and print diagnostics:
    • python3 .claude/skills/known-issues-manager/scripts/known_issue_maintenance.py library/known-issues
  • Check generated artifact status without writing:
    • python3 .claude/skills/known-issues-manager/scripts/known_issue_maintenance.py library/known-issues --check
  • Rebuild the optional frequency cache from a ledger:
    • python3 .claude/skills/known-issues-manager/scripts/known_issue_maintenance.py library/known-issues --ledger-path <path> --write-frequency-cache

Known Issues Registry Schema

File: library/known-issues/{agent-name}.json

[
  {
    "pattern_id": "KI-001",
    "agent": "legal-writing-agent",
    "document_type": "advisory",
    "dimension": 4,
    "pattern": "번역투: '~에 의해' passive construction overuse",
    "detection_rule": "register-validator.py pattern 'passive_by' count ≥ 5 in single document",
    "recommended_fix": "Restructure as active voice with subject-verb-object",
    "frequency": 7,
    "first_seen": "2026-03-12",
    "last_seen": "2026-03-12",
    "examples": [
      "본 계약은 양 당사자에 의해 체결되었다 → 양 당사자가 본 계약을 체결하였다"
    ]
  }
]

Pattern Matching Algorithm

  1. Load known-issues for the inferred originating agent
  2. Load the generated sidecar index if it exists and its source_sha256 matches the registry
  3. For each finding in issue-registry:
    • Compare dimension match
    • Compare document_type match (if specified in pattern)
    • Compare description similarity (keyword overlap > 50%)
    • Prefer index candidates in this order: exact match_signature, same dimension + document_type, same dimension
    • Fall back to the legacy dimension scan if the index is missing, stale, or returns no candidates
  4. If match found:
    • Tag finding with recurring_pattern: {pattern_id}
    • Add pattern note to review comment
    • Update pattern's frequency and last_seen

New Pattern Proposal Format

새로운 반복 패턴을 발견했습니다:

패턴: [description]
차원: Dimension [N]
발생 빈도: [N]회 (서로 다른 [N]건에서)
관련 에이전트: [agent-name]

이 패턴을 Known Issues 레지스트리에 추가할까요? (Y/N)

English Proposal Format

Recurring pattern detected:

Pattern: [description]
Dimension: Dimension [N]
Frequency: [N] occurrences across [N] distinct matters
Originating agent: [agent-name]

Add this pattern to the Known Issues registry? (Y/N)

Use document language for the proposal. If document is English, use the English template.

References

  • references/known-issues-schema.md — full schema documentation
  • scripts/known_issue_normalizer.py — v2 matching metadata normalization helpers
  • scripts/known_issue_index.py — generated sidecar index builder and candidate lookup helpers
  • scripts/known_issue_ledger.py — append-only occurrence ledger and distinct-matter counting helpers
  • scripts/known_issue_maintenance.py — rebuild/check command for generated indexes and optional frequency cache
  • ../../../docs/plans/known-issues-performance-plan.md — performance improvement plan for matching, indexing, and frequency tracking

Checkpoint

This skill runs as part of Step 6 alongside scoring-engine. The main agent updates checkpoint.json after both skills complete — see scoring-engine/SKILL.md for details.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.