Skip to content

fix(skills-evolution): harden candidate processing and details - #155

Merged
Pepps233 merged 12 commits into
feat/evolved-skill-operator-controlsfrom
fix/skills-evolution-ux
Aug 31, 2026
Merged

Pepps233 merged 12 commits into
feat/evolved-skill-operator-controlsfrom
fix/skills-evolution-ux

Conversation

@Pepps233

Copy link
Copy Markdown
Contributor

Summary

Prevent concurrent evolution runtimes from processing the same skill-candidate job, producing duplicate drafts, and recording a failure after another processor has already completed the work. Also keep evolved-skill detail output focused on the target harness and review material.

Reasoning

Candidate polling was advisory: every Diffex process could select the same completed evolution job, and registry compare-and-swap protected individual appends without claiming the full processing operation. Two processors could therefore share a work ID and attempt, invoke synthesis twice, race lifecycle transitions, and leave contradictory completion/failure history.

A renewable, fenced candidate-work lease makes ownership durable across processes while preserving the existing completion-dominates-retry behavior. Retry paths remain safe by treating identical downstream lifecycle records as idempotent and by binding draft identity to synthesized content.

Changes

  • Add renewable candidate-work leases with unique runtime owners and heartbeat-based lease-loss cancellation.
  • Fence candidate registry appends with the active work lease and return busy workers to the polling delay.
  • Suppress failure records once durable completion exists.
  • Make identical draft, validation, and evaluation retries idempotent after downstream transitions.
  • Include synthesized content in immutable draft identity.
  • Remove redundant operation, state, and rollback lines from evolved-skill details.
  • Add deterministic lease, race, acknowledgement-loss, retry, draft-identity, and UI coverage.
  • No dependency changes.

Testing

  • npm run check
  • ./test.sh
  • cd packages/evolution && node ../../node_modules/vitest/dist/cli.js --run test/skill-candidate-worker.test.ts test/skill-candidate-registry.test.ts test/skill-synthesizer.test.ts test/filesystem-store.test.ts
  • cd packages/coding-agent && node ../../node_modules/vitest/dist/cli.js --run test/evolution-runtime.test.ts

@Pepps233 Pepps233 self-assigned this Aug 29, 2026
@Pepps233
Pepps233 force-pushed the fix/skills-evolution-ux branch 2 times, most recently from fb56081 to c03bd19 Compare August 30, 2026 15:10
@Pepps233
Pepps233 force-pushed the fix/skills-evolution-ux branch from c03bd19 to 28de8bd Compare August 30, 2026 21:32
@Pepps233
Pepps233 merged commit 4e079e7 into main Aug 31, 2026
0 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant