analysis-pipeline
Reverse engineering - multi-source product intelligence analysis with provenance tracking. Master methodology for all analysis…
Cross-validates sanitized output specs against raw source specs to detect lost behavioral detail, dropped constants, missing features, or diluted precision. Run AFTER sanitization and AFTER contamination audit passes.
Claude Code
$ npx -y skills add prime-radiant-inc/greenfield --skill fidelity-validation --agent claude-code
Codex
$ npx skills add prime-radiant-inc/greenfield --skill fidelity-validation -a codex -y
Cursor
$ npx skills add prime-radiant-inc/greenfield --skill fidelity-validation -a cursor -y
Gemini CLI
$ npx skills add prime-radiant-inc/greenfield --skill fidelity-validation -a gemini-cli -y
GitHub Copilot
$ npx skills add prime-radiant-inc/greenfield --skill fidelity-validation -a github-copilot -y
OpenCode
$ npx skills add prime-radiant-inc/greenfield --skill fidelity-validation -a opencode -y
Windsurf
$ npx skills add prime-radiant-inc/greenfield --skill fidelity-validation -a windsurf -y
name: fidelity-validation description: Cross-validates sanitized output specs against raw source specs to detect lost behavioral detail, dropped constants, missing features, or diluted precision. Run AFTER sanitization and AFTER contamination audit passes.
Sanitization removes source code identifiers. But aggressive sanitization can also remove behavioral detail that an implementor needs. This skill detects information loss.
The sanitization pass rewrites raw specs into output specs. Each rewrite risks:
Run this AFTER: 1. Sanitization (Layer 5) is complete 2. Contamination audit (Layer 6) passes — output specs are confirmed free of source identifiers 3. All remediation/rewriting rounds are done
This is the final quality gate before handing the output to the implementer.
**Every behavioral claim in the raw specs must have a corresponding claim in the output specs — with equal or greater precision.**
The output specs may use different words (that's the point of sanitization), but it must convey the same behavior. If the raw spec says "retry N times with a specific base, cap, and jitter", the output specs must say the same — not just "the system retries on failure."
For each raw module spec (`workspace/raw/specs/modules/*.md`), extract: 1. **All numeric constants** — timeouts, limits, sizes, counts, thresholds, intervals, percentages 2. **All behavioral rules** — "when X happens, the system does Y" 3. **All error conditions** — what errors occur and how they're handled 4. **All state transitions** — state machines, mode changes, lifecycle events 5. **All decision trees** — if/else branches, priority orders, cascades 6. **All features** — distinct capabilities described
Write this inventory to `workspace/raw/audit/fidelity-inventory.md`.
For each item in the source claim inventory, search the corresponding output domain spec(s) for a matching behavioral claim.
**Match criteria:**
**Report format per item:**
### [RAW-SPEC: section-name] Claim: "description of the behavioral claim" - Constant/Rule/Error/State/Decision/Feature - Raw value: [exact value from raw specs] - Output location: [file:section where it appears in the output] or MISSING - Output value: [exact value from output specs] or N/A - Status: MATCH | WEAKENED | MISSING | CHANGED - Notes: [if WEAKENED/MISSING/CHANGED, explain what was lost]
Status definitions:
Repeat Phase 2 for:
Categorize all WEAKENED, MISSING, and CHANGED findings:
| Severity | Criteria | Action | |----------|----------|--------| | **P0-CRITICAL** | A P0 behavior (critical path) is MISSING or CHANGED | Must fix before implementation | | **P0-WEAKENED** | A P0 behavior lost precision (constants, branch coverage) | Must fix before implementation | | **P1-MISSING** | A P1 behavior is entirely absent from the output | Should fix | | **P1-WEAKENED** | A P1 behavior lost precision | Should fix | | **P2-MISSING** | A P2/P3 behavior is absent | Advisory — may fix | | **P2-WEAKENED** | A P2/P3 behavior lost precision | Advisory — may fix |
Write the full report to `workspace/raw/audit/fidelity-report.md`.
The report SHALL include: 1. **Summary statistics**: total claims checked, MATCH count, WEAKENED count, MISSING count, CHANGED count 2. **P0-CRITICAL and P0-WEAKENED findings**: full details with exact raw vs output text 3. **P1 findings**: full details 4. **P2 findings**: summary only 5. **Verdict**: PASS (zero P0 issues) or FAIL (any P0 issue exists)
Write a summary to `workspace/output/audit/fidelity-summary.md`:
The fidelity validation is compute-heavy (reading all raw specs AND all output specs). Dispatch as:
1. **Inventory builders** (parallel, one per 4-5 raw module specs): Extract behavioral
Reverse engineer clean behavioral specs from any codebase. Greenfield reads source code, documentation, SDKs, runtime behavior, and binaries, then produces behavioral specifications, test vectors, acceptance criteria, and a full provenance trail.
Reverse engineering - multi-source product intelligence analysis with provenance tracking. Master methodology for all analysis…
Layer 1 intelligence source discovery - auto-detect available sources, search for public information, negotiate with user,…
Layer 3 deep documentation methodology. Per-module behavioral specifications, external and behavioral integration contracts,…
Layer 1 methodology for extracting behavioral intelligence from compiled binaries, bytecode archives, managed assemblies, and…
Layer 1 skill for community intelligence gathering. Search channels, extraction methodology, consensus analysis, version-aware…
Infrastructure skill for containerized target execution. Runtime detection, container lifecycle, security restrictions,…
You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…
Ask which skill or flow fits your situation. A router over the skills in this repo.