@kodax-ai/kodax 0.7.80 → 0.7.82

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.
Files changed (64) hide show
  1. package/CHANGELOG.md +57 -0
  2. package/README.md +26 -3
  3. package/README_CN.md +21 -3
  4. package/dist/chunks/{agent-5PHGNFW3.js → agent-4UTCCMD5.js} +1 -1
  5. package/dist/chunks/argument-completer-N7ORRJBS.js +2 -0
  6. package/dist/chunks/{chunk-PMKAG4SZ.js → chunk-7ZN2MLVM.js} +1 -1
  7. package/dist/chunks/{chunk-GC4JBMBS.js → chunk-GIVYTXQW.js} +7 -7
  8. package/dist/chunks/{chunk-IHPH3444.js → chunk-JDZFNWMZ.js} +2 -2
  9. package/dist/chunks/{chunk-BWX4YZX3.js → chunk-KH2HED37.js} +2 -2
  10. package/dist/chunks/{chunk-RXXKDR6Y.js → chunk-NINELPXH.js} +1 -1
  11. package/dist/chunks/chunk-PGTU7JQX.js +30 -0
  12. package/dist/chunks/{chunk-T5U4OP2N.js → chunk-S6JTWDN6.js} +1 -1
  13. package/dist/chunks/{chunk-CDCCTM5I.js → chunk-VQBJMNFD.js} +2 -2
  14. package/dist/chunks/{chunk-CEB5FDND.js → chunk-WMYCNECP.js} +57 -57
  15. package/dist/chunks/{chunk-FQ7NVMSU.js → chunk-XTCDCU2Q.js} +136 -136
  16. package/dist/chunks/{chunk-RPF5RGWZ.js → chunk-ZOBNDWOA.js} +151 -151
  17. package/dist/chunks/chunk-ZZUIO5KL.js +348 -0
  18. package/dist/chunks/{compaction-config-6J6XCBJS.js → compaction-config-IDL5JQVI.js} +1 -1
  19. package/dist/chunks/{construction-bootstrap-KPCAE3VN.js → construction-bootstrap-STYUR6XA.js} +1 -1
  20. package/dist/chunks/{dist-RWEVZOFK.js → dist-RKBHBUHV.js} +1 -1
  21. package/dist/chunks/{host-OGS2R5J4.js → host-RF2IX3N6.js} +1 -1
  22. package/dist/chunks/{run-manager-2YMM3BOT.js → run-manager-WE2KPAKZ.js} +1 -1
  23. package/dist/chunks/{utils-2YHRUZYC.js → utils-Z2RSAENX.js} +1 -1
  24. package/dist/index.d.ts +12 -12
  25. package/dist/index.js +1 -1
  26. package/dist/kodax_bootstrap.js +1 -1
  27. package/dist/kodax_cli.js +1292 -1292
  28. package/dist/kodax_resume.js +4 -4
  29. package/dist/runtime-worker.js +1148 -1148
  30. package/dist/sandbox-workspace-session.js +4 -4
  31. package/dist/sdk-a2a.d.ts +8 -8
  32. package/dist/sdk-a2a.js +1 -1
  33. package/dist/sdk-agent.d.ts +10 -10
  34. package/dist/sdk-agent.js +1 -1
  35. package/dist/sdk-coding.d.ts +13 -13
  36. package/dist/sdk-coding.js +1 -1
  37. package/dist/sdk-mcp.js +1 -1
  38. package/dist/sdk-repl.d.ts +11 -11
  39. package/dist/sdk-repl.js +1 -1
  40. package/dist/sdk-runtime.d.ts +15 -8
  41. package/dist/sdk-runtime.js +1 -1
  42. package/dist/sdk-sandbox.js +1 -1
  43. package/dist/sdk-session.d.ts +4 -4
  44. package/dist/sdk-session.js +1 -1
  45. package/dist/sdk-skills.js +1 -1
  46. package/dist/semantic-worker.js +2 -2
  47. package/dist/types-chunks/{bash-prefix-extractor.d-DStqKIlu.d.ts → bash-prefix-extractor.d-CJM7OY-L.d.ts} +4 -2
  48. package/dist/types-chunks/{capsule.d-BuFJaYxA.d.ts → capsule.d-B7yoH4dM.d.ts} +4 -2
  49. package/dist/types-chunks/{controller.d-C2aHqzHj.d.ts → controller.d-CYNuR2n9.d.ts} +2 -2
  50. package/dist/types-chunks/{guardrail.d-DM-OK0m3.d.ts → guardrail.d-fM3mn4Op.d.ts} +2 -2
  51. package/dist/types-chunks/{history-retrieval.d-DImTKgO6.d.ts → history-retrieval.d-BDI-ZMvY.d.ts} +1 -1
  52. package/dist/types-chunks/{public-api.d-CewTvUKV.d.ts → public-api.d-i10kvYFs.d.ts} +2 -2
  53. package/dist/types-chunks/{repl.d-DvXQtgr7.d.ts → repl.d-Cs3eqGVT.d.ts} +5 -5
  54. package/dist/types-chunks/{run-manager.d-C6ahvZqK.d.ts → run-manager.d-CodHf6rw.d.ts} +1 -1
  55. package/dist/types-chunks/{sdk-session-C59RUrri.d.ts → sdk-session-CRXu5xNs.d.ts} +2 -2
  56. package/dist/types-chunks/{shell-command-sets.d-Dp4UvPLL.d.ts → shell-command-sets.d-DfeSUjjM.d.ts} +1 -1
  57. package/dist/types-chunks/{types.d-BzpPDBPV.d.ts → types.d-DIXZFauU.d.ts} +1 -1
  58. package/dist/types-chunks/{types.d-yuJzE82x.d.ts → types.d-DKs4tfSd.d.ts} +2 -2
  59. package/dist/types-chunks/{utils.d-BpACJmzt.d.ts → utils.d-CgITiLyc.d.ts} +4 -4
  60. package/docs/SDK_EMBEDDER_GUIDE.md +38 -10
  61. package/package.json +1 -1
  62. package/dist/chunks/argument-completer-FXRZFMTC.js +0 -2
  63. package/dist/chunks/chunk-UZSHBQER.js +0 -30
  64. package/dist/chunks/chunk-VECRQTSD.js +0 -348
package/CHANGELOG.md CHANGED
@@ -10,6 +10,63 @@ No changes yet.
10
10
 
11
11
  ---
12
12
 
13
+ ## [0.7.82] - 2026-08-05
14
+
15
+ > Git tag and GitHub Release are created by the release workflow. npm
16
+ > publication remains a separate manual operator step.
17
+
18
+ ### Fixed
19
+
20
+ - Daemon Host Tool capability discovery now preserves complete, lease-scoped
21
+ snapshots when it composes them with the active MCP runtime. Explicit server
22
+ filters select only their requested source, unfiltered discovery stays
23
+ complete/live, and legacy providers are queried without the ordinary page cap
24
+ while retaining explicit degraded metadata (Issue 279).
25
+ - A recorded managed-Run Stop now fences provider retry/fallback/continuation,
26
+ guardrail, tool, and Actor work after cooperative cancellation is observed.
27
+ The trusted Stop/Abort cause is classified before credential redaction, so
28
+ status, terminal event, `runs.get()`, and `runs.await()` consistently report
29
+ interruption without overriding genuine completion or independent failures
30
+ (Issue 280).
31
+ - `runtime.runs.submitInput()` and daemon preflight now resolve the admitted
32
+ authoritative Run before reading mutable Session history. Active interrupt
33
+ and after-turn admission no longer fail with transient `data_changed`; queued
34
+ continuations still wait for predecessor settlement and retain exact
35
+ operation-id idempotency (Issue 281).
36
+
37
+ ---
38
+
39
+ ## [0.7.81] - 2026-08-05
40
+
41
+ > Git tag and GitHub Release are created by the release workflow. npm
42
+ > publication remains a separate manual operator step.
43
+
44
+ ### Added
45
+
46
+ - Delivered Runtime interrupt inputs now expose an `entryId`: the exact physical
47
+ Session-lineage entry created by canonical user-input persistence. The value
48
+ is available in both `RuntimeInterruptInputStatus` and the
49
+ `run.input.delivered` event payload, so an SDK host can correlate a completed
50
+ interrupt with conversation history without reconstructing ordinal position.
51
+
52
+ ### Changed
53
+
54
+ - A safe-boundary drain keeps every queued user prompt as its own transcript
55
+ message and passes the per-queue-id `queuedMessageEntryIds` mapping through
56
+ the Runner/Runtime boundary. A delivered batch is therefore ordered and
57
+ referentially exact even when it contains multiple prompts.
58
+
59
+ ### Fixed
60
+
61
+ - Runtime-owned Session persistence completes before an interrupt is reported
62
+ as delivered. Missing, ambiguous, or failed canonical persistence now fails
63
+ delivery closed; no durable delivery event or delivered status is published.
64
+ The canonical entry reference survives event replay, Session compaction, and
65
+ Runtime restart. Legacy persisted delivery records remain readable without an
66
+ `entryId`.
67
+
68
+ ---
69
+
13
70
  ## [0.7.80] - 2026-08-04
14
71
 
15
72
  > Git tag and GitHub Release are created by the release workflow. npm
package/README.md CHANGED
@@ -599,9 +599,32 @@ repetition loops are closed; parallel review and delegation guidance are
599
599
  restored and tightened. FEATURE_278/279/282/283/285 were explicitly
600
600
  rescheduled to v0.7.85, so v0.7.80 remains a debug/patch slot and no incomplete
601
601
  feature is represented as shipped. See the
602
- [v0.7.80 release checklist](docs/release.md#v0780-release-preparation).
603
-
604
- The v0.7.77 release also adds an opt-in, host-configurable Shell Execution Contract.
602
+ [v0.7.80 release checklist](docs/release.md#v0780-release-preparation).
603
+
604
+ **v0.7.81 Runtime interrupt integrity release:** Active-Run inputs submitted
605
+ with `delivery: 'interrupt'` now receive one canonical physical Session entry
606
+ before KodaX reports them as delivered. Every delivered item exposes its
607
+ `entryId` in both `runtime.runs.get(...).interruptInputs` and the durable
608
+ `run.input.delivered` event, including after compaction, replay, or Runtime
609
+ restart. A multi-input safe-boundary drain keeps each prompt as a separate user
610
+ message and maps it to its own entry. Runtime-owned persistence or provenance
611
+ failure fails the delivery closed rather than emitting an unverifiable event.
612
+ FEATURE_287 remains planned for v0.7.88; this is a non-Feature patch. See the
613
+ [v0.7.81 release checklist](docs/release.md#v0781-release-preparation).
614
+
615
+ **v0.7.82 Runtime causality release:** Daemon capability discovery now composes
616
+ live, complete MCP and Host Tool snapshots only for unfiltered search; an
617
+ explicit server filter selects that source alone, while legacy providers report
618
+ honest incomplete/unknown discovery. An observed Stop cooperatively fences
619
+ later retries, continuations, guardrails, tools, and Run-admitted Actor work;
620
+ trusted Abort remains terminal causality before credential redaction without
621
+ overriding a real completion or independent failure. Input submission resolves
622
+ the admitted authoritative Run before reading mutable Session history, so
623
+ active interrupt and after-turn admission do not produce a transient
624
+ `data_changed` rejection. FEATURE_287 remains planned for v0.7.88; this is a
625
+ non-Feature patch. See the [v0.7.82 release checklist](docs/release.md#v0782-release-preparation).
626
+
627
+ The v0.7.77 release also adds an opt-in, host-configurable Shell Execution Contract.
605
628
  Runtime Session settings or an individual Run can select `pwsh`, Windows
606
629
  PowerShell, `cmd`, `bash`, `zsh`, or an explicit Git Bash executable; KodaX
607
630
  resolves the shell environment in the effective project cwd and then executes
package/README_CN.md CHANGED
@@ -212,9 +212,27 @@ idle-yield 恢复都会重置计数——它只是失控循环的熔断,绝不
212
212
  Managed-run 重复循环已被封堵,并行 review 与 delegation 指引已恢复并收紧。
213
213
  FEATURE_278/279/282/283/285 已显式改期到 v0.7.85,因此 v0.7.80 仍是
214
214
  debug/patch 槽位,没有把未完成特性表述为已交付。详见
215
- [v0.7.80 发布清单](docs/release.md#v0780-release-preparation)。
216
-
217
- v0.7.77 还增加了由宿主显式配置的 Shell Execution Contract。Runtime Session
215
+ [v0.7.80 发布清单](docs/release.md#v0780-release-preparation)。
216
+
217
+ **v0.7.81 Runtime 中断交付完整性发布**:以 `delivery: 'interrupt'` 提交给活动 Run
218
+ 的输入,会先获得唯一的 canonical Session 物理 entry,之后才会被标记为已交付。
219
+ `runtime.runs.get(...).interruptInputs` 与 durable `run.input.delivered` 事件均公开
220
+ 每项的 `entryId`;压缩、事件重放和 Runtime 重启后该引用仍可追溯。一次批量安全边界
221
+ 交付会保留每条 prompt 独立的 user message 与 entry 映射。Runtime-owned 持久化或
222
+ provenance 失败会 fail closed,不会发布无法验证的交付事件。FEATURE_287 仍计划于
223
+ v0.7.88;本版本是非 Feature 补丁。详见
224
+ [v0.7.81 发布清单](docs/release.md#v0781-release-preparation)。
225
+
226
+ **v0.7.82 Runtime 因果性发布**:daemon 的未过滤 capability 发现会组合 live、complete
227
+ 的 MCP 与 Host Tool snapshot;显式 `server` 过滤只选择对应来源,legacy provider 则如实
228
+ 报告 incomplete/unknown。观察到 Stop 后,后续 retry、continuation、guardrail、tool 及
229
+ Run-admitted Actor 工作会协作式停止;可信 Abort 会在 credential redaction 前保留为终态
230
+ 因果,但不会覆盖真实 completion 或独立 failure。输入提交先解析已接纳的 authoritative
231
+ Run,再读取可变 Session history,因此活动中断和 after-turn 接纳不会产生瞬态
232
+ `data_changed` 拒绝。FEATURE_287 仍计划于 v0.7.88;本版本是非 Feature 补丁。详见
233
+ [v0.7.82 发布清单](docs/release.md#v0782-release-preparation)。
234
+
235
+ v0.7.77 还增加了由宿主显式配置的 Shell Execution Contract。Runtime Session
218
236
  设置或单次 Run 可以选择 `pwsh`、Windows PowerShell、`cmd`、`bash`、`zsh`
219
237
  或 Git Bash 的绝对路径;KodaX 会在实际项目 cwd 中解析 shell 环境,再通过同一
220
238
  解释器执行命令。环境缓存按 contract 与 cwd 隔离,使用有界 TTL,也可由宿主显式
@@ -1,2 +1,2 @@
1
1
  // @kodax-ai/kodax — bundled distribution. See docs/ADR.md ADR-022 + ADR-024.
2
- import{Ja as g,La as h,Ya as i,Za as j,a as c,db as k,ra as d,sa as e,ta as f}from"./chunk-VECRQTSD.js";import"./chunk-HTVLCHWH.js";import"./chunk-GC4JBMBS.js";import"./chunk-KHEFUT6O.js";import"./chunk-TRNAWSXP.js";import{wb as a,xb as b}from"./chunk-CEB5FDND.js";import"./chunk-EVXIJPZ6.js";import"./chunk-E7C4DRD2.js";import"./chunk-6UENDY33.js";import"./chunk-ONUPGMER.js";export{e as bucketProviderPayloadSize,g as buildAutoRepoIntelligenceContext,f as checkPromiseSignal,b as cleanupIncompleteToolCalls,h as describeTransientProviderRetry,c as emitResilienceDebug,d as estimateProviderPayloadBytes,k as runKodaX,j as saveRequiredSessionSnapshot,i as saveSessionSnapshot,a as validateAndFixToolHistory};
2
+ import{Ja as g,La as h,Ya as i,Za as j,a as c,db as k,ra as d,sa as e,ta as f}from"./chunk-ZZUIO5KL.js";import"./chunk-HTVLCHWH.js";import"./chunk-GIVYTXQW.js";import"./chunk-KHEFUT6O.js";import"./chunk-TRNAWSXP.js";import{wb as a,xb as b}from"./chunk-WMYCNECP.js";import"./chunk-EVXIJPZ6.js";import"./chunk-E7C4DRD2.js";import"./chunk-6UENDY33.js";import"./chunk-ONUPGMER.js";export{e as bucketProviderPayloadSize,g as buildAutoRepoIntelligenceContext,f as checkPromiseSignal,b as cleanupIncompleteToolCalls,h as describeTransientProviderRetry,c as emitResilienceDebug,d as estimateProviderPayloadBytes,k as runKodaX,j as saveRequiredSessionSnapshot,i as saveSessionSnapshot,a as validateAndFixToolHistory};
@@ -0,0 +1,2 @@
1
+ // @kodax-ai/kodax — bundled distribution. See docs/ADR.md ADR-022 + ADR-024.
2
+ import{Ea as a,Fa as b}from"./chunk-JDZFNWMZ.js";import"./chunk-VQBJMNFD.js";import"./chunk-7ZN2MLVM.js";import"./chunk-ZOBNDWOA.js";import"./chunk-ZZUIO5KL.js";import"./chunk-NINELPXH.js";import"./chunk-HTVLCHWH.js";import"./chunk-KH2HED37.js";import"./chunk-GIVYTXQW.js";import"./chunk-KHEFUT6O.js";import"./chunk-TRNAWSXP.js";import"./chunk-WMYCNECP.js";import"./chunk-EVXIJPZ6.js";import"./chunk-E7C4DRD2.js";import"./chunk-6UENDY33.js";import"./chunk-ONUPGMER.js";export{a as ArgumentCompleter,b as createArgumentCompleter};
@@ -1,2 +1,2 @@
1
1
  // @kodax-ai/kodax — bundled distribution. See docs/ADR.md ADR-022 + ADR-024.
2
- import{pc as o}from"./chunk-CEB5FDND.js";import{h as c}from"./chunk-EVXIJPZ6.js";import{a as n}from"./chunk-ONUPGMER.js";import{readFile as a}from"fs/promises";var i={enabled:!0,triggerPercent:75};async function s(r){let t=c("config.json");try{let e=await f(t);if(e?.compaction)return o({...i,...e.compaction})}catch{}return o(i)}n(s,"loadCompactionConfig");async function f(r){try{let t=await a(r,"utf-8");return JSON.parse(t)}catch{return null}}n(f,"readConfigFile");export{s as a};
2
+ import{pc as o}from"./chunk-WMYCNECP.js";import{h as c}from"./chunk-EVXIJPZ6.js";import{a as n}from"./chunk-ONUPGMER.js";import{readFile as a}from"fs/promises";var i={enabled:!0,triggerPercent:75};async function s(r){let t=c("config.json");try{let e=await f(t);if(e?.compaction)return o({...i,...e.compaction})}catch{}return o(i)}n(s,"loadCompactionConfig");async function f(r){try{let t=await a(r,"utf-8");return JSON.parse(t)}catch{return null}}n(f,"readConfigFile");export{s as a};