@circuitwall/jarela 2.2.1 → 2.4.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/.next/standalone/.next/BUILD_ID +1 -1
- package/.next/standalone/.next/app-path-routes-manifest.json +2 -1
- package/.next/standalone/.next/build-manifest.json +2 -2
- package/.next/standalone/.next/prerender-manifest.json +3 -3
- package/.next/standalone/.next/routes-manifest.json +8 -0
- package/.next/standalone/.next/server/app/_global-error/page.js +68 -68
- package/.next/standalone/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/_global-error.html +1 -1
- package/.next/standalone/.next/server/app/_global-error.rsc +1 -1
- package/.next/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_not-found/page.js +76 -76
- package/.next/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/_not-found.html +2 -2
- package/.next/standalone/.next/server/app/_not-found.rsc +2 -2
- package/.next/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/_not-found.segments/_index.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
- package/.next/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
- package/.next/standalone/.next/server/app/api/v1/access/[identity]/route.js +100 -93
- package/.next/standalone/.next/server/app/api/v1/access/route.js +176 -169
- package/.next/standalone/.next/server/app/api/v1/agents/[id]/compact/route.js +89 -56
- package/.next/standalone/.next/server/app/api/v1/agents/[id]/compact/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/agents/[id]/display-filters/route.js +139 -127
- package/.next/standalone/.next/server/app/api/v1/agents/[id]/route.js +107 -100
- package/.next/standalone/.next/server/app/api/v1/agents/[id]/thread/route.js +765 -753
- package/.next/standalone/.next/server/app/api/v1/agents/route.js +72 -65
- package/.next/standalone/.next/server/app/api/v1/allowed-sites/[hostname]/route.js +371 -364
- package/.next/standalone/.next/server/app/api/v1/allowed-sites/route.js +809 -802
- package/.next/standalone/.next/server/app/api/v1/artifacts/lifecycle/route.js +9 -2
- package/.next/standalone/.next/server/app/api/v1/attachments/files/route.js +49 -49
- package/.next/standalone/.next/server/app/api/v1/attachments/images/route.js +910 -910
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/chats/route.js +583 -16
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/chats/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/ignores/[remote_jid]/route.js +41 -30
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/ignores/route.js +48 -37
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/lookup/route.js +697 -130
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/lookup/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/pair/route.js +703 -136
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/pair/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/route.js +796 -229
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/routes/[route_id]/route.js +762 -746
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/routes/route.js +1050 -1034
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/status/route.js +673 -106
- package/.next/standalone/.next/server/app/api/v1/bridges/[id]/status/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/bridges/kinds/route.js +811 -804
- package/.next/standalone/.next/server/app/api/v1/bridges/kinds/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/bridges/route.js +718 -706
- package/.next/standalone/.next/server/app/api/v1/bridges/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/builtin-tools/route.js +9 -9
- package/.next/standalone/.next/server/app/api/v1/builtin-tools/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/config/route.js +85 -85
- package/.next/standalone/.next/server/app/api/v1/credentials/[id]/route.js +709 -709
- package/.next/standalone/.next/server/app/api/v1/credentials/[id]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/credentials/route.js +2 -2
- package/.next/standalone/.next/server/app/api/v1/credentials/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/dashboard/currency/route.js +10 -10
- package/.next/standalone/.next/server/app/api/v1/dashboard/metrics/route.js +796 -784
- package/.next/standalone/.next/server/app/api/v1/dashboard/pricing/route.js +30 -23
- package/.next/standalone/.next/server/app/api/v1/dashboard/pricing-task/route.js +86 -86
- package/.next/standalone/.next/server/app/api/v1/dashboard/pricing-task/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/delegations/codex/[job_id]/route.js +57 -57
- package/.next/standalone/.next/server/app/api/v1/delegations/codex/[job_id]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/documents/search/route.js +385 -378
- package/.next/standalone/.next/server/app/api/v1/documents/settings/route.js +51 -44
- package/.next/standalone/.next/server/app/api/v1/documents/sources/[id]/reindex/route.js +65 -65
- package/.next/standalone/.next/server/app/api/v1/documents/sources/[id]/reindex/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/documents/sources/[id]/route.js +122 -122
- package/.next/standalone/.next/server/app/api/v1/documents/sources/[id]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/documents/sources/route.js +37 -37
- package/.next/standalone/.next/server/app/api/v1/documents/sources/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/env/route.js +9 -9
- package/.next/standalone/.next/server/app/api/v1/env-sync/allowlist/route.js +375 -368
- package/.next/standalone/.next/server/app/api/v1/env-sync/route.js +51 -44
- package/.next/standalone/.next/server/app/api/v1/events/route.js +745 -178
- package/.next/standalone/.next/server/app/api/v1/events/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/events/test/route.js +77 -77
- package/.next/standalone/.next/server/app/api/v1/extension/agents/route.js +763 -763
- package/.next/standalone/.next/server/app/api/v1/extension/agents/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/extension/browser/activate/route.js +51 -44
- package/.next/standalone/.next/server/app/api/v1/extension/browser/foreground/route.js +16 -9
- package/.next/standalone/.next/server/app/api/v1/extension/browser/history/route.js +72 -65
- package/.next/standalone/.next/server/app/api/v1/extension/browser/poll/route.js +41 -34
- package/.next/standalone/.next/server/app/api/v1/extension/browser/progress/route.js +211 -204
- package/.next/standalone/.next/server/app/api/v1/extension/browser/result/route.js +140 -133
- package/.next/standalone/.next/server/app/api/v1/extension/browser/retry/route.js +113 -106
- package/.next/standalone/.next/server/app/api/v1/extension/browser/status/route.js +121 -114
- package/.next/standalone/.next/server/app/api/v1/extension/browser/tabs/route.js +141 -134
- package/.next/standalone/.next/server/app/api/v1/extension/fill/route.js +690 -690
- package/.next/standalone/.next/server/app/api/v1/extension/fill/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/extension/refine/route.js +93 -93
- package/.next/standalone/.next/server/app/api/v1/extension/refine/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/extension/turn/route.js +9 -9
- package/.next/standalone/.next/server/app/api/v1/extension/turn/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/extensions/route.js +185 -185
- package/.next/standalone/.next/server/app/api/v1/extensions/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/extensions/tools/[name]/config/route.js +171 -171
- package/.next/standalone/.next/server/app/api/v1/extensions/tools/[name]/config/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/extensions/tools/[name]/route.js +396 -396
- package/.next/standalone/.next/server/app/api/v1/extensions/tools/[name]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/extensions/tools/[name]/secrets/route.js +212 -212
- package/.next/standalone/.next/server/app/api/v1/extensions/tools/[name]/secrets/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/files/[name]/route.js +235 -235
- package/.next/standalone/.next/server/app/api/v1/fs/browse/route.js +26 -26
- package/.next/standalone/.next/server/app/api/v1/harnesses/[id]/route.js +228 -221
- package/.next/standalone/.next/server/app/api/v1/harnesses/default/route.js +65 -58
- package/.next/standalone/.next/server/app/api/v1/harnesses/route.js +79 -72
- package/.next/standalone/.next/server/app/api/v1/health/probes/route.js +9 -9
- package/.next/standalone/.next/server/app/api/v1/health/probes/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/health/route.js +783 -771
- package/.next/standalone/.next/server/app/api/v1/integrations/[name]/route.js +140 -133
- package/.next/standalone/.next/server/app/api/v1/integrations/[name]/test/route.js +9 -9
- package/.next/standalone/.next/server/app/api/v1/integrations/[name]/test/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/integrations/gmail/oauth/callback/route.js +370 -363
- package/.next/standalone/.next/server/app/api/v1/integrations/gmail/oauth/start/route.js +240 -233
- package/.next/standalone/.next/server/app/api/v1/integrations/gmail/oauth/status/route.js +689 -682
- package/.next/standalone/.next/server/app/api/v1/integrations/outlook/oauth/callback/route.js +886 -879
- package/.next/standalone/.next/server/app/api/v1/integrations/outlook/oauth/start/route.js +115 -108
- package/.next/standalone/.next/server/app/api/v1/integrations/outlook/oauth/status/route.js +955 -948
- package/.next/standalone/.next/server/app/api/v1/integrations/route.js +223 -216
- package/.next/standalone/.next/server/app/api/v1/lifecycle/adoption/route.js +876 -847
- package/.next/standalone/.next/server/app/api/v1/lifecycle/adoption/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/local-file/route.js +26 -26
- package/.next/standalone/.next/server/app/api/v1/logs/route.js +70 -70
- package/.next/standalone/.next/server/app/api/v1/maps/embed/route.js +79 -72
- package/.next/standalone/.next/server/app/api/v1/mcp-servers/[name]/route.js +991 -979
- package/.next/standalone/.next/server/app/api/v1/mcp-servers/registry/route.js +196 -196
- package/.next/standalone/.next/server/app/api/v1/mcp-servers/route.js +19 -7
- package/.next/standalone/.next/server/app/api/v1/memory/[namespace]/[key]/route.js +539 -532
- package/.next/standalone/.next/server/app/api/v1/memory/policy/route.js +86 -79
- package/.next/standalone/.next/server/app/api/v1/memory/route.js +58 -51
- package/.next/standalone/.next/server/app/api/v1/memory/search/route.js +138 -131
- package/.next/standalone/.next/server/app/api/v1/models/[name]/compact-threads/route.js +381 -369
- package/.next/standalone/.next/server/app/api/v1/models/[name]/compact-threads/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/models/[name]/route.js +150 -143
- package/.next/standalone/.next/server/app/api/v1/models/route.js +634 -627
- package/.next/standalone/.next/server/app/api/v1/packages/catalog/route.js +445 -445
- package/.next/standalone/.next/server/app/api/v1/packages/defaults/[id]/route.js +120 -120
- package/.next/standalone/.next/server/app/api/v1/packages/defaults/[id]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/packages/install/[id]/route.js +234 -234
- package/.next/standalone/.next/server/app/api/v1/packages/install/[id]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/packages/install/route.js +407 -407
- package/.next/standalone/.next/server/app/api/v1/packages/install/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/packages/manifests/[name]/enabled/route.js +37 -37
- package/.next/standalone/.next/server/app/api/v1/packages/manifests/[name]/enabled/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/packages/manifests/[name]/route.js +107 -107
- package/.next/standalone/.next/server/app/api/v1/packages/manifests/[name]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/packages/manifests/route.js +228 -228
- package/.next/standalone/.next/server/app/api/v1/packages/manifests/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/packages/reload/route.js +9 -9
- package/.next/standalone/.next/server/app/api/v1/packages/reload/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/packages/route.js +148 -148
- package/.next/standalone/.next/server/app/api/v1/packages/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/page-capture/route.js +787 -787
- package/.next/standalone/.next/server/app/api/v1/page-capture/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/pending-actions/[id]/approve/route.js +529 -514
- package/.next/standalone/.next/server/app/api/v1/pending-actions/[id]/approve/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/pending-actions/[id]/deny/route.js +181 -181
- package/.next/standalone/.next/server/app/api/v1/pending-actions/[id]/deny/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/pending-actions/route.js +258 -258
- package/.next/standalone/.next/server/app/api/v1/pending-actions/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/profile/location/route.js +37 -30
- package/.next/standalone/.next/server/app/api/v1/profile/route.js +171 -164
- package/.next/standalone/.next/server/app/api/v1/providers/[provider]/models/route.js +51 -44
- package/.next/standalone/.next/server/app/api/v1/providers/[provider]/probe/route.js +15 -8
- package/.next/standalone/.next/server/app/api/v1/providers/github-copilot/auth/route.js +171 -164
- package/.next/standalone/.next/server/app/api/v1/providers/route.js +101 -94
- package/.next/standalone/.next/server/app/api/v1/proxy-config/route.js +457 -450
- package/.next/standalone/.next/server/app/api/v1/redaction/init/route.js +44 -37
- package/.next/standalone/.next/server/app/api/v1/redaction/route.js +65 -58
- package/.next/standalone/.next/server/app/api/v1/scheduled-tasks/[id]/route.js +617 -605
- package/.next/standalone/.next/server/app/api/v1/scheduled-tasks/[id]/run/route.js +44 -44
- package/.next/standalone/.next/server/app/api/v1/scheduled-tasks/[id]/run/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/scheduled-tasks/route.js +739 -732
- package/.next/standalone/.next/server/app/api/v1/security/idle-timeout/route.js +329 -322
- package/.next/standalone/.next/server/app/api/v1/security/pin/route.js +204 -197
- package/.next/standalone/.next/server/app/api/v1/security/state/route.js +58 -51
- package/.next/standalone/.next/server/app/api/v1/security/unlock/route.js +183 -176
- package/.next/standalone/.next/server/app/api/v1/security/verify-pin/route.js +194 -187
- package/.next/standalone/.next/server/app/api/v1/setup/test-key/route.js +26 -26
- package/.next/standalone/.next/server/app/api/v1/skills/[id]/route.js +776 -769
- package/.next/standalone/.next/server/app/api/v1/skills/repos/[id]/route.js +122 -115
- package/.next/standalone/.next/server/app/api/v1/skills/repos/route.js +334 -327
- package/.next/standalone/.next/server/app/api/v1/skills/route.js +873 -866
- package/.next/standalone/.next/server/app/api/v1/system/abort/route.js +838 -808
- package/.next/standalone/.next/server/app/api/v1/system/restart/route.js +177 -177
- package/.next/standalone/.next/server/app/api/v1/system/restart/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/tailscale/route.js +164 -164
- package/.next/standalone/.next/server/app/api/v1/tasks/[agent_id]/route.js +122 -115
- package/.next/standalone/.next/server/app/api/v1/tasks/route.js +30 -23
- package/.next/standalone/.next/server/app/api/v1/threads/[thread_id]/activity/route.js +1436 -0
- package/.next/standalone/.next/server/app/api/v1/threads/[thread_id]/activity/route.js.nft.json +1 -0
- package/.next/standalone/.next/server/app/api/v1/threads/[thread_id]/activity/route_client-reference-manifest.js +1 -0
- package/.next/standalone/.next/server/app/api/v1/threads/[thread_id]/context-pin/route.js +638 -631
- package/.next/standalone/.next/server/app/api/v1/threads/[thread_id]/context-pin/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/threads/[thread_id]/route.js +60 -439
- package/.next/standalone/.next/server/app/api/v1/threads/[thread_id]/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/threads/[thread_id]/run/route.js +172 -173
- package/.next/standalone/.next/server/app/api/v1/threads/[thread_id]/run/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/threads/route.js +925 -913
- package/.next/standalone/.next/server/app/api/v1/tools/route.js +2 -2
- package/.next/standalone/.next/server/app/api/v1/tools/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/update/apply/route.js +17 -17
- package/.next/standalone/.next/server/app/api/v1/update/apply/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/update/route.js +570 -570
- package/.next/standalone/.next/server/app/api/v1/voice/transcribe/route.js +241 -229
- package/.next/standalone/.next/server/app/api/v1/voice/tts/route.js +989 -977
- package/.next/standalone/.next/server/app/api/v1/watchers/[id]/route.js +40 -28
- package/.next/standalone/.next/server/app/api/v1/watchers/[id]/run/route.js +72 -72
- package/.next/standalone/.next/server/app/api/v1/watchers/[id]/run/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/api/v1/watchers/reaction-scripts/route.js +128 -128
- package/.next/standalone/.next/server/app/api/v1/watchers/route.js +164 -164
- package/.next/standalone/.next/server/app/api/v1/watchers/route.js.nft.json +1 -1
- package/.next/standalone/.next/server/app/icon.svg/route.js +62 -62
- package/.next/standalone/.next/server/app/manifest.webmanifest/route.js +436 -436
- package/.next/standalone/.next/server/app/page.js +1179 -743
- package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app/setup/page.js +99 -91
- package/.next/standalone/.next/server/app/setup/page_client-reference-manifest.js +1 -1
- package/.next/standalone/.next/server/app-paths-manifest.json +2 -1
- package/.next/standalone/.next/server/chunks/{424.js → 1388.js} +441 -1022
- package/.next/standalone/.next/server/chunks/1433.js +1 -1
- package/.next/standalone/.next/server/chunks/1638.js +1 -2
- package/.next/standalone/.next/server/chunks/1738.js +1 -1
- package/.next/standalone/.next/server/chunks/2068.js +47 -10
- package/.next/standalone/.next/server/chunks/210.js +3 -3
- package/.next/standalone/.next/server/chunks/2151.js +31 -1
- package/.next/standalone/.next/server/chunks/2207.js +1 -0
- package/.next/standalone/.next/server/chunks/2447.js +10 -5
- package/.next/standalone/.next/server/chunks/2471.js +45 -45
- package/.next/standalone/.next/server/chunks/2504.js +1 -1
- package/.next/standalone/.next/server/chunks/2695.js +17 -17
- package/.next/standalone/.next/server/chunks/3042.js +24 -16
- package/.next/standalone/.next/server/chunks/{4540.js → 309.js} +104 -38
- package/.next/standalone/.next/server/chunks/{2350.js → 3272.js} +104 -37
- package/.next/standalone/.next/server/chunks/3399.js +526 -526
- package/.next/standalone/.next/server/chunks/3524.js +150 -67
- package/.next/standalone/.next/server/chunks/3566.js +1 -1
- package/.next/standalone/.next/server/chunks/4189.js +946 -0
- package/.next/standalone/.next/server/chunks/4433.js +146 -146
- package/.next/standalone/.next/server/chunks/4508.js +3 -3
- package/.next/standalone/.next/server/chunks/4588.js +1 -0
- package/.next/standalone/.next/server/chunks/46.js +78 -28
- package/.next/standalone/.next/server/chunks/466.js +12 -0
- package/.next/standalone/.next/server/chunks/4868.js +206 -206
- package/.next/standalone/.next/server/chunks/4992.js +13 -0
- package/.next/standalone/.next/server/chunks/5120.js +963 -0
- package/.next/standalone/.next/server/chunks/5701.js +1 -1
- package/.next/standalone/.next/server/chunks/5900.js +1 -1
- package/.next/standalone/.next/server/chunks/5908.js +63 -42
- package/.next/standalone/.next/server/chunks/6142.js +10 -2
- package/.next/standalone/.next/server/chunks/6210.js +1 -0
- package/.next/standalone/.next/server/chunks/6213.js +1 -1
- package/.next/standalone/.next/server/chunks/6649.js +3 -3
- package/.next/standalone/.next/server/chunks/6703.js +3 -3
- package/.next/standalone/.next/server/chunks/7445.js +1 -0
- package/.next/standalone/.next/server/chunks/8067.js +12 -0
- package/.next/standalone/.next/server/chunks/8461.js +24 -17
- package/.next/standalone/.next/server/chunks/8558.js +1 -1
- package/.next/standalone/.next/server/chunks/8724.js +1 -1
- package/.next/standalone/.next/server/chunks/8849.js +91 -91
- package/.next/standalone/.next/server/chunks/9032.js +4 -3
- package/.next/standalone/.next/server/chunks/{2563.js → 9164.js} +33389 -31418
- package/.next/standalone/.next/server/chunks/9237.js +396 -396
- package/.next/standalone/.next/server/chunks/{9640.js → 9304.js} +1672 -575
- package/.next/standalone/.next/server/chunks/9406.js +1 -1
- package/.next/standalone/.next/server/chunks/9590.js +68 -18
- package/.next/standalone/.next/server/chunks/9824.js +98 -98
- package/.next/standalone/.next/server/chunks/9826.js +1 -0
- package/.next/standalone/.next/server/middleware-build-manifest.js +2 -2
- package/.next/standalone/.next/server/middleware.js +486 -415
- package/.next/standalone/.next/server/pages/404.html +2 -2
- package/.next/standalone/.next/server/pages/500.html +1 -1
- package/.next/standalone/.next/server/preview-props.json +3 -3
- package/.next/standalone/.next/server/server-reference-manifest.json +1 -1
- package/.next/standalone/.next/static/chunks/{1395-a340fb0a345382a4.js → 1395-e4a99912b8f83044.js} +13 -1
- package/.next/standalone/.next/static/chunks/app/_global-error/{page-36cb8b428b38b26a.js → page-6fc5f8e744c81802.js} +1 -1
- package/.next/standalone/.next/static/chunks/app/api/v1/access/[identity]/{route-36cb8b428b38b26a.js → route-6fc5f8e744c81802.js} +1 -1
- package/.next/standalone/.next/static/chunks/app/api/v1/access/{route-36cb8b428b38b26a.js → route-6fc5f8e744c81802.js} +1 -1
- package/.next/standalone/.next/static/chunks/app/api/v1/agents/[id]/compact/{route-36cb8b428b38b26a.js → route-6fc5f8e744c81802.js} +1 -1
- package/.next/standalone/.next/static/chunks/app/api/v1/agents/[id]/display-filters/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/agents/[id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/agents/[id]/thread/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/agents/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/allowed-sites/[hostname]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/allowed-sites/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/artifacts/lifecycle/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/attachments/files/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/attachments/images/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/chats/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/ignores/[remote_jid]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/ignores/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/lookup/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/pair/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/routes/[route_id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/routes/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/status/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/kinds/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/builtin-tools/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/config/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/credentials/[id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/credentials/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/dashboard/currency/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/dashboard/metrics/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/dashboard/pricing/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/dashboard/pricing-task/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/delegations/codex/[job_id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/documents/search/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/documents/settings/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/documents/sources/[id]/reindex/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/documents/sources/[id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/documents/sources/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/env/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/env-sync/allowlist/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/env-sync/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/events/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/events/test/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/agents/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/activate/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/foreground/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/history/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/poll/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/progress/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/result/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/retry/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/status/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/tabs/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/fill/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/refine/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/turn/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extensions/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extensions/tools/[name]/config/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extensions/tools/[name]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/extensions/tools/[name]/secrets/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/files/[name]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/fs/browse/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/harnesses/[id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/harnesses/default/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/harnesses/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/health/probes/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/health/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/[name]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/[name]/test/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/gmail/oauth/callback/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/gmail/oauth/start/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/gmail/oauth/status/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/outlook/oauth/callback/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/outlook/oauth/start/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/outlook/oauth/status/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/lifecycle/adoption/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/local-file/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/logs/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/maps/embed/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/mcp-servers/[name]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/mcp-servers/registry/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/mcp-servers/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/memory/[namespace]/[key]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/memory/policy/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/memory/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/memory/search/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/models/[name]/compact-threads/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/models/[name]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/models/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/catalog/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/defaults/[id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/install/[id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/install/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/manifests/[name]/enabled/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/manifests/[name]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/manifests/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/reload/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/page-capture/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/pending-actions/[id]/approve/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/pending-actions/[id]/deny/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/pending-actions/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/profile/location/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/profile/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/providers/[provider]/models/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/providers/[provider]/probe/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/providers/github-copilot/auth/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/providers/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/proxy-config/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/redaction/init/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/redaction/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/scheduled-tasks/[id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/scheduled-tasks/[id]/run/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/scheduled-tasks/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/security/idle-timeout/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/security/pin/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/security/state/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/security/unlock/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/security/verify-pin/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/setup/test-key/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/skills/[id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/skills/repos/[id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/skills/repos/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/skills/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/system/abort/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/system/restart/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/tailscale/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/tasks/[agent_id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/tasks/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/threads/[thread_id]/activity/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/threads/[thread_id]/context-pin/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/threads/[thread_id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/threads/[thread_id]/run/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/threads/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/tools/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/update/apply/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/update/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/voice/transcribe/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/voice/tts/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/watchers/[id]/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/watchers/[id]/run/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/watchers/reaction-scripts/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/api/v1/watchers/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/manifest.webmanifest/route-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/app/{page-7017f07f8a7a083c.js → page-04748847c6ff866f.js} +1013 -585
- package/.next/standalone/.next/static/chunks/next/dist/client/components/builtin/app-error-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/next/dist/client/components/builtin/forbidden-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/next/dist/client/components/builtin/not-found-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/chunks/next/dist/client/components/builtin/unauthorized-6fc5f8e744c81802.js +17 -0
- package/.next/standalone/.next/static/css/{d80058f0b9b41c09.css → 2669e8744cc8c212.css} +2 -2
- package/.next/standalone/docs/adoption/changesets.json +358 -0
- package/.next/standalone/lib/skills/builtins/memory-organization/SKILL.md +16 -0
- package/.next/standalone/package.json +3 -3
- package/CHANGELOG.md +44 -0
- package/api/client.ts +9 -0
- package/api/types.ts +29 -0
- package/app/api/v1/lifecycle/adoption/route.ts +14 -2
- package/app/api/v1/models/[name]/compact-threads/route.ts +14 -11
- package/app/api/v1/threads/[thread_id]/activity/route.ts +19 -0
- package/app/api/v1/threads/[thread_id]/context-pin/route.test.ts +1 -0
- package/app/api/v1/threads/[thread_id]/context-pin/route.ts +2 -1
- package/app/api/v1/threads/[thread_id]/route.ts +5 -1
- package/app/api/v1/threads/[thread_id]/run/route.ts +0 -1
- package/components/chat/ChatView.tsx +52 -11
- package/components/chat/ContextBoundary.test.tsx +68 -1
- package/components/chat/ContextBoundary.tsx +92 -13
- package/components/chat/MessageBubble.tsx +12 -0
- package/components/chat/MessageList.test.tsx +31 -0
- package/components/chat/MessageList.tsx +49 -28
- package/components/chat/ToolList.test.tsx +92 -16
- package/components/chat/ToolList.tsx +59 -4
- package/components/chat/chat-helpers.test.tsx +24 -1
- package/components/chat/chat-helpers.ts +47 -4
- package/components/chat/useThreadActivity.test.tsx +113 -0
- package/components/chat/useThreadActivity.ts +94 -0
- package/components/chat/useThreadData.ts +16 -16
- package/components/chat/workflow-step-retry.ts +25 -0
- package/components/integrations/NetworkSection.tsx +2 -2
- package/components/ui/BootScreen.tsx +17 -0
- package/components/ui/WorkflowChecklist.tsx +71 -33
- package/hooks/useSSE.ts +28 -3
- package/lib/agents/citation-checker.test.ts +40 -2
- package/lib/agents/citation-checker.ts +56 -11
- package/lib/agents/compaction-pipeline.test.ts +202 -0
- package/lib/agents/compaction-pipeline.ts +483 -0
- package/lib/agents/context-boundary.ts +5 -6
- package/lib/agents/conversation-summary.ts +37 -21
- package/lib/agents/instruction-edits.test.ts +120 -0
- package/lib/agents/instruction-edits.ts +65 -42
- package/lib/agents/prepare/history-window.test.ts +18 -0
- package/lib/agents/prepare/history-window.ts +11 -2
- package/lib/agents/prepare/request.ts +4 -2
- package/lib/agents/prepare/system-prompt.test.ts +49 -0
- package/lib/agents/prepare/system-prompt.ts +16 -5
- package/lib/agents/prompt-registry.test.ts +5 -140
- package/lib/agents/prompt-registry.ts +45 -1
- package/lib/agents/prompt-variants.ts +146 -0
- package/lib/agents/proposals.test.ts +76 -0
- package/lib/agents/proposals.ts +13 -5
- package/lib/agents/run-registry.test.ts +22 -0
- package/lib/agents/run-registry.ts +29 -0
- package/lib/agents/run-thread.auto-boundary.test.ts +125 -5
- package/lib/agents/run-thread.retry.test.ts +67 -1
- package/lib/agents/run-thread.ts +110 -10
- package/lib/agents/sqlite-checkpoint-saver.test.ts +91 -0
- package/lib/agents/thread-activity.test.ts +31 -0
- package/lib/agents/thread-activity.ts +27 -0
- package/lib/agents/thread-compaction-state.test.ts +82 -0
- package/lib/agents/thread-compaction-state.ts +121 -0
- package/lib/agents/thread-compaction.test.ts +83 -4
- package/lib/agents/thread-compaction.ts +34 -11
- package/lib/agents/warm-summary-background.test.ts +219 -5
- package/lib/agents/warm-summary-background.ts +346 -143
- package/lib/agents/warm-topics.test.ts +191 -0
- package/lib/agents/warm-topics.ts +317 -0
- package/lib/agents/workflow-step-retry.test.ts +96 -0
- package/lib/agents/workflow-step-retry.ts +216 -0
- package/lib/api/browser-control.ts +0 -3
- package/lib/bridges/dispatcher.ts +1 -0
- package/lib/bridges/message-role.test.ts +81 -0
- package/lib/bridges/message-role.ts +23 -10
- package/lib/bridges/types.ts +6 -0
- package/lib/bridges/whatsapp-link.test.ts +32 -0
- package/lib/bridges/whatsapp-link.ts +21 -0
- package/lib/bridges/whatsapp.inbound.test.ts +239 -0
- package/lib/bridges/whatsapp.sender.test.ts +80 -1
- package/lib/bridges/whatsapp.ts +76 -38
- package/lib/db/migrations.ts +5 -0
- package/lib/env/config.ts +2 -0
- package/lib/env/schema.ts +12 -0
- package/lib/lifecycle/changeset-build.test.ts +93 -0
- package/lib/lifecycle/changeset-build.ts +210 -0
- package/lib/lifecycle/changesets.test.ts +101 -0
- package/lib/lifecycle/changesets.ts +166 -0
- package/lib/lifecycle/surface-collect.test.ts +88 -0
- package/lib/lifecycle/surface-collect.ts +64 -0
- package/lib/lifecycle/surface-snapshot.test.ts +104 -0
- package/lib/lifecycle/surface-snapshot.ts +210 -0
- package/lib/memory/record.ts +0 -2
- package/lib/pricing/snapshot.test.ts +70 -0
- package/lib/pricing/snapshot.ts +10 -2
- package/lib/providers/external.ts +0 -2
- package/lib/proxy/dispatcher.test.ts +119 -1
- package/lib/proxy/dispatcher.ts +22 -9
- package/lib/skills/builtins/memory-organization/SKILL.md +16 -0
- package/lib/stores/agent-configs.ts +10 -5
- package/lib/stores/bridges.test.ts +81 -0
- package/lib/stores/bridges.ts +9 -8
- package/lib/stores/proxy-config.test.ts +120 -0
- package/lib/stores/proxy-config.ts +22 -4
- package/lib/stores/threads.test.ts +9 -0
- package/lib/stores/threads.ts +33 -19
- package/lib/stores/version-adoption.test.ts +96 -0
- package/lib/stores/version-adoption.ts +239 -26
- package/lib/stores/workflow-progress.ts +3 -0
- package/lib/tools/communications/calendar.test.ts +43 -2
- package/lib/tools/communications/calendar.ts +2 -0
- package/lib/tools/communications/gmail.test.ts +51 -1
- package/lib/tools/communications/gmail.ts +44 -2
- package/lib/tools/communications/ms-todo.ts +0 -7
- package/lib/tools/communications/outlook-calendar.ts +2 -0
- package/lib/tools/communications/outlook.test.ts +33 -2
- package/lib/tools/communications/outlook.ts +2 -0
- package/lib/tools/filesystem/edit-match.test.ts +133 -0
- package/lib/tools/filesystem/edit-match.ts +7 -2
- package/lib/tools/general/memory.ts +1 -1
- package/lib/tools/general/workflow-progress.ts +2 -0
- package/lib/tools/runtime/catalog.ts +1 -25
- package/lib/tools/support/result-refs.test.ts +131 -0
- package/lib/tools/support/result-refs.ts +41 -9
- package/lib/triggers/registry.ts +0 -4
- package/lib/utils/source-link.test.ts +51 -0
- package/lib/utils/source-link.ts +45 -0
- package/package.json +3 -3
- package/scripts/install-to-system.ps1 +39 -11
- package/scripts/install-to-system.sh +37 -3
- package/.next/standalone/.next/server/chunks/3979.js +0 -581
- package/.next/standalone/.next/server/chunks/5936.js +0 -594
- package/.next/standalone/.next/static/chunks/app/api/v1/agents/[id]/display-filters/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/agents/[id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/agents/[id]/thread/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/agents/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/allowed-sites/[hostname]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/allowed-sites/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/artifacts/lifecycle/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/attachments/files/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/attachments/images/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/chats/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/ignores/[remote_jid]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/ignores/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/lookup/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/pair/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/routes/[route_id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/routes/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/[id]/status/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/kinds/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/bridges/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/builtin-tools/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/config/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/credentials/[id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/credentials/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/dashboard/currency/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/dashboard/metrics/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/dashboard/pricing/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/dashboard/pricing-task/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/delegations/codex/[job_id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/documents/search/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/documents/settings/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/documents/sources/[id]/reindex/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/documents/sources/[id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/documents/sources/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/env/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/env-sync/allowlist/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/env-sync/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/events/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/events/test/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/agents/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/activate/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/foreground/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/history/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/poll/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/progress/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/result/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/retry/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/status/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/browser/tabs/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/fill/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/refine/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extension/turn/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extensions/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extensions/tools/[name]/config/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extensions/tools/[name]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/extensions/tools/[name]/secrets/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/files/[name]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/fs/browse/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/harnesses/[id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/harnesses/default/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/harnesses/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/health/probes/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/health/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/[name]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/[name]/test/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/gmail/oauth/callback/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/gmail/oauth/start/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/gmail/oauth/status/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/outlook/oauth/callback/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/outlook/oauth/start/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/outlook/oauth/status/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/integrations/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/lifecycle/adoption/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/local-file/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/logs/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/maps/embed/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/mcp-servers/[name]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/mcp-servers/registry/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/mcp-servers/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/memory/[namespace]/[key]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/memory/policy/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/memory/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/memory/search/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/models/[name]/compact-threads/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/models/[name]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/models/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/catalog/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/defaults/[id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/install/[id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/install/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/manifests/[name]/enabled/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/manifests/[name]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/manifests/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/reload/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/packages/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/page-capture/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/pending-actions/[id]/approve/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/pending-actions/[id]/deny/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/pending-actions/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/profile/location/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/profile/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/providers/[provider]/models/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/providers/[provider]/probe/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/providers/github-copilot/auth/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/providers/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/proxy-config/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/redaction/init/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/redaction/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/scheduled-tasks/[id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/scheduled-tasks/[id]/run/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/scheduled-tasks/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/security/idle-timeout/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/security/pin/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/security/state/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/security/unlock/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/security/verify-pin/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/setup/test-key/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/skills/[id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/skills/repos/[id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/skills/repos/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/skills/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/system/abort/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/system/restart/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/tailscale/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/tasks/[agent_id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/tasks/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/threads/[thread_id]/context-pin/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/threads/[thread_id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/threads/[thread_id]/run/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/threads/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/tools/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/update/apply/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/update/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/voice/transcribe/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/voice/tts/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/watchers/[id]/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/watchers/[id]/run/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/watchers/reaction-scripts/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/api/v1/watchers/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/app/manifest.webmanifest/route-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/next/dist/client/components/builtin/app-error-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/next/dist/client/components/builtin/forbidden-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/next/dist/client/components/builtin/not-found-36cb8b428b38b26a.js +0 -17
- package/.next/standalone/.next/static/chunks/next/dist/client/components/builtin/unauthorized-36cb8b428b38b26a.js +0 -17
- /package/.next/standalone/.next/static/{NUrC9xax1sp1Q70nlFqS6 → hwujW4hR1b-r3k5WdMxZO}/_buildManifest.js +0 -0
- /package/.next/standalone/.next/static/{NUrC9xax1sp1Q70nlFqS6 → hwujW4hR1b-r3k5WdMxZO}/_ssgManifest.js +0 -0
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
import { afterAll, describe, expect, it } from "vitest";
|
|
2
|
+
import { mkdirSync, mkdtempSync, readFileSync, rmSync, writeFileSync } from "node:fs";
|
|
3
|
+
import { tmpdir } from "node:os";
|
|
4
|
+
import { join } from "node:path";
|
|
5
|
+
import {
|
|
6
|
+
extractAdoptionHints,
|
|
7
|
+
renderChangesetsMarkdown,
|
|
8
|
+
upsertChangeset,
|
|
9
|
+
writeReleaseChangeset,
|
|
10
|
+
} from "./changeset-build";
|
|
11
|
+
import type { SurfaceSnapshot } from "./surface-snapshot";
|
|
12
|
+
|
|
13
|
+
const tmpRoot = mkdtempSync(join(tmpdir(), "jarela-changeset-build-"));
|
|
14
|
+
afterAll(() => {
|
|
15
|
+
try { rmSync(tmpRoot, { recursive: true, force: true }); } catch { /* held open */ }
|
|
16
|
+
});
|
|
17
|
+
|
|
18
|
+
const CHANGELOG = [
|
|
19
|
+
"# Changelog",
|
|
20
|
+
"## [Unreleased]",
|
|
21
|
+
"## [2.3.0] - 2026-02-01",
|
|
22
|
+
"### Added",
|
|
23
|
+
"- Something.",
|
|
24
|
+
"### Adoption",
|
|
25
|
+
"- Re-run watchers that use `web_search`;",
|
|
26
|
+
" the `query` param is now required.",
|
|
27
|
+
"- Remove `old_tool` from allowlists.",
|
|
28
|
+
"## [2.2.0] - 2026-01-01",
|
|
29
|
+
"### Adoption",
|
|
30
|
+
"- Older hint.",
|
|
31
|
+
].join("\n");
|
|
32
|
+
|
|
33
|
+
function snapshot(version: string, tools: SurfaceSnapshot["tools"], prompts: SurfaceSnapshot["prompts"] = {}): SurfaceSnapshot {
|
|
34
|
+
return { schema_version: 1, version, prompts, tools };
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
describe("extractAdoptionHints", () => {
|
|
38
|
+
it("reads only the version's Adoption bullets, joining wrapped lines", () => {
|
|
39
|
+
expect(extractAdoptionHints(CHANGELOG, "2.3.0")).toEqual([
|
|
40
|
+
"Re-run watchers that use `web_search`; the `query` param is now required.",
|
|
41
|
+
"Remove `old_tool` from allowlists.",
|
|
42
|
+
]);
|
|
43
|
+
expect(extractAdoptionHints(CHANGELOG, "2.2.0")).toEqual(["Older hint."]);
|
|
44
|
+
expect(extractAdoptionHints(CHANGELOG, "9.9.9")).toEqual([]);
|
|
45
|
+
});
|
|
46
|
+
});
|
|
47
|
+
|
|
48
|
+
describe("upsertChangeset and renderChangesetsMarkdown", () => {
|
|
49
|
+
const base = { previous_version: "1.0.0", date: "d", hints: [], commits: [], prompts: [], tools: [] };
|
|
50
|
+
|
|
51
|
+
it("replaces an existing version and keeps versions sorted", () => {
|
|
52
|
+
const file = upsertChangeset(
|
|
53
|
+
{ schema_version: 1, changesets: [{ ...base, version: "2.10.0" }, { ...base, version: "2.9.0", hints: ["old"] }] },
|
|
54
|
+
{ ...base, version: "2.9.0", hints: ["new"] },
|
|
55
|
+
);
|
|
56
|
+
expect(file.changesets.map((e) => [e.version, e.hints])).toEqual([["2.9.0", ["new"]], ["2.10.0", []]]);
|
|
57
|
+
const md = renderChangesetsMarkdown(file);
|
|
58
|
+
expect(md.indexOf("## 2.10.0")).toBeLessThan(md.indexOf("## 2.9.0"));
|
|
59
|
+
expect(md).toContain("- new");
|
|
60
|
+
});
|
|
61
|
+
});
|
|
62
|
+
|
|
63
|
+
describe("writeReleaseChangeset", () => {
|
|
64
|
+
it("diffs the committed snapshot, writes docs, and advances the snapshot", () => {
|
|
65
|
+
const root = join(tmpRoot, "repo");
|
|
66
|
+
mkdirSync(join(root, "docs/adoption"), { recursive: true });
|
|
67
|
+
writeFileSync(join(root, "CHANGELOG.md"), CHANGELOG);
|
|
68
|
+
const prev = snapshot("2.2.0", { web_search: { description: "Search.", parameters: { type: "object", properties: { query: {} } } } });
|
|
69
|
+
writeFileSync(join(root, "docs/adoption/surface-snapshot.json"), JSON.stringify(prev));
|
|
70
|
+
const next = snapshot("ignored", {
|
|
71
|
+
web_search: { description: "Search.", parameters: { type: "object", properties: { query: {} }, required: ["query"] } },
|
|
72
|
+
}, { "system.Rules": { source: "s.ts", text: "be careful" } });
|
|
73
|
+
|
|
74
|
+
const entry = writeReleaseChangeset({ root, version: "2.3.0", nextSnapshot: next, date: "2026-02-01" });
|
|
75
|
+
|
|
76
|
+
expect(entry).toMatchObject({ version: "2.3.0", previous_version: "2.2.0", commits: [] });
|
|
77
|
+
expect(entry.hints).toHaveLength(2);
|
|
78
|
+
expect(entry.tools).toMatchObject([{ name: "web_search", required_added: ["query"] }]);
|
|
79
|
+
expect(entry.prompts).toMatchObject([{ id: "system.Rules", change: "added" }]);
|
|
80
|
+
const written = JSON.parse(readFileSync(join(root, "docs/adoption/changesets.json"), "utf8"));
|
|
81
|
+
expect(written.changesets.map((e: { version: string }) => e.version)).toEqual(["2.3.0"]);
|
|
82
|
+
expect(JSON.parse(readFileSync(join(root, "docs/adoption/surface-snapshot.json"), "utf8")).version).toBe("2.3.0");
|
|
83
|
+
expect(readFileSync(join(root, "docs/adoption/index.md"), "utf8")).toContain("`web_search` — changed");
|
|
84
|
+
});
|
|
85
|
+
|
|
86
|
+
it("refuses to record a version that is not newer than the snapshot", () => {
|
|
87
|
+
const root = join(tmpRoot, "stale");
|
|
88
|
+
mkdirSync(join(root, "docs/adoption"), { recursive: true });
|
|
89
|
+
writeFileSync(join(root, "docs/adoption/surface-snapshot.json"), JSON.stringify(snapshot("2.3.0", {})));
|
|
90
|
+
expect(() => writeReleaseChangeset({ root, version: "2.2.0", nextSnapshot: snapshot("x", {}), date: "d" }))
|
|
91
|
+
.toThrow(/must be newer/);
|
|
92
|
+
});
|
|
93
|
+
});
|
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Release-time changeset generation. Diffs the committed surface snapshot
|
|
3
|
+
* (docs/adoption/surface-snapshot.json) against the current one and records
|
|
4
|
+
* the prompt and tool deltas for the release version. Run through
|
|
5
|
+
* `npm run release:changeset`; never imported by the running app.
|
|
6
|
+
*/
|
|
7
|
+
import { execFileSync } from "node:child_process";
|
|
8
|
+
import { existsSync, readFileSync, writeFileSync } from "node:fs";
|
|
9
|
+
import { join } from "node:path";
|
|
10
|
+
import {
|
|
11
|
+
changesetFileSchema,
|
|
12
|
+
compareVersions,
|
|
13
|
+
type ChangesetFile,
|
|
14
|
+
type ReleaseChangeset,
|
|
15
|
+
} from "./changesets";
|
|
16
|
+
import { diffSurfaces, type SurfaceSnapshot } from "./surface-snapshot";
|
|
17
|
+
|
|
18
|
+
export const ADOPTION_DOCS_DIR = "docs/adoption";
|
|
19
|
+
export const CHANGESETS_FILE = `${ADOPTION_DOCS_DIR}/changesets.json`;
|
|
20
|
+
export const SNAPSHOT_FILE = `${ADOPTION_DOCS_DIR}/surface-snapshot.json`;
|
|
21
|
+
export const CHANGESETS_PAGE = `${ADOPTION_DOCS_DIR}/index.md`;
|
|
22
|
+
const MAX_COMMITS = 40;
|
|
23
|
+
|
|
24
|
+
/** Bullets under `### Adoption` in the version's CHANGELOG section. */
|
|
25
|
+
export function extractAdoptionHints(changelog: string, version: string): string[] {
|
|
26
|
+
const lines = changelog.split(/\r?\n/);
|
|
27
|
+
const start = lines.findIndex((line) => new RegExp(`^## \\[?${version.replace(/\./g, "\\.")}\\]?(\\s|$)`).test(line));
|
|
28
|
+
if (start === -1) return [];
|
|
29
|
+
const hints: string[] = [];
|
|
30
|
+
let inAdoption = false;
|
|
31
|
+
for (const line of lines.slice(start + 1)) {
|
|
32
|
+
if (/^## /.test(line)) break;
|
|
33
|
+
if (/^### /.test(line)) {
|
|
34
|
+
inAdoption = /^### Adoption\s*$/i.test(line);
|
|
35
|
+
continue;
|
|
36
|
+
}
|
|
37
|
+
if (!inAdoption) continue;
|
|
38
|
+
const bullet = /^\s*[-*]\s+(.+)$/.exec(line);
|
|
39
|
+
if (bullet) hints.push(bullet[1].trim());
|
|
40
|
+
else if (line.trim() && hints.length > 0) hints[hints.length - 1] += ` ${line.trim()}`;
|
|
41
|
+
}
|
|
42
|
+
return hints;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function buildChangesetEntry(input: {
|
|
46
|
+
version: string;
|
|
47
|
+
previousSnapshot: SurfaceSnapshot;
|
|
48
|
+
nextSnapshot: SurfaceSnapshot;
|
|
49
|
+
date: string;
|
|
50
|
+
hints: string[];
|
|
51
|
+
commits: string[];
|
|
52
|
+
}): ReleaseChangeset {
|
|
53
|
+
const delta = diffSurfaces(input.previousSnapshot, input.nextSnapshot);
|
|
54
|
+
return {
|
|
55
|
+
version: input.version,
|
|
56
|
+
previous_version: input.previousSnapshot.version,
|
|
57
|
+
date: input.date,
|
|
58
|
+
hints: input.hints,
|
|
59
|
+
commits: input.commits.slice(0, MAX_COMMITS),
|
|
60
|
+
prompts: delta.prompts,
|
|
61
|
+
tools: delta.tools,
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export function upsertChangeset(file: ChangesetFile, entry: ReleaseChangeset): ChangesetFile {
|
|
66
|
+
const rest = file.changesets.filter((existing) => existing.version !== entry.version);
|
|
67
|
+
return {
|
|
68
|
+
schema_version: 1,
|
|
69
|
+
changesets: [...rest, entry].sort((a, b) => compareVersions(a.version, b.version)),
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export function renderChangesetsMarkdown(file: ChangesetFile): string {
|
|
74
|
+
const out = [
|
|
75
|
+
"# Version adoption changesets",
|
|
76
|
+
"",
|
|
77
|
+
"Generated by `npm run release:changeset` — do not edit by hand.",
|
|
78
|
+
"",
|
|
79
|
+
"Each release records how the model-facing surface changed: prompt text Jarela sends and built-in tool",
|
|
80
|
+
"descriptions and parameter schemas. When Jarela starts on a new version, the default agent reads the",
|
|
81
|
+
"changesets between your last adopted version and the running one, then adapts your settings, agent",
|
|
82
|
+
"instructions, skills, and scheduled task or watcher prompts. Code changes are covered by the",
|
|
83
|
+
"[changelog](https://github.com/CircuitWall/jarela/blob/main/CHANGELOG.md).",
|
|
84
|
+
"",
|
|
85
|
+
"Release authors can add adoption hints as bullets under a `### Adoption` heading in the version's",
|
|
86
|
+
"CHANGELOG section.",
|
|
87
|
+
];
|
|
88
|
+
for (const entry of [...file.changesets].reverse()) {
|
|
89
|
+
out.push("", `## ${entry.version}`, "", `From ${entry.previous_version ?? "—"} · ${entry.date}`, "");
|
|
90
|
+
if (entry.hints.length) {
|
|
91
|
+
out.push("### Adoption hints", "", ...entry.hints.map((hint) => `- ${hint}`), "");
|
|
92
|
+
}
|
|
93
|
+
out.push("### Tools", "");
|
|
94
|
+
if (entry.tools.length === 0) out.push("No tool description or schema changes.");
|
|
95
|
+
for (const tool of entry.tools) {
|
|
96
|
+
const details = [
|
|
97
|
+
tool.description_changed ? "description changed" : "",
|
|
98
|
+
tool.params_added.length ? `params added: ${tool.params_added.map((p) => `\`${p}\``).join(", ")}` : "",
|
|
99
|
+
tool.params_removed.length ? `params removed: ${tool.params_removed.map((p) => `\`${p}\``).join(", ")}` : "",
|
|
100
|
+
tool.params_changed.length ? `params changed: ${tool.params_changed.map((p) => `\`${p}\``).join(", ")}` : "",
|
|
101
|
+
tool.required_added.length ? `now required: ${tool.required_added.map((p) => `\`${p}\``).join(", ")}` : "",
|
|
102
|
+
tool.required_removed.length ? `no longer required: ${tool.required_removed.map((p) => `\`${p}\``).join(", ")}` : "",
|
|
103
|
+
].filter(Boolean);
|
|
104
|
+
out.push(`- \`${tool.name}\` — ${tool.change}${details.length ? `; ${details.join("; ")}` : ""}`);
|
|
105
|
+
}
|
|
106
|
+
out.push("", "### Prompts", "");
|
|
107
|
+
if (entry.prompts.length === 0) out.push("No prompt text changes.");
|
|
108
|
+
for (const prompt of entry.prompts) {
|
|
109
|
+
out.push(`- \`${prompt.id}\` — ${prompt.change} (\`${prompt.source}\`)`);
|
|
110
|
+
const diff = [
|
|
111
|
+
...prompt.added_lines.map((line) => `+ ${line}`),
|
|
112
|
+
...prompt.removed_lines.map((line) => `- ${line}`),
|
|
113
|
+
...(prompt.omitted_lines > 0 ? [`… ${prompt.omitted_lines} more line(s)`] : []),
|
|
114
|
+
];
|
|
115
|
+
if (diff.length) out.push("", " ```diff", ...diff.map((line) => ` ${line}`), " ```", "");
|
|
116
|
+
}
|
|
117
|
+
if (entry.commits.length) {
|
|
118
|
+
out.push("", "### Commits", "", ...entry.commits.map((subject) => `- ${subject}`));
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
return `${out.join("\n").replace(/\n{3,}/g, "\n\n")}\n`;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
export function readChangesetFile(root: string): ChangesetFile {
|
|
125
|
+
const path = join(root, CHANGESETS_FILE);
|
|
126
|
+
if (!existsSync(path)) return { schema_version: 1, changesets: [] };
|
|
127
|
+
return changesetFileSchema.parse(JSON.parse(readFileSync(path, "utf8")));
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
export function readSnapshot(path: string): SurfaceSnapshot {
|
|
131
|
+
return JSON.parse(readFileSync(path, "utf8")) as SurfaceSnapshot;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
function snapshotAtTag(root: string, version: string): SurfaceSnapshot | null {
|
|
135
|
+
try {
|
|
136
|
+
const raw = execFileSync("git", ["show", `v${version}:${SNAPSHOT_FILE}`], {
|
|
137
|
+
cwd: root,
|
|
138
|
+
encoding: "utf8",
|
|
139
|
+
maxBuffer: 64 * 1024 * 1024,
|
|
140
|
+
stdio: ["ignore", "pipe", "ignore"],
|
|
141
|
+
});
|
|
142
|
+
return JSON.parse(raw) as SurfaceSnapshot;
|
|
143
|
+
} catch {
|
|
144
|
+
return null;
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
export function gitCommitSubjects(root: string, from: string, to: string): string[] {
|
|
149
|
+
try {
|
|
150
|
+
const raw = execFileSync("git", ["log", "--no-merges", "--format=%s", `${from}..${to}`], {
|
|
151
|
+
cwd: root,
|
|
152
|
+
encoding: "utf8",
|
|
153
|
+
stdio: ["ignore", "pipe", "ignore"],
|
|
154
|
+
});
|
|
155
|
+
return raw.split(/\r?\n/).map((line) => line.trim()).filter(Boolean);
|
|
156
|
+
} catch {
|
|
157
|
+
return [];
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
function writeJson(path: string, value: unknown): void {
|
|
162
|
+
writeFileSync(path, `${JSON.stringify(value, null, 2)}\n`, "utf8");
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
/**
|
|
166
|
+
* Records the changeset for `version` against the committed snapshot, then
|
|
167
|
+
* moves the committed snapshot forward. Re-running for the same version
|
|
168
|
+
* replaces that entry, diffing against the snapshot committed at the
|
|
169
|
+
* predecessor's release tag.
|
|
170
|
+
*/
|
|
171
|
+
export function writeReleaseChangeset(input: {
|
|
172
|
+
root: string;
|
|
173
|
+
version: string;
|
|
174
|
+
nextSnapshot: SurfaceSnapshot;
|
|
175
|
+
date: string;
|
|
176
|
+
/** Git ref the release is cut from, for commit subjects. Defaults to HEAD. */
|
|
177
|
+
ref?: string;
|
|
178
|
+
/** Snapshot to diff against instead of the committed one (backfill). */
|
|
179
|
+
previousSnapshot?: SurfaceSnapshot;
|
|
180
|
+
}): ReleaseChangeset {
|
|
181
|
+
const snapshotPath = join(input.root, SNAPSHOT_FILE);
|
|
182
|
+
const file = readChangesetFile(input.root);
|
|
183
|
+
let previous = input.previousSnapshot ?? readSnapshot(snapshotPath);
|
|
184
|
+
if (!input.previousSnapshot && previous.version === input.version) {
|
|
185
|
+
const recorded = file.changesets.find((entry) => entry.version === input.version)?.previous_version;
|
|
186
|
+
const prior = recorded ? snapshotAtTag(input.root, recorded) : null;
|
|
187
|
+
if (!prior) {
|
|
188
|
+
throw new Error(`Snapshot is already at ${input.version}; cannot find the v${recorded ?? "?"} snapshot to diff against.`);
|
|
189
|
+
}
|
|
190
|
+
previous = prior;
|
|
191
|
+
}
|
|
192
|
+
if (compareVersions(input.version, previous.version) <= 0) {
|
|
193
|
+
throw new Error(`Release version ${input.version} must be newer than snapshot version ${previous.version}.`);
|
|
194
|
+
}
|
|
195
|
+
const changelogPath = join(input.root, "CHANGELOG.md");
|
|
196
|
+
const changelog = existsSync(changelogPath) ? readFileSync(changelogPath, "utf8") : "";
|
|
197
|
+
const entry = buildChangesetEntry({
|
|
198
|
+
version: input.version,
|
|
199
|
+
previousSnapshot: previous,
|
|
200
|
+
nextSnapshot: { ...input.nextSnapshot, version: input.version },
|
|
201
|
+
date: input.date,
|
|
202
|
+
hints: extractAdoptionHints(changelog, input.version),
|
|
203
|
+
commits: gitCommitSubjects(input.root, `v${previous.version}`, input.ref ?? "HEAD"),
|
|
204
|
+
});
|
|
205
|
+
const updated = upsertChangeset(file, entry);
|
|
206
|
+
writeJson(join(input.root, CHANGESETS_FILE), updated);
|
|
207
|
+
writeFileSync(join(input.root, CHANGESETS_PAGE), renderChangesetsMarkdown(updated), "utf8");
|
|
208
|
+
writeJson(snapshotPath, { ...input.nextSnapshot, version: input.version });
|
|
209
|
+
return entry;
|
|
210
|
+
}
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
import { describe, expect, it } from "vitest";
|
|
2
|
+
import { readFileSync } from "node:fs";
|
|
3
|
+
import { join } from "node:path";
|
|
4
|
+
import {
|
|
5
|
+
changesetFileSchema,
|
|
6
|
+
changesetsBetween,
|
|
7
|
+
compareVersions,
|
|
8
|
+
formatChangesetsForPrompt,
|
|
9
|
+
loadBundledChangesets,
|
|
10
|
+
summarizeChangesets,
|
|
11
|
+
type ReleaseChangeset,
|
|
12
|
+
} from "./changesets";
|
|
13
|
+
|
|
14
|
+
function entry(version: string, previous: string | null, overrides: Partial<ReleaseChangeset> = {}): ReleaseChangeset {
|
|
15
|
+
return { version, previous_version: previous, date: "2026-01-01", hints: [], commits: [], prompts: [], tools: [], ...overrides };
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
const tool = (name: string, change: "added" | "removed" | "changed") => ({
|
|
19
|
+
name, change, description_changed: change === "changed", description: `${name} does things.`,
|
|
20
|
+
params_added: [], params_removed: [], params_changed: [], required_added: [], required_removed: [],
|
|
21
|
+
});
|
|
22
|
+
|
|
23
|
+
describe("compareVersions", () => {
|
|
24
|
+
it("orders numerically, not lexically", () => {
|
|
25
|
+
expect(compareVersions("2.10.0", "2.9.9")).toBeGreaterThan(0);
|
|
26
|
+
expect(compareVersions("2.0.5", "2.0.5")).toBe(0);
|
|
27
|
+
expect(compareVersions("1.99.0", "2.0.0")).toBeLessThan(0);
|
|
28
|
+
});
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
describe("changesetsBetween", () => {
|
|
32
|
+
const all = [entry("2.0.1", "2.0.0"), entry("2.1.0", "2.0.1"), entry("2.2.0", "2.1.0")];
|
|
33
|
+
|
|
34
|
+
it("returns the cumulative range (previous, current] and marks full coverage", () => {
|
|
35
|
+
const range = changesetsBetween("2.0.1", "2.2.0", all);
|
|
36
|
+
expect(range.entries.map((e) => e.version)).toEqual(["2.1.0", "2.2.0"]);
|
|
37
|
+
expect(range.complete).toBe(true);
|
|
38
|
+
});
|
|
39
|
+
|
|
40
|
+
it("flags partial coverage when the range starts before the first changeset", () => {
|
|
41
|
+
const range = changesetsBetween("1.9.0", "2.2.0", all);
|
|
42
|
+
expect(range.entries).toHaveLength(3);
|
|
43
|
+
expect(range.complete).toBe(false);
|
|
44
|
+
});
|
|
45
|
+
|
|
46
|
+
it("flags partial coverage when the current version has no changeset", () => {
|
|
47
|
+
expect(changesetsBetween("2.1.0", "2.3.0", all).complete).toBe(false);
|
|
48
|
+
});
|
|
49
|
+
});
|
|
50
|
+
|
|
51
|
+
describe("summarizeChangesets and formatChangesetsForPrompt", () => {
|
|
52
|
+
const entries = [
|
|
53
|
+
entry("2.1.0", "2.0.0", {
|
|
54
|
+
hints: ["Re-check watchers."],
|
|
55
|
+
tools: [tool("old_tool", "removed"), tool("search", "changed")],
|
|
56
|
+
prompts: [{ id: "system.Tool usage SOP", source: "s.ts", change: "changed", added_lines: ["+rule"], removed_lines: ["-rule"], omitted_lines: 2 }],
|
|
57
|
+
}),
|
|
58
|
+
entry("2.2.0", "2.1.0", { tools: [tool("old_tool", "added")] }),
|
|
59
|
+
];
|
|
60
|
+
|
|
61
|
+
it("keeps the latest state of each surface across the range", () => {
|
|
62
|
+
expect(summarizeChangesets(entries)).toEqual({
|
|
63
|
+
promptIds: ["system.Tool usage SOP"],
|
|
64
|
+
toolNames: ["old_tool", "search"],
|
|
65
|
+
removedTools: [],
|
|
66
|
+
hints: ["2.1.0: Re-check watchers."],
|
|
67
|
+
});
|
|
68
|
+
});
|
|
69
|
+
|
|
70
|
+
it("renders hints, tool deltas, and prompt excerpts within the budget", () => {
|
|
71
|
+
const text = formatChangesetsForPrompt(entries);
|
|
72
|
+
expect(text).toContain("adoption hint: Re-check watchers.");
|
|
73
|
+
expect(text).toContain("tool `old_tool`: removed");
|
|
74
|
+
expect(text).toContain("+ +rule");
|
|
75
|
+
expect(text).toContain("2 more changed line(s)");
|
|
76
|
+
expect(formatChangesetsForPrompt(entries, 40).length).toBeLessThan(200);
|
|
77
|
+
});
|
|
78
|
+
});
|
|
79
|
+
|
|
80
|
+
describe("bundled changesets", () => {
|
|
81
|
+
const raw = JSON.parse(readFileSync(join(process.cwd(), "docs/adoption/changesets.json"), "utf8"));
|
|
82
|
+
const bundled = loadBundledChangesets();
|
|
83
|
+
|
|
84
|
+
it("matches the schema", () => {
|
|
85
|
+
expect(changesetFileSchema.safeParse(raw).success).toBe(true);
|
|
86
|
+
expect(bundled.length).toBe(raw.changesets.length);
|
|
87
|
+
});
|
|
88
|
+
|
|
89
|
+
it("has an entry for the package.json version so the release PR cannot skip it", () => {
|
|
90
|
+
const { version } = JSON.parse(readFileSync(join(process.cwd(), "package.json"), "utf8")) as { version: string };
|
|
91
|
+
expect(bundled.map((e) => e.version), "run `npm run release:changeset` in the release PR").toContain(version);
|
|
92
|
+
const snapshot = JSON.parse(readFileSync(join(process.cwd(), "docs/adoption/surface-snapshot.json"), "utf8"));
|
|
93
|
+
expect(snapshot.version).toBe(version);
|
|
94
|
+
});
|
|
95
|
+
|
|
96
|
+
it("chains each release to its predecessor without gaps", () => {
|
|
97
|
+
for (let i = 1; i < bundled.length; i++) {
|
|
98
|
+
expect(bundled[i].previous_version, bundled[i].version).toBe(bundled[i - 1].version);
|
|
99
|
+
}
|
|
100
|
+
});
|
|
101
|
+
});
|
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Bundled release changesets (docs/adoption/changesets.json), generated at
|
|
3
|
+
* release time by `npm run release:changeset`. Installed bundles have no git
|
|
4
|
+
* history, so version adoption reads these to learn which prompts and tool
|
|
5
|
+
* descriptions/schemas changed between the user's last adopted version and
|
|
6
|
+
* the running one.
|
|
7
|
+
*/
|
|
8
|
+
import { z } from "zod";
|
|
9
|
+
import bundled from "@/docs/adoption/changesets.json";
|
|
10
|
+
import type { PromptChange, ToolChange } from "./surface-snapshot";
|
|
11
|
+
|
|
12
|
+
const changeKind = z.enum(["added", "removed", "changed"]);
|
|
13
|
+
|
|
14
|
+
const promptChangeSchema = z.object({
|
|
15
|
+
id: z.string(),
|
|
16
|
+
source: z.string(),
|
|
17
|
+
change: changeKind,
|
|
18
|
+
added_lines: z.array(z.string()),
|
|
19
|
+
removed_lines: z.array(z.string()),
|
|
20
|
+
omitted_lines: z.number().int().nonnegative(),
|
|
21
|
+
});
|
|
22
|
+
|
|
23
|
+
const toolChangeSchema = z.object({
|
|
24
|
+
name: z.string(),
|
|
25
|
+
change: changeKind,
|
|
26
|
+
description_changed: z.boolean(),
|
|
27
|
+
description: z.string().optional(),
|
|
28
|
+
previous_description: z.string().optional(),
|
|
29
|
+
params_added: z.array(z.string()),
|
|
30
|
+
params_removed: z.array(z.string()),
|
|
31
|
+
params_changed: z.array(z.string()),
|
|
32
|
+
required_added: z.array(z.string()),
|
|
33
|
+
required_removed: z.array(z.string()),
|
|
34
|
+
});
|
|
35
|
+
|
|
36
|
+
export const releaseChangesetSchema = z.object({
|
|
37
|
+
version: z.string().regex(/^\d+\.\d+\.\d+$/),
|
|
38
|
+
previous_version: z.string().regex(/^\d+\.\d+\.\d+$/).nullable(),
|
|
39
|
+
date: z.string(),
|
|
40
|
+
hints: z.array(z.string()),
|
|
41
|
+
commits: z.array(z.string()),
|
|
42
|
+
prompts: z.array(promptChangeSchema),
|
|
43
|
+
tools: z.array(toolChangeSchema),
|
|
44
|
+
});
|
|
45
|
+
|
|
46
|
+
export const changesetFileSchema = z.object({
|
|
47
|
+
schema_version: z.literal(1),
|
|
48
|
+
changesets: z.array(releaseChangesetSchema),
|
|
49
|
+
});
|
|
50
|
+
|
|
51
|
+
export type ReleaseChangeset = z.infer<typeof releaseChangesetSchema>;
|
|
52
|
+
export type ChangesetFile = z.infer<typeof changesetFileSchema>;
|
|
53
|
+
|
|
54
|
+
// Compile-time guard: the bundled schema must stay in sync with the diff types.
|
|
55
|
+
type Assert<T extends true> = T;
|
|
56
|
+
type _PromptShape = Assert<PromptChange extends z.infer<typeof promptChangeSchema> ? true : false>;
|
|
57
|
+
type _ToolShape = Assert<ToolChange extends z.infer<typeof toolChangeSchema> ? true : false>;
|
|
58
|
+
|
|
59
|
+
export function compareVersions(a: string, b: string): number {
|
|
60
|
+
const pa = a.split(".").map((part) => Number.parseInt(part, 10) || 0);
|
|
61
|
+
const pb = b.split(".").map((part) => Number.parseInt(part, 10) || 0);
|
|
62
|
+
for (let i = 0; i < Math.max(pa.length, pb.length); i++) {
|
|
63
|
+
const diff = (pa[i] ?? 0) - (pb[i] ?? 0);
|
|
64
|
+
if (diff !== 0) return diff;
|
|
65
|
+
}
|
|
66
|
+
return 0;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
let cached: ReleaseChangeset[] | null = null;
|
|
70
|
+
|
|
71
|
+
export function loadBundledChangesets(): ReleaseChangeset[] {
|
|
72
|
+
if (cached) return cached;
|
|
73
|
+
const parsed = changesetFileSchema.safeParse(bundled);
|
|
74
|
+
cached = parsed.success
|
|
75
|
+
? [...parsed.data.changesets].sort((a, b) => compareVersions(a.version, b.version))
|
|
76
|
+
: [];
|
|
77
|
+
return cached;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
export interface ChangesetRange {
|
|
81
|
+
entries: ReleaseChangeset[];
|
|
82
|
+
/** True when the entries chain fully from `previous` to `current`. */
|
|
83
|
+
complete: boolean;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
/** Cumulative changesets for versions in (previous, current]. */
|
|
87
|
+
export function changesetsBetween(
|
|
88
|
+
previous: string,
|
|
89
|
+
current: string,
|
|
90
|
+
all: readonly ReleaseChangeset[] = loadBundledChangesets(),
|
|
91
|
+
): ChangesetRange {
|
|
92
|
+
const entries = all
|
|
93
|
+
.filter((entry) => compareVersions(entry.version, previous) > 0 && compareVersions(entry.version, current) <= 0)
|
|
94
|
+
.sort((a, b) => compareVersions(a.version, b.version));
|
|
95
|
+
const reachesCurrent = entries.some((entry) => compareVersions(entry.version, current) === 0);
|
|
96
|
+
const first = entries[0];
|
|
97
|
+
const reachesPrevious = Boolean(first?.previous_version && compareVersions(first.previous_version, previous) <= 0);
|
|
98
|
+
return { entries, complete: reachesCurrent && reachesPrevious };
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
export interface ChangesetSurfaceSummary {
|
|
102
|
+
promptIds: string[];
|
|
103
|
+
toolNames: string[];
|
|
104
|
+
removedTools: string[];
|
|
105
|
+
hints: string[];
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
/** Collapses a version range to the latest state of each changed surface. */
|
|
109
|
+
export function summarizeChangesets(entries: readonly ReleaseChangeset[]): ChangesetSurfaceSummary {
|
|
110
|
+
const prompts = new Set<string>();
|
|
111
|
+
const tools = new Map<string, ToolChange["change"]>();
|
|
112
|
+
const hints: string[] = [];
|
|
113
|
+
for (const entry of entries) {
|
|
114
|
+
for (const prompt of entry.prompts) prompts.add(prompt.id);
|
|
115
|
+
for (const tool of entry.tools) tools.set(tool.name, tool.change);
|
|
116
|
+
for (const hint of entry.hints) hints.push(`${entry.version}: ${hint}`);
|
|
117
|
+
}
|
|
118
|
+
return {
|
|
119
|
+
promptIds: [...prompts].sort(),
|
|
120
|
+
toolNames: [...tools.keys()].sort(),
|
|
121
|
+
removedTools: [...tools].filter(([, change]) => change === "removed").map(([name]) => name).sort(),
|
|
122
|
+
hints,
|
|
123
|
+
};
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
function describeTool(tool: ToolChange): string {
|
|
127
|
+
const parts: string[] = [];
|
|
128
|
+
if (tool.change === "added") parts.push("new tool");
|
|
129
|
+
if (tool.change === "removed") parts.push("removed — references to it will fail");
|
|
130
|
+
if (tool.description_changed) parts.push("description changed");
|
|
131
|
+
if (tool.params_added.length) parts.push(`params added: ${tool.params_added.join(", ")}`);
|
|
132
|
+
if (tool.params_removed.length) parts.push(`params removed: ${tool.params_removed.join(", ")}`);
|
|
133
|
+
if (tool.params_changed.length) parts.push(`params changed: ${tool.params_changed.join(", ")}`);
|
|
134
|
+
if (tool.required_added.length) parts.push(`now required: ${tool.required_added.join(", ")}`);
|
|
135
|
+
if (tool.required_removed.length) parts.push(`no longer required: ${tool.required_removed.join(", ")}`);
|
|
136
|
+
const head = ` - tool \`${tool.name}\`: ${parts.join("; ") || tool.change}`;
|
|
137
|
+
return tool.description && tool.change !== "removed"
|
|
138
|
+
? `${head}\n description: ${tool.description}`
|
|
139
|
+
: head;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
function describePrompt(prompt: PromptChange): string {
|
|
143
|
+
const lines = [` - prompt \`${prompt.id}\` (${prompt.source}): ${prompt.change}`];
|
|
144
|
+
for (const line of prompt.added_lines) lines.push(` + ${line}`);
|
|
145
|
+
for (const line of prompt.removed_lines) lines.push(` - ${line}`);
|
|
146
|
+
if (prompt.omitted_lines > 0) lines.push(` … ${prompt.omitted_lines} more changed line(s)`);
|
|
147
|
+
return lines.join("\n");
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
/** Renders the range for the adoption prompt, bounded to `maxChars`. */
|
|
151
|
+
export function formatChangesetsForPrompt(entries: readonly ReleaseChangeset[], maxChars = 8000): string {
|
|
152
|
+
const blocks: string[] = [];
|
|
153
|
+
for (const entry of entries) {
|
|
154
|
+
const lines = [`Version ${entry.version} (from ${entry.previous_version ?? "unknown"}, ${entry.date}):`];
|
|
155
|
+
if (entry.hints.length) lines.push(...entry.hints.map((hint) => ` - adoption hint: ${hint}`));
|
|
156
|
+
lines.push(...entry.tools.map(describeTool));
|
|
157
|
+
lines.push(...entry.prompts.map(describePrompt));
|
|
158
|
+
if (!entry.hints.length && !entry.tools.length && !entry.prompts.length) {
|
|
159
|
+
lines.push(" - no prompt or tool surface changes");
|
|
160
|
+
}
|
|
161
|
+
blocks.push(lines.join("\n"));
|
|
162
|
+
}
|
|
163
|
+
const text = blocks.join("\n");
|
|
164
|
+
if (text.length <= maxChars) return text;
|
|
165
|
+
return `${text.slice(0, maxChars)}\n… changeset truncated; the full record is docs/adoption/changesets.json in the release.`;
|
|
166
|
+
}
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Collects the live prompt + tool surface and checks it is complete and
|
|
3
|
+
* deterministic. `scripts/release-changeset.mjs` also drives this file to
|
|
4
|
+
* write snapshots and release changesets, because collection needs the
|
|
5
|
+
* TypeScript runtime and the `@/` alias:
|
|
6
|
+
* JARELA_SURFACE_OUT=<path> write the live snapshot to <path>
|
|
7
|
+
* JARELA_CHANGESET_WRITE=1 record the release changeset (see the script)
|
|
8
|
+
*/
|
|
9
|
+
import { describe, it, expect, afterAll } from "vitest";
|
|
10
|
+
import { mkdtempSync, readFileSync, rmSync, writeFileSync } from "node:fs";
|
|
11
|
+
import { tmpdir } from "node:os";
|
|
12
|
+
import { join } from "node:path";
|
|
13
|
+
|
|
14
|
+
const tmpRoot = mkdtempSync(join(tmpdir(), "jarela-surface-"));
|
|
15
|
+
process.env.JARELA_DB_DIR = tmpRoot;
|
|
16
|
+
|
|
17
|
+
const { collectSurfaceSnapshot } = await import("./surface-collect");
|
|
18
|
+
const { SURFACE_SNAPSHOT_SCHEMA_VERSION } = await import("./surface-snapshot");
|
|
19
|
+
type SurfaceSnapshot = import("./surface-snapshot").SurfaceSnapshot;
|
|
20
|
+
|
|
21
|
+
afterAll(() => {
|
|
22
|
+
try { rmSync(tmpRoot, { recursive: true, force: true }); } catch { /* held open */ }
|
|
23
|
+
});
|
|
24
|
+
|
|
25
|
+
const root = process.cwd();
|
|
26
|
+
const packageVersion = (JSON.parse(readFileSync(join(root, "package.json"), "utf8")) as { version: string }).version;
|
|
27
|
+
const snapshot = await collectSurfaceSnapshot(packageVersion);
|
|
28
|
+
|
|
29
|
+
if (process.env.JARELA_SURFACE_OUT) {
|
|
30
|
+
writeFileSync(process.env.JARELA_SURFACE_OUT, `${JSON.stringify(snapshot, null, 2)}\n`, "utf8");
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
if (process.env.JARELA_CHANGESET_WRITE === "1") {
|
|
34
|
+
const { writeReleaseChangeset, readSnapshot } = await import("./changeset-build");
|
|
35
|
+
const readOptional = (path: string | undefined): SurfaceSnapshot | undefined =>
|
|
36
|
+
path ? readSnapshot(path) : undefined;
|
|
37
|
+
const entry = writeReleaseChangeset({
|
|
38
|
+
root,
|
|
39
|
+
version: process.env.JARELA_CHANGESET_VERSION || packageVersion,
|
|
40
|
+
nextSnapshot: readOptional(process.env.JARELA_CHANGESET_NEXT_SNAPSHOT) ?? snapshot,
|
|
41
|
+
previousSnapshot: readOptional(process.env.JARELA_CHANGESET_PREVIOUS_SNAPSHOT),
|
|
42
|
+
date: process.env.JARELA_CHANGESET_DATE || new Date().toISOString().slice(0, 10),
|
|
43
|
+
ref: process.env.JARELA_CHANGESET_REF || undefined,
|
|
44
|
+
});
|
|
45
|
+
if (process.env.JARELA_CHANGESET_REPORT) {
|
|
46
|
+
writeFileSync(process.env.JARELA_CHANGESET_REPORT, JSON.stringify({
|
|
47
|
+
version: entry.version,
|
|
48
|
+
previous_version: entry.previous_version,
|
|
49
|
+
prompts: entry.prompts.length,
|
|
50
|
+
tools: entry.tools.length,
|
|
51
|
+
hints: entry.hints.length,
|
|
52
|
+
commits: entry.commits.length,
|
|
53
|
+
}), "utf8");
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
describe("model-facing surface snapshot", () => {
|
|
58
|
+
it("covers static prompts, system prompt sections, and built-in tools", () => {
|
|
59
|
+
expect(snapshot.schema_version).toBe(SURFACE_SNAPSHOT_SCHEMA_VERSION);
|
|
60
|
+
expect(snapshot.prompts["static.agent.tool-usage-sop"]?.text).toBeTruthy();
|
|
61
|
+
expect(Object.keys(snapshot.prompts).filter((id) => id.startsWith("system."))).toEqual(
|
|
62
|
+
expect.arrayContaining(["system.Tool usage SOP", "system.Self-configuration (with user approval)"]),
|
|
63
|
+
);
|
|
64
|
+
expect(Object.keys(snapshot.tools).length).toBeGreaterThan(50);
|
|
65
|
+
expect(snapshot.tools.update_scheduled_task?.description).toBeTruthy();
|
|
66
|
+
});
|
|
67
|
+
|
|
68
|
+
it("records an object parameter schema for every tool", () => {
|
|
69
|
+
for (const [name, tool] of Object.entries(snapshot.tools)) {
|
|
70
|
+
expect((tool.parameters as { type?: unknown }).type, name).toBe("object");
|
|
71
|
+
expect(tool.parameters, name).not.toHaveProperty("$schema");
|
|
72
|
+
}
|
|
73
|
+
});
|
|
74
|
+
|
|
75
|
+
it("excludes host- and time-dependent prompt content", () => {
|
|
76
|
+
expect(snapshot.prompts).not.toHaveProperty(["system.Host environment"]);
|
|
77
|
+
expect(snapshot.prompts).not.toHaveProperty(["system.System signals"]);
|
|
78
|
+
for (const [id, prompt] of Object.entries(snapshot.prompts)) {
|
|
79
|
+
if (!id.startsWith("system.")) continue;
|
|
80
|
+
expect(prompt.text, id).not.toMatch(/^Current (time|local date and time):/m);
|
|
81
|
+
expect(prompt.text, id).not.toContain(tmpRoot);
|
|
82
|
+
}
|
|
83
|
+
});
|
|
84
|
+
|
|
85
|
+
it("is deterministic across collections", async () => {
|
|
86
|
+
expect(await collectSurfaceSnapshot(packageVersion)).toEqual(snapshot);
|
|
87
|
+
});
|
|
88
|
+
});
|