harness-evolve
Skill này làm gì
Skill này chạy một quy trình tiến hóa trên harness AI, thử các biến thể của cài đặt chính sách và chỉ đưa lên những biến thể có điểm tốt hơn. Nó dành cho nhóm muốn tinh chỉnh harness bằng kết quả đo được thay vì phỏng đoán.
Khi nào nên dùng
- ✓Khi một harness đạt điểm thấp hơn mục tiêu và bạn chưa biết cài đặt nào gây ra.
- ✓Khi bạn muốn tìm một thiết lập khởi đầu tốt cho một lĩnh vực mới bằng thử nghiệm.
- ✓Khi bạn muốn so sánh một harness chỉnh tay với một harness đã tiến hóa.
Liên kết skill
https://github.com/ruvnet/ruflo/blob/main/plugins/ruflo-metaharness/skills/harness-evolve/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Hãy tiến hóa harness trong repo của tôi theo các test của nó và cho tôi xem thay đổi nào đã cải thiện điểm số.”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Skill kiểm tra đầu vào và giới hạn, in ra một kế hoạch, rồi chỉ chạy tiến hóa khi bạn xác nhận. Mỗi biến thể được chấm điểm trong một sandbox, và chỉ những người thắng đo được mới được đưa lên.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
Surfaces the upstream metaharness-darwin evolve CLI as a ruflo skill. The
write layer that pairs with ADR-150's read layer (score / genome /
mcp-scan / threat-model / oia-audit). Use when you have a harness whose
readiness scores are flat and you want to discover which surface mutation
moves them — without retraining the foundation model.
When to use
- A
harness-scoreresult is below target and you don't know which policy surface is responsible. - You're seeding a harness for a new vertical and want to find a good starting configuration empirically rather than hand-tuning.
- You're comparing your hand-tuned harness against an evolved baseline (treat darwin's champion as the strawman).
When NOT to use
- For continuous background optimization. Darwin Mode is human-initiated. Wire it into CI for one-shot exploration, not for autonomous self-modification.
- For ruflo itself in CI. ADR-153 §5 explicitly rejects auto-evolving ruflo — the CI gate verifies graceful degradation, not convergence.
Algorithm
Implementation: scripts/evolve.mjs.
- Validate args (
--repoexists, caps on--generations≤ 50,--children≤ 20,--concurrency≤ 8, sandbox/selection/mutator are known values). - Without
--confirm: print plan + exit 0 (mirrorsharness-mintsafety convention; defense in depth over the upstreamsafety.tschecks). - With
--confirm: runmetaharness-darwin evolve <repo> ...from the installed@metaharness/darwin(pin in_darwin.mjs; one-time~/.ruflo/darwin-cache-<pin>install only if no installed copy qualifies — never npx) via the shared_darwin.mjsasync helper. Per-generation progress is forwarded to stderr; final champion JSON is captured from stdout. - Compute timeout from
generations × children × per-variant(per-variant ≈ 60s real, ≈ 2s mock). Caller may override with--timeout-ms. - Honor upstream exit code 99 — propagate as "safety-disqualified", do not
remap. This is a designed-in tripwire (a variant tripped
inspectVariantfor secrets / shell-out / network / dynamic-eval). See ADR-153 §"Safety model". - Optional
--alert-on-no-improvement: exit 1 when champion ≤ parent.
The seven mutation surfaces
| Surface | What it owns |
|---|---|
planner |
task decomposition / step ordering |
contextBuilder |
what gets fed into the prompt |
reviewer |
self-critique / output verification |
retryPolicy |
when + how to retry on failure |
toolPolicy |
which tools the agent may use, under which conditions |
memoryPolicy |
what to persist, recall, forget |
scorePolicy |
how the agent grades its own output |
One mutation per variant. Multi-surface mutations are not allowed (causal attribution stays clean).
Output
Reports land under <repo>/.metaharness/:
.metaharness/
archive.json # full lineage tree (sampling next gen draws from this)
lineage.json # parent→child edges only
variants/<id>/ # per-variant code (kept for audit)
runs/<id>/ # per-variant sandbox test output
reports/winner.json # final champion + score delta vs parent
Skill stdout = JSON {success, data: {champion, plan, durationMs, improved}}
(plus data.diagnosis when --diagnose is passed — see below).
Failure diagnosis (--diagnose)
GEPA's key trick is natural-language failure diagnosis from execution traces
feeding the next mutation — not just scalar fitness. --diagnose adds a
modest slice of that: after the evolution completes, the losing / failed
variants' transcripts are run through darwin's GEPA library ops
(analyzeTranscript + classifyFailure, via the shared importGepa
resolver in scripts/_darwin.mjs) and a diagnosis section is appended to
the emitted JSON:
"diagnosis": {
"available": true,
"scope": "losing-variants",
"variants": [
{ "id": "g1_v0", "transcripts": 2,
"failureClasses": { "exploration-loop": 1, "edit-mechanics": 1 },
"dominantClass": "exploration-loop" }
],
"totals": { "exploration-loop": 1, "edit-mechanics": 1 }
}
Upstream shape caveats (verified against @metaharness/darwin@0.8.0):
metaharness-darwin evolve --jsonprints a TEXT leaderboard — the stdout carries no JSON and no transcripts. Per-variant run records live at<repo>/.metaharness/runs/<id>.json.- Those run records hold sandbox exec traces (
{taskId, exitCode, stdout, stderr}), which are NOT GEPA `{
Câu hỏi thường gặp
Nó có chạy mà không cần bạn đồng ý không?
Không. Nếu không có tùy chọn confirm, skill chỉ in kế hoạch và không thay đổi gì.
Các giới hạn được đặt thế nào?
Mã nguồn giới hạn 50 thế hệ, 20 con và 8 luồng chạy đồng thời.
Nó có nhằm thay đổi chính Ruflo không?
Không. Ghi chú nói rằng cổng CI cho Ruflo kiểm tra khả năng suy giảm êm ái, không phải tự thay đổi.
Chi tiết
Mô tả gốc của tác giả
Run `@metaharness/darwin evolve {repo}`: mutate a harness's seven policy surfaces, sandbox-score each variant and promote only measured wins. Use when evolving a harness against its tests or a bench suite. Degrades gracefully without darwin (ADR-150/153).
repo: ruvnet/ruflo
Độ phổ biến
- Sao GitHub
- 81k
- Vị trí xếp hạng
- #1647
- Giấy phép
- MIT
- Cập nhật
- 2/11/2026
Bình luận
- …
Thêm skill từ kho mã này
agent-adaptive-coordinator
81kGiúp agent của bạn chia và cân bằng lại một nhóm agent AI khi khối lượng công việc thay đổi, chọn bố cục phù hợp với tác vụ.
agent-agent
81kDạy agent của bạn biến một mục tiêu lớn thành kế hoạch hành động có thứ tự, và lập lại kế hoạch khi điều kiện thay đổi.
agent-agentic-payments
81kGiúp agent của bạn quản lý ủy quyền chi tiêu cho mua sắm bằng AI, với hạn mức chi, khung thời gian, quy tắc người bán và phê duyệt có chữ ký.
agent-analyze-code-quality
81kGiúp agent của bạn rà soát chất lượng mã, tìm code smell, nợ kỹ thuật và gợi ý tái cấu trúc mà không thay đổi các file.
Skill tương tự
add-model-provider
394kGiúp agent của bạn kết nối nhà cung cấp mô hình AI mới với OpenClaw bằng lệnh an toàn, giữ API key khỏi văn bản thuần và chạy thử.
acp-router
394kGiúp agent của bạn gửi một tác vụ đến trợ lý lập trình như Claude Code hoặc Cursor qua OpenClaw, để công việc chạy ngay trong công cụ đó.
browser-automation
394kHướng dẫn agent của bạn điều khiển trang web từng bước, gồm đăng nhập, tab và cách khôi phục khi trang ngừng phản hồi.