autoresearch-finalize
Fungsinya
Skill ini mengambil perubahan yang disimpan dari sesi autoresearch dan mengelompokkannya menjadi cabang yang rapi, satu untuk setiap ide. Skill ini untuk orang yang menginginkan pekerjaan yang bisa ditinjau sebelum digabung.
Kapan dipakai
- βSaat sesi autoresearch sudah selesai dan Anda ingin perubahannya ditinjau.
- βSaat Anda memiliki banyak komit eksperimen kecil dan perlu mengaturnya per topik.
- βSaat Anda ingin memastikan perubahan mana yang disimpan sebelum menyiapkan cabang.
Link skill
https://github.com/davebcn87/pi-autoresearch/blob/main/skills/autoresearch-finalize/SKILL.mdSalin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.
Cara pakai
Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.
Pesan siap tempel
Untuk Claude Code, Codex, atau Cursor: jalankan di folder proyek, lalu skill langsung terpasang.
Unduh SKILL.md lalu taruh di folder skill agen Anda.
Contoh permintaan ke AI
βFinalkan sesi autoresearch saya agar setiap peningkatan berada di cabang bersih sendiri untuk ditinjau.β
5 skill baru setiap minggu. 1 menit baca.
Cara kerjanya
Skill membaca log sesi, hanya menyimpan eksperimen yang ditandai sebagai disimpan, dan mengelompokkannya per topik. Skill mengusulkan kelompok itu untuk Anda tinjau, lalu membuat satu cabang untuk setiap kelompok dari titik awal bersama dengan cabang utama.
Konten teknis (SKILL.md asli)
Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.
Finalize Autoresearch
Turn a noisy autoresearch branch into clean, independent branches β one per logical change, each starting from the merge-base.
Step 1 β Analyze and Propose Groups
- Read
.auto/log.jsonl(legacy:autoresearch.jsonl). Filter to kept experiments only. - Read
.auto/prompt.md(legacy:autoresearch.md) for context. - Expand all short commit hashes to full hashes:
git rev-parse <short_hash> - Get the merge-base:
git merge-base HEAD main - For each kept commit, get the diff stat (use
$BASE..<commit>for the first,<prev_kept>..<commit>for subsequent). - Group kept commits into logical changesets:
- Preserve application order. Group N comes before Group N+1.
- No two groups may touch the same file. Each branch is applied to merge-base independently β overlapping files would conflict. If two groups touch the same file, merge them into one group.
- Watch for cross-file dependencies. Each branch is independent, so if group 1 adds an API in
api.jsand group 2 calls it inparser.js, group 2's branch won't work in isolation. When proposing groups, flag dependencies: "group 2 depends on group 1 β review together." If the dependency is tight, merge the groups. - Keep each group small and focused. One idea, one theme per group.
- Don't hardcode a count. Could be 2, could be 15.
Present the proposed grouping to the user:
Proposed branches (each from merge-base, independent):
1. **Switch test runner to forks pool** (commits abc1234, def5678)
Files: vitest.config.ts, package.json
Metric: 42.3s β 38.1s (-9.9%)
2. **Tune worker count and timeouts** (commits ghi9012, jkl3456)
Files: test/setup.ts
Metric: 38.1s β 31.7s (-16.8%)
Wait for approval before proceeding.
Step 2 β Write groups.json and Run
Write groups.json:
{
"base": "<full merge-base hash>",
"trunk": "main",
"final_tree": "<full hash of current HEAD>",
"goal": "short-slug",
"groups": [
{
"title": "Switch to forks pool",
"body": "Why + what changed.\n\nExperiments: #3, #5\nMetric: total_time 42.3s β 38.1s (-9.9%)",
"last_commit": "<full hash of last kept commit in this group>",
"slug": "forks-pool"
}
]
}
Key rules:
last_commitmust be a full hash. Expand from jsonl short hashes withgit rev-parse.- No two groups may share a file. The script validates this and fails if violated.
Then run:
bash <SKILL_DIR>/finalize.sh /tmp/groups.json
The script creates one branch per group from the merge-base, verifies the union matches the original branch, and prints a summary with all branches, cleanup commands, and any ideas from .auto/ideas.md (legacy: autoresearch.ideas.md).
On creation failure: rolls back (deletes branches, restores original branch, pops stash). On verification failure: exits non-zero but leaves branches intact for inspection.
Step 3 β Report
After the script finishes, report to the user:
- Branches created and what each contains
- Overall metric improvement (baseline β best)
- Show the cleanup commands from the script's summary output
Edge Cases
- Only 1 kept experiment: One branch is fine β don't force splits.
- Overlapping files between groups: The script fails with an error naming the file. Merge the overlapping groups and retry.
- Non-experiment commits on the branch: Skip them β only process kept experiments from the jsonl.
Pertanyaan umum
Apakah saya bisa memeriksa kelompoknya dulu?
Ya. Skill menampilkan kelompok yang diusulkan sebelum cabang dibuat.
Apa yang terjadi pada perubahan yang tidak disimpan?
Hanya eksperimen yang ditandai sebagai disimpan yang dipakai, sehingga percobaan yang dibuang tidak disertakan.
Cabang mana yang dijadikan pembanding?
Ia memakai merge-base dengan cabang utama sebagai titik awal untuk setiap kelompok.
Detail
Deskripsi asli dari pembuat
Finalize an autoresearch session into clean, reviewable branches. Use when asked to "finalize autoresearch", "clean up experiments", or "prepare autoresearch for review".
Popularitas
- Bintang GitHub
- 8.2k
- Peringkat
- #12523
- Lisensi
- MIT
- Diperbarui
- 7/10/2026
Komentar
- β¦
Skill lain dari repositori ini
autoresearch-create
8.2kMembantu agent Anda menjalankan siklus eksperimen otonom yang mencoba ide, menyimpan yang meningkatkan target pilihan, dan membuang sisanya.
autoresearch-hooks
8.2kMengajari agent Anda menulis skrip kecil yang berjalan sebelum dan sesudah setiap eksperimen, untuk peringatan, catatan tersimpan, atau pengambilan riset.
Skill serupa
diffs
394kMemungkinkan agent Anda menghasilkan diff perubahan yang nyata dan dapat dibagikan sebagai tautan viewer atau file gambar, bukan ringkasan yang ditulis manual.
coding-agent
394kMembantu agent Anda menyerahkan pekerjaan pemrograman besar ke Codex, Claude Code, atau OpenCode di latar belakang, lalu memeriksa kemajuannya.
gh-issues
394kMembantu agent Anda menemukan issue GitHub, memilih yang dikerjakan, dan membuka pull request perbaikan, termasuk tindak lanjut komentar tinjauan.