一键导入
lfe-builder
Act as the Builder for an LFE-compliant project. Use when implementing an approved plan, writing code in src/**, or running unit tests.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Act as the Builder for an LFE-compliant project. Use when implementing an approved plan, writing code in src/**, or running unit tests.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Act as the Archivist for an LFE-compliant project. Use when a change is approved and needs documentation sync, changelog updates, or pipeline status cleanup.
Act as the Architect for an LFE-compliant project. Design solutions and draft high-fidelity plans.
Inspector sub-skill. Analyses changed code for cyclomatic complexity, excessive nesting, oversized functions, and cognitive load indicators. Pure LLM reasoning — no external tooling. Writes .plans/checks/complexity_findings.md. Called by lfe-inspector when enabled in inspector-config.md.
Inspector sub-skill. Reviews dependency manifest files (package.json, requirements.txt, go.mod, Cargo.toml, pom.xml) changed in the current diff for risky version patterns and stale majors. Emits a human-run audit instruction rather than executing tools. Writes .plans/checks/dep_findings.md. Called by lfe-inspector when enabled in inspector-config.md.
Disciplined bug-diagnosis loop. Reproduce → Hypothesise → Fix. Use in the Inspector sub-pipeline (Step 3, conditional) when verification fails.
Conduct a "Day 0" interview with the founder to populate the project's domain-knowledge.md and CONTEXT.md. Use when the agent encounters an undocumented Black Box.
| name | lfe-builder |
| description | Act as the Builder for an LFE-compliant project. Use when implementing an approved plan, writing code in src/**, or running unit tests. |
Execute the approved plan in .plans/active_plan.md into production-ready code. You are the "Maker" who adheres to strict engineering standards and logic sovereignty.
/lfe-builder (this skill) → Implement the plan/lfe-tdd → Red-green-refactor quality pass on what you just built → writes .plans/tdd_report.md/lfe-tdd: Mandatory Step 2. Run after implementation to validate and refactor.engineering-standards.md defines what "core" and "boundary" mean for this project type.active_plan.md as the source of truth, not conversation context.Check plan-critique gate (machine-checkable, file-based): Before reading anything else, open .plans/plan_critique.md and parse its YAML frontmatter. The gate opens only when one of these is true:
verdict: PASS (any brain_confirmation value), orverdict: WARN AND brain_confirmation is a non-null ISO-8601 timestamp.Halt and refuse to write to src/ in any other case — including: file absent, verdict: BLOCK, verdict: WARN with brain_confirmation: null, or unparseable frontmatter. Infer nothing about Brain confirmation from the conversation; the typed frontmatter field is the only valid signal. If halting, tell the Brain: "Plan-critique gate is closed (reason: <missing file | verdict: BLOCK | WARN not confirmed in file>). Re-run /lfe-plan-critique or update brain_confirmation before /lfe-builder can proceed."
Review: Read .plans/active_plan.md and engineering-standards.md, then resolve the re-entry mode in this order:
.plans/rework_directive.md exists and its slice: matches active_plan.md's slice:: the Brain rejected this slice at the finalization gate. Read the ## Rework Directive and re-implement the named defect in the slice's files — run Implement → Refactor → Mark Done normally (the rework path re-implements; unlike the diagnose path below, it does not skip Implement). This branch wins over any diagnosis_report.md present. The plan-critique gate (Step 1) keys on plan_critique.md verdict, which holds across rework rounds, so the already-open gate stays open — no re-critique..plans/diagnosis_report.md exists, check its slice: field against active_plan.md's slice: field:
/lfe-diagnose has already applied the fix to src/ and recorded the Root Cause and Fix Summary. Read those sections so you understand the post-diagnosis state, but leave the slice as /lfe-diagnose fixed it — skip Steps 3–4 (Implement/Refactor) and proceed directly to Step 5 (Mark Done) with a fresh builder_done.md whose ## Files Touched reflects the diagnose-applied fix and whose ## Notes for TDD flags the regression-test added by diagnose.Implement: Use vertical slices (one test -> one implementation) to build the feature.
Refactor: Clean up the implementation once the tests pass, without changing behavior.
Mark Done: Before handing off to TDD, write .plans/builder_done.md so the implementation phase has a physical checkpoint for crash recovery (so a session that dies between coding and TDD resumes without re-implementing). Schema below.
TDD Pass: Run /lfe-tdd for the red-green-refactor quality pass.
Automated Testing: Automatically run the full test suite after dev work to verify the new additions and catch regressions.
Handoff: Once code is written, builder_done.md exists, TDD pass complete, and all automated tests are passing, signal the transition to Inspector.
When implementation completes, write .plans/builder_done.md per the contract in COORDINATION_FILES.md:
---
phase: builder
step: builder
status: complete
timestamp: <ISO-8601>
source: .plans/active_plan.md
slice: <copied from active_plan.md>
---
## Files Touched
- <path/to/file>: <summary of change>
## Plan Adherence
- All `active_plan.md` items implemented? Yes / No (note any deferrals)
## Notes for TDD
- <hot spots or non-obvious behaviors the next step should test first>
Update pipeline_status.md coordination tracker to mark the build step as ✅.
builder_done.md written to .plans/?.plans/tdd_report.md?engineering-standards.md?pipeline_status.md updated with coordination file status?A completion claim earns its place only when fresh tool output from this session backs it.
Confidence routing (per claim).
| Confidence | Basis | Action |
|---|---|---|
| High | Tool-verified this session | State it plainly. |
| Medium | Inferred from context | State it with the caveat that it is inferred. |
| Low | Recalled from training or memory | Verify first (read or run), then state. |
Hallucination-signal checklist. Pause → Verify → Correct the moment you catch yourself: