minicode-ai 0.15.0 → 0.21.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -4
- package/cli/auto-update.ts +24 -15
- package/cli/commands/exec.ts +3 -2
- package/cli/commands/openwork.ts +1 -1
- package/cli/commands.ts +6 -6
- package/cli/index.ts +61 -22
- package/cli/model-manager.ts +1 -1
- package/cli/setup.ts +119 -62
- package/cli/tui.ts +128 -13
- package/docs/CONTROL-PLANE-MAP.md +6 -4
- package/docs/OUTPUT_EVENT_MODEL.md +4 -3
- package/docs/OUTPUT_PROTOCOL_SPEC.md +1 -1
- package/docs/OUTPUT_RENDERING_SPEC.md +16 -4
- package/docs/OUTPUT_UX_RULES.md +38 -32
- package/docs/P14_OPEN_WORK.md +290 -0
- package/docs/README.md +1 -1
- package/docs/SUMMARY.md +36 -22
- package/docs/TERMINAL_CONTRACT.md +74 -11
- package/docs/UI_RENDER_PIPELINE.md +53 -11
- package/docs/agents.md +1 -1
- package/docs/architecture.md +9 -8
- package/docs/autonomous-scheduler.md +142 -0
- package/docs/choosing-mode.md +2 -2
- package/docs/cli.md +4 -4
- package/docs/concepts.md +5 -5
- package/docs/config-providers.md +3 -3
- package/docs/contributing.md +7 -9
- package/docs/environment.md +6 -4
- package/docs/getting-started.md +4 -4
- package/docs/mcp-lsp.md +2 -2
- package/docs/memory-sessions.md +1 -1
- package/docs/policy-sandbox.md +7 -4
- package/docs/pricing-budget.md +3 -3
- package/docs/quickstart.md +1 -1
- package/docs/repl.md +5 -5
- package/docs/security-model.md +1 -1
- package/docs/security.md +9 -8
- package/docs/skills.md +2 -2
- package/docs/terminal.md +10 -2
- package/docs/tools.md +4 -4
- package/docs/troubleshooting.md +3 -3
- package/docs/verify-benchmark.md +0 -3
- package/package.json +9 -18
- package/src/app/session.ts +40 -7
- package/src/constants.ts +31 -0
- package/src/hooks/run.ts +5 -6
- package/src/mcp/http-transport.ts +1 -1
- package/src/policy/bash-guard.ts +26 -6
- package/src/policy/compaction.ts +107 -17
- package/src/policy/consequence-engine.ts +3 -3
- package/src/policy/context-window.ts +24 -1
- package/src/policy/context.ts +16 -4
- package/src/policy/permission.ts +219 -4
- package/src/policy/update-check.ts +6 -4
- package/src/presentation/adapter.ts +1 -1
- package/src/presentation/events.ts +2 -2
- package/src/presentation/label.ts +3 -3
- package/src/presentation/model.ts +4 -0
- package/src/presentation/store.ts +2 -2
- package/src/runtime/child-execution.ts +1 -1
- package/src/runtime/composition.ts +5 -5
- package/src/runtime/execution-registry.ts +1 -1
- package/src/runtime/production-execution.ts +3 -3
- package/src/runtime/production-runtime.ts +2 -2
- package/src/runtime/runtime-capabilities.ts +1 -1
- package/src/runtime/runtime-status-facts.ts +1 -1
- package/src/runtime/runtime-task-admission.ts +2 -2
- package/src/session/context-assembly.ts +8 -1
- package/src/session/context-identity.ts +2 -2
- package/src/session/context-projection.ts +36 -11
- package/src/session/persistence.ts +1 -1
- package/src/task/autonomous-context.ts +2 -2
- package/src/task/autonomous-policy.ts +3 -3
- package/src/task/model.ts +2 -2
- package/src/task/production-scheduler.ts +2 -2
- package/src/task/scheduler.ts +3 -2
- package/src/task/scheduling-policy.ts +2 -1
- package/src/task/trigger.ts +5 -5
- package/src/tools/read_image.ts +2 -1
- package/src/tools/task.ts +1 -1
- package/src/ui/assistant/simple.ts +47 -30
- package/src/ui/footer.ts +48 -9
- package/src/ui/i18n/en.ts +21 -0
- package/src/ui/i18n/id.ts +21 -0
- package/src/ui/input/prompt-engine.ts +36 -10
- package/src/ui/render/activity-group.ts +53 -0
- package/src/ui/render/activity-panel.ts +91 -0
- package/src/ui/render/cells.ts +347 -0
- package/src/ui/render/composer-wrap.ts +73 -0
- package/src/ui/render/detail.ts +2 -2
- package/src/ui/render/diff.ts +7 -0
- package/src/ui/render/ledger.ts +47 -0
- package/src/ui/render/markdown.ts +6 -1
- package/src/ui/render/session-summary.ts +7 -2
- package/src/ui/render/theme.ts +40 -4
- package/src/ui/render/width.ts +2 -2
- package/src/ui/render/wrap.ts +5 -3
- package/src/ui/runtime/loading-bar.ts +125 -0
- package/src/ui/runtime/screen.ts +84 -7
- package/src/ui/runtime/statusline.ts +26 -0
- package/src/ui/screens/model-manager.ts +1 -1
- package/src/ui/session-state.ts +22 -0
- package/src/ui/tui/app.ts +336 -65
- package/src/ui/tui/transcript.ts +407 -106
- package/vendor/minicore/VENDOR.md +15 -11
- package/vendor/minicore/src/core/events.ts +1 -0
- package/vendor/minicore/src/core/loop.ts +10 -0
- package/vendor/minicore/src/core/session.ts +39 -0
|
@@ -0,0 +1,290 @@
|
|
|
1
|
+
# Open Work — Pekerjaan Lintas Sesi
|
|
2
|
+
|
|
3
|
+
Panduan operasi untuk pekerjaan belum selesai lintas sesi (P14). Semua yang
|
|
4
|
+
dijelaskan di sini memakai mekanisme otoritas yang SUDAH ADA — TaskStore tetap
|
|
5
|
+
satu-satunya otoritas status; tidak ada TaskStore/queue/scheduler kedua.
|
|
6
|
+
|
|
7
|
+
Panduan ini menjelaskan surface Open Work yang tersedia. Batasannya meliputi
|
|
8
|
+
ekstraksi intent dari prosa bebas, readout TUI `/openwork`, merge dengan
|
|
9
|
+
lease/admission, dan merge lintas sesi tanpa adopsi eksplisit.
|
|
10
|
+
|
|
11
|
+
## Gambaran alur
|
|
12
|
+
|
|
13
|
+
```
|
|
14
|
+
minicode openwork ① TEMUKAN (read-only, lintas sesi)
|
|
15
|
+
minicode openwork inventory ①b AUDIT (inventaris P14.0 lintas sumber)
|
|
16
|
+
minicode openwork context --session S --task tN
|
|
17
|
+
①c SUSUN KONTEKS (P14.5, tanpa eksekusi)
|
|
18
|
+
minicode --session <target> \
|
|
19
|
+
--adopt-task <source>/<taskId> "..." ② ADOPSI (eksplisit, otoritas ganda)
|
|
20
|
+
/scheduler run ③ LANJUTKAN (manual, lewat gate continuity)
|
|
21
|
+
(minimum satu turn) ④ KERJAKAN (claim = generasi BARU)
|
|
22
|
+
minicode openwork --closed ⑤ TUTUP (feedback berprovenance)
|
|
23
|
+
minicode openwork export --out FILE ⑤b EKSPOR (json/md, atomik)
|
|
24
|
+
minicode openwork merge ... ⑥ DEDUP (eksplisit + evidence)
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## ① Menemukan: `minicode openwork`
|
|
28
|
+
|
|
29
|
+
Portofolio read-only seluruh task non-terminal di **workspace ini** (tasks.db
|
|
30
|
+
memang per-workspace — sesi proyek lain memang tidak terlihat, itu batas yang
|
|
31
|
+
benar, bukan bug), **ditambah** kandidat intent terstruktur dari histori
|
|
32
|
+
(lihat "Kandidat intent" di bawah).
|
|
33
|
+
|
|
34
|
+
```
|
|
35
|
+
Open Work — 1 item(s) · 1 intent · 1 stale · 0 unknown-provenance
|
|
36
|
+
workspace: D:\proyek · stale after 7d · TaskStore remains the sole status authority
|
|
37
|
+
|
|
38
|
+
p14ow-source/t1 · IN_PROGRESS · PARTIAL · P2 · 2d old
|
|
39
|
+
title: Fix login bug
|
|
40
|
+
flags: STALE · FROM:p14ow-source · SIMILAR×2(UNPROVEN)
|
|
41
|
+
blockers: TASK_BLOCKED: API key rotated
|
|
42
|
+
depends on: t2 (PENDING, unsatisfied)
|
|
43
|
+
next: resume: rebuild context from provenance, then continue via TaskStore/Scheduler
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
Arti bidang:
|
|
47
|
+
|
|
48
|
+
| Bidang | Makna |
|
|
49
|
+
|---|---|
|
|
50
|
+
| `status` | status kanonik TaskStore — **satu-satunya otoritas** |
|
|
51
|
+
| state (kolom ke-4) | state P14.1 berbasis bukti: `OPEN/PARTIAL/BLOCKED/WAITING_FOR_USER/DELEGATED/FAILED_NEEDS_FOLLOWUP/UNKNOWN`; verifikasi gagal → FAILED_NEEDS_FOLLOWUP, dependensi tak tuntas → BLOCKED |
|
|
52
|
+
| `P0..P3` | prioritas presentasi: BLOCKED/FAILED=P0, WAITING/DELEGATED/UNKNOWN=P1, PARTIAL=P2, OPEN=P3; item STALE dinaikkan satu tingkat — umur sinyal, bukan bukti |
|
|
53
|
+
| `blockers:` | blocker eksplisit (TASK_BLOCKED / DEPENDENCY / VERIFICATION); kosong = tidak ada yang diklaim |
|
|
54
|
+
| `depends on:` | dependensi kanonik direkonsiliasi ke status saat baca; hanya COMPLETED yang *satisfied* |
|
|
55
|
+
| `next:` | tindak lanjut eksplisit — selalu lewat jalur otoritas yang ada; openwork TIDAK PERNAH mengeksekusi |
|
|
56
|
+
|
|
57
|
+
Arti penanda:
|
|
58
|
+
|
|
59
|
+
| Penanda | Makna | Tindak lanjut |
|
|
60
|
+
|---|---|---|
|
|
61
|
+
| `STALE` | baris tak bergerak ≥ ambang (default 7 hari, `--stale-days <n>`) | prioritas, bukan keputusan otoritas |
|
|
62
|
+
| `PROVENANCE-UNKNOWN` | tidak ada baris sesi di sessions.db — asal tak bisa ditelusuri | periksa manual; jangan dianggap rusak |
|
|
63
|
+
| `FROM:<sesi>` | task ini DIPINDAHKAN dari sesi lain (ledger `task_transfers`) | provenance asal eksplisit |
|
|
64
|
+
| `SIMILAR×N(UNPROVEN)` | N task berbagi judul ternormalisasi | **bukan bukti duplikat** — lihat ⑥ |
|
|
65
|
+
| `DUP-GROUP×N(UNPROVEN)` | grup duplikat **lintas sesi** (task + intent) beranggota N | lihat seksi "Grup duplikat lintas sesi" |
|
|
66
|
+
|
|
67
|
+
Filter: `--session <id>`, `--status <S>`, `--state <S>`, `--priority <P0..P3>`,
|
|
68
|
+
`--min-age-days <n>`, `--blocked`, `--depends-on <taskId>`, `--closed`,
|
|
69
|
+
`--json` (satu objek JSON mesin di stdout). Exit: `0` sukses (termasuk daftar
|
|
70
|
+
kosong), `1` gagal runtime/lookup, `2` salah pakai (nilai enum tak dikenal
|
|
71
|
+
termasuk).
|
|
72
|
+
|
|
73
|
+
**Batas kejujuran:** `openwork` tidak pernah menulis apa pun — tidak
|
|
74
|
+
mengakuisisi lease, tidak membuat sessions.db, tidak menulis backup manifest
|
|
75
|
+
korup, tidak memicu scheduler. Ia indeks, bukan otoritas. (Dijaga guard
|
|
76
|
+
arsitektur + tes nol-mutasi, kini termasuk jalur inventaris.)
|
|
77
|
+
|
|
78
|
+
## Kandidat intent: histori terstruktur, TANPA menebak prosa
|
|
79
|
+
|
|
80
|
+
Portofolio juga menampilkan **kandidat intent open** dari histori yang
|
|
81
|
+
terstruktur dan durable:
|
|
82
|
+
|
|
83
|
+
| Sumber | Kapan jadi kandidat | State |
|
|
84
|
+
|---|---|---|
|
|
85
|
+
| `plan.updated` | langkah plan `pending`/`active`/`blocked` **tanpa** task kanonik (atau baris task-nya hilang) | OPEN / PARTIAL / BLOCKED |
|
|
86
|
+
| `approval.requested` | belum ada `approval.settled` | WAITING_FOR_USER |
|
|
87
|
+
| sesi anak sub-agent | belum ada hasil terminal | DELEGATED |
|
|
88
|
+
| sesi anak + `turn.failed` | delegasi gagal | FAILED_NEEDS_FOLLOWUP |
|
|
89
|
+
| run `INTERRUPTED` | eksekusi terputus (restart/kill) | FAILED_NEEDS_FOLLOWUP |
|
|
90
|
+
|
|
91
|
+
Yang SENGAJA tidak dilakukan: memindai isi pesan bebas pengguna. Janji dari
|
|
92
|
+
prosa ("nanti kita perbaiki login") TIDAK PERNAH menjadi tugas — roadmap P14
|
|
93
|
+
melarang menganggap brainstorming sebagai task, dan menentukan kapan intent
|
|
94
|
+
prosa jadi komitmen adalah keputusan produk yang belum diputuskan pemilik.
|
|
95
|
+
|
|
96
|
+
Aturan kejujuran ekstraksi (dijaga tes):
|
|
97
|
+
|
|
98
|
+
1. Langkah plan yang menunjuk task kanonik yang masih OPEN **menempel sebagai
|
|
99
|
+
bukti** di entri task (`plan evidence`), bukan item duplikat.
|
|
100
|
+
2. Langkah plan yang mengaku `active` atas task yang SUDAH terminal tidak
|
|
101
|
+
dihidupkan kembali — masuk closure dengan alasan "canonical task
|
|
102
|
+
<status> supersedes plan claim", konflik diungkap, bukan disembunyikan.
|
|
103
|
+
3. Approval yang di-**allow** bukan bukti pekerjaan selesai — tidak
|
|
104
|
+
menghasilkan kandidat apa pun (hanya deny yang menghasilkan DECLINED).
|
|
105
|
+
4. Run `RUNNING` bukan open loop — runtime hidup adalah kondisi normal.
|
|
106
|
+
5. Cakupan pencarian dibatasi binding `cwd` baris sesi; **sesi anak mewarisi
|
|
107
|
+
cakupan leluhur termulaiannya** (hasil sub-agent tetap terlihat); sesi
|
|
108
|
+
tanpa binding dilabel UNBOUND dan dikeluarkan — tidak ada yang ditebak.
|
|
109
|
+
6. `plan.updated` adalah **snapshot**, bukan delta: adaptor menerbitkannya setiap
|
|
110
|
+
`todo_write` sukses dengan SELURUH daftar langkah. Hanya snapshot TERAKHIR
|
|
111
|
+
per **sesi** yang dibaca (bukan per `planId` — `planId` memuat nomor turn,
|
|
112
|
+
sedangkan daftar todo milik sesi). Akibatnya: versi pending/active lama tidak
|
|
113
|
+
muncul sebagai open loop kedua, langkah yang dihapus dari daftar tidak
|
|
114
|
+
dihidupkan, dan langkah yang masih terbuka tidak berganda di setiap turn.
|
|
115
|
+
|
|
116
|
+
## Grup duplikat lintas sesi (P14.3 penuh)
|
|
117
|
+
|
|
118
|
+
Kandidat dengan judul ternormalisasi sama **lintas sesi** (termasuk task vs
|
|
119
|
+
langkah plan) dikelompokkan dan diungkapkan:
|
|
120
|
+
|
|
121
|
+
```
|
|
122
|
+
Similar groups — 1 (UNPROVEN, never auto-merged)
|
|
123
|
+
"fix login bug" ×2 across 2 session(s) · DIVERGENT states
|
|
124
|
+
sessions: p14fs-a · p14fs-b
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
Grup dengan state yang saling bertentangan ditandai `DIVERGENT` (jumlahnya
|
|
128
|
+
juga di header + `counts.conflicts`). Grup **tidak pernah** menyatukkan apa
|
|
129
|
+
pun: perpindahan otoritas tetap wajib adopsi eksplisit (②), merge tetap
|
|
130
|
+
satu-sesi (⑥). Tugas berulang yang sengaja independen boleh berbagi grup —
|
|
131
|
+
itu penanda untuk diperiksa, bukan vonis.
|
|
132
|
+
|
|
133
|
+
## ①b Inventaris: `minicode openwork inventory [--json]`
|
|
134
|
+
|
|
135
|
+
Inventaris P14.0 lintas sumber, read-only: jumlah sesi (in-scope / foreign /
|
|
136
|
+
unbound / anak), task (total/open/terminal), event presentasi per tipe, run,
|
|
137
|
+
manifest checkpoint (termasuk yang **corrupt** — dilabel, tidak dibackup oleh
|
|
138
|
+
proyeksi), langkah plan, approval, dan hasil sub-agent. Sesi yang dikeluarkan
|
|
139
|
+
dicantumkan **dengan alasannya**. Event yang gagal didekode dilaporkan sebagai
|
|
140
|
+
"unreadable", tidak disembunyikan.
|
|
141
|
+
|
|
142
|
+
## ①c Konteks: `minicode openwork context --session <id> --task <taskId>`
|
|
143
|
+
|
|
144
|
+
Context pack P14.5 untuk satu task: field kanonik (status/revisi/verification/
|
|
145
|
+
dependsOn/evidence), state + prioritas + blocker + next action, bukti langkah
|
|
146
|
+
plan, ketersediaan checkpoint (termasuk corrupt), provenance transfer/merge,
|
|
147
|
+
freshness, dan **checklist resume**. Pack ini murni baca — checklist menunjuk
|
|
148
|
+
jalur yang MEMAKSAK otoritas saat resume (ceiling P12, gate continuity P13.3,
|
|
149
|
+
claim generation TaskStore, budget/cancellation P12/P13); openwork sendiri
|
|
150
|
+
tidak memeriksa apalagi mengeksekusi. Exit `1` bila task tak ditemukan,
|
|
151
|
+
`2` bila id cacat.
|
|
152
|
+
|
|
153
|
+
## ② Mengadopsi: `--adopt-task <source>/<taskId>`
|
|
154
|
+
|
|
155
|
+
Satu task per invokasi, HANYA saat startup sesi tujuan, sebelum turn pertama:
|
|
156
|
+
|
|
157
|
+
```
|
|
158
|
+
minicode --session target --adopt-task p14ow-source/t1 "lanjutkan pekerjaan ini"
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
Yang terjadi (satu transaksi TaskStore, dicek ulang di dalam transaksi):
|
|
162
|
+
inkarnasi sumber+tujuan, revisi, **kedua lease** (token sumber dan tujuan),
|
|
163
|
+
status non-terminal, konsistensi lineage, tabrakan id target, dan provenance
|
|
164
|
+
relasi. Penulis sesi sumber yang **hidup** = `REFUSED_SOURCE_BUSY` (tidak ada
|
|
165
|
+
takeover paksa). Lease sumber kedaluwarsa = takeover + **fence epoch** —
|
|
166
|
+
proses lama tidak bisa lagi renew/release/menulis/menjadwalkan sesi sumber.
|
|
167
|
+
|
|
168
|
+
Yang TIDAK terjadi: tidak menyalin task, tidak membuat generasi baru, tidak
|
|
169
|
+
menandai selesai, tidak menyentuh jurnal runtime/child run/approval, dan
|
|
170
|
+
**tidak memicu scheduler**. Task in-flight hasil adopsi tetap `IN_PROGRESS`
|
|
171
|
+
dengan lineage asli — apakah boleh dilanjutkan adalah keputusan gate (③),
|
|
172
|
+
bukan adopsi.
|
|
173
|
+
|
|
174
|
+
Rantai relasi diadopsi **berurutan** (parent/dependency dulu, lalu anak);
|
|
175
|
+
penolakan menamai id yang belum diadopsi. Id task tidak pernah direnumber.
|
|
176
|
+
|
|
177
|
+
## ③ Melanjutkan: `/scheduler run` (manual, tersupervisi)
|
|
178
|
+
|
|
179
|
+
Adopsi tidak menyalakan scheduler. Lanjutan tetap lewat trigger manual yang
|
|
180
|
+
sudah ada (`/scheduler run` di sesi TUJUAN; butuh `--enable-scheduler` saat
|
|
181
|
+
memulai sesi CLI, sedangkan sesi daemon hosted mendapatkannya via
|
|
182
|
+
`--runtime owned`). Reconcilasi menilai task in-flight hasil
|
|
183
|
+
adopsi lewat **continuity gate P13.3** — kontraknya tidak berubah:
|
|
184
|
+
|
|
185
|
+
- `SAFE_TO_RETRY` (bukti resume + admission + **seluruh** scope tool otonom
|
|
186
|
+
read-only) → revert ke PENDING → **claim generasi BARU** → dispatch serial.
|
|
187
|
+
- Selain itu → `HOLD` / `REQUIRES_VERIFIER`, baris tidak disentuh, nol
|
|
188
|
+
dispatch. Tanpa gate = HOLD (fail-closed).
|
|
189
|
+
|
|
190
|
+
**Tidak pernah ada replay instruksi tool jurnal lama** — work item hanya
|
|
191
|
+
membawa `(taskId, title, instruction, sessionId)`; eksekusi baru lahir dari
|
|
192
|
+
claim baru. Permission ceiling P12, budget, cancellation, dan stop criteria
|
|
193
|
+
P13 tetap berlaku persis seperti sesi biasa.
|
|
194
|
+
|
|
195
|
+
## ④ Menutup: lifecycle biasa
|
|
196
|
+
|
|
197
|
+
Selesaian lewat jalur kanonik yang sudah ada (verifier / `todo_write` /
|
|
198
|
+
operator) — P14 tidak punya jalur penutupan sendiri dan tidak pernah
|
|
199
|
+
menulis `COMPLETED` atas nama operator.
|
|
200
|
+
|
|
201
|
+
## ⑤ Feedback penutupan: `minicode openwork --closed`
|
|
202
|
+
|
|
203
|
+
Closure feedback adalah **pembacaan ulang status kanonik + ledger**, bukan
|
|
204
|
+
kesimpulan: task yang sudah terminal dan punya provenance P14 (transfer
|
|
205
|
+
atau merge) muncul dengan `status`, `closed`, `FROM <sesi>`,
|
|
206
|
+
`duplicate-of <task>`, dan evidence operator. Duplikat yang dibuka kembali
|
|
207
|
+
operator otomatis muncul lagi di seksi open — status saat itulah kebenaran.
|
|
208
|
+
|
|
209
|
+
Sejak pengiriman full-scope, closure juga mencakup **artefak intent terminal**
|
|
210
|
+
(`kind INTENT`) dengan **label klaim** yang wajib dibaca:
|
|
211
|
+
|
|
212
|
+
| `claim` | Arti |
|
|
213
|
+
|---|---|
|
|
214
|
+
| `verified` | task kanonik terminal dengan `verification.verdict = passed` |
|
|
215
|
+
| `unverified` | klaim penyelesaian oleh artefak (mis. plan step `completed`) **tanpa** verifikasi — ditampilkan apa adanya, BUKAN disembunyikan, BUKAN dianggap terbukti |
|
|
216
|
+
| `not-applicable` | DECLINED/CANCELLED — tidak ada klaim penyelesaian untuk diverifikasi |
|
|
217
|
+
|
|
218
|
+
Termasuk: approval yang ditolak pengguna → `DECLINED` (terminal, tidak pernah
|
|
219
|
+
hidup lagi sebagai open loop), dan langkah plan yang mengaku `active` atas task
|
|
220
|
+
terminal → closure dengan alasan "canonical task `<status>` supersedes plan
|
|
221
|
+
claim" — konflik klaim diungkap, tidak ditelan.
|
|
222
|
+
|
|
223
|
+
## ⑤b Ekspor: `minicode openwork export --out <path> [--format json|md] [--force]`
|
|
224
|
+
|
|
225
|
+
- `json` (default) — objek portofolio lengkap (selalu menyertakan inventaris
|
|
226
|
+
P14.0), indentasi 2 spasi.
|
|
227
|
+
- `md` — laporan manusia tersanitasi (judul/evidence bebas sekuens ANSI).
|
|
228
|
+
- Ditulis **atomik** (`atomicWriteText`); **menolak menimpa** berkas yang ada
|
|
229
|
+
kecuali `--force`; kegagalan tulis = exit `1` tanpa berkas sampah `.tmp.*`.
|
|
230
|
+
|
|
231
|
+
## ⑥ Dedup eksplisit: `openwork merge`
|
|
232
|
+
|
|
233
|
+
```
|
|
234
|
+
minicode openwork merge --session target --keep t1 --drop t2 \
|
|
235
|
+
--evidence "satu unit kerja yang sama: sama-sama memperbaiki login bug"
|
|
236
|
+
```
|
|
237
|
+
|
|
238
|
+
Aturan (dijaga tes + guard):
|
|
239
|
+
|
|
240
|
+
1. **Evidence WAJIB** dan direkam utuh di ledger append-only `task_merges`.
|
|
241
|
+
Kemiripan judul TIDAK PERNAH menjadi bukti; `SIMILAR×N(UNPROVEN)` hanyalah
|
|
242
|
+
penanda. Tidak ada merge otomatis dari proyeksi.
|
|
243
|
+
2. Duplikat ditutup **`CANCELLED`, bukan `COMPLETED`** — menyatakan "dikerjakan
|
|
244
|
+
di task lain" tidak boleh meng-inferr penyelesaian.
|
|
245
|
+
3. Penulisan status lewat `patchTask` (lifecycle biasa: revisi maju, ownership
|
|
246
|
+
in-flight dilepas) + INSERT ledger dalam **SATU transaksi** — gagal ledger =
|
|
247
|
+
status ikut rollback.
|
|
248
|
+
4. Duplikat terminal ditolak (pekerjaan tertutup tidak dibuka untuk ditutup
|
|
249
|
+
lagi). Survivor terminal BOLEH (kasus klasik: pending ternyata sudah
|
|
250
|
+
dikerjakan task yang selesai — duplikat tetap CANCELLED).
|
|
251
|
+
5. **Antar-sesi ditolak**: merge hanya satu namespace. Duplikat lintas sesi
|
|
252
|
+
harus diadopsi dulu (②), lalu merge di sesi tujuan.
|
|
253
|
+
6. Pembalikan = penulisan lifecycle biasa (patch status kembali). Ledger
|
|
254
|
+
append-only tetap mencatat deklarasi — audit sejarah, status = kebenaran.
|
|
255
|
+
|
|
256
|
+
## Peta bukti
|
|
257
|
+
|
|
258
|
+
| Klaim | Bukti |
|
|
259
|
+
|---|---|
|
|
260
|
+
| Proyeksi read-only (nol mutasi) | `test/p14-open-work.test.ts` (proyeksi nol-mutasi) |
|
|
261
|
+
| Nol mutasi jalur PENUH (histori + inventaris ikut diuji; tanpa backup manifest korup) | `test/p14-full-scope.test.ts` (zero-mutasi proyeksi penuh) |
|
|
262
|
+
| UNKNOWN/stale dilabel jujur | `test/p14-open-work.test.ts` (provenance UNKNOWN tanpa membuat sessions.db; STALE ambang disuntik) |
|
|
263
|
+
| Kemiripan bukan identitas | idem (SIMILAR UNPROVEN, ambiguous tetap terpisah) |
|
|
264
|
+
| Grup duplikat LINTAS SESI + konflik divergent, tanpa merge otomatis | `test/p14-full-scope.test.ts` (P14.3 grup lintas sesi) |
|
|
265
|
+
| Kontrak P14.1: state/prioritas/next action murni + fail-closed | idem (P14.1 kontrak murni) |
|
|
266
|
+
| Ekstraksi intent: approval allow ≠ COMPLETED; pesan bebas tak dipindai; cakupan lineage | idem (P14.2 extractIntentCandidates) |
|
|
267
|
+
| Klaim plan atas task terminal: tak dihidupkan, konflik diungkap, label claim verified/unverified | idem (P14.2 proyeksi histori) |
|
|
268
|
+
| Inventaris P14.0 lintas sumber + sesi dikeluarkan dengan alasan | idem (P14.0 inventaris) |
|
|
269
|
+
| Matriks forensik: restart/terputus/pembatalan/stale | idem (P14.6 matriks forensik) |
|
|
270
|
+
| Portofolio: blocker/dependensi/verifikasi/next action | idem (P14.4 bidang portofolio) |
|
|
271
|
+
| CLI: filter baru, inventory, context, export atomik + sanitasi | idem (CLI full-scope; exit 0/1/2 sesuai I28) |
|
|
272
|
+
| Merge aman/auditable/atomic | `test/p14-open-work.test.ts` (DECLARED/refusal/terminal/stale/atomic-rollback/pembalikan) |
|
|
273
|
+
| Alur ①→⑤ utuh, generasi baru, tanpa replay | idem (P14.5 alur operator) |
|
|
274
|
+
| Adopsi: otoritas ganda, fence, ledger transfer | `test/p14-cross-session-adoption.test.ts` (14 skenario) |
|
|
275
|
+
| Guard "bukan TaskStore/scheduler kedua" + proyeksi murni | `test/p2-architecture-guards.test.ts` |
|
|
276
|
+
| Kontrak penulis CLI (OAP-008) | `test/writer-inventory.test.ts` (deklarasi per writer) |
|
|
277
|
+
| Snapshot `plan.updated` dikolaps per sesi (tanpa duplikasi riwayat) | `test/p14-full-scope.test.ts` (5 tes snapshot plan) |
|
|
278
|
+
|
|
279
|
+
## Batas scope yang TIDAK diklaim
|
|
280
|
+
|
|
281
|
+
Dokumen ini sengaja tidak menjanjikan hal-hal berikut; semuanya eksklusi
|
|
282
|
+
scope P14 yang disetujui pemilik 2026-10-26, bukan pekerjaan tertunda:
|
|
283
|
+
|
|
284
|
+
| Tidak ada | Alasan |
|
|
285
|
+
|---|---|
|
|
286
|
+
| Ekstraksi intent dari prosa bebas | Dilarang eksplisit oleh roadmap ("jangan anggap setiap pesan brainstorming sebagai tugas") |
|
|
287
|
+
| Readout TUI `/openwork` | Teks milestone hanya "tampilkan/ekspor"; permukaan TUI baru butuh kontrak terminal sendiri |
|
|
288
|
+
| Merge dengan lease/admission | Di luar teks milestone; merge tetap satu transaksi + ledger audit |
|
|
289
|
+
| Merge lintas sesi tanpa adopsi eksplisit | Model otoritas roadmap: portfolio = projection, perubahan task lewat jalur authority |
|
|
290
|
+
| Klaim release-ready | Closure P14 hanya untuk kontrak bukti-terstruktur; limitasi P13 tetap berlaku dan tree masih uncommitted |
|
package/docs/README.md
CHANGED
|
@@ -16,7 +16,7 @@ MiniCode adalah coding agent terminal yang dibangun di atas kernel MiniCore. Jal
|
|
|
16
16
|
|
|
17
17
|
## Peta dokumentasi
|
|
18
18
|
|
|
19
|
-
`SUMMARY.md` adalah daftar navigasi
|
|
19
|
+
`SUMMARY.md` adalah daftar navigasi; dibaca build minilabs untuk membangun indeks halaman. Versi terbit tersedia di [minilabs.id/projects/minicode/docs](https://minilabs.id/projects/minicode/docs/). [Arsitektur](architecture.md) memuat peta struktur dan alur runtime.
|
|
20
20
|
|
|
21
21
|
## Pengembangan
|
|
22
22
|
|
package/docs/SUMMARY.md
CHANGED
|
@@ -1,53 +1,67 @@
|
|
|
1
1
|
# Summary
|
|
2
2
|
|
|
3
|
-
* [
|
|
3
|
+
* [MiniCode — Dokumentasi](README.md)
|
|
4
4
|
|
|
5
5
|
## Memulai
|
|
6
6
|
|
|
7
|
-
* [Konsep & Desain](concepts.md)
|
|
8
7
|
* [Instalasi](getting-started.md)
|
|
9
8
|
* [Quickstart 5 menit](quickstart.md)
|
|
9
|
+
* [Konsep & Desain](concepts.md)
|
|
10
|
+
* [Memilih Mode](choosing-mode.md)
|
|
10
11
|
* [Glosarium](glossary.md)
|
|
11
12
|
|
|
12
13
|
## Menggunakan
|
|
13
14
|
|
|
14
15
|
* [CLI — Mode & Flags](cli.md)
|
|
15
|
-
* [Memilih Mode](choosing-mode.md)
|
|
16
16
|
* [TUI — Slash & Keyboard](repl.md)
|
|
17
17
|
* [Otomasi & CI](exec.md)
|
|
18
|
-
* [Config — File & Lokasi Data](config.md)
|
|
19
|
-
* [Config & Provider](config-providers.md)
|
|
20
|
-
* [Pricing & Budget](pricing-budget.md)
|
|
21
|
-
* [Environment Variables](environment.md)
|
|
22
18
|
* [Skills & Hooks](skills.md)
|
|
19
|
+
* [Pricing & Budget](pricing-budget.md)
|
|
23
20
|
|
|
24
|
-
##
|
|
21
|
+
## Kemampuan (tools & integrasi)
|
|
25
22
|
|
|
26
23
|
* [Tools](tools.md)
|
|
27
24
|
* [Sub-Agents & Tasks](agents.md)
|
|
28
25
|
* [MCP & LSP](mcp-lsp.md)
|
|
26
|
+
|
|
27
|
+
## Konfigurasi
|
|
28
|
+
|
|
29
|
+
* [Config — File & Lokasi Data](config.md)
|
|
30
|
+
* [Config & Provider](config-providers.md)
|
|
31
|
+
* [Environment Variables](environment.md)
|
|
32
|
+
|
|
33
|
+
## State & Memori
|
|
34
|
+
|
|
29
35
|
* [Memory & Sessions](memory-sessions.md)
|
|
30
36
|
* [Verify & Benchmark](verify-benchmark.md)
|
|
31
37
|
|
|
32
38
|
## Keamanan
|
|
33
39
|
|
|
34
|
-
* [Security Model](security-model.md)
|
|
35
|
-
* [Policy & Sandbox](policy-sandbox.md)
|
|
36
|
-
* [Keamanan](security.md)
|
|
40
|
+
* [Security Model](security-model.md) — ancaman & trust boundary
|
|
41
|
+
* [Policy & Sandbox](policy-sandbox.md) — mode, guard, sandbox
|
|
42
|
+
* [Keamanan](security.md) — mekanisme & bukti pengukuran
|
|
43
|
+
|
|
44
|
+
## Bantuan
|
|
45
|
+
|
|
37
46
|
* [Troubleshooting](troubleshooting.md)
|
|
38
47
|
|
|
39
|
-
##
|
|
48
|
+
## Eksperimental
|
|
49
|
+
|
|
50
|
+
* [Autonomous Scheduler](autonomous-scheduler.md)
|
|
51
|
+
* [Open Work — Lintas Sesi](P14_OPEN_WORK.md)
|
|
52
|
+
|
|
53
|
+
## Kontributor & Arsitektur
|
|
40
54
|
|
|
41
|
-
* [Arsitektur](architecture.md)
|
|
42
|
-
* [Kontrak Terminal](terminal.md)
|
|
55
|
+
* [Arsitektur & Peta Repository](architecture.md)
|
|
56
|
+
* [Kontrak Terminal (ringkas)](terminal.md)
|
|
43
57
|
* [Contributing](contributing.md)
|
|
44
58
|
|
|
45
|
-
##
|
|
59
|
+
## Spesifikasi internal (FROZEN — untuk kontributor)
|
|
46
60
|
|
|
47
|
-
* [Terminal Contract
|
|
48
|
-
* [Output Event Model
|
|
49
|
-
* [Output Protocol Spec
|
|
50
|
-
* [Output Rendering Spec
|
|
51
|
-
* [Output UX Rules
|
|
52
|
-
* [Control Plane
|
|
53
|
-
* [UI Render Pipeline
|
|
61
|
+
* [Terminal Contract - 35 invariant, v7.12](TERMINAL_CONTRACT.md)
|
|
62
|
+
* [Output Event Model](OUTPUT_EVENT_MODEL.md)
|
|
63
|
+
* [Output Protocol Spec](OUTPUT_PROTOCOL_SPEC.md)
|
|
64
|
+
* [Output Rendering Spec](OUTPUT_RENDERING_SPEC.md)
|
|
65
|
+
* [Output UX Rules](OUTPUT_UX_RULES.md)
|
|
66
|
+
* [Control Plane Map](CONTROL-PLANE-MAP.md)
|
|
67
|
+
* [UI Render Pipeline](UI_RENDER_PIPELINE.md)
|
|
@@ -1,4 +1,14 @@
|
|
|
1
|
-
# Kontrak Terminal MiniCode (TUI fullscreen — v7.
|
|
1
|
+
# Kontrak Terminal MiniCode (TUI fullscreen — v7.12, 2026-11-10)
|
|
2
|
+
|
|
3
|
+
Perubahan v7.12: footer `context` & `metrics` (window %) kini **live per step**
|
|
4
|
+
selama turn berjalan — kernel meng-emit estimasi konteks turn-store via event
|
|
5
|
+
`provider:extension` kind `context-window` SETELAH `step:completed`, dan footer
|
|
6
|
+
membacanya alih-alih terpaku pada `session.contextTokens` (committed store yang
|
|
7
|
+
hanya berubah saat `turn:completed`). Saat idle, footer kembali ke nilai
|
|
8
|
+
committed. Estimator sama sekali tidak berubah/berduplikasi — tetap satu sumber
|
|
9
|
+
(`estimateSessionContext`), hanya nilai yang dibaca saat turn aktif memakai
|
|
10
|
+
turn-store (yang tumbuh), bukan committed store (beku). Sumber: `vendor/minicore/
|
|
11
|
+
src/core/loop.ts` (emit) + `cli/tui.ts` (wiring footer).
|
|
2
12
|
|
|
3
13
|
Perubahan v7.11: thinking & jawaban di TUI dan renderer linear kini membungkus di
|
|
4
14
|
batas kata (`wrapByWidth`) — tidak memotong di tengah kata — dan baris diff ikut
|
|
@@ -209,7 +219,23 @@ Non-TTY (pipe/redirect/CI/file): **0 cursor control, 0 alternate screen,
|
|
|
209
219
|
## Invariant (nomor dipakai di peta proteksi)
|
|
210
220
|
|
|
211
221
|
1. Satu tampilan interaktif: TUI fullscreen; frame penuh tiap repaint (tepat
|
|
212
|
-
`rows` baris); scrollback utama tak tersentuh selama sesi.
|
|
222
|
+
`rows` baris); scrollback utama tak tersentuh selama sesi. Frame LOGIS tetap
|
|
223
|
+
penuh `rows` baris (hasil layar identik), namun PENULISAN FISIK ke terminal
|
|
224
|
+
boleh inkremental per SEL dan dikirim sebagai SATU `write` per frame
|
|
225
|
+
(`screen.paint` memakai diff sel terhadap frame sebelumnya; repaint
|
|
226
|
+
pertama/resize/perubahan jumlah kolom tetap `ESC[H`+`ESC[2J` clear penuh)
|
|
227
|
+
— ini murni optimasi menghapus flicker/latensi `ESC[2J` tiap keystroke,
|
|
228
|
+
bukan perubahan perilaku yang terlihat. Diff per sel menyimpan gaya sebagai
|
|
229
|
+
STATE SGR ternormalisasi (urutan kanonik, bukan riwayat sekuens), sehingga
|
|
230
|
+
sel yang identik secara visual tidak pernah ditulis ulang; glyph lebar
|
|
231
|
+
(CJK/emoji) dilindungi sel lanjutan (`cont`) agar diff tidak memotong glyph.
|
|
232
|
+
Penulisan per baris berubah: dari kolom berbeda PERTAMA sampai akhir baris
|
|
233
|
+
(prefix identik dilewati), didahului EL (`ESC[0K`) — ekor dihapus-lalu-ditulis
|
|
234
|
+
ulang supaya sisa glyph lebar / ekor baris lama tidak menempel. Tulis asing ke
|
|
235
|
+
stderr selama alt-screen hidup (mis. `[hooks] skipped …`, warning provider)
|
|
236
|
+
menandai terminal "kotor" (`statusline.consumeScreenDrift`) dan memaksa
|
|
237
|
+
repaint penuh pada paint berikutnya; tanpa ini baris yang kebetulan tak
|
|
238
|
+
berubah akan mempertahankan fragmen asing di atas diff inkremental.
|
|
213
239
|
2. stdout/stderr contract seperti tabel di atas (TTY & non-TTY deterministic).
|
|
214
240
|
3. Satu kepemilikan layar (`App`); popup satu lifecycle (`suspend`/`resume` +
|
|
215
241
|
`paintRegion`).
|
|
@@ -233,6 +259,12 @@ Non-TTY (pipe/redirect/CI/file): **0 cursor control, 0 alternate screen,
|
|
|
233
259
|
|
|
234
260
|
13. Status bar: 1 baris dasar (`✦ 00.00.00 Work Mode: Discuss model cwd …
|
|
235
261
|
context Permission Mode: Auto`) dari sumber yang sama dengan angka sesi.
|
|
262
|
+
Nilai `context` (dan `metrics` window %) saat turn AKTIF memakai occupancy
|
|
263
|
+
LIVE turn-store yang di-emit kernel per step (event `provider:extension`
|
|
264
|
+
kind `context-window`, setelah `step:completed`); saat idle kembali ke
|
|
265
|
+
`session.contextTokens` (committed store). Estimator tetap satu sumber —
|
|
266
|
+
hanya store yang dibaca berganti antara turn-store (tumbuh) vs committed
|
|
267
|
+
(beku), tak ada duplikasi angka sumber (v7.12).
|
|
236
268
|
Ikon gembok `🔒` mengikuti Permission Mode di ujung kanan: terang bila
|
|
237
269
|
bash allow-list aktif (restrictBash + mode `Auto`), redup bila tidak.
|
|
238
270
|
Work Mode berada di kiri; Permission Mode cyan berada di kanan dekat
|
|
@@ -273,7 +305,7 @@ Non-TTY (pipe/redirect/CI/file): **0 cursor control, 0 alternate screen,
|
|
|
273
305
|
saat turn). Composer memakai tinggi tetap: prompt saat editing, dots saat
|
|
274
306
|
reasoning, atau tool target; satu baris kosong selalu memisahkannya dari
|
|
275
307
|
footer. Proyeksi presentasi: baris running di-pin dari snapshot, elapsed
|
|
276
|
-
tetap pada ledger tool, status tool final memakai
|
|
308
|
+
tetap pada ledger tool, status tool final memakai warna + kata
|
|
277
309
|
(`completed`/`failed`/`denied`/`cancelled`/`interrupted`), retry dan grup
|
|
278
310
|
anak mengikuti model, serta ringkasan turn masuk sebagai system entry.
|
|
279
311
|
**Retry provider:** setiap `model.delta`/`reasoning.delta` live membawa
|
|
@@ -310,7 +342,11 @@ Non-TTY (pipe/redirect/CI/file): **0 cursor control, 0 alternate screen,
|
|
|
310
342
|
berikutnya = auto-batal (cancel), total semantik 90 dtk lama; SATU
|
|
311
343
|
ketikan apa pun me-reset kedua timer.
|
|
312
344
|
22. Thinking terlihat SECARA DEFAULT (expanded): composer memakai dots clock;
|
|
313
|
-
|
|
345
|
+
dengan panel aktivitas ON (default TUI; `/fold`), transkrip menampilkan
|
|
346
|
+
AREA thinking = blok live maks 10 baris visual terakhir (header
|
|
347
|
+
`+ thinking`, penanda `… N baris lagi`), lalu saat fase berakhir diringkas
|
|
348
|
+
SATU baris (`+ thinking · N baris`) dengan detail penuh tetap tersedia di
|
|
349
|
+
`/expand`; dengan panel OFF, perilaku legacy = alir thinking ber-warna terbaca (`c.thinking`,
|
|
314
350
|
abu-kebiruan) dan ber-indentasi 2 kolom, dipisah SATU baris kosong dari
|
|
315
351
|
jawaban/ledger — bukan `dim`; minimized (`/thinking`, `MINICODE_SHOW_THINKING=0`)
|
|
316
352
|
= bersih tanpa marker (`… thinking`); isi tetap tersedia di `/expand`;
|
|
@@ -347,14 +383,22 @@ Non-TTY (pipe/redirect/CI/file): **0 cursor control, 0 alternate screen,
|
|
|
347
383
|
dan `approval.*` terstruktur plus teks delta. Exit code, pipe safety, dan
|
|
348
384
|
determinisme non-TTY tetap sama.
|
|
349
385
|
|
|
350
|
-
27. Painter transient stderr (spinner setup/cek-update,
|
|
351
|
-
DITAHAN selama layar interaktif memegang terminal: `beginInteractiveScreen`
|
|
386
|
+
27. Painter transient stderr (spinner setup/cek-update, bar loading startup,
|
|
387
|
+
garis status turn) DITAHAN selama layar interaktif memegang terminal: `beginInteractiveScreen`
|
|
352
388
|
(`src/ui/runtime/statusline.ts`) membisukan `paintWrite` (nol byte + baris
|
|
353
389
|
painter dibersihkan sekali saat layar mengambil alih), nested dihitung,
|
|
354
390
|
release idempoten. Pemegang: `askLine`/`askSecret`/`runPicker` (raw-mode)
|
|
355
391
|
dan `openAltScreen` (alt-screen, release di `close()`). Tanpa ini tick
|
|
356
392
|
`\r\x1b[2K` spinner menghapus baris prompt wizard (laporan "macet di
|
|
357
|
-
Menyiapkan sesi…").
|
|
393
|
+
Menyiapkan sesi…"). Bar loading (`src/ui/runtime/loading-bar.ts`) adalah
|
|
394
|
+
painter transient jenis kedua: single-line blok `▓░` + persen + label,
|
|
395
|
+
digambar ulang HANYA saat `update(label, percent)` dipanggil (bukan
|
|
396
|
+
interval), TTY-only (non-TTY = no-op nol byte), label disanitasi, kursor
|
|
397
|
+
direstore di `exit`. Fase startup (update check/install/restart, provider,
|
|
398
|
+
RAG, tool, kernel, resume) memanggil `update`; diagnostik startup
|
|
399
|
+
(resume/recovery/context/dll) DITUNDA saat REPL dan di-flush ke transcript
|
|
400
|
+
TUI (`ctx.startupNotices`), sedangkan non-interaktif tetap mencetak langsung.
|
|
401
|
+
Output npm saat auto-update disembunyikan (`stdio: pipe` dibuang).
|
|
358
402
|
28. Kontrak exit code: **0** sukses/help, **1** gagal runtime/lookup, **2**
|
|
359
403
|
salah pakai (argumen hilang/malformed, subcommand asing). Flag sebagai
|
|
360
404
|
positional id = salah pakai (exit 2). `exec --json` yang gagal di fase
|
|
@@ -459,7 +503,7 @@ status bar `✦ 00.00.00 Work Mode: Discuss model cwd … context Permission
|
|
|
459
503
|
jam; tanpa bullet separator; permission rata kanan dekat token konteks; label
|
|
460
504
|
dipadatkan pada terminal sempit; `🔒` terang = bash allow-list aktif, redup = tidak)
|
|
461
505
|
+ satu spacer sebelum footer · ledger tool
|
|
462
|
-
` › name target` (hijau) / merah saat error · error
|
|
506
|
+
` › name target` (hijau) / merah saat error · error `pesan` berwarna merah sekali per
|
|
463
507
|
kegagalan · pesan error TUI = formatter kanonik (`formatError`,
|
|
464
508
|
`src/ui/render/errors.ts`): credential di-redaksi (bearer/key/query), escape
|
|
465
509
|
ANSI dibuang, body provider diringkas + dipotong; `e.message` mentah tak
|
|
@@ -468,11 +512,11 @@ belakang + kotak terpusat (form di dalam) + Esc tutup · approval tercatat ·
|
|
|
468
512
|
`/status`, `/history`, `/help` ringkas & `/expand` mengalir ke transkrip ·
|
|
469
513
|
`/mode` = permission mode · `/work-mode` = WorkMode (intent layer) ·
|
|
470
514
|
`/fold` = lipat aktivitas tool per turn (`MINICODE_MINIMIZE_ACTIVITY`, ON di TUI) —
|
|
471
|
-
baris ledger per-tool dirangkum jadi SATU baris ringkas (
|
|
515
|
+
baris ledger per-tool dirangkum jadi SATU baris ringkas (`n tools · nama · x ok · y gagal`),
|
|
472
516
|
tidak hilang diam-diam; detail dibuka via `/expand` ·
|
|
473
517
|
tabel markdown dirender kotak ber-garis (opencode-like) ber-`wrap` (konten panjang
|
|
474
518
|
tidak kepotong) + margin kiri 1 kolom; teks paragraf ber-margin kiri 1 kolom ·
|
|
475
|
-
Projection V2: `› name target … running`, ledger status ber-
|
|
519
|
+
Projection V2: `› name target … running`, ledger status ber-warna/kata,
|
|
476
520
|
retry/grup anak (anak ber-identitas run = baris `↳ run_<8>` sendiri; tanpa
|
|
477
521
|
identitas run = hitungan `n child tools`), ringkasan turn, dan marker evict
|
|
478
522
|
sesuai flag ·
|
|
@@ -534,6 +578,7 @@ panjang).
|
|
|
534
578
|
- `test/tui-transcript.test.ts` — projection source-mapped: wrap, CJK/ANSI, user prefix, tabel TSV, selection text, cap buffer live, dan render markdown inline jawaban model (heading/bold/code; delimiter fence disembunyikan, isi fence dan gema user tetap literal).
|
|
535
579
|
- `test/screen-buffer.test.ts` — parser frame harness (unit).
|
|
536
580
|
- `test/tui-transcript.test.ts` — I7/I12/I17/I22 (ledger satu baris per tool, cap 5000 + marker evict, `total()` monotonik kebal evict, viewport, thinking minimized/expanded).
|
|
581
|
+
- `test/thinking-area.test.ts` — I22 area thinking: blok live maks 10 baris (header/`… N baris lagi`), ringkasan 1 baris + detail `/expand` saat turn selesai, tanpa duplikasi, dan fallback legacy saat panel OFF.
|
|
537
582
|
- `test/presentation-projections.test.ts` — I12/I17/I32 (projection
|
|
538
583
|
snapshot, running/elapsed, status terminal, retry/child grouping, summary,
|
|
539
584
|
marker evict + `total()` monotonik, dan parity flag OFF) + F-AGENT-1
|
|
@@ -578,6 +623,9 @@ panjang).
|
|
|
578
623
|
- `test/approval-tui.test.ts` — I23 (blok + keputusan tercatat, deny;
|
|
579
624
|
stdout-pipe tanpa sink = deny).
|
|
580
625
|
- `test/footer-render.test.ts` — I13 (label title case, Work Mode kiri dan Permission Mode cyan rata kanan dekat konteks, posisi kolom stabil, fallback terminal sempit, ikon gembok 🔒 terang/redup).
|
|
626
|
+
- `test/e2e.test.ts` — I13 v7.12 (kernel meng-emit `provider:extension`
|
|
627
|
+
kind `context-window` berisi `usedTokens`/`windowTokens` setelah
|
|
628
|
+
`step:completed` — sumber live-occupancy footer; nilai > 0 terbukti).
|
|
581
629
|
- `test/work-mode-runtime.test.ts` — I35 (WorkMode runtime: ceiling permission
|
|
582
630
|
dievaluasi per pemanggilan tool; transisi BUILD/EXECUTE↔DISCUSS↔PLAN pada sesi
|
|
583
631
|
yang sama; daftar tool yang dilihat kernel ikut berubah; hooks mengikuti
|
|
@@ -618,6 +666,9 @@ panjang).
|
|
|
618
666
|
final, sementara sink linear memberi marker dan usage tetap tercatat.
|
|
619
667
|
- `test/transient-arbitration.test.ts` — I3/I9/I27 (hold layar interaktif:
|
|
620
668
|
picker/askLine, nesting, delayMs).
|
|
669
|
+
- `test/loading-bar.test.ts` — I27/I6 (bar loading: non-TTY no-op nol byte,
|
|
670
|
+
delay pertama, progres blok+persen+label, sanitasi label, stop idempoten,
|
|
671
|
+
restore kursor, mutual exclusion transient, ditahan layar interaktif).
|
|
621
672
|
- `test/statusline-bun-guard.test.ts` — I4 (painter Bun/Windows: painter
|
|
622
673
|
dinonaktifkan sendiri, write asli dipulihkan).
|
|
623
674
|
- `test/turn-status.test.ts` — garis status turn lifecycle deterministik
|
|
@@ -640,7 +691,19 @@ panjang).
|
|
|
640
691
|
`test/info-window.test.ts` — DIHAPUS bersama REPL/chrome/jendela.
|
|
641
692
|
- `test/cli-commands.test.ts` — /status cetak, /sessions popup.
|
|
642
693
|
- `test/screen.test.ts` — I16 (pairing + paintRegion; open/paint writer failure
|
|
643
|
-
mencoba memulihkan alt-screen dan reset region)
|
|
694
|
+
mencoba memulihkan alt-screen dan reset region) + I1 (satu `write` per frame;
|
|
695
|
+
repaint penuh saat frame pertama / drift stderr / perubahan kolom, dan diff
|
|
696
|
+
inkremental per sel pada paint berikutnya yang setara — bukan clear `ESC[2J`
|
|
697
|
+
tiap keystroke).
|
|
698
|
+
- `test/cells.test.ts` — I1 (tokenizer sel grapheme + diff "tulis-ulang ekor":
|
|
699
|
+
prefix identik nol byte, dari kolom berbeda pertama sampai akhir baris ditulis
|
|
700
|
+
ulang setelah EL `ESC[0K`; start mundur ke sel pembawa glyph agar EL tak
|
|
701
|
+
membelah glyph lebar; state SGR ternormalisasi urutan kanonik — `ESC[39m`
|
|
702
|
+
membatalkan bukan menumpuk, `38;5;n`/`38;2;r;g;b` utuh, glyph lebar dilindungi
|
|
703
|
+
`cont`; fuzz 500 kasus paritas output vs referensi).
|
|
704
|
+
- `test/composer-wrap.test.ts` — I1 (wrap composer inkremental paritas dengan
|
|
705
|
+
`chunkByWidth` penuh untuk append/backspace di ujung, CJK lebar, multiline;
|
|
706
|
+
pola tak didukung → fallback).
|
|
644
707
|
- `test/screen-buffer.test.ts` — parser grid ANSI/CUP dengan pengukuran grapheme
|
|
645
708
|
yang sama dengan renderer (termasuk emoji ZWJ dua kolom).
|
|
646
709
|
- `test/tui-startup-failure.test.ts` — UI-COMPAT-01 (CLI subprocess non-TTY:
|