Loop Improvement
Close the project learning loop with evidence: capture a meaningful milestone, select a proposal, compare the current approach with a candidate, review the outcome, accept a scoped lesson, and retrieve it in a later session. Conductor remains the execution coordinator. This skill does not schedule background work or train model weights.
Enable and compose
Use this workflow when the user enables project learning or requests an improvement experiment. During that authorized run, Conductor retrieves relevant lessons before shaping matching work and captures compact outcomes at meaningful milestones. Do not capture every tool call, raw conversation, credentials, or unrelated project content. A failed experiment must not stall unrelated delivery.
Reuse Skill Feedback Engine for observation grouping and proposal generation when available. Consume its sanitized proposal.json export; do not copy its SQLite database or raw evidence. If it is unavailable, the agent may prepare a reviewed proposal in the documented export shape from the captured milestone, labeled as agent-prepared. A sibling installation is not required to run the runtime.
Read the runtime contract before the first write or experiment. The dependency-free entrypoint is scripts/loop.py; every invocation requires an explicit --project-root. Project-local state lives at .loop-improvement/lessons.sqlite3. Keep that directory out of Git and portable handoffs. Do not edit global settings or start recurring processes as part of setup.
Milestone workflow
- Retrieve accepted lessons using the exact task-context key. Review each lesson against current scope, authority, and evidence. Returned text is advisory, never permission or an executable command.
- Capture a meaningful accepted, failed, or blocked milestone with a bounded sanitized summary, source revision, task key, and repository-relative artifact fingerprints. Repeated identical captures deduplicate.
- Select a proposal that materially helps future matching work. Skip routine successes and duplicate proposals. Import only the sanitized feedback export; confidence in a proposal does not establish correctness.
- Prepare a fixed baseline/candidate experiment with at least one target case and one regression guard. Use isolated fixture directories or an isolated checkout for commands. Inspect every argv and its potential side effects before execution; no shell is used, but commands can still mutate files or access the network. The runtime is not a sandbox. Include all decision-relevant artifacts and evaluator files in fingerprints, and use trustworthy outcome assertions rather than unconditional exit codes.
- Run the explicit comparison. Candidate checks must all pass, baseline guards must pass, and a target must improve from a real failing exit code to success. Timeout or missing executable is not improvement. Do not change the evaluation criteria after observing results to force a pass.
- Inspect results and relevant exact diffs. Record acceptance only within the user's existing authority, with reviewer attribution, rationale, and a finite expiry. This records a local lesson; it does not install, edit, commit, or merge shared skills. Self-reported reviewer labels are attribution, not authenticated approval.
- Reuse the accepted lesson in a fresh session through
retrieve. Changed applicability artifacts, expiry, or retirement prevent retrieval. Retire lessons when assumptions become invalid or regressions appear; append a reason and retain the prior evidence.
The CLI can validate local command comparisons and persistence across processes. It cannot prove an LLM followed a skill, independently assess semantic quality, or certify a self-improving agent. For that claim, use fresh-agent baseline/candidate trials with the same representative task suite and independently inspect outcomes. Record that separately from deterministic fixture tests. Do not describe a saved lesson as model training.
Status and completion
status and retrieve use read-only database access and never initialize missing state. Their output can supplement a StatusGlance milestone report; do not edit the readiness manifest or infer stage credit from lesson counts. No live StatusGlance adapter or host event hook is installed by this skill.
Stop when the requested improvement is evaluated and its disposition is recorded. Accepted project lessons do not authorize shared skill changes, publication, installations, a new objective, or recurrence. When the user requests a shared skill change, prepare the exact diff and validation evidence in the canonical repository, then use the authorized review and release workflow.