zidane 8.2.1 → 8.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (182) hide show
  1. package/dist/acp-cli.js +8 -8
  2. package/dist/{acp-D7Pr8NGt.js → acp-oYRjlh71.js} +6 -6
  3. package/dist/{acp-D7Pr8NGt.js.map → acp-oYRjlh71.js.map} +1 -1
  4. package/dist/acp.d.ts +2 -2
  5. package/dist/acp.js +1 -1
  6. package/dist/{agent-DecDtKA_.js → agent-CBQglXtH.js} +9 -379
  7. package/dist/agent-CBQglXtH.js.map +1 -0
  8. package/dist/agent.d.ts +1 -1
  9. package/dist/agent.js +1 -1
  10. package/dist/{builtin-artifact-kinds-B_OEgf8b.js → builtin-artifact-kinds-BmorPkgz.js} +36 -9
  11. package/dist/builtin-artifact-kinds-BmorPkgz.js.map +1 -0
  12. package/dist/chat/pure.d.ts +3 -3
  13. package/dist/chat/pure.js +4 -4
  14. package/dist/chat.d.ts +4 -4
  15. package/dist/chat.js +14 -14
  16. package/dist/{cli-shared-Dx4vmif6.js → cli-shared-E5m_pI8A.js} +2 -2
  17. package/dist/{cli-shared-Dx4vmif6.js.map → cli-shared-E5m_pI8A.js.map} +1 -1
  18. package/dist/{client-core-imHuBWV3.d.ts → client-core-BdD20sOv.d.ts} +24 -5
  19. package/dist/{client-core-imHuBWV3.d.ts.map → client-core-BdD20sOv.d.ts.map} +1 -1
  20. package/dist/{connection-loop-CdHt3iQi.d.ts → connection-loop-DTk82YVl.d.ts} +3 -3
  21. package/dist/{connection-loop-CdHt3iQi.d.ts.map → connection-loop-DTk82YVl.d.ts.map} +1 -1
  22. package/dist/contexts/daytona.d.ts +1 -1
  23. package/dist/contexts/e2b.d.ts +1 -1
  24. package/dist/{credentials-Dti61yoi.js → credentials-B9DfBJP9.js} +11 -7
  25. package/dist/credentials-B9DfBJP9.js.map +1 -0
  26. package/dist/daemon-cli.js +2 -2
  27. package/dist/{dispatcher-vy3J6JMA.js → dispatcher-BICXFGiJ.js} +27 -13
  28. package/dist/dispatcher-BICXFGiJ.js.map +1 -0
  29. package/dist/{engine-BN6PjWAW.js → engine-QCX3GV-i.js} +5 -5
  30. package/dist/{engine-BN6PjWAW.js.map → engine-QCX3GV-i.js.map} +1 -1
  31. package/dist/{eval-BaJtxLCW.js → eval-CfQlBR81.js} +2 -2
  32. package/dist/{eval-BaJtxLCW.js.map → eval-CfQlBR81.js.map} +1 -1
  33. package/dist/eval.d.ts +1 -1
  34. package/dist/eval.js +1 -1
  35. package/dist/{executor-CT4oUkg6.js → executor-B8GoXaaE.js} +2 -2
  36. package/dist/{executor-CT4oUkg6.js.map → executor-B8GoXaaE.js.map} +1 -1
  37. package/dist/{extensions-BKt7lxxv.js → extensions-BeH3D-bq.js} +114 -113
  38. package/dist/extensions-BeH3D-bq.js.map +1 -0
  39. package/dist/extensions.d.ts +1 -1
  40. package/dist/extensions.js +2 -2
  41. package/dist/{fold-rules-BYedvsH7.d.ts → fold-rules-DSypi36k.d.ts} +2 -2
  42. package/dist/{fold-rules-BYedvsH7.d.ts.map → fold-rules-DSypi36k.d.ts.map} +1 -1
  43. package/dist/google-O6pRnddf.js +881 -0
  44. package/dist/google-O6pRnddf.js.map +1 -0
  45. package/dist/{headless-Ebd1ZEzC.js → headless-R4pbpTkm.js} +3 -3
  46. package/dist/{headless-Ebd1ZEzC.js.map → headless-R4pbpTkm.js.map} +1 -1
  47. package/dist/headless.d.ts +1 -1
  48. package/dist/headless.js +1 -1
  49. package/dist/{host-scoped-settings-Cy_zbmB_.js → host-scoped-settings-CCnaBkCV.js} +2 -2
  50. package/dist/{host-scoped-settings-Cy_zbmB_.js.map → host-scoped-settings-CCnaBkCV.js.map} +1 -1
  51. package/dist/{host-signals-Cx2IAbHh.js → host-signals-DI9JQvR9.js} +5 -5
  52. package/dist/{host-signals-Cx2IAbHh.js.map → host-signals-DI9JQvR9.js.map} +1 -1
  53. package/dist/{index-pc71ADi6.d.ts → index-BkNeiJYI.d.ts} +71 -4
  54. package/dist/index-BkNeiJYI.d.ts.map +1 -0
  55. package/dist/{index-CidMTcxS.d.ts → index-DyQyDLX1.d.ts} +167 -10
  56. package/dist/index-DyQyDLX1.d.ts.map +1 -0
  57. package/dist/{index-Bt_G2Z_2.d.ts → index-lcuvhQfF.d.ts} +5 -5
  58. package/dist/{index-Bt_G2Z_2.d.ts.map → index-lcuvhQfF.d.ts.map} +1 -1
  59. package/dist/index.d.ts +3 -3
  60. package/dist/index.js +15 -15
  61. package/dist/ipc/remote.d.ts +5 -5
  62. package/dist/ipc/remote.js +3 -3
  63. package/dist/ipc.d.ts +5 -5
  64. package/dist/ipc.js +6 -6
  65. package/dist/{links-DSZ4uQ5w.js → links-CN5JFFde.js} +9 -9
  66. package/dist/{links-DSZ4uQ5w.js.map → links-CN5JFFde.js.map} +1 -1
  67. package/dist/mcp.d.ts +1 -1
  68. package/dist/{oauth-BSqXgads.js → oauth-TVPPye84.js} +155 -25
  69. package/dist/oauth-TVPPye84.js.map +1 -0
  70. package/dist/{openai-dTmPxM6T.js → openai-Rh6u5NXF.js} +121 -2
  71. package/dist/openai-Rh6u5NXF.js.map +1 -0
  72. package/dist/{openrouter-CtZbQDa0.js → openrouter-Dg0yaI-o.js} +91 -2
  73. package/dist/openrouter-Dg0yaI-o.js.map +1 -0
  74. package/dist/output/stream-json.d.ts +1 -1
  75. package/dist/output/terminal.d.ts +1 -1
  76. package/dist/plugins.d.ts +1 -1
  77. package/dist/{presets-EzlHyFSi.js → presets-DXeHsd24.js} +3 -3
  78. package/dist/{presets-EzlHyFSi.js.map → presets-DXeHsd24.js.map} +1 -1
  79. package/dist/presets.d.ts +1 -1
  80. package/dist/presets.js +1 -1
  81. package/dist/{prompts-D2lPHLOV.d.ts → prompts-DmY13jvF.d.ts} +2 -1
  82. package/dist/prompts-DmY13jvF.d.ts.map +1 -0
  83. package/dist/protocol-BIv1Yuvl.js.map +1 -1
  84. package/dist/providers/anthropic.d.ts +1 -1
  85. package/dist/providers/arcee.d.ts +1 -1
  86. package/dist/providers/baseten.d.ts +1 -1
  87. package/dist/providers/cerebras.d.ts +1 -1
  88. package/dist/providers/google.d.ts +1 -1
  89. package/dist/providers/google.js +1 -784
  90. package/dist/providers/local.d.ts +1 -1
  91. package/dist/providers/neuralwatt.d.ts +1 -1
  92. package/dist/providers/openai-compat.d.ts +1 -1
  93. package/dist/providers/openai.d.ts +1 -1
  94. package/dist/providers/openai.js +1 -1
  95. package/dist/providers/openrouter.d.ts +1 -1
  96. package/dist/providers/openrouter.js +1 -1
  97. package/dist/providers/xai.d.ts +1 -1
  98. package/dist/providers/xai.js +1 -101
  99. package/dist/providers.d.ts +2 -2
  100. package/dist/providers.js +6 -5
  101. package/dist/{registry-BBaEgTsX.js → registry-PNi9rsGi.js} +3 -3
  102. package/dist/{registry-BBaEgTsX.js.map → registry-PNi9rsGi.js.map} +1 -1
  103. package/dist/{remote-hosts-bO7wOt44.js → remote-hosts-b6Luwdhu.js} +4 -4
  104. package/dist/{remote-hosts-bO7wOt44.js.map → remote-hosts-b6Luwdhu.js.map} +1 -1
  105. package/dist/restate.d.ts +1 -1
  106. package/dist/{secret-shapes-Cda65uDH.js → secret-shapes-CEoGmfEE.js} +10 -1
  107. package/dist/secret-shapes-CEoGmfEE.js.map +1 -0
  108. package/dist/session/sqlite.d.ts +1 -1
  109. package/dist/{session-factory-BazyVdzj.js → session-factory-CMwIXE-7.js} +5 -5
  110. package/dist/{session-factory-BazyVdzj.js.map → session-factory-CMwIXE-7.js.map} +1 -1
  111. package/dist/session.d.ts +1 -1
  112. package/dist/{settings-keys-zYaer8DY.js → settings-keys-DssjmqAV.js} +3 -3
  113. package/dist/{settings-keys-zYaer8DY.js.map → settings-keys-DssjmqAV.js.map} +1 -1
  114. package/dist/{shell-path-od9XHRPt.js → shell-path-BUFwqU_A.js} +3 -3
  115. package/dist/{shell-path-od9XHRPt.js.map → shell-path-BUFwqU_A.js.map} +1 -1
  116. package/dist/{skills-use-D68a1gyZ.js → skills-use-CssTEaIj.js} +375 -2
  117. package/dist/skills-use-CssTEaIj.js.map +1 -0
  118. package/dist/skills.d.ts +1 -1
  119. package/dist/{system-freeze-DXvJpveP.js → system-freeze-Um9ZJiPo.js} +24 -9
  120. package/dist/system-freeze-Um9ZJiPo.js.map +1 -0
  121. package/dist/{todo-edits-CmqNFvLJ.js → todo-edits-H77ROt6X.js} +2 -2
  122. package/dist/{todo-edits-CmqNFvLJ.js.map → todo-edits-H77ROt6X.js.map} +1 -1
  123. package/dist/tools/fetch-url.d.ts +1 -1
  124. package/dist/tools/prompts.d.ts +1 -1
  125. package/dist/tools/prompts.js +7 -0
  126. package/dist/tools/prompts.js.map +1 -1
  127. package/dist/tools/web-search.d.ts +1 -1
  128. package/dist/{tools-9Dpm8F-f.js → tools-pZVFIJ_K.js} +273 -2
  129. package/dist/tools-pZVFIJ_K.js.map +1 -0
  130. package/dist/tools.d.ts +3 -3
  131. package/dist/tools.js +4 -4
  132. package/dist/{transcript-anchors-B3TFJqr_.js → transcript-anchors-s-yxh0jt.js} +10 -10
  133. package/dist/{transcript-anchors-B3TFJqr_.js.map → transcript-anchors-s-yxh0jt.js.map} +1 -1
  134. package/dist/{transcript-reconcile-BC2DbTmp.js → transcript-reconcile-DeFLIQ14.js} +19 -2
  135. package/dist/{transcript-reconcile-BC2DbTmp.js.map → transcript-reconcile-DeFLIQ14.js.map} +1 -1
  136. package/dist/tui.d.ts +7 -7
  137. package/dist/tui.js +24 -22
  138. package/dist/tui.js.map +1 -1
  139. package/dist/{turn-operations-CIFoOebZ.d.ts → turn-operations-BbGJ-KSt.d.ts} +2 -2
  140. package/dist/{turn-operations-CIFoOebZ.d.ts.map → turn-operations-BbGJ-KSt.d.ts.map} +1 -1
  141. package/dist/{types-iFLlZKd0.d.ts → types-C0PJmBaO.d.ts} +2 -2
  142. package/dist/{types-iFLlZKd0.d.ts.map → types-C0PJmBaO.d.ts.map} +1 -1
  143. package/dist/types-JzccL5GE.js +24 -0
  144. package/dist/types-JzccL5GE.js.map +1 -0
  145. package/dist/types.d.ts +2 -2
  146. package/dist/{url-BTH-HE9Y.js → url-CLl0u4Z8.js} +2 -2
  147. package/dist/{url-BTH-HE9Y.js.map → url-CLl0u4Z8.js.map} +1 -1
  148. package/dist/{version-4T82xRxQ.js → version-v77Y4A3C.js} +2 -2
  149. package/dist/{version-4T82xRxQ.js.map → version-v77Y4A3C.js.map} +1 -1
  150. package/dist/wire-DH77Z-rr.js +80 -0
  151. package/dist/wire-DH77Z-rr.js.map +1 -0
  152. package/dist/{workspace-exec-stream-By8na6vz.js → workspace-exec-stream-kqARO8iC.js} +4 -4
  153. package/dist/{workspace-exec-stream-By8na6vz.js.map → workspace-exec-stream-kqARO8iC.js.map} +1 -1
  154. package/dist/{write-file-B4vi3SvQ.js → write-file-QYrcDdl3.js} +3 -3
  155. package/dist/{write-file-B4vi3SvQ.js.map → write-file-QYrcDdl3.js.map} +1 -1
  156. package/dist/{ws-CS312Jpx.js → ws-BD9FN98u.js} +5 -5
  157. package/dist/{ws-CS312Jpx.js.map → ws-BD9FN98u.js.map} +1 -1
  158. package/dist/{ws-client-wWka-Jku.js → ws-client-D7eb2UbH.js} +3 -3
  159. package/dist/{ws-client-wWka-Jku.js.map → ws-client-D7eb2UbH.js.map} +1 -1
  160. package/dist/xai-CStTwCV2.js +182 -0
  161. package/dist/xai-CStTwCV2.js.map +1 -0
  162. package/docs/ARCHITECTURE.md +1 -0
  163. package/docs/ARTIFACTS.md +1 -1
  164. package/docs/EXTENSIONS.md +9 -5
  165. package/package.json +2 -2
  166. package/dist/agent-DecDtKA_.js.map +0 -1
  167. package/dist/builtin-artifact-kinds-B_OEgf8b.js.map +0 -1
  168. package/dist/credentials-Dti61yoi.js.map +0 -1
  169. package/dist/dispatcher-vy3J6JMA.js.map +0 -1
  170. package/dist/extensions-BKt7lxxv.js.map +0 -1
  171. package/dist/index-CidMTcxS.d.ts.map +0 -1
  172. package/dist/index-pc71ADi6.d.ts.map +0 -1
  173. package/dist/oauth-BSqXgads.js.map +0 -1
  174. package/dist/openai-dTmPxM6T.js.map +0 -1
  175. package/dist/openrouter-CtZbQDa0.js.map +0 -1
  176. package/dist/prompts-D2lPHLOV.d.ts.map +0 -1
  177. package/dist/providers/google.js.map +0 -1
  178. package/dist/providers/xai.js.map +0 -1
  179. package/dist/secret-shapes-Cda65uDH.js.map +0 -1
  180. package/dist/skills-use-D68a1gyZ.js.map +0 -1
  181. package/dist/system-freeze-DXvJpveP.js.map +0 -1
  182. package/dist/tools-9Dpm8F-f.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"cli-shared-Dx4vmif6.js","names":[],"sources":["../src/chat/auth.ts","../src/cli-shared.ts"],"sourcesContent":["import type { ProviderCredential } from './credentials'\nimport type { ProviderDescriptor } from './providers'\nimport { API_KEY_ACCOUNT_LABEL } from './cred-keys'\nimport { oauthAccountLabel, readCredentials, storedCredentialsOf } from './credentials'\nimport { credKeyOf } from './providers'\n\nexport { API_KEY_ACCOUNT_LABEL } from './cred-keys'\n\n/**\n * Provider identifier as known to the TUI. Built-in keys include `anthropic`,\n * `openai`, `openrouter` and `cerebras`, and hosts can register additional\n * keys via {@link ProviderDescriptor} — so the type is open.\n */\nexport type ProviderKey = string\n\n/** One credential source detected for a provider. */\nexport interface AuthMethod {\n /** Where the credential comes from: an environment variable, a stored OAuth grant, or a stored API key. */\n source: 'env' | 'oauth' | 'apikey'\n /**\n * Human-readable detail: the env var name, the credentials file, or an\n * OAuth grant's expiry. The OAuth account name is in `label`, not here.\n */\n detail: string\n /**\n * True for the credential every reader actually resolves.\n *\n * Exactly one STORED credential is active: the one in the canonical file key\n * (see `alternateCredKey`). A provider can hold an API key and any number of\n * OAuth accounts, so the list alone does not say which one wins. `env` is\n * never marked active — it is an observable signal, not a stored credential\n * the user can promote.\n *\n * Optional so hosts that build `ProviderAuth` themselves (this type is public\n * via `zidane/chat`) keep compiling; absent reads as \"not active\".\n * {@link detectAuth} always sets it.\n */\n active?: boolean\n /**\n * Credentials-file key of a STORED credential — the identity to hand to\n * `setPreferredCredential({ key })` / `removeStoredCredential`. Several OAuth\n * accounts share `source: 'oauth'`, so `source` alone does not select one.\n * Absent for `env`.\n */\n key?: string\n /**\n * Account name — always set for stored OAuth credentials: the user-given one,\n * or `DEFAULT_OAUTH_ACCOUNT_LABEL` when the grant was never named.\n */\n label?: string\n /**\n * Stable id of a STORED credential (`ProviderCredential.id`): unlike\n * {@link key}, it does not move when another account is promoted. What a\n * session pinned to this account stores. Absent for `env`, and for an entry\n * written before ids until its next write.\n */\n id?: string\n}\n\n/** One stored credential of a provider that a session can run on (see {@link ProviderAuth.accounts}). */\nexport interface ProviderAccount {\n /** The credential's stable id: what a session pins (`metadata.account`). */\n id: string\n /** Display name: the OAuth account's label, or `API key`. */\n label: string\n /** Whether the account is an OAuth grant or an API key. */\n kind: 'oauth' | 'apikey'\n /** The provider's active credential (what an unpinned session runs on). */\n active: boolean\n}\n\n/** Authentication state of one provider, as listed by {@link detectAuth}. */\nexport interface ProviderAuth {\n /** Provider key. */\n key: ProviderKey\n /** Display name of the provider. */\n label: string\n /** True when at least one credential source is present. */\n available: boolean\n /** Credential sources currently present, stored credentials first. */\n methods: AuthMethod[]\n /**\n * The stored credentials a session can be pinned to, active first — set\n * only when there is a choice: the provider's factory takes an account\n * (`ProviderDescriptor.accounts`) and at least two are stored. Absent:\n * one account (or none), so pickers show the provider as before.\n */\n accounts?: ProviderAccount[]\n /**\n * Env var this provider reads, when it declares one.\n *\n * Carried separately from {@link methods} because the settings list shows the\n * env slot even when it holds nothing. `methods` only ever lists sources that\n * are actually present, since `available` is derived from it.\n */\n envKey?: string\n}\n\n/** The stored, id-carrying credentials among `methods`, as accounts (order kept: active first). */\nfunction accountsOf(methods: readonly AuthMethod[]): ProviderAccount[] {\n const out: ProviderAccount[] = []\n for (const method of methods) {\n if (!method.id || (method.source !== 'oauth' && method.source !== 'apikey'))\n continue\n out.push({\n id: method.id,\n label: method.source === 'oauth' ? (method.label ?? 'Default') : API_KEY_ACCOUNT_LABEL,\n kind: method.source,\n active: method.active === true,\n })\n }\n return out\n}\n\n/**\n * Detect available auth for every registered provider.\n *\n * A method appears in `methods` for every layer that has a credential:\n *\n * - `kind: 'apikey'` from `credentials.json` (injected into env at TUI launch)\n * - explicit env var (descriptor's `envKey`)\n * - `kind: 'oauth'` from `credentials.json` (migrated on first read from a\n * legacy `.credentials.json`, see `readCredentials`), one per stored account\n *\n * The preferred credential lives in the canonical file key and is flagged\n * {@link AuthMethod.active}; the others sit in sibling slots and are reported\n * too, keyed by {@link AuthMethod.key}, so the UI can offer to promote or\n * remove them. Order within `methods` is presentational — active first — not a\n * resolution order, because the active flag answers that directly.\n *\n * Never refreshes tokens or rewrites existing credentials. The one write is\n * the first-read migration of a legacy `.credentials.json` when\n * `credentials.json` does not exist yet (see `readCredentials`).\n *\n * @param dataDir - Directory holding `credentials.json`.\n * @param registry - Provider descriptors keyed by id.\n * @param env - Environment used to look for ambient credentials. Defaults to `process.env`.\n */\nexport function detectAuth(\n dataDir: string,\n registry: Readonly<Record<string, ProviderDescriptor>>,\n env: Record<string, string | undefined> = process.env,\n): ProviderAuth[] {\n const creds = readCredentials(dataDir)\n\n return Object.values(registry).map((descriptor) => {\n const methods: AuthMethod[] = []\n const stored = storedCredentialsOf(creds, credKeyOf(descriptor))\n const fileEntry = stored.find(s => s.active)?.credential\n\n // 1. Stored API key / OAuth accounts, active first. Every slot goes through\n // the same description so a parked credential renders identically to the\n // preferred one, differing only in `active`.\n const describeStored = (key: string, entry: ProviderCredential, active: boolean): AuthMethod | undefined => {\n const id = typeof entry.id === 'string' && entry.id ? { id: entry.id } : {}\n if (entry.kind === 'apikey' && entry.value)\n return { source: 'apikey', detail: 'credentials.json', active, key, ...id }\n if (entry.kind === 'oauth' && entry.access) {\n const label = oauthAccountLabel(entry)\n const expiry = typeof entry.expires === 'number'\n ? `expires ${new Date(entry.expires).toLocaleString()}`\n : 'credentials.json'\n return { source: 'oauth', detail: expiry, active, key, label, ...id }\n }\n return undefined\n }\n\n for (const slot of stored) {\n const method = describeStored(slot.key, slot.credential, slot.active)\n if (method)\n methods.push(method)\n }\n\n // 1b. customFields-only credential (descriptor has no `envKey` and is\n // authenticated entirely by configuration — e.g. the `local` provider,\n // where the auth signal is the configured base URL). The credential\n // is \"present\" when every required field has a stored value.\n if (\n fileEntry?.kind === 'apikey'\n && !fileEntry.value\n && descriptor.customFields\n && descriptor.customFields.length > 0\n ) {\n const stored = fileEntry.customFields ?? {}\n const required = descriptor.customFields.filter(f => f.required)\n const allRequiredPresent = required.every(\n f => typeof stored[f.key] === 'string' && (stored[f.key] as string).length > 0,\n )\n if (allRequiredPresent) {\n methods.push({ source: 'apikey', detail: 'credentials.json (configured)', active: true })\n }\n }\n\n // 1c. Env-only custom field configuration. This lets local/OpenAI-compatible\n // endpoints participate in auth/model detection when configured through\n // `LOCAL_LLM_BASE_URL` without first writing credentials.json.\n if (descriptor.customFields && descriptor.customFields.length > 0) {\n const required = descriptor.customFields.filter(f => f.required)\n const allRequiredPresent = required.length > 0 && required.every(\n f => typeof env[f.envVar] === 'string' && (env[f.envVar] as string).length > 0,\n )\n\n if (allRequiredPresent) {\n methods.push({ source: 'env', detail: required.map(f => f.envVar).join(', '), active: false })\n }\n }\n\n // 2. Env var (may be set by `applyApiKeyEnv` from a stored key, or by the\n // user's shell. Either way, treated as the same observable signal.)\n if (descriptor.envKey && env[descriptor.envKey])\n methods.push({ source: 'env', detail: descriptor.envKey, active: false })\n\n // Selection identity is the file key for stored credentials and `source`\n // for everything else. Two API-key rows cannot be a choice the user can\n // express (there is one API key per provider) — a customFields-configured\n // credential sitting beside a stored one, or a stale duplicate from an\n // older build, collapses to the FIRST, which the order above makes the\n // active one. OAuth accounts are distinct by key and all survive.\n const unique: AuthMethod[] = []\n for (const method of methods) {\n const duplicate = unique.some(seen =>\n method.source === 'oauth'\n ? seen.key !== undefined && seen.key === method.key\n : seen.source === method.source,\n )\n if (!duplicate)\n unique.push(method)\n }\n\n const accounts = descriptor.accounts === true ? accountsOf(unique) : []\n return {\n key: descriptor.key,\n label: descriptor.label,\n available: unique.length > 0,\n methods: unique,\n ...(accounts.length >= 2 ? { accounts } : {}),\n ...(descriptor.envKey ? { envKey: descriptor.envKey } : {}),\n }\n })\n}\n","/**\n * Shared glue for the CLI entrypoints (`start.ts` — human renderer,\n * `headless-cli.ts` — machine contract). Both build an execution context,\n * resolve a session (memory or sqlite), and parse `--mcp` config the same way;\n * this module is the single source of truth for that wiring so the two CLIs\n * stay in lockstep without duplicating it.\n */\n\nimport type { ExecutionContext } from './contexts'\nimport type { Session } from './session'\nimport { createProcessContext, createSandboxContext } from './contexts'\nimport { createDaytonaProvider } from './contexts/daytona'\nimport { createDockerContext, hostWorkspaceMounts } from './contexts/docker'\nimport { createE2BProvider } from './contexts/e2b'\nimport { createMemoryStore, createSession, loadSession } from './session'\n\nexport { parseMcpConfig } from './start/shared-options'\n\n/**\n * Build the execution context for a CLI run: `process` (default), `docker`,\n * `e2b`, or `daytona`.\n *\n * The `e2b` backend reads its `E2B_API_KEY` / `E2B_DOMAIN` / `E2B_TEMPLATE`\n * from the environment (point `E2B_DOMAIN` at a self-hosted cluster, and set\n * `E2B_TEMPLATE` to a template that exists there — the default `base` does\n * not); `--cwd` becomes the sandbox working directory.\n *\n * The Daytona backend reads `DAYTONA_API_KEY` / `DAYTONA_API_URL` /\n * `DAYTONA_TARGET` from the environment. `--cwd` becomes the sandbox working\n * directory.\n *\n * Docker: when `--cwd` is an existing host directory, its git worktree (and\n * the git common dir, for linked worktrees) is bind-mounted at the same\n * absolute path (git hooks/config read-only); otherwise, or when that tree\n * is `/`, `$HOME`, or an ancestor of it, `--cwd` is a container-only path.\n *\n * `env` (from `--env` / `--pass-env`) is forwarded to whichever context is\n * selected: baked into remote sandboxes at create time, set on the Docker\n * container, or merged into the in-process command environment.\n *\n * `pregame` (from `--pregame`) is supported by the remote sandbox providers:\n * a setup script uploaded and run in the sandbox once it's ready, before\n * prompting begins.\n *\n * `sandboxId` (from `--sandbox`) attaches to a pre-existing remote sandbox\n * instead of creating a fresh one.\n */\nexport function createCliExecution(type: string, opts: { image?: string, cwd?: string, env?: Record<string, string>, pregame?: { name: string, content: string }, sandboxId?: string, sandboxOnDestroy?: 'kill' | 'pause' | 'leave' }): ExecutionContext {\n switch (type) {\n case 'docker': {\n // An existing host dir is bind-mounted at the same path so the agent\n // works on the real checkout; a container-only path mounts nothing.\n const mounts = opts.cwd ? hostWorkspaceMounts(opts.cwd) : []\n return createDockerContext({ image: opts.image, cwd: opts.cwd, env: opts.env, ...(mounts.length > 0 ? { mounts } : {}) })\n }\n case 'e2b':\n return createSandboxContext(createE2BProvider({ cwd: opts.cwd, env: opts.env, ...(opts.pregame ? { pregame: opts.pregame } : {}), ...(opts.sandboxId ? { sandboxId: opts.sandboxId } : {}), ...(opts.sandboxOnDestroy ? { onDestroy: opts.sandboxOnDestroy } : {}) }))\n case 'daytona':\n return createSandboxContext(createDaytonaProvider({ cwd: opts.cwd, env: opts.env, ...(opts.pregame ? { pregame: opts.pregame } : {}), ...(opts.sandboxId ? { sandboxId: opts.sandboxId } : {}), ...(opts.sandboxOnDestroy ? { onDestroy: opts.sandboxOnDestroy } : {}) }))\n case 'process':\n default:\n return createProcessContext({ cwd: opts.cwd, env: opts.env })\n }\n}\n\n/**\n * Contexts whose filesystem is a remote sandbox: host paths don't exist\n * there, so host-derived cwds must not be forwarded.\n */\nexport function isRemoteSandboxContext(type: string): boolean {\n return type === 'e2b' || type === 'daytona'\n}\n\n/**\n * Resolve the session for a CLI run.\n * - `sessionDb` set → sqlite-backed; resume `sessionId` if it exists, else\n * create it (or a fresh id when `sessionId` is omitted).\n * - `sessionDb` absent → in-memory store.\n *\n * Fresh sessions are saved immediately so the store has a header row from\n * the start — incremental `appendTurns` against a header-less sqlite store\n * would otherwise be silent no-ops, and an error / Ctrl+C before the final\n * save would lose the whole run.\n */\nexport async function createCliSession(sessionDb?: string, sessionId?: string): Promise<Session> {\n if (sessionDb) {\n const { createSqliteStore } = await import('./session/sqlite')\n const store = createSqliteStore({ path: sessionDb })\n if (sessionId) {\n const existing = await loadSession(store, sessionId)\n if (existing)\n return existing\n const session = await createSession({ store, id: sessionId })\n await session.save()\n return session\n }\n const session = await createSession({ store })\n await session.save()\n return session\n }\n return await createSession({ store: createMemoryStore() })\n}\n\n/**\n * Install SIGINT/SIGTERM handlers for a CLI run. The first signal aborts the\n * returned `AbortSignal` so the running agent can unwind cleanly (persist the\n * session, destroy execution contexts) and the process exits through the\n * normal path — which is what fires the `process.on('exit')` orphan reaper\n * for detached background process groups. A second signal force-exits\n * immediately (the synchronous 'exit' reaper still runs, but async cleanup\n * such as Docker container teardown is skipped).\n */\nexport function installCliSignalHandlers(): AbortSignal {\n const controller = new AbortController()\n const onSignal = (name: NodeJS.Signals): void => {\n if (controller.signal.aborted)\n process.exit(name === 'SIGTERM' ? 143 : 130) // 128 + signal number\n controller.abort(new Error(`Received ${name}, stopping the run`))\n }\n process.on('SIGINT', () => onSignal('SIGINT'))\n process.on('SIGTERM', () => onSignal('SIGTERM'))\n return controller.signal\n}\n"],"mappings":";;;;;;;;;AAmGA,SAAS,WAAW,SAAmD;CACrE,MAAM,MAAyB,CAAC;CAChC,KAAK,MAAM,UAAU,SAAS;EAC5B,IAAI,CAAC,OAAO,MAAO,OAAO,WAAW,WAAW,OAAO,WAAW,UAChE;EACF,IAAI,KAAK;GACP,IAAI,OAAO;GACX,OAAO,OAAO,WAAW,UAAW,OAAO,SAAS,YAAa;GACjE,MAAM,OAAO;GACb,QAAQ,OAAO,WAAW;EAC5B,CAAC;CACH;CACA,OAAO;AACT;;;;;;;;;;;;;;;;;;;;;;;;;AA0BA,SAAgB,WACd,SACA,UACA,MAA0C,QAAQ,KAClC;CAChB,MAAM,QAAQ,gBAAgB,OAAO;CAErC,OAAO,OAAO,OAAO,QAAQ,CAAC,CAAC,KAAK,eAAe;EACjD,MAAM,UAAwB,CAAC;EAC/B,MAAM,SAAS,oBA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,CAAC;GAAI,GAAI,KAAK,YAAY,EAAE,WAAW,KAAK,UAAU,IAAI,CAAC;GAAI,GAAI,KAAK,mBAAmB,EAAE,WAAW,KAAK,iBAAiB,IAAI,CAAC;EAAG,CAAC,CAAC;EACvQ,KAAK,WACH,OAAO,qBAAqB,sBAAsB;GAAE,KAAK,KAAK;GAAK,KAAK,KAAK;GAAK,GAAI,KAAK,UAAU,EAAE,SAAS,KAAK,QAAQ,IAAI,CAAC;GAAI,GAAI,KAAK,YAAY,EAAE,WAAW,KAAK,UAAU,IAAI,CAAC;GAAI,GAAI,KAAK,mBAAmB,EAAE,WAAW,KAAK,iBAAiB,IAAI,CAAC;EAAG,CAAC,CAAC;EAE3Q,SACE,OAAO,qBAAqB;GAAE,KAAK,KAAK;GAAK,KAAK,KAAK;EAAI,CAAC;CAChE;AACF;;;;;AAMA,SAAgB,uBAAuB,MAAuB;CAC5D,OAAO,SAAS,SAAS,SAAS;AACpC"}
1
+ {"version":3,"file":"cli-shared-E5m_pI8A.js","names":[],"sources":["../src/chat/auth.ts","../src/cli-shared.ts"],"sourcesContent":["import type { ProviderCredential } from './credentials'\nimport type { ProviderDescriptor } from './providers'\nimport { API_KEY_ACCOUNT_LABEL } from './cred-keys'\nimport { oauthAccountLabel, readCredentials, storedCredentialsOf } from './credentials'\nimport { credKeyOf } from './providers'\n\nexport { API_KEY_ACCOUNT_LABEL } from './cred-keys'\n\n/**\n * Provider identifier as known to the TUI. Built-in keys include `anthropic`,\n * `openai`, `openrouter` and `cerebras`, and hosts can register additional\n * keys via {@link ProviderDescriptor} — so the type is open.\n */\nexport type ProviderKey = string\n\n/** One credential source detected for a provider. */\nexport interface AuthMethod {\n /** Where the credential comes from: an environment variable, a stored OAuth grant, or a stored API key. */\n source: 'env' | 'oauth' | 'apikey'\n /**\n * Human-readable detail: the env var name, the credentials file, or an\n * OAuth grant's expiry. The OAuth account name is in `label`, not here.\n */\n detail: string\n /**\n * True for the credential every reader actually resolves.\n *\n * Exactly one STORED credential is active: the one in the canonical file key\n * (see `alternateCredKey`). A provider can hold an API key and any number of\n * OAuth accounts, so the list alone does not say which one wins. `env` is\n * never marked active — it is an observable signal, not a stored credential\n * the user can promote.\n *\n * Optional so hosts that build `ProviderAuth` themselves (this type is public\n * via `zidane/chat`) keep compiling; absent reads as \"not active\".\n * {@link detectAuth} always sets it.\n */\n active?: boolean\n /**\n * Credentials-file key of a STORED credential — the identity to hand to\n * `setPreferredCredential({ key })` / `removeStoredCredential`. Several OAuth\n * accounts share `source: 'oauth'`, so `source` alone does not select one.\n * Absent for `env`.\n */\n key?: string\n /**\n * Account name — always set for stored OAuth credentials: the user-given one,\n * or `DEFAULT_OAUTH_ACCOUNT_LABEL` when the grant was never named.\n */\n label?: string\n /**\n * Stable id of a STORED credential (`ProviderCredential.id`): unlike\n * {@link key}, it does not move when another account is promoted. What a\n * session pinned to this account stores. Absent for `env`, and for an entry\n * written before ids until its next write.\n */\n id?: string\n}\n\n/** One stored credential of a provider that a session can run on (see {@link ProviderAuth.accounts}). */\nexport interface ProviderAccount {\n /** The credential's stable id: what a session pins (`metadata.account`). */\n id: string\n /** Display name: the OAuth account's label, or `API key`. */\n label: string\n /** Whether the account is an OAuth grant or an API key. */\n kind: 'oauth' | 'apikey'\n /** The provider's active credential (what an unpinned session runs on). */\n active: boolean\n}\n\n/** Authentication state of one provider, as listed by {@link detectAuth}. */\nexport interface ProviderAuth {\n /** Provider key. */\n key: ProviderKey\n /** Display name of the provider. */\n label: string\n /** True when at least one credential source is present. */\n available: boolean\n /** Credential sources currently present, stored credentials first. */\n methods: AuthMethod[]\n /**\n * The stored credentials a session can be pinned to, active first — set\n * only when there is a choice: the provider's factory takes an account\n * (`ProviderDescriptor.accounts`) and at least two are stored. Absent:\n * one account (or none), so pickers show the provider as before.\n */\n accounts?: ProviderAccount[]\n /**\n * Env var this provider reads, when it declares one.\n *\n * Carried separately from {@link methods} because the settings list shows the\n * env slot even when it holds nothing. `methods` only ever lists sources that\n * are actually present, since `available` is derived from it.\n */\n envKey?: string\n}\n\n/** The stored, id-carrying credentials among `methods`, as accounts (order kept: active first). */\nfunction accountsOf(methods: readonly AuthMethod[]): ProviderAccount[] {\n const out: ProviderAccount[] = []\n for (const method of methods) {\n if (!method.id || (method.source !== 'oauth' && method.source !== 'apikey'))\n continue\n out.push({\n id: method.id,\n label: method.source === 'oauth' ? (method.label ?? 'Default') : API_KEY_ACCOUNT_LABEL,\n kind: method.source,\n active: method.active === true,\n })\n }\n return out\n}\n\n/**\n * Detect available auth for every registered provider.\n *\n * A method appears in `methods` for every layer that has a credential:\n *\n * - `kind: 'apikey'` from `credentials.json` (injected into env at TUI launch)\n * - explicit env var (descriptor's `envKey`)\n * - `kind: 'oauth'` from `credentials.json` (migrated on first read from a\n * legacy `.credentials.json`, see `readCredentials`), one per stored account\n *\n * The preferred credential lives in the canonical file key and is flagged\n * {@link AuthMethod.active}; the others sit in sibling slots and are reported\n * too, keyed by {@link AuthMethod.key}, so the UI can offer to promote or\n * remove them. Order within `methods` is presentational — active first — not a\n * resolution order, because the active flag answers that directly.\n *\n * Never refreshes tokens or rewrites existing credentials. The one write is\n * the first-read migration of a legacy `.credentials.json` when\n * `credentials.json` does not exist yet (see `readCredentials`).\n *\n * @param dataDir - Directory holding `credentials.json`.\n * @param registry - Provider descriptors keyed by id.\n * @param env - Environment used to look for ambient credentials. Defaults to `process.env`.\n */\nexport function detectAuth(\n dataDir: string,\n registry: Readonly<Record<string, ProviderDescriptor>>,\n env: Record<string, string | undefined> = process.env,\n): ProviderAuth[] {\n const creds = readCredentials(dataDir)\n\n return Object.values(registry).map((descriptor) => {\n const methods: AuthMethod[] = []\n const stored = storedCredentialsOf(creds, credKeyOf(descriptor))\n const fileEntry = stored.find(s => s.active)?.credential\n\n // 1. Stored API key / OAuth accounts, active first. Every slot goes through\n // the same description so a parked credential renders identically to the\n // preferred one, differing only in `active`.\n const describeStored = (key: string, entry: ProviderCredential, active: boolean): AuthMethod | undefined => {\n const id = typeof entry.id === 'string' && entry.id ? { id: entry.id } : {}\n if (entry.kind === 'apikey' && entry.value)\n return { source: 'apikey', detail: 'credentials.json', active, key, ...id }\n if (entry.kind === 'oauth' && entry.access) {\n const label = oauthAccountLabel(entry)\n const expiry = typeof entry.expires === 'number'\n ? `expires ${new Date(entry.expires).toLocaleString()}`\n : 'credentials.json'\n return { source: 'oauth', detail: expiry, active, key, label, ...id }\n }\n return undefined\n }\n\n for (const slot of stored) {\n const method = describeStored(slot.key, slot.credential, slot.active)\n if (method)\n methods.push(method)\n }\n\n // 1b. customFields-only credential (descriptor has no `envKey` and is\n // authenticated entirely by configuration — e.g. the `local` provider,\n // where the auth signal is the configured base URL). The credential\n // is \"present\" when every required field has a stored value.\n if (\n fileEntry?.kind === 'apikey'\n && !fileEntry.value\n && descriptor.customFields\n && descriptor.customFields.length > 0\n ) {\n const stored = fileEntry.customFields ?? {}\n const required = descriptor.customFields.filter(f => f.required)\n const allRequiredPresent = required.every(\n f => typeof stored[f.key] === 'string' && (stored[f.key] as string).length > 0,\n )\n if (allRequiredPresent) {\n methods.push({ source: 'apikey', detail: 'credentials.json (configured)', active: true })\n }\n }\n\n // 1c. Env-only custom field configuration. This lets local/OpenAI-compatible\n // endpoints participate in auth/model detection when configured through\n // `LOCAL_LLM_BASE_URL` without first writing credentials.json.\n if (descriptor.customFields && descriptor.customFields.length > 0) {\n const required = descriptor.customFields.filter(f => f.required)\n const allRequiredPresent = required.length > 0 && required.every(\n f => typeof env[f.envVar] === 'string' && (env[f.envVar] as string).length > 0,\n )\n\n if (allRequiredPresent) {\n methods.push({ source: 'env', detail: required.map(f => f.envVar).join(', '), active: false })\n }\n }\n\n // 2. Env var (may be set by `applyApiKeyEnv` from a stored key, or by the\n // user's shell. Either way, treated as the same observable signal.)\n if (descriptor.envKey && env[descriptor.envKey])\n methods.push({ source: 'env', detail: descriptor.envKey, active: false })\n\n // Selection identity is the file key for stored credentials and `source`\n // for everything else. Two API-key rows cannot be a choice the user can\n // express (there is one API key per provider) — a customFields-configured\n // credential sitting beside a stored one, or a stale duplicate from an\n // older build, collapses to the FIRST, which the order above makes the\n // active one. OAuth accounts are distinct by key and all survive.\n const unique: AuthMethod[] = []\n for (const method of methods) {\n const duplicate = unique.some(seen =>\n method.source === 'oauth'\n ? seen.key !== undefined && seen.key === method.key\n : seen.source === method.source,\n )\n if (!duplicate)\n unique.push(method)\n }\n\n const accounts = descriptor.accounts === true ? accountsOf(unique) : []\n return {\n key: descriptor.key,\n label: descriptor.label,\n available: unique.length > 0,\n methods: unique,\n ...(accounts.length >= 2 ? { accounts } : {}),\n ...(descriptor.envKey ? { envKey: descriptor.envKey } : {}),\n }\n })\n}\n","/**\n * Shared glue for the CLI entrypoints (`start.ts` — human renderer,\n * `headless-cli.ts` — machine contract). Both build an execution context,\n * resolve a session (memory or sqlite), and parse `--mcp` config the same way;\n * this module is the single source of truth for that wiring so the two CLIs\n * stay in lockstep without duplicating it.\n */\n\nimport type { ExecutionContext } from './contexts'\nimport type { Session } from './session'\nimport { createProcessContext, createSandboxContext } from './contexts'\nimport { createDaytonaProvider } from './contexts/daytona'\nimport { createDockerContext, hostWorkspaceMounts } from './contexts/docker'\nimport { createE2BProvider } from './contexts/e2b'\nimport { createMemoryStore, createSession, loadSession } from './session'\n\nexport { parseMcpConfig } from './start/shared-options'\n\n/**\n * Build the execution context for a CLI run: `process` (default), `docker`,\n * `e2b`, or `daytona`.\n *\n * The `e2b` backend reads its `E2B_API_KEY` / `E2B_DOMAIN` / `E2B_TEMPLATE`\n * from the environment (point `E2B_DOMAIN` at a self-hosted cluster, and set\n * `E2B_TEMPLATE` to a template that exists there — the default `base` does\n * not); `--cwd` becomes the sandbox working directory.\n *\n * The Daytona backend reads `DAYTONA_API_KEY` / `DAYTONA_API_URL` /\n * `DAYTONA_TARGET` from the environment. `--cwd` becomes the sandbox working\n * directory.\n *\n * Docker: when `--cwd` is an existing host directory, its git worktree (and\n * the git common dir, for linked worktrees) is bind-mounted at the same\n * absolute path (git hooks/config read-only); otherwise, or when that tree\n * is `/`, `$HOME`, or an ancestor of it, `--cwd` is a container-only path.\n *\n * `env` (from `--env` / `--pass-env`) is forwarded to whichever context is\n * selected: baked into remote sandboxes at create time, set on the Docker\n * container, or merged into the in-process command environment.\n *\n * `pregame` (from `--pregame`) is supported by the remote sandbox providers:\n * a setup script uploaded and run in the sandbox once it's ready, before\n * prompting begins.\n *\n * `sandboxId` (from `--sandbox`) attaches to a pre-existing remote sandbox\n * instead of creating a fresh one.\n */\nexport function createCliExecution(type: string, opts: { image?: string, cwd?: string, env?: Record<string, string>, pregame?: { name: string, content: string }, sandboxId?: string, sandboxOnDestroy?: 'kill' | 'pause' | 'leave' }): ExecutionContext {\n switch (type) {\n case 'docker': {\n // An existing host dir is bind-mounted at the same path so the agent\n // works on the real checkout; a container-only path mounts nothing.\n const mounts = opts.cwd ? hostWorkspaceMounts(opts.cwd) : []\n return createDockerContext({ image: opts.image, cwd: opts.cwd, env: opts.env, ...(mounts.length > 0 ? { mounts } : {}) })\n }\n case 'e2b':\n return createSandboxContext(createE2BProvider({ cwd: opts.cwd, env: opts.env, ...(opts.pregame ? { pregame: opts.pregame } : {}), ...(opts.sandboxId ? { sandboxId: opts.sandboxId } : {}), ...(opts.sandboxOnDestroy ? { onDestroy: opts.sandboxOnDestroy } : {}) }))\n case 'daytona':\n return createSandboxContext(createDaytonaProvider({ cwd: opts.cwd, env: opts.env, ...(opts.pregame ? { pregame: opts.pregame } : {}), ...(opts.sandboxId ? { sandboxId: opts.sandboxId } : {}), ...(opts.sandboxOnDestroy ? { onDestroy: opts.sandboxOnDestroy } : {}) }))\n case 'process':\n default:\n return createProcessContext({ cwd: opts.cwd, env: opts.env })\n }\n}\n\n/**\n * Contexts whose filesystem is a remote sandbox: host paths don't exist\n * there, so host-derived cwds must not be forwarded.\n */\nexport function isRemoteSandboxContext(type: string): boolean {\n return type === 'e2b' || type === 'daytona'\n}\n\n/**\n * Resolve the session for a CLI run.\n * - `sessionDb` set → sqlite-backed; resume `sessionId` if it exists, else\n * create it (or a fresh id when `sessionId` is omitted).\n * - `sessionDb` absent → in-memory store.\n *\n * Fresh sessions are saved immediately so the store has a header row from\n * the start — incremental `appendTurns` against a header-less sqlite store\n * would otherwise be silent no-ops, and an error / Ctrl+C before the final\n * save would lose the whole run.\n */\nexport async function createCliSession(sessionDb?: string, sessionId?: string): Promise<Session> {\n if (sessionDb) {\n const { createSqliteStore } = await import('./session/sqlite')\n const store = createSqliteStore({ path: sessionDb })\n if (sessionId) {\n const existing = await loadSession(store, sessionId)\n if (existing)\n return existing\n const session = await createSession({ store, id: sessionId })\n await session.save()\n return session\n }\n const session = await createSession({ store })\n await session.save()\n return session\n }\n return await createSession({ store: createMemoryStore() })\n}\n\n/**\n * Install SIGINT/SIGTERM handlers for a CLI run. The first signal aborts the\n * returned `AbortSignal` so the running agent can unwind cleanly (persist the\n * session, destroy execution contexts) and the process exits through the\n * normal path — which is what fires the `process.on('exit')` orphan reaper\n * for detached background process groups. A second signal force-exits\n * immediately (the synchronous 'exit' reaper still runs, but async cleanup\n * such as Docker container teardown is skipped).\n */\nexport function installCliSignalHandlers(): AbortSignal {\n const controller = new AbortController()\n const onSignal = (name: NodeJS.Signals): void => {\n if (controller.signal.aborted)\n process.exit(name === 'SIGTERM' ? 143 : 130) // 128 + signal number\n controller.abort(new Error(`Received ${name}, stopping the run`))\n }\n process.on('SIGINT', () => onSignal('SIGINT'))\n process.on('SIGTERM', () => onSignal('SIGTERM'))\n return controller.signal\n}\n"],"mappings":";;;;;;;;;AAmGA,SAAS,WAAW,SAAmD;CACrE,MAAM,MAAyB,CAAC;CAChC,KAAK,MAAM,UAAU,SAAS;EAC5B,IAAI,CAAC,OAAO,MAAO,OAAO,WAAW,WAAW,OAAO,WAAW,UAChE;EACF,IAAI,KAAK;GACP,IAAI,OAAO;GACX,OAAO,OAAO,WAAW,UAAW,OAAO,SAAS,YAAa;GACjE,MAAM,OAAO;GACb,QAAQ,OAAO,WAAW;EAC5B,CAAC;C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O,KAAK,KAAK;IAAK,KAAK,KAAK;IAAK,GAAI,OAAO,SAAS,IAAI,EAAE,OAAO,IAAI,CAAC;GAAG,CAAC;EAC1H;EACA,KAAK,OACH,OAAO,qBAAqB,kBAAkB;GAAE,KAAK,KAAK;GAAK,KAAK,KAAK;GAAK,GAAI,KAAK,UAAU,EAAE,SAAS,KAAK,QAAQ,IAAI,CAAC;GAAI,GAAI,KAAK,YAAY,EAAE,WAAW,KAAK,UAAU,IAAI,CAAC;GAAI,GAAI,KAAK,mBAAmB,EAAE,WAAW,KAAK,iBAAiB,IAAI,CAAC;EAAG,CAAC,CAAC;EACvQ,KAAK,WACH,OAAO,qBAAqB,sBAAsB;GAAE,KAAK,KAAK;GAAK,KAAK,KAAK;GAAK,GAAI,KAAK,UAAU,EAAE,SAAS,KAAK,QAAQ,IAAI,CAAC;GAAI,GAAI,KAAK,YAAY,EAAE,WAAW,KAAK,UAAU,IAAI,CAAC;GAAI,GAAI,KAAK,mBAAmB,EAAE,WAAW,KAAK,iBAAiB,IAAI,CAAC;EAAG,CAAC,CAAC;EAE3Q,SACE,OAAO,qBAAqB;GAAE,KAAK,KAAK;GAAK,KAAK,KAAK;EAAI,CAAC;CAChE;AACF;;;;;AAMA,SAAgB,uBAAuB,MAAuB;CAC5D,OAAO,SAAS,SAAS,SAAS;AACpC"}
@@ -1,8 +1,8 @@
1
- import { Ah as SessionEnvironmentSummary, BD as ThinkingLevel, Cv as EnvironmentSettingsChange, Fb as ContextBreakdown, Fh as StreamEvent, Fv as EnvironmentActionSummary, Fw as McpServerConfig, Jv as EnvironmentRequest, Mh as SessionMeta, Mp as CommandOutputBlock, Nw as JsonValue, Pv as EnvironmentActionResult, Xv as EnvironmentTeardownResult, Zv as EnvironmentVerifyResult, em as InteractionResponse, fD as SessionArtifact, fy as ProviderKey, jh as SessionHeader, oT as SessionTurn, pE as SessionData, yv as EnvironmentDescriptor } from "./index-CidMTcxS.js";
1
+ import { AE as SessionData, CT as SessionTurn, Cv as EnvironmentDescriptor, Dv as EnvironmentSettingsChange, Fh as SessionHeader, Ih as SessionMeta, Ip as CommandOutputBlock, Ph as SessionEnvironmentSummary, Qv as EnvironmentRequest, Qw as McpServerConfig, Rv as EnvironmentActionResult, Xw as JsonValue, ey as EnvironmentTeardownResult, gy as ProviderKey, im as InteractionResponse, kD as SessionArtifact, rO as ThinkingLevel, ty as EnvironmentVerifyResult, zb as ContextBreakdown, zh as StreamEvent, zv as EnvironmentActionSummary } from "./index-DyQyDLX1.js";
2
2
  import { m as ExecResult, v as ListFilesEntry } from "./isolation-CbGNAEhQ.js";
3
- import { Ao as TerminalAdoptResult, Au as ApprovalDecision, Ba as WorkerSummary, Bs as BrowserResponse, Io as TerminalProjectOpenInput, Jo as MachineLinksStatus, Ko as MachineInfo, No as TerminalInfo, Po as TerminalOpenInput, Ra as CreateWorkerParams, Ro as TerminalProjectState, Sa as ContextSegmentsReport, Vo as TerminalSessionState, Wu as TodoItem, Xr as SearchTurnResult, Yo as MachineRegisterParams, Za as SessionLaunchOverrides, Zr as SessionHistoryMatch, _o as SessionPresence, ba as CacheReport, bo as WireApprovalRequest, co as HostSettings, do as PromptAttachment, ho as SendOptions, ja as CompactionReport, jo as TerminalAttachResult, lo as HostSignal, mo as RunningWorkItem, od as SystemMdFile, oo as CommandArgSuggestionSummary, po as QueuedItem, so as CommandSummary, uo as PendingInteraction, va as CacheImpact, wa as WorkspaceListFilesOptions, ya as CacheImpactChange, yo as TodosSnapshot, za as WorkerRow, zo as TerminalProjectStateInput } from "./turn-operations-CIFoOebZ.js";
4
- import "./index-pc71ADi6.js";
5
- import "./types-iFLlZKd0.js";
3
+ import { Ao as TerminalAdoptResult, Au as ApprovalDecision, Ba as WorkerSummary, Bs as BrowserResponse, Io as TerminalProjectOpenInput, Jo as MachineLinksStatus, Ko as MachineInfo, No as TerminalInfo, Po as TerminalOpenInput, Ra as CreateWorkerParams, Ro as TerminalProjectState, Sa as ContextSegmentsReport, Vo as TerminalSessionState, Wu as TodoItem, Xr as SearchTurnResult, Yo as MachineRegisterParams, Za as SessionLaunchOverrides, Zr as SessionHistoryMatch, _o as SessionPresence, ba as CacheReport, bo as WireApprovalRequest, co as HostSettings, do as PromptAttachment, ho as SendOptions, ja as CompactionReport, jo as TerminalAttachResult, lo as HostSignal, mo as RunningWorkItem, od as SystemMdFile, oo as CommandArgSuggestionSummary, po as QueuedItem, so as CommandSummary, uo as PendingInteraction, va as CacheImpact, wa as WorkspaceListFilesOptions, ya as CacheImpactChange, yo as TodosSnapshot, za as WorkerRow, zo as TerminalProjectStateInput } from "./turn-operations-BbGJ-KSt.js";
4
+ import "./index-BkNeiJYI.js";
5
+ import "./types-C0PJmBaO.js";
6
6
  import { c as SyncClaimResult, d as SyncPushResult, p as SyncStatus, s as SyncCategory, u as SyncPayload } from "./types-BWzrS7jZ.js";
7
7
  //#region src/ipc/protocol.d.ts
8
8
  /**
@@ -2135,6 +2135,25 @@ interface HostModelProvider {
2135
2135
  * from hosts that predate decisions. Additive.
2136
2136
  */
2137
2137
  decisionModels?: HostDecisionModel[];
2138
+ /**
2139
+ * Image models of the provider's image endpoint, with whether this host's
2140
+ * credentials can use them. Absent on providers without one, and from
2141
+ * hosts that predate image generation. Additive.
2142
+ */
2143
+ imageModels?: HostImageModel[];
2144
+ }
2145
+ /** One image model a host's provider serves (`HostModelProvider.imageModels`). */
2146
+ interface HostImageModel {
2147
+ id: string;
2148
+ name: string;
2149
+ /** The model takes reference images. */
2150
+ references: boolean;
2151
+ /** The model can return a transparent background. */
2152
+ transparency: boolean;
2153
+ available: boolean;
2154
+ reason?: string;
2155
+ /** The model `generate_image` uses while no image model is picked. Additive. */
2156
+ isDefault?: boolean;
2138
2157
  }
2139
2158
  /** `decisions.test`: how the probe decision went. */
2140
2159
  interface HostDecisionTestResult {
@@ -2524,4 +2543,4 @@ declare class IpcVersionMismatchError extends Error {
2524
2543
  }
2525
2544
  //#endregion
2526
2545
  export { LOAD_EVENTS_PAGE_TURNS as A, SessionResumeResult as B, IPC_PROTOCOL_VERSION as C, IpcParams as D, IpcMethods as E, SESSION_TURNS_PAGE as F, loadEventsPage as G, SignalMeta as H, SIGNAL_SEQ_FIELD as I, loadSessionDocument as K, SequencedSignal as L, ModelFallbackRef as M, REDACTED as N, IpcResult as O, SESSION_TURNS_MAX_PAGE as P, SessionDocumentHead as R, HostRef as S, IpcMethodName as T, hostRefOf as U, SessionRow as V, loadAllEvents as W, HostModelProvider as _, FsDirListing as a, HostOAuthStep as b, HelloResult as c, HostCatalogExtension as d, HostCatalogMcp as f, HostModelInfo as g, HostKind as h, FsDirEntry as i, LoadEventsPaging as j, LOAD_EVENTS_MAX_PAGE_TURNS as k, HostAuthMethod as l, HostCatalogSkill as m, IpcVersionMismatchError as n, FsRoots as o, HostCatalogPlugin as p, CreateSessionParams as r, HelloParams as s, IpcClient as t, HostCatalogError as u, HostOAuthBegin as v, IpcErrorCode as w, HostProviderAuth as x, HostOAuthComplete as y, SessionEventsPage as z };
2527
- //# sourceMappingURL=client-core-imHuBWV3.d.ts.map
2546
+ //# sourceMappingURL=client-core-BdD20sOv.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"client-core-imHuBWV3.d.ts","names":["OrchestrationCreateWorkerParams","OrchestrationWorkerRow","OrchestrationWorkerSummary"],"sources":["../src/ipc/protocol.ts","../src/ipc/transports/client-core.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAwMa;;;;;;cAOA;;;;;;;;;;;;;;;;;;;;;;;;cAgCA;;UAGI;;EAEf;;;UAIe;;EAEf;;EAEA,QAAQ;;;KAIE;EACJ;EAAU,SAAS;;;;EAEnB;EAAW;;;;;;;;;;UAcF;;EAEf;IAAe,QAAQ,KAAK;IAAsB;MAAU;;;;EAE5D;IAAoB;MAAU;;IAAqB;;;EAEnD;IAAgB;MAAU;MAAmB;;IAAmB;;;EAEh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f;;EAEA;;EAEA;;;;;;;EAOA;;;;;;;;;EASA;;;;;;KAOU;;UAGK;;EAEf;;EAEA,MAAM;;EAEN;;;UAIe;;EAEf;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;;;;;EAMA;;EAEA,WAAW;;EAEX;;;;;;;EAOA;;;;;EAKA;;;;;EAKA;;;;;;EAMA;;EAEA;;;;;EAKA;;;;;;EAMA;;;KAIU;;;;UChtDK;;EAEf,OAAO;;;;;EAKP,UAAU,UAAU,eAAe,QAAQ,GAAG,QAAQ,UAAU,OAAO,QAAQ,UAAU;;;;;;;EAOzF,SAAS,UAAU,eAAe,QAAQ,GAAG,QAAQ,UAAU;;EAE/D,WAAW,IAAI;;EAEf;;KAGU,kBAAkB,QAAQ,YAAY,OAAO;;cAG5C,gCAAgC;WAKL,SAAS;;;;;EAAnC,YAAA,iBAA0B,SAAS"}
1
+ {"version":3,"file":"client-core-BdD20sOv.d.ts","names":["OrchestrationCreateWorkerParams","OrchestrationWorkerRow","OrchestrationWorkerSummary"],"sources":["../src/ipc/protocol.ts","../src/ipc/transports/client-core.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAwMa;;;;;;cAOA;;;;;;;;;;;;;;;;;;;;;;;;cAgCA;;UAGI;;EAEf;;;UAIe;;EAEf;;EAEA,QAAQ;;;KAIE;EACJ;EAAU,SAAS;;;;EAEnB;EAAW;;;;;;;;;;UAcF;;EAEf;IAAe,QAAQ,KAAK;IAAsB;MAAU;;;;EAE5D;IAAoB;MAAU;;IAAqB;;;EAEnD;IAAgB;MAAU;MAAmB;;IAAmB;;;EAEhE;IAAmB;MAAU;MAAmB;;IAAmB;;;EAEnE;IACE;MAAU;MAAmB;MAAiB;MAA4B;;IAC1E;MAAU;;;;EAGZ;IAAoB;MAAU;;IAAqB;;;;;;;EAMnD;IAAuB;MAAU;;IAA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;EAEN;;;UAIe;;EAEf;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;;;;;EAMA;;EAEA,WAAW;;EAEX;;;;;;;EAOA;;;;;EAKA;;;;;EAKA;;;;;;EAMA;;EAEA;;;;;EAKA;;;;;;EAMA;;;KAIU;;;;UCpuDK;;EAEf,OAAO;;;;;EAKP,UAAU,UAAU,eAAe,QAAQ,GAAG,QAAQ,UAAU,OAAO,QAAQ,UAAU;;;;;;;EAOzF,SAAS,UAAU,eAAe,QAAQ,GAAG,QAAQ,UAAU;;EAE/D,WAAW,IAAI;;EAEf;;KAGU,kBAAkB,QAAQ,YAAY,OAAO;;cAG5C,gCAAgC;WAKL,SAAS;;;;;EAAnC,YAAA,iBAA0B,SAAS"}
@@ -1,6 +1,6 @@
1
- import { lo as HostSignal } from "./turn-operations-CIFoOebZ.js";
1
+ import { lo as HostSignal } from "./turn-operations-BbGJ-KSt.js";
2
2
  import { t as HostConnectionStatus } from "./connection-CvoXPgZw.js";
3
- import { t as IpcClient } from "./client-core-imHuBWV3.js";
3
+ import { t as IpcClient } from "./client-core-BdD20sOv.js";
4
4
  //#region src/ipc/hosts/connection-loop.d.ts
5
5
  /** How a failed connect is handled: retried with backoff, re-checked slowly (`protocol`), or reported and left alone. */
6
6
  type HostFailureKind = 'auth' | 'identity' | 'protocol' | 'retry';
@@ -67,4 +67,4 @@ interface HostConnectionLoop {
67
67
  declare function keepHostConnected(options: HostConnectionLoopOptions): HostConnectionLoop;
68
68
  //#endregion
69
69
  export { keepHostConnected as a, HostFailureKind as i, HostConnectionLoopOptions as n, HostConnectionPatch as r, HostConnectionLoop as t };
70
- //# sourceMappingURL=connection-loop-CdHt3iQi.d.ts.map
70
+ //# sourceMappingURL=connection-loop-DTk82YVl.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"connection-loop-CdHt3iQi.d.ts","names":[],"sources":["../src/ipc/hosts/connection-loop.ts"],"mappings":";;;;;KAoBY;;UAaK;;EAEf,SAAS;;EAET,SAAS;;EAET;;EAEA;;;UAIe;;EAEf,UAAU;IAAW,QAAQ;IAAa;QAA0B,QAAQ;;EAE5E,SAAS,OAAO;;;;;;EAMhB,YAAY,iBAAiB;;;;;EAK7B;;EAEA,eAAe,QAAQ;;EAEvB,YAAY,QAAQ;;EAEpB;;;;;EAKA;;;;;EAKA;;;UAIe;;EAEf;;EAEA;;;;;;;iBAYc,kBAAkB,SAAS,4BAA4B"}
1
+ {"version":3,"file":"connection-loop-DTk82YVl.d.ts","names":[],"sources":["../src/ipc/hosts/connection-loop.ts"],"mappings":";;;;;KAoBY;;UAaK;;EAEf,SAAS;;EAET,SAAS;;EAET;;EAEA;;;UAIe;;EAEf,UAAU;IAAW,QAAQ;IAAa;QAA0B,QAAQ;;EAE5E,SAAS,OAAO;;;;;;EAMhB,YAAY,iBAAiB;;;;;EAK7B;;EAEA,eAAe,QAAQ;;EAEvB,YAAY,QAAQ;;EAEpB;;;;;EAKA;;;;;EAKA;;;UAIe;;EAEf;;EAEA;;;;;;;iBAYc,kBAAkB,SAAS,4BAA4B"}
@@ -1,4 +1,4 @@
1
- import { Fm as Logger } from "../index-CidMTcxS.js";
1
+ import { zm as Logger } from "../index-DyQyDLX1.js";
2
2
  import { m as ExecResult } from "../isolation-CbGNAEhQ.js";
3
3
  import { t as SandboxProvider } from "../sandbox--bc6zacQ.js";
4
4
  import { Buffer } from "node:buffer";
@@ -1,4 +1,4 @@
1
- import { Fm as Logger } from "../index-CidMTcxS.js";
1
+ import { zm as Logger } from "../index-DyQyDLX1.js";
2
2
  import { t as SandboxProvider } from "../sandbox--bc6zacQ.js";
3
3
  //#region src/contexts/e2b-sdk.d.ts
4
4
  /**
@@ -12,14 +12,14 @@ import { cerebras } from "./providers/cerebras.js";
12
12
  import { t as generatePkce } from "./pkce-CNABhw6J.js";
13
13
  import { n as createCursorOAuthProvider } from "./cursor-ntwMDfyD.js";
14
14
  import { n as zai, r as mistral } from "./providers-CYuhNshA.js";
15
- import { GOOGLE_DEFAULT_MODEL, GOOGLE_EXTRA_MODELS, google, googleVertex } from "./providers/google.js";
15
+ import { a as google, f as GOOGLE_IMAGE_MODELS, n as GOOGLE_EXTRA_MODELS, s as googleVertex, t as GOOGLE_DEFAULT_MODEL } from "./google-O6pRnddf.js";
16
+ import { a as OPENAI_DECISION_MODELS, o as OPENAI_IMAGE_MODELS, r as openai } from "./openai-Rh6u5NXF.js";
17
+ import { a as openrouterImageModels, i as OPENROUTER_DECISION_MODELS, r as openrouter, t as OPENROUTER_DEFAULT_MODEL } from "./openrouter-Dg0yaI-o.js";
18
+ import { n as XAI_IMAGE_MODELS, t as xai } from "./xai-CStTwCV2.js";
16
19
  import { local } from "./providers/local.js";
17
20
  import { NEURALWATT_DEFAULT_MODEL, neuralwatt } from "./providers/neuralwatt.js";
18
- import { a as OPENAI_DECISION_MODELS, r as openai } from "./openai-dTmPxM6T.js";
19
- import { i as OPENROUTER_DECISION_MODELS, r as openrouter, t as OPENROUTER_DEFAULT_MODEL } from "./openrouter-CtZbQDa0.js";
20
21
  import { i as listensForCallback, o as startCallbackServer, r as honorsRemoteCallback, t as awaitAuthorizationCode } from "./server-uWgMffBf.js";
21
22
  import { n as createXaiOAuthProvider } from "./xai-6tBTk6CU.js";
22
- import { xai } from "./providers/xai.js";
23
23
  import { rt as modelDisplayName } from "./spaces-CyjMh5Zf.js";
24
24
  import { n as renderDefaultCallbackPage } from "./render-gPS08Uiz.js";
25
25
  import { Buffer } from "node:buffer";
@@ -714,6 +714,7 @@ const openaiDescriptor = {
714
714
  apiKeyPlaceholder: "sk-… (platform) or eyJ… (Codex)",
715
715
  oauthProvider: openaiCodexOAuthProvider,
716
716
  decisionModels: OPENAI_DECISION_MODELS,
717
+ imageModels: OPENAI_IMAGE_MODELS,
717
718
  modelAliases: { "gpt-5.6": "gpt-5.6-sol" },
718
719
  optionsFor: (id) => OPENAI_PRIORITY_TIER_MODELS.has(id) ? [{
719
720
  id: "fast",
@@ -737,6 +738,7 @@ const openrouterDescriptor = {
737
738
  envKey: "OPENROUTER_API_KEY",
738
739
  apiKeyPlaceholder: "sk-or-…",
739
740
  decisionModels: OPENROUTER_DECISION_MODELS,
741
+ imageModels: openrouterImageModels(),
740
742
  modelAliases: {
741
743
  "anthropic/claude-sonnet-4-6": "anthropic/claude-sonnet-4.6",
742
744
  "anthropic/claude-fable-5-1": "anthropic/claude-fable-5.1"
@@ -771,7 +773,8 @@ const xaiDescriptor = {
771
773
  oauthProvider: xaiOAuthProvider,
772
774
  oauthHint: "SuperGrok or X Premium+ plan",
773
775
  credentialFileKey: "xai-oauth",
774
- piProviderId: "xai"
776
+ piProviderId: "xai",
777
+ imageModels: XAI_IMAGE_MODELS
775
778
  };
776
779
  /** Picker rows for the Google models pi-ai hasn't bundled yet (`GOOGLE_EXTRA_MODELS`). */
777
780
  function googleExtraModels(route) {
@@ -801,7 +804,8 @@ const googleDescriptor = {
801
804
  envKey: "GEMINI_API_KEY",
802
805
  apiKeyPlaceholder: "AIza…",
803
806
  piProviderId: "google",
804
- extraModels: googleExtraModels("google")
807
+ extraModels: googleExtraModels("google"),
808
+ imageModels: GOOGLE_IMAGE_MODELS
805
809
  };
806
810
  /**
807
811
  * Google Vertex AI, with Google Cloud credentials for the configured project:
@@ -2267,4 +2271,4 @@ function providerFactoryOptions(dataDir, descriptor, account) {
2267
2271
  //#endregion
2268
2272
  export { modelSupportsReasoning as A, defaultModelOf as C, localDescriptor as D, getModelInfo as E, restoreModelOptions as F, openaiDescriptor as M, openrouterDescriptor as N, modelLabel as O, piIdOf as P, credKeyOf as S, getContextWindow as T, writeCredentialEntry as _, readCredentialEntry as a, anthropicDescriptor as b, readProviderCredentialPair as c, removeStoredCredential as d, setCredentialLabel as f, storedCredentialsOf as g, storedCredentialById as h, providerFactoryOptions as i, modelsForDescriptor as j, modelOptionsFor as k, readProviderCredentials as l, setProviderCredential as m, credentialsPath as n, readCredentials as o, setPreferredCredential as p, ensureCredentialIds as r, readProviderCredential as s, applyApiKeyEnv as t, removeProviderCredential as u, writeCredentials as v, enabledModelOptions as w, cerebrasDescriptor as x, BUILTIN_PROVIDERS as y };
2269
2273
 
2270
- //# sourceMappingURL=credentials-Dti61yoi.js.map
2274
+ //# sourceMappingURL=credentials-B9DfBJP9.js.map