@psnext/slingcli 2.5.20260629-1 → 2.5.20260705-1

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 (380) hide show
  1. package/node_modules/@aws/lambda-invoke-store/README.md +25 -1
  2. package/node_modules/@aws/lambda-invoke-store/dist-cjs/invoke-store.js +12 -0
  3. package/node_modules/@aws/lambda-invoke-store/dist-es/invoke-store.js +12 -0
  4. package/node_modules/@aws/lambda-invoke-store/dist-types/invoke-store.d.ts +6 -0
  5. package/node_modules/@aws/lambda-invoke-store/package.json +1 -1
  6. package/node_modules/@aws-sdk/core/account-id-endpoint.d.ts +1 -3
  7. package/node_modules/@aws-sdk/core/client.d.ts +1 -3
  8. package/node_modules/@aws-sdk/core/httpAuthSchemes.d.ts +1 -3
  9. package/node_modules/@aws-sdk/core/package.json +10 -17
  10. package/node_modules/@aws-sdk/core/protocols.d.ts +1 -3
  11. package/node_modules/@aws-sdk/core/util.d.ts +1 -3
  12. package/node_modules/@aws-sdk/credential-provider-env/package.json +5 -5
  13. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/index.js +172 -1
  14. package/node_modules/@aws-sdk/credential-provider-http/node_modules/@smithy/node-http-handler/dist-cjs/index.js +3 -51
  15. package/node_modules/@aws-sdk/credential-provider-http/node_modules/@smithy/node-http-handler/dist-es/index.js +3 -3
  16. package/node_modules/@aws-sdk/credential-provider-http/node_modules/@smithy/node-http-handler/dist-types/index.d.ts +3 -3
  17. package/node_modules/@aws-sdk/credential-provider-http/node_modules/@smithy/node-http-handler/package.json +4 -4
  18. package/node_modules/@aws-sdk/credential-provider-http/package.json +8 -10
  19. package/node_modules/@aws-sdk/credential-provider-ini/package.json +13 -13
  20. package/node_modules/@aws-sdk/credential-provider-login/package.json +6 -6
  21. package/node_modules/@aws-sdk/credential-provider-node/package.json +11 -11
  22. package/node_modules/@aws-sdk/credential-provider-process/package.json +5 -5
  23. package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/package.json +6 -6
  24. package/node_modules/@aws-sdk/credential-provider-sso/package.json +7 -7
  25. package/node_modules/@aws-sdk/credential-provider-web-identity/dist-cjs/index.js +58 -3
  26. package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +7 -8
  27. package/node_modules/@aws-sdk/eventstream-handler-node/package.json +4 -4
  28. package/node_modules/@aws-sdk/middleware-eventstream/package.json +4 -4
  29. package/node_modules/@aws-sdk/middleware-websocket/package.json +7 -7
  30. package/node_modules/@aws-sdk/nested-clients/cognito-identity.d.ts +1 -3
  31. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/cognito-identity/index.js +13 -25
  32. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/signin/index.js +13 -17
  33. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso/index.js +12 -15
  34. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sso-oidc/index.js +12 -15
  35. package/node_modules/@aws-sdk/nested-clients/dist-cjs/submodules/sts/index.js +13 -25
  36. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/cognito-identity/commandBuilder.js +6 -0
  37. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/cognito-identity/commands/GetCredentialsForIdentityCommand.js +2 -14
  38. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/cognito-identity/commands/GetIdCommand.js +2 -14
  39. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/cognito-identity/index.js +1 -0
  40. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/cognito-identity/runtimeConfig.browser.js +0 -2
  41. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/cognito-identity/runtimeConfig.js +1 -2
  42. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/cognito-identity/runtimeConfig.native.js +0 -2
  43. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/cognito-identity/runtimeConfig.shared.js +2 -0
  44. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/signin/commandBuilder.js +8 -0
  45. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/signin/commands/CreateOAuth2TokenCommand.js +2 -17
  46. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/signin/index.js +1 -0
  47. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/signin/runtimeConfig.browser.js +0 -2
  48. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/signin/runtimeConfig.js +1 -2
  49. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/signin/runtimeConfig.native.js +0 -2
  50. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/signin/runtimeConfig.shared.js +2 -0
  51. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso/commandBuilder.js +6 -0
  52. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso/commands/GetRoleCredentialsCommand.js +2 -14
  53. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso/index.js +1 -0
  54. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso/runtimeConfig.browser.js +0 -2
  55. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso/runtimeConfig.js +1 -2
  56. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso/runtimeConfig.native.js +0 -2
  57. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso/runtimeConfig.shared.js +2 -0
  58. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso-oidc/commandBuilder.js +6 -0
  59. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso-oidc/commands/CreateTokenCommand.js +2 -14
  60. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso-oidc/index.js +1 -0
  61. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso-oidc/runtimeConfig.browser.js +0 -2
  62. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso-oidc/runtimeConfig.js +1 -2
  63. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso-oidc/runtimeConfig.native.js +0 -2
  64. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sso-oidc/runtimeConfig.shared.js +2 -0
  65. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/commandBuilder.js +6 -0
  66. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/commands/AssumeRoleCommand.js +2 -14
  67. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/commands/AssumeRoleWithWebIdentityCommand.js +2 -14
  68. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/index.js +1 -0
  69. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/runtimeConfig.browser.js +0 -2
  70. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/runtimeConfig.js +1 -2
  71. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/runtimeConfig.native.js +0 -2
  72. package/node_modules/@aws-sdk/nested-clients/dist-es/submodules/sts/runtimeConfig.shared.js +2 -0
  73. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/commandBuilder.d.ts +18 -0
  74. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/commands/GetCredentialsForIdentityCommand.d.ts +3 -8
  75. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/commands/GetIdCommand.d.ts +3 -8
  76. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/index.d.ts +1 -0
  77. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/runtimeConfig.browser.d.ts +2 -2
  78. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/runtimeConfig.d.ts +2 -2
  79. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/runtimeConfig.native.d.ts +2 -2
  80. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/cognito-identity/runtimeConfig.shared.d.ts +1 -0
  81. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/commandBuilder.d.ts +18 -0
  82. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/commands/CreateOAuth2TokenCommand.d.ts +3 -8
  83. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/index.d.ts +1 -0
  84. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/runtimeConfig.browser.d.ts +2 -2
  85. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/runtimeConfig.d.ts +2 -2
  86. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/runtimeConfig.native.d.ts +2 -2
  87. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/signin/runtimeConfig.shared.d.ts +1 -0
  88. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso/commandBuilder.d.ts +18 -0
  89. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso/commands/GetRoleCredentialsCommand.d.ts +3 -8
  90. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso/index.d.ts +1 -0
  91. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso/runtimeConfig.browser.d.ts +2 -2
  92. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso/runtimeConfig.d.ts +2 -2
  93. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso/runtimeConfig.native.d.ts +2 -2
  94. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso/runtimeConfig.shared.d.ts +1 -0
  95. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso-oidc/commandBuilder.d.ts +18 -0
  96. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso-oidc/commands/CreateTokenCommand.d.ts +3 -8
  97. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso-oidc/index.d.ts +1 -0
  98. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso-oidc/runtimeConfig.browser.d.ts +2 -2
  99. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso-oidc/runtimeConfig.d.ts +2 -2
  100. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso-oidc/runtimeConfig.native.d.ts +2 -2
  101. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sso-oidc/runtimeConfig.shared.d.ts +1 -0
  102. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/commandBuilder.d.ts +18 -0
  103. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/commands/AssumeRoleCommand.d.ts +3 -8
  104. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/commands/AssumeRoleWithWebIdentityCommand.d.ts +3 -8
  105. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/index.d.ts +1 -0
  106. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/runtimeConfig.browser.d.ts +2 -2
  107. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/runtimeConfig.d.ts +2 -2
  108. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/runtimeConfig.native.d.ts +2 -2
  109. package/node_modules/@aws-sdk/nested-clients/dist-types/submodules/sts/runtimeConfig.shared.d.ts +1 -0
  110. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/cognito-identity/commandBuilder.d.ts +46 -0
  111. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/cognito-identity/commands/GetCredentialsForIdentityCommand.d.ts +7 -16
  112. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/cognito-identity/commands/GetIdCommand.d.ts +7 -16
  113. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/cognito-identity/index.d.ts +1 -0
  114. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/cognito-identity/runtimeConfig.browser.d.ts +8 -2
  115. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/cognito-identity/runtimeConfig.d.ts +8 -2
  116. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/cognito-identity/runtimeConfig.native.d.ts +8 -2
  117. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/cognito-identity/runtimeConfig.shared.d.ts +1 -0
  118. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/signin/commandBuilder.d.ts +42 -0
  119. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/signin/commands/CreateOAuth2TokenCommand.d.ts +3 -8
  120. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/signin/index.d.ts +1 -0
  121. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/signin/runtimeConfig.browser.d.ts +8 -2
  122. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/signin/runtimeConfig.d.ts +8 -2
  123. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/signin/runtimeConfig.native.d.ts +8 -2
  124. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/signin/runtimeConfig.shared.d.ts +1 -0
  125. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso/commandBuilder.d.ts +42 -0
  126. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso/commands/GetRoleCredentialsCommand.d.ts +3 -8
  127. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso/index.d.ts +1 -0
  128. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso/runtimeConfig.browser.d.ts +8 -2
  129. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso/runtimeConfig.d.ts +8 -2
  130. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso/runtimeConfig.native.d.ts +8 -2
  131. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso/runtimeConfig.shared.d.ts +1 -0
  132. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso-oidc/commandBuilder.d.ts +42 -0
  133. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso-oidc/commands/CreateTokenCommand.d.ts +3 -8
  134. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso-oidc/index.d.ts +1 -0
  135. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso-oidc/runtimeConfig.browser.d.ts +8 -2
  136. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso-oidc/runtimeConfig.d.ts +8 -2
  137. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso-oidc/runtimeConfig.native.d.ts +8 -2
  138. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sso-oidc/runtimeConfig.shared.d.ts +1 -0
  139. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sts/commandBuilder.d.ts +46 -0
  140. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sts/commands/AssumeRoleCommand.d.ts +7 -16
  141. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sts/commands/AssumeRoleWithWebIdentityCommand.d.ts +7 -16
  142. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sts/index.d.ts +1 -0
  143. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sts/runtimeConfig.browser.d.ts +8 -2
  144. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sts/runtimeConfig.d.ts +8 -2
  145. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sts/runtimeConfig.native.d.ts +8 -2
  146. package/node_modules/@aws-sdk/nested-clients/dist-types/ts3.4/submodules/sts/runtimeConfig.shared.d.ts +1 -0
  147. package/node_modules/@aws-sdk/nested-clients/node_modules/@smithy/node-http-handler/dist-cjs/index.js +3 -51
  148. package/node_modules/@aws-sdk/nested-clients/node_modules/@smithy/node-http-handler/dist-es/index.js +3 -3
  149. package/node_modules/@aws-sdk/nested-clients/node_modules/@smithy/node-http-handler/dist-types/index.d.ts +3 -3
  150. package/node_modules/@aws-sdk/nested-clients/node_modules/@smithy/node-http-handler/package.json +4 -4
  151. package/node_modules/@aws-sdk/nested-clients/package.json +8 -10
  152. package/node_modules/@aws-sdk/nested-clients/signin.d.ts +1 -3
  153. package/node_modules/@aws-sdk/nested-clients/sso-oidc.d.ts +1 -3
  154. package/node_modules/@aws-sdk/nested-clients/sso.d.ts +1 -3
  155. package/node_modules/@aws-sdk/nested-clients/sts.d.ts +1 -3
  156. package/node_modules/@aws-sdk/signature-v4-multi-region/package.json +4 -4
  157. package/node_modules/@aws-sdk/types/package.json +2 -2
  158. package/node_modules/@aws-sdk/xml-builder/dist-cjs/index.js +236 -3
  159. package/node_modules/@aws-sdk/xml-builder/package.json +3 -4
  160. package/node_modules/@earendil-works/pi-agent-core/dist/agent.js +10 -1
  161. package/node_modules/@earendil-works/pi-agent-core/dist/harness/compaction/compaction.js +4 -6
  162. package/node_modules/@earendil-works/pi-agent-core/dist/harness/env/nodejs.js +20 -2
  163. package/node_modules/@earendil-works/pi-agent-core/package.json +2 -2
  164. package/node_modules/@earendil-works/pi-ai/dist/api/azure-openai-responses.js +2 -14
  165. package/node_modules/@earendil-works/pi-ai/dist/api/bedrock-converse-stream.js +16 -5
  166. package/node_modules/@earendil-works/pi-ai/dist/api/google-generative-ai.js +2 -1
  167. package/node_modules/@earendil-works/pi-ai/dist/api/google-vertex.js +2 -1
  168. package/node_modules/@earendil-works/pi-ai/dist/api/openai-codex-responses.js +54 -19
  169. package/node_modules/@earendil-works/pi-ai/dist/api/openai-completions.js +8 -3
  170. package/node_modules/@earendil-works/pi-ai/dist/api/openai-responses.js +2 -14
  171. package/node_modules/@earendil-works/pi-ai/dist/api/openrouter-images.js +2 -1
  172. package/node_modules/@earendil-works/pi-ai/dist/image-models.generated.js +15 -45
  173. package/node_modules/@earendil-works/pi-ai/dist/providers/amazon-bedrock.models.js +124 -4
  174. package/node_modules/@earendil-works/pi-ai/dist/providers/anthropic.models.js +18 -0
  175. package/node_modules/@earendil-works/pi-ai/dist/providers/cerebras.models.js +18 -0
  176. package/node_modules/@earendil-works/pi-ai/dist/providers/cloudflare-ai-gateway.models.js +18 -0
  177. package/node_modules/@earendil-works/pi-ai/dist/providers/fireworks.models.js +4 -3
  178. package/node_modules/@earendil-works/pi-ai/dist/providers/github-copilot.models.js +57 -0
  179. package/node_modules/@earendil-works/pi-ai/dist/providers/groq.models.js +1 -1
  180. package/node_modules/@earendil-works/pi-ai/dist/providers/mistral.models.js +4 -4
  181. package/node_modules/@earendil-works/pi-ai/dist/providers/nvidia.models.js +4 -4
  182. package/node_modules/@earendil-works/pi-ai/dist/providers/opencode-go.models.js +5 -5
  183. package/node_modules/@earendil-works/pi-ai/dist/providers/opencode.models.js +75 -2
  184. package/node_modules/@earendil-works/pi-ai/dist/providers/openrouter.models.js +105 -88
  185. package/node_modules/@earendil-works/pi-ai/dist/providers/together.models.js +2 -2
  186. package/node_modules/@earendil-works/pi-ai/dist/providers/vercel-ai-gateway.models.js +41 -4
  187. package/node_modules/@earendil-works/pi-ai/dist/providers/xiaomi-token-plan-ams.models.js +12 -12
  188. package/node_modules/@earendil-works/pi-ai/dist/providers/xiaomi-token-plan-cn.models.js +12 -12
  189. package/node_modules/@earendil-works/pi-ai/dist/providers/xiaomi-token-plan-sgp.models.js +12 -12
  190. package/node_modules/@earendil-works/pi-ai/dist/providers/xiaomi.models.js +15 -15
  191. package/node_modules/@earendil-works/pi-ai/dist/utils/error-body.js +109 -0
  192. package/node_modules/@earendil-works/pi-ai/dist/utils/oauth/device-code.js +15 -2
  193. package/node_modules/@earendil-works/pi-ai/dist/utils/oauth/github-copilot.js +3 -2
  194. package/node_modules/@earendil-works/pi-ai/dist/utils/overflow.js +3 -0
  195. package/node_modules/@earendil-works/pi-ai/dist/utils/retry.js +1 -0
  196. package/node_modules/@earendil-works/pi-ai/package.json +1 -1
  197. package/node_modules/@earendil-works/pi-coding-agent/dist/core/agent-session.js +35 -4
  198. package/node_modules/@earendil-works/pi-coding-agent/dist/core/auth-storage.js +13 -5
  199. package/node_modules/@earendil-works/pi-coding-agent/dist/core/compaction/compaction.js +5 -8
  200. package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/loader.js +6 -0
  201. package/node_modules/@earendil-works/pi-coding-agent/dist/core/extensions/runner.js +33 -1
  202. package/node_modules/@earendil-works/pi-coding-agent/dist/core/http-dispatcher.js +28 -1
  203. package/node_modules/@earendil-works/pi-coding-agent/dist/core/model-resolver.js +14 -17
  204. package/node_modules/@earendil-works/pi-coding-agent/dist/core/project-trust.js +1 -1
  205. package/node_modules/@earendil-works/pi-coding-agent/dist/core/provider-attribution.js +0 -10
  206. package/node_modules/@earendil-works/pi-coding-agent/dist/core/session-manager.js +87 -68
  207. package/node_modules/@earendil-works/pi-coding-agent/dist/core/settings-manager.js +8 -0
  208. package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/bash.js +20 -5
  209. package/node_modules/@earendil-works/pi-coding-agent/dist/core/tools/edit.js +2 -2
  210. package/node_modules/@earendil-works/pi-coding-agent/dist/index.js +2 -1
  211. package/node_modules/@earendil-works/pi-coding-agent/dist/main.js +1 -1
  212. package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/assistant-message.js +15 -7
  213. package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/custom-entry.js +52 -0
  214. package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/settings-selector.js +13 -1
  215. package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/status-indicator.js +60 -0
  216. package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/components/user-message.js +18 -5
  217. package/node_modules/@earendil-works/pi-coding-agent/dist/modes/interactive/interactive-mode.js +143 -130
  218. package/node_modules/@earendil-works/pi-coding-agent/dist/package-manager-cli.js +7 -0
  219. package/node_modules/@earendil-works/pi-coding-agent/npm-shrinkwrap.json +12 -12
  220. package/node_modules/@earendil-works/pi-coding-agent/package.json +4 -4
  221. package/node_modules/@earendil-works/pi-orchestrator/package.json +2 -2
  222. package/node_modules/@earendil-works/pi-tui/package.json +1 -1
  223. package/node_modules/@smithy/core/dist-cjs/submodules/checksum/index.browser.js +358 -145
  224. package/node_modules/@smithy/core/dist-cjs/submodules/checksum/index.js +462 -142
  225. package/node_modules/@smithy/core/dist-cjs/submodules/checksum/index.native.js +358 -145
  226. package/node_modules/@smithy/core/dist-cjs/submodules/client/index.js +18 -0
  227. package/node_modules/@smithy/core/dist-cjs/submodules/config/index.js +108 -63
  228. package/node_modules/@smithy/core/dist-cjs/submodules/event-streams/index.browser.js +11 -8
  229. package/node_modules/@smithy/core/dist-cjs/submodules/event-streams/index.js +11 -8
  230. package/node_modules/@smithy/core/dist-cjs/submodules/protocols/index.js +5 -2
  231. package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.browser.js +30 -36
  232. package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.js +85 -137
  233. package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.native.js +30 -36
  234. package/node_modules/@smithy/core/dist-es/submodules/checksum/crc32/Crc32Js.js +30 -0
  235. package/node_modules/@smithy/core/dist-es/submodules/checksum/crc32/Crc32Node.js +24 -0
  236. package/node_modules/@smithy/core/dist-es/submodules/checksum/index.browser.js +7 -1
  237. package/node_modules/@smithy/core/dist-es/submodules/checksum/index.js +7 -1
  238. package/node_modules/@smithy/core/dist-es/submodules/checksum/index.native.js +7 -1
  239. package/node_modules/@smithy/core/dist-es/submodules/checksum/md5/Md5Js.js +92 -0
  240. package/node_modules/@smithy/core/dist-es/submodules/checksum/md5/Md5Node.js +29 -0
  241. package/node_modules/@smithy/core/dist-es/submodules/checksum/sha256/Sha256Js.js +179 -0
  242. package/node_modules/@smithy/core/dist-es/submodules/checksum/sha256/Sha256Node.js +59 -0
  243. package/node_modules/@smithy/core/dist-es/submodules/checksum/sha256/Sha256WebCrypto.js +71 -0
  244. package/node_modules/@smithy/core/dist-es/submodules/client/index.js +1 -0
  245. package/node_modules/@smithy/core/dist-es/submodules/client/smithy-client/client-command-builder.js +17 -0
  246. package/node_modules/@smithy/core/dist-es/submodules/config/config-resolver/regionConfig/config.js +6 -1
  247. package/node_modules/@smithy/core/dist-es/submodules/config/config-resolver/regionConfig/getInstanceMetadataRegion.js +92 -0
  248. package/node_modules/@smithy/core/dist-es/submodules/config/defaults-mode/constants.js +3 -0
  249. package/node_modules/@smithy/core/dist-es/submodules/config/defaults-mode/resolveDefaultsModeConfig.js +3 -56
  250. package/node_modules/@smithy/core/dist-es/submodules/event-streams/eventstream-codec/EventStreamCodec.js +5 -3
  251. package/node_modules/@smithy/core/dist-es/submodules/event-streams/eventstream-codec/splitMessage.js +7 -6
  252. package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpProtocol.js +4 -1
  253. package/node_modules/@smithy/core/dist-es/submodules/serde/concatBytes.js +15 -0
  254. package/node_modules/@smithy/core/dist-es/submodules/serde/index.browser.js +2 -0
  255. package/node_modules/@smithy/core/dist-es/submodules/serde/index.js +2 -0
  256. package/node_modules/@smithy/core/dist-es/submodules/serde/index.native.js +2 -0
  257. package/node_modules/@smithy/core/dist-es/submodules/serde/util-stream/checksum/ChecksumStream.js +35 -27
  258. package/node_modules/@smithy/core/dist-es/submodules/serde/util-stream/headStream.js +2 -1
  259. package/node_modules/@smithy/core/dist-es/submodules/serde/util-stream/stream-collector.browser.js +12 -38
  260. package/node_modules/@smithy/core/dist-es/submodules/serde/util-stream/stream-collector.js +18 -33
  261. package/node_modules/@smithy/core/dist-es/submodules/serde/util-utf8/toUint8Array.browser.js +3 -0
  262. package/node_modules/@smithy/core/dist-es/submodules/serde/util-utf8/toUint8Array.js +3 -0
  263. package/node_modules/@smithy/core/dist-types/submodules/checksum/crc32/Crc32Js.d.ts +18 -0
  264. package/node_modules/@smithy/core/dist-types/submodules/checksum/crc32/Crc32Node.d.ts +18 -0
  265. package/node_modules/@smithy/core/dist-types/submodules/checksum/index.browser.d.ts +7 -1
  266. package/node_modules/@smithy/core/dist-types/submodules/checksum/index.d.ts +7 -1
  267. package/node_modules/@smithy/core/dist-types/submodules/checksum/index.native.d.ts +7 -1
  268. package/node_modules/@smithy/core/dist-types/submodules/checksum/md5/Md5Js.d.ts +19 -0
  269. package/node_modules/@smithy/core/dist-types/submodules/checksum/md5/Md5Node.d.ts +17 -0
  270. package/node_modules/@smithy/core/dist-types/submodules/checksum/sha256/Sha256Js.d.ts +28 -0
  271. package/node_modules/@smithy/core/dist-types/submodules/checksum/sha256/Sha256Node.d.ts +13 -0
  272. package/node_modules/@smithy/core/dist-types/submodules/checksum/sha256/Sha256WebCrypto.d.ts +22 -0
  273. package/node_modules/@smithy/core/dist-types/submodules/client/index.d.ts +1 -0
  274. package/node_modules/@smithy/core/dist-types/submodules/client/smithy-client/client-command-builder.d.ts +22 -0
  275. package/node_modules/@smithy/core/dist-types/submodules/client/smithy-client/command.d.ts +5 -6
  276. package/node_modules/@smithy/core/dist-types/submodules/config/config-resolver/regionConfig/getInstanceMetadataRegion.d.ts +7 -0
  277. package/node_modules/@smithy/core/dist-types/submodules/config/defaults-mode/constants.d.ts +12 -0
  278. package/node_modules/@smithy/core/dist-types/submodules/endpoints/index.browser.d.ts +4 -5
  279. package/node_modules/@smithy/core/dist-types/submodules/endpoints/index.d.ts +4 -5
  280. package/node_modules/@smithy/core/dist-types/submodules/endpoints/middleware-endpoint/adaptors/getEndpointFromInstructions.d.ts +3 -4
  281. package/node_modules/@smithy/core/dist-types/submodules/endpoints/middleware-endpoint/endpointMiddleware.d.ts +1 -2
  282. package/node_modules/@smithy/core/dist-types/submodules/endpoints/middleware-endpoint/getEndpointPlugin.d.ts +1 -2
  283. package/node_modules/@smithy/core/dist-types/submodules/serde/concatBytes.d.ts +6 -0
  284. package/node_modules/@smithy/core/dist-types/submodules/serde/index.browser.d.ts +2 -0
  285. package/node_modules/@smithy/core/dist-types/submodules/serde/index.d.ts +2 -0
  286. package/node_modules/@smithy/core/dist-types/submodules/serde/index.native.d.ts +2 -0
  287. package/node_modules/@smithy/core/dist-types/submodules/serde/util-stream/checksum/ChecksumStream.d.ts +29 -12
  288. package/node_modules/@smithy/core/dist-types/submodules/serde/util-stream/stream-collector.browser.d.ts +8 -2
  289. package/node_modules/@smithy/core/dist-types/submodules/serde/util-stream/stream-collector.d.ts +4 -1
  290. package/node_modules/@smithy/core/package.json +5 -5
  291. package/node_modules/@smithy/credential-provider-imds/package.json +3 -3
  292. package/node_modules/@smithy/fetch-http-handler/dist-cjs/index.js +2 -55
  293. package/node_modules/@smithy/fetch-http-handler/dist-es/index.js +2 -2
  294. package/node_modules/@smithy/fetch-http-handler/dist-types/index.d.ts +2 -2
  295. package/node_modules/@smithy/fetch-http-handler/package.json +4 -4
  296. package/node_modules/@smithy/signature-v4/package.json +3 -4
  297. package/node_modules/@smithy/types/dist-types/index.d.ts +1 -0
  298. package/node_modules/@smithy/types/package.json +1 -1
  299. package/node_modules/@types/node/README.md +1 -1
  300. package/node_modules/@types/node/buffer.d.ts +64 -25
  301. package/node_modules/@types/node/crypto.d.ts +18 -5
  302. package/node_modules/@types/node/diagnostics_channel.d.ts +237 -3
  303. package/node_modules/@types/node/dns.d.ts +1 -1
  304. package/node_modules/@types/node/ffi.d.ts +486 -0
  305. package/node_modules/@types/node/fs/promises.d.ts +3 -0
  306. package/node_modules/@types/node/fs.d.ts +21 -6
  307. package/node_modules/@types/node/http.d.ts +25 -0
  308. package/node_modules/@types/node/index.d.ts +1 -0
  309. package/node_modules/@types/node/package.json +2 -2
  310. package/node_modules/@types/node/process.d.ts +14 -1
  311. package/node_modules/@types/node/quic.d.ts +92 -11
  312. package/node_modules/@types/node/sqlite.d.ts +55 -0
  313. package/node_modules/@types/node/stream/iter.d.ts +150 -0
  314. package/node_modules/@types/node/stream.d.ts +32 -0
  315. package/node_modules/@types/node/test.d.ts +112 -2
  316. package/node_modules/@types/node/ts5.6/index.d.ts +1 -0
  317. package/node_modules/@types/node/ts5.7/index.d.ts +1 -0
  318. package/node_modules/@types/node/util.d.ts +19 -2
  319. package/node_modules/@types/node/v8.d.ts +84 -2
  320. package/node_modules/@types/node/worker_threads.d.ts +8 -7
  321. package/node_modules/protobufjs/dist/light/protobuf.js +2 -2
  322. package/node_modules/protobufjs/dist/light/protobuf.min.js +2 -2
  323. package/node_modules/protobufjs/dist/minimal/protobuf.js +2 -2
  324. package/node_modules/protobufjs/dist/minimal/protobuf.min.js +2 -2
  325. package/node_modules/protobufjs/dist/protobuf.js +5 -2
  326. package/node_modules/protobufjs/dist/protobuf.js.map +1 -1
  327. package/node_modules/protobufjs/dist/protobuf.min.js +3 -3
  328. package/node_modules/protobufjs/dist/protobuf.min.js.map +1 -1
  329. package/node_modules/protobufjs/package.json +1 -1
  330. package/node_modules/protobufjs/src/parse.js +3 -0
  331. package/package.json +7 -7
  332. package/slingshot/index.js +261 -261
  333. package/node_modules/@aws-crypto/crc32/CHANGELOG.md +0 -100
  334. package/node_modules/@aws-crypto/crc32/LICENSE +0 -201
  335. package/node_modules/@aws-crypto/crc32/README.md +0 -16
  336. package/node_modules/@aws-crypto/crc32/build/main/aws_crc32.d.ts +0 -7
  337. package/node_modules/@aws-crypto/crc32/build/main/aws_crc32.js +0 -31
  338. package/node_modules/@aws-crypto/crc32/build/main/aws_crc32.js.map +0 -1
  339. package/node_modules/@aws-crypto/crc32/build/main/index.d.ts +0 -7
  340. package/node_modules/@aws-crypto/crc32/build/main/index.js +0 -108
  341. package/node_modules/@aws-crypto/crc32/build/main/index.js.map +0 -1
  342. package/node_modules/@aws-crypto/crc32/build/module/aws_crc32.d.ts +0 -7
  343. package/node_modules/@aws-crypto/crc32/build/module/aws_crc32.js +0 -28
  344. package/node_modules/@aws-crypto/crc32/build/module/aws_crc32.js.map +0 -1
  345. package/node_modules/@aws-crypto/crc32/build/module/index.d.ts +0 -7
  346. package/node_modules/@aws-crypto/crc32/build/module/index.js +0 -103
  347. package/node_modules/@aws-crypto/crc32/build/module/index.js.map +0 -1
  348. package/node_modules/@aws-crypto/crc32/package.json +0 -32
  349. package/node_modules/@aws-crypto/crc32/src/aws_crc32.ts +0 -24
  350. package/node_modules/@aws-crypto/crc32/src/index.ts +0 -92
  351. package/node_modules/@aws-crypto/crc32/tsconfig.json +0 -9
  352. package/node_modules/@aws-crypto/crc32/tsconfig.module.json +0 -7
  353. package/node_modules/@aws-sdk/core/dist-cjs/submodules/client/index.browser.js +0 -869
  354. package/node_modules/@aws-sdk/core/dist-cjs/submodules/client/index.native.js +0 -862
  355. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/fromHttp/checkUrl.js +0 -42
  356. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/fromHttp/fromHttp.browser.js +0 -27
  357. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/fromHttp/fromHttp.js +0 -71
  358. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/fromHttp/requestHelpers.js +0 -49
  359. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/fromHttp/retry-wrapper.js +0 -13
  360. package/node_modules/@aws-sdk/credential-provider-http/dist-cjs/index.browser.js +0 -2
  361. package/node_modules/@aws-sdk/credential-provider-http/node_modules/@smithy/node-http-handler/dist-es/stream-collector/collector.js +0 -8
  362. package/node_modules/@aws-sdk/credential-provider-http/node_modules/@smithy/node-http-handler/dist-es/stream-collector/index.js +0 -41
  363. package/node_modules/@aws-sdk/credential-provider-http/node_modules/@smithy/node-http-handler/dist-types/stream-collector/collector.d.ts +0 -5
  364. package/node_modules/@aws-sdk/credential-provider-http/node_modules/@smithy/node-http-handler/dist-types/stream-collector/index.d.ts +0 -7
  365. package/node_modules/@aws-sdk/credential-provider-web-identity/dist-cjs/fromTokenFile.js +0 -29
  366. package/node_modules/@aws-sdk/credential-provider-web-identity/dist-cjs/fromWebToken.js +0 -25
  367. package/node_modules/@aws-sdk/nested-clients/node_modules/@smithy/node-http-handler/dist-es/stream-collector/collector.js +0 -8
  368. package/node_modules/@aws-sdk/nested-clients/node_modules/@smithy/node-http-handler/dist-es/stream-collector/index.js +0 -41
  369. package/node_modules/@aws-sdk/nested-clients/node_modules/@smithy/node-http-handler/dist-types/stream-collector/collector.d.ts +0 -5
  370. package/node_modules/@aws-sdk/nested-clients/node_modules/@smithy/node-http-handler/dist-types/stream-collector/index.d.ts +0 -7
  371. package/node_modules/@aws-sdk/xml-builder/dist-cjs/xml-parser.browser.js +0 -57
  372. package/node_modules/@aws-sdk/xml-builder/dist-cjs/xml-parser.js +0 -234
  373. package/node_modules/@smithy/core/dist-es/submodules/checksum/md5-js/constants.js +0 -3
  374. package/node_modules/@smithy/core/dist-es/submodules/checksum/md5-js/md5.js +0 -168
  375. package/node_modules/@smithy/core/dist-types/submodules/checksum/md5-js/constants.d.ts +0 -12
  376. package/node_modules/@smithy/core/dist-types/submodules/checksum/md5-js/md5.d.ts +0 -16
  377. package/node_modules/@smithy/fetch-http-handler/dist-es/stream-collector.js +0 -53
  378. package/node_modules/@smithy/fetch-http-handler/dist-types/stream-collector.d.ts +0 -2
  379. /package/node_modules/@smithy/{core/dist-es/submodules/endpoints/middleware-endpoint/types.js → types/dist-es/endpoints/EndpointParameterInstructions.js} +0 -0
  380. /package/node_modules/@smithy/{core/dist-types/submodules/endpoints/middleware-endpoint/types.d.ts → types/dist-types/endpoints/EndpointParameterInstructions.d.ts} +0 -0
@@ -11,9 +11,9 @@ export const XIAOMI_TOKEN_PLAN_AMS_MODELS = {
11
11
  reasoning: true,
12
12
  input: ["text", "image"],
13
13
  cost: {
14
- input: 0.4,
15
- output: 2,
16
- cacheRead: 0.08,
14
+ input: 0.14,
15
+ output: 0.28,
16
+ cacheRead: 0.0028,
17
17
  cacheWrite: 0,
18
18
  },
19
19
  contextWindow: 262144,
@@ -29,9 +29,9 @@ export const XIAOMI_TOKEN_PLAN_AMS_MODELS = {
29
29
  reasoning: true,
30
30
  input: ["text"],
31
31
  cost: {
32
- input: 1,
33
- output: 3,
34
- cacheRead: 0.2,
32
+ input: 0.435,
33
+ output: 0.87,
34
+ cacheRead: 0.0036,
35
35
  cacheWrite: 0,
36
36
  },
37
37
  contextWindow: 1048576,
@@ -47,9 +47,9 @@ export const XIAOMI_TOKEN_PLAN_AMS_MODELS = {
47
47
  reasoning: true,
48
48
  input: ["text", "image"],
49
49
  cost: {
50
- input: 0.4,
51
- output: 2,
52
- cacheRead: 0.08,
50
+ input: 0.14,
51
+ output: 0.28,
52
+ cacheRead: 0.0028,
53
53
  cacheWrite: 0,
54
54
  },
55
55
  contextWindow: 1048576,
@@ -65,9 +65,9 @@ export const XIAOMI_TOKEN_PLAN_AMS_MODELS = {
65
65
  reasoning: true,
66
66
  input: ["text"],
67
67
  cost: {
68
- input: 1,
69
- output: 3,
70
- cacheRead: 0.2,
68
+ input: 0.435,
69
+ output: 0.87,
70
+ cacheRead: 0.0036,
71
71
  cacheWrite: 0,
72
72
  },
73
73
  contextWindow: 1048576,
@@ -11,9 +11,9 @@ export const XIAOMI_TOKEN_PLAN_CN_MODELS = {
11
11
  reasoning: true,
12
12
  input: ["text", "image"],
13
13
  cost: {
14
- input: 0.4,
15
- output: 2,
16
- cacheRead: 0.08,
14
+ input: 0.14,
15
+ output: 0.28,
16
+ cacheRead: 0.0028,
17
17
  cacheWrite: 0,
18
18
  },
19
19
  contextWindow: 262144,
@@ -29,9 +29,9 @@ export const XIAOMI_TOKEN_PLAN_CN_MODELS = {
29
29
  reasoning: true,
30
30
  input: ["text"],
31
31
  cost: {
32
- input: 1,
33
- output: 3,
34
- cacheRead: 0.2,
32
+ input: 0.435,
33
+ output: 0.87,
34
+ cacheRead: 0.0036,
35
35
  cacheWrite: 0,
36
36
  },
37
37
  contextWindow: 1048576,
@@ -47,9 +47,9 @@ export const XIAOMI_TOKEN_PLAN_CN_MODELS = {
47
47
  reasoning: true,
48
48
  input: ["text", "image"],
49
49
  cost: {
50
- input: 0.4,
51
- output: 2,
52
- cacheRead: 0.08,
50
+ input: 0.14,
51
+ output: 0.28,
52
+ cacheRead: 0.0028,
53
53
  cacheWrite: 0,
54
54
  },
55
55
  contextWindow: 1048576,
@@ -65,9 +65,9 @@ export const XIAOMI_TOKEN_PLAN_CN_MODELS = {
65
65
  reasoning: true,
66
66
  input: ["text"],
67
67
  cost: {
68
- input: 1,
69
- output: 3,
70
- cacheRead: 0.2,
68
+ input: 0.435,
69
+ output: 0.87,
70
+ cacheRead: 0.0036,
71
71
  cacheWrite: 0,
72
72
  },
73
73
  contextWindow: 1048576,
@@ -11,9 +11,9 @@ export const XIAOMI_TOKEN_PLAN_SGP_MODELS = {
11
11
  reasoning: true,
12
12
  input: ["text", "image"],
13
13
  cost: {
14
- input: 0.4,
15
- output: 2,
16
- cacheRead: 0.08,
14
+ input: 0.14,
15
+ output: 0.28,
16
+ cacheRead: 0.0028,
17
17
  cacheWrite: 0,
18
18
  },
19
19
  contextWindow: 262144,
@@ -29,9 +29,9 @@ export const XIAOMI_TOKEN_PLAN_SGP_MODELS = {
29
29
  reasoning: true,
30
30
  input: ["text"],
31
31
  cost: {
32
- input: 1,
33
- output: 3,
34
- cacheRead: 0.2,
32
+ input: 0.435,
33
+ output: 0.87,
34
+ cacheRead: 0.0036,
35
35
  cacheWrite: 0,
36
36
  },
37
37
  contextWindow: 1048576,
@@ -47,9 +47,9 @@ export const XIAOMI_TOKEN_PLAN_SGP_MODELS = {
47
47
  reasoning: true,
48
48
  input: ["text", "image"],
49
49
  cost: {
50
- input: 0.4,
51
- output: 2,
52
- cacheRead: 0.08,
50
+ input: 0.14,
51
+ output: 0.28,
52
+ cacheRead: 0.0028,
53
53
  cacheWrite: 0,
54
54
  },
55
55
  contextWindow: 1048576,
@@ -65,9 +65,9 @@ export const XIAOMI_TOKEN_PLAN_SGP_MODELS = {
65
65
  reasoning: true,
66
66
  input: ["text"],
67
67
  cost: {
68
- input: 1,
69
- output: 3,
70
- cacheRead: 0.2,
68
+ input: 0.435,
69
+ output: 0.87,
70
+ cacheRead: 0.0036,
71
71
  cacheWrite: 0,
72
72
  },
73
73
  contextWindow: 1048576,
@@ -11,9 +11,9 @@ export const XIAOMI_MODELS = {
11
11
  reasoning: true,
12
12
  input: ["text"],
13
13
  cost: {
14
- input: 0.1,
15
- output: 0.3,
16
- cacheRead: 0.01,
14
+ input: 0.14,
15
+ output: 0.28,
16
+ cacheRead: 0.0028,
17
17
  cacheWrite: 0,
18
18
  },
19
19
  contextWindow: 262144,
@@ -29,9 +29,9 @@ export const XIAOMI_MODELS = {
29
29
  reasoning: true,
30
30
  input: ["text", "image"],
31
31
  cost: {
32
- input: 0.4,
33
- output: 2,
34
- cacheRead: 0.08,
32
+ input: 0.14,
33
+ output: 0.28,
34
+ cacheRead: 0.0028,
35
35
  cacheWrite: 0,
36
36
  },
37
37
  contextWindow: 262144,
@@ -47,9 +47,9 @@ export const XIAOMI_MODELS = {
47
47
  reasoning: true,
48
48
  input: ["text"],
49
49
  cost: {
50
- input: 1,
51
- output: 3,
52
- cacheRead: 0.2,
50
+ input: 0.435,
51
+ output: 0.87,
52
+ cacheRead: 0.0036,
53
53
  cacheWrite: 0,
54
54
  },
55
55
  contextWindow: 1048576,
@@ -65,9 +65,9 @@ export const XIAOMI_MODELS = {
65
65
  reasoning: true,
66
66
  input: ["text", "image"],
67
67
  cost: {
68
- input: 0.4,
69
- output: 2,
70
- cacheRead: 0.08,
68
+ input: 0.14,
69
+ output: 0.28,
70
+ cacheRead: 0.0028,
71
71
  cacheWrite: 0,
72
72
  },
73
73
  contextWindow: 1048576,
@@ -83,9 +83,9 @@ export const XIAOMI_MODELS = {
83
83
  reasoning: true,
84
84
  input: ["text"],
85
85
  cost: {
86
- input: 1,
87
- output: 3,
88
- cacheRead: 0.2,
86
+ input: 0.435,
87
+ output: 0.87,
88
+ cacheRead: 0.0036,
89
89
  cacheWrite: 0,
90
90
  },
91
91
  contextWindow: 1048576,
@@ -0,0 +1,109 @@
1
+ // Shared normalization for provider HTTP error objects.
2
+ //
3
+ // Endpoints behind a proxy / gateway may return a non-2xx response whose body
4
+ // the provider SDK cannot fold into `error.message`. The SDK error object still
5
+ // carries the HTTP status and the raw/parsed body, but under SDK-specific field
6
+ // names. Provider catch blocks that read only `error.message` therefore drop
7
+ // the body and surface opaque messages like `"403 status code (no body)"` or
8
+ // collapse to `"Unknown: UnknownError"`.
9
+ //
10
+ // `normalizeProviderError` probes the known SDK field shapes (Mistral,
11
+ // `openai`, `@google/genai`, AWS Bedrock) and returns a struct each provider
12
+ // composes into its display string. The `messageCarriesBody` flag captures the
13
+ // Anthropic / `@google/genai` happy path where the SDK already folded the body
14
+ // into the message, so providers can preserve it without double-printing.
15
+ export const MAX_PROVIDER_ERROR_BODY_CHARS = 4000;
16
+ export function normalizeProviderError(error) {
17
+ if (!(error instanceof Error)) {
18
+ return { message: safeJsonStringify(error), messageCarriesBody: false };
19
+ }
20
+ const sdkError = error;
21
+ const status = extractStatus(sdkError);
22
+ const body = extractBody(sdkError);
23
+ const messageCarriesBody = body === undefined || error.message.includes(body);
24
+ return {
25
+ status,
26
+ body,
27
+ message: error.message,
28
+ messageCarriesBody,
29
+ };
30
+ }
31
+ /**
32
+ * Probe the HTTP status, first numeric hit wins, in SDK-field order:
33
+ * `statusCode` (Mistral) → `status` (`openai`, `@google/genai`) →
34
+ * `$metadata.httpStatusCode` (Bedrock) → `$response.statusCode` (Bedrock).
35
+ */
36
+ function extractStatus(error) {
37
+ if (typeof error.statusCode === "number")
38
+ return error.statusCode;
39
+ if (typeof error.status === "number")
40
+ return error.status;
41
+ if (typeof error.$metadata?.httpStatusCode === "number")
42
+ return error.$metadata.httpStatusCode;
43
+ if (typeof error.$response?.statusCode === "number")
44
+ return error.$response.statusCode;
45
+ return undefined;
46
+ }
47
+ /**
48
+ * Probe the raw body reason, first usable hit wins, in SDK-field order:
49
+ * `body` string (Mistral) → `error` parsed JSON body object (`openai` SDK's
50
+ * `this.error`) → `$response.body` (Bedrock). Empty objects are treated as no
51
+ * body so an empty parsed body does not surface as `"{}"`. The chosen body is
52
+ * truncated to the cap.
53
+ */
54
+ function extractBody(error) {
55
+ const bodyText = pickBodyText(error);
56
+ if (bodyText === undefined)
57
+ return undefined;
58
+ const trimmed = bodyText.trim();
59
+ if (trimmed.length === 0)
60
+ return undefined;
61
+ return truncateErrorText(trimmed, MAX_PROVIDER_ERROR_BODY_CHARS);
62
+ }
63
+ function pickBodyText(error) {
64
+ if (typeof error.body === "string")
65
+ return error.body;
66
+ if (isNonEmptyObject(error.error))
67
+ return safeJsonStringify(error.error);
68
+ const responseBody = error.$response?.body;
69
+ if (typeof responseBody === "string")
70
+ return responseBody;
71
+ if (isNonEmptyObject(responseBody))
72
+ return safeJsonStringify(responseBody);
73
+ return undefined;
74
+ }
75
+ function isNonEmptyObject(value) {
76
+ return typeof value === "object" && value !== null && Object.keys(value).length > 0;
77
+ }
78
+ /**
79
+ * Compose a display string from a normalized error. When the message already
80
+ * carries the body (Anthropic / `@google/genai` happy path) or no body/status
81
+ * was extracted, the message is returned unchanged. Otherwise the status and
82
+ * body are surfaced, with an optional provider prefix.
83
+ *
84
+ * - no prefix: `"<status>: <body>"`
85
+ * - prefix: `"<prefix> (<status>): <body>"`
86
+ */
87
+ export function formatProviderError(norm, prefix) {
88
+ if (norm.messageCarriesBody || norm.status === undefined || norm.body === undefined) {
89
+ return prefix !== undefined && norm.status !== undefined
90
+ ? `${prefix} (${norm.status}): ${norm.message}`
91
+ : norm.message;
92
+ }
93
+ return prefix !== undefined ? `${prefix} (${norm.status}): ${norm.body}` : `${norm.status}: ${norm.body}`;
94
+ }
95
+ export function truncateErrorText(text, maxChars) {
96
+ if (text.length <= maxChars)
97
+ return text;
98
+ return `${text.slice(0, maxChars)}... [truncated ${text.length - maxChars} chars]`;
99
+ }
100
+ export function safeJsonStringify(value) {
101
+ try {
102
+ const serialized = JSON.stringify(value);
103
+ return serialized === undefined ? String(value) : serialized;
104
+ }
105
+ catch {
106
+ return String(value);
107
+ }
108
+ }
109
+ //# sourceMappingURL=error-body.js.map
@@ -29,6 +29,12 @@ export async function pollOAuthDeviceCodeFlow(options) {
29
29
  : Number.POSITIVE_INFINITY;
30
30
  let intervalMs = Math.max(MINIMUM_INTERVAL_MS, Math.floor((options.intervalSeconds ?? DEFAULT_POLL_INTERVAL_SECONDS) * 1000));
31
31
  let slowDownResponses = 0;
32
+ if (options.waitBeforeFirstPoll) {
33
+ const remainingMs = deadline - Date.now();
34
+ if (remainingMs > 0) {
35
+ await abortableSleep(Math.min(intervalMs, remainingMs), options.signal, CANCEL_MESSAGE);
36
+ }
37
+ }
32
38
  while (Date.now() < deadline) {
33
39
  if (options.signal?.aborted) {
34
40
  throw new Error(CANCEL_MESSAGE);
@@ -42,8 +48,15 @@ export async function pollOAuthDeviceCodeFlow(options) {
42
48
  }
43
49
  if (result.status === "slow_down") {
44
50
  slowDownResponses += 1;
45
- // RFC 8628 section 3.5: apply this increase to this and all subsequent requests.
46
- intervalMs = Math.max(MINIMUM_INTERVAL_MS, intervalMs + SLOW_DOWN_INTERVAL_INCREMENT_MS);
51
+ // Use the server-provided interval when given (GitHub reports the new required minimum
52
+ // in `interval`); trusting only a client-tracked value risks polling early forever under
53
+ // WSL/VM clock drift. Otherwise apply RFC 8628 section 3.5: increase by 5 seconds.
54
+ intervalMs =
55
+ typeof result.intervalSeconds === "number" &&
56
+ Number.isFinite(result.intervalSeconds) &&
57
+ result.intervalSeconds > 0
58
+ ? Math.max(MINIMUM_INTERVAL_MS, Math.floor(result.intervalSeconds * 1000))
59
+ : Math.max(MINIMUM_INTERVAL_MS, intervalMs + SLOW_DOWN_INTERVAL_INCREMENT_MS);
47
60
  }
48
61
  const remainingMs = deadline - Date.now();
49
62
  if (remainingMs <= 0) {
@@ -156,6 +156,7 @@ async function pollForGitHubAccessToken(domain, device, signal) {
156
156
  return pollOAuthDeviceCodeFlow({
157
157
  intervalSeconds: device.interval,
158
158
  expiresInSeconds: device.expires_in,
159
+ waitBeforeFirstPoll: true,
159
160
  signal,
160
161
  poll: async () => {
161
162
  const raw = await fetchJson(urls.accessTokenUrl, {
@@ -175,12 +176,12 @@ async function pollForGitHubAccessToken(domain, device, signal) {
175
176
  return { status: "complete", value: raw.access_token };
176
177
  }
177
178
  if (raw && typeof raw === "object" && typeof raw.error === "string") {
178
- const { error, error_description: description } = raw;
179
+ const { error, error_description: description, interval } = raw;
179
180
  if (error === "authorization_pending") {
180
181
  return { status: "pending" };
181
182
  }
182
183
  if (error === "slow_down") {
183
- return { status: "slow_down" };
184
+ return { status: "slow_down", intervalSeconds: typeof interval === "number" ? interval : undefined };
184
185
  }
185
186
  const descriptionSuffix = description ? `: ${description}` : "";
186
187
  return { status: "failed", message: `Device flow failed: ${error}${descriptionSuffix}` };
@@ -22,6 +22,7 @@
22
22
  * - GitHub Copilot: "prompt token count of X exceeds the limit of Y"
23
23
  * - MiniMax: "invalid params, context window exceeds limit"
24
24
  * - Kimi For Coding: "Your request exceeded model token limit: X (requested: Y)"
25
+ * - DS4: "Prompt has X tokens, but the configured context size is Y tokens"
25
26
  * - Cerebras: "400/413 status code (no body)"
26
27
  * - Mistral: "Prompt contains X tokens ... too large for model with Y maximum context length"
27
28
  * - z.ai: Does NOT error, accepts overflow silently - handled via usage.input > contextWindow
@@ -48,6 +49,7 @@ const OVERFLOW_PATTERNS = [
48
49
  /context window exceeds limit/i, // MiniMax
49
50
  /exceeded model token limit/i, // Kimi For Coding
50
51
  /too large for model with \d+ maximum context length/i, // Mistral
52
+ /prompt has [\d,]+ tokens?, but the configured context size is [\d,]+ tokens?/i, // DS4 server
51
53
  /model_context_window_exceeded/i, // z.ai non-standard finish_reason surfaced as error text
52
54
  /prompt too long; exceeded (?:max )?context length/i, // Ollama explicit overflow error
53
55
  /context[_ ]length[_ ]exceeded/i, // Generic fallback
@@ -94,6 +96,7 @@ const NON_OVERFLOW_PATTERNS = [
94
96
  * - llama.cpp: "exceeds the available context size"
95
97
  * - LM Studio: "greater than the context length"
96
98
  * - Kimi For Coding: "exceeded model token limit: X (requested: Y)"
99
+ * - DS4: "Prompt has X tokens, but the configured context size is Y tokens"
97
100
  *
98
101
  * **Unreliable detection:**
99
102
  * - z.ai: Sometimes accepts overflow silently (detectable via usage.input > contextWindow),
@@ -27,6 +27,7 @@ const RETRYABLE_PROVIDER_ERROR_PATTERN = buildProviderErrorPattern([
27
27
  "502",
28
28
  "503",
29
29
  "504",
30
+ "524",
30
31
  "service.?unavailable",
31
32
  "server.?error",
32
33
  "internal.?error",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@earendil-works/pi-ai",
3
- "version": "0.80.2",
3
+ "version": "0.80.3",
4
4
  "description": "Unified LLM API with automatic model discovery and provider configuration",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -120,6 +120,7 @@ export class AgentSession {
120
120
  // Base system prompt (without extension appends) - used to apply fresh appends each turn
121
121
  _baseSystemPrompt = "";
122
122
  _baseSystemPromptOptions;
123
+ _systemPromptOverride;
123
124
  constructor(config) {
124
125
  this.agent = config.agent;
125
126
  this.sessionManager = config.sessionManager;
@@ -139,6 +140,7 @@ export class AgentSession {
139
140
  // (session persistence, extensions, auto-compaction, retry logic)
140
141
  this._unsubscribeAgent = this.agent.subscribe(this._handleAgentEvent);
141
142
  this._installAgentToolHooks();
143
+ this._installAgentNextTurnRefresh();
142
144
  this._buildRuntime({
143
145
  activeToolNames: this._initialActiveToolNames,
144
146
  includeAllExtensionTools: true,
@@ -227,6 +229,26 @@ export class AgentSession {
227
229
  };
228
230
  };
229
231
  }
232
+ _installAgentNextTurnRefresh() {
233
+ const previousPrepareNextTurnWithContext = this.agent.prepareNextTurnWithContext ??
234
+ (this.agent.prepareNextTurn
235
+ ? async (_turn, signal) => await this.agent.prepareNextTurn?.(signal)
236
+ : undefined);
237
+ this.agent.prepareNextTurnWithContext = async (turn, signal) => {
238
+ const previousSnapshot = await previousPrepareNextTurnWithContext?.(turn, signal);
239
+ const previousContext = previousSnapshot?.context ?? turn.context;
240
+ return {
241
+ ...previousSnapshot,
242
+ context: {
243
+ ...previousContext,
244
+ systemPrompt: this._systemPromptOverride ?? this._baseSystemPrompt,
245
+ tools: this.agent.state.tools.slice(),
246
+ },
247
+ model: this.agent.state.model,
248
+ thinkingLevel: this.agent.state.thinkingLevel,
249
+ };
250
+ };
251
+ }
230
252
  // =========================================================================
231
253
  // Event Subscription
232
254
  // =========================================================================
@@ -560,7 +582,7 @@ export class AgentSession {
560
582
  this.agent.state.tools = tools;
561
583
  // Rebuild base system prompt with new tool set
562
584
  this._baseSystemPrompt = this._rebuildSystemPrompt(validToolNames);
563
- this.agent.state.systemPrompt = this._baseSystemPrompt;
585
+ this.agent.state.systemPrompt = this._systemPromptOverride ?? this._baseSystemPrompt;
564
586
  }
565
587
  /** Whether compaction or branch summarization is currently running */
566
588
  get isCompacting() {
@@ -668,6 +690,7 @@ export class AgentSession {
668
690
  }
669
691
  }
670
692
  finally {
693
+ this._systemPromptOverride = undefined;
671
694
  this._flushPendingBashMessages();
672
695
  }
673
696
  }
@@ -808,11 +831,13 @@ export class AgentSession {
808
831
  }
809
832
  }
810
833
  // Apply extension-modified system prompt, or reset to base
811
- if (result?.systemPrompt) {
834
+ if (result?.systemPrompt !== undefined) {
835
+ this._systemPromptOverride = result.systemPrompt;
812
836
  this.agent.state.systemPrompt = result.systemPrompt;
813
837
  }
814
838
  else {
815
839
  // Ensure we're using the base prompt (in case previous turn had modifications)
840
+ this._systemPromptOverride = undefined;
816
841
  this.agent.state.systemPrompt = this._baseSystemPrompt;
817
842
  }
818
843
  }
@@ -1760,7 +1785,11 @@ export class AgentSession {
1760
1785
  });
1761
1786
  },
1762
1787
  appendEntry: (customType, data) => {
1763
- this.sessionManager.appendCustomEntry(customType, data);
1788
+ const entryId = this.sessionManager.appendCustomEntry(customType, data);
1789
+ const entry = this.sessionManager.getEntry(entryId);
1790
+ if (entry) {
1791
+ this._emit({ type: "entry_appended", entry });
1792
+ }
1764
1793
  },
1765
1794
  setSessionName: (name) => {
1766
1795
  this.setSessionName(name);
@@ -2137,7 +2166,9 @@ export class AgentSession {
2137
2166
  */
2138
2167
  setSessionName(name) {
2139
2168
  this.sessionManager.appendSessionInfo(name);
2140
- this._emit({ type: "session_info_changed", name: this.sessionManager.getSessionName() });
2169
+ const event = { type: "session_info_changed", name: this.sessionManager.getSessionName() };
2170
+ this._emit(event);
2171
+ void this._extensionRunner.emit(event);
2141
2172
  }
2142
2173
  // =========================================================================
2143
2174
  // Tree Navigation
@@ -208,9 +208,15 @@ export class AuthStorage {
208
208
  }
209
209
  persistProviderChange(provider, credential) {
210
210
  if (this.loadError) {
211
- return;
211
+ this.reload();
212
+ }
213
+ if (this.loadError) {
214
+ const error = new Error(`Cannot update auth storage because it could not be loaded: ${this.loadError.message}`);
215
+ this.recordError(error);
216
+ throw error;
212
217
  }
213
218
  try {
219
+ let persistedData = {};
214
220
  this.storage.withLock((current) => {
215
221
  const currentData = this.parseStorageData(current);
216
222
  const merged = { ...currentData };
@@ -220,11 +226,15 @@ export class AuthStorage {
220
226
  else {
221
227
  delete merged[provider];
222
228
  }
229
+ persistedData = merged;
223
230
  return { result: undefined, next: JSON.stringify(merged, null, 2) };
224
231
  });
232
+ this.loadError = null;
233
+ return persistedData;
225
234
  }
226
235
  catch (error) {
227
236
  this.recordError(error);
237
+ throw error;
228
238
  }
229
239
  }
230
240
  /**
@@ -244,15 +254,13 @@ export class AuthStorage {
244
254
  * Set credential for a provider.
245
255
  */
246
256
  set(provider, credential) {
247
- this.data[provider] = credential;
248
- this.persistProviderChange(provider, credential);
257
+ this.data = this.persistProviderChange(provider, credential);
249
258
  }
250
259
  /**
251
260
  * Remove credential for a provider.
252
261
  */
253
262
  remove(provider) {
254
- delete this.data[provider];
255
- this.persistProviderChange(provider, undefined);
263
+ this.data = this.persistProviderChange(provider, undefined);
256
264
  }
257
265
  /**
258
266
  * List all providers with credentials.
@@ -568,16 +568,13 @@ Be concise. Focus on what's needed to understand the kept suffix.`;
568
568
  */
569
569
  export async function compact(preparation, model, apiKey, headers, customInstructions, signal, thinkingLevel, streamFn, env) {
570
570
  const { firstKeptEntryId, messagesToSummarize, turnPrefixMessages, isSplitTurn, tokensBefore, previousSummary, fileOps, settings, } = preparation;
571
- // Generate summaries (can be parallel if both needed) and merge into one
571
+ // Generate summaries and merge into one
572
572
  let summary;
573
573
  if (isSplitTurn && turnPrefixMessages.length > 0) {
574
- // Generate both summaries in parallel
575
- const [historyResult, turnPrefixResult] = await Promise.all([
576
- messagesToSummarize.length > 0
577
- ? generateSummary(messagesToSummarize, model, settings.reserveTokens, apiKey, headers, signal, customInstructions, previousSummary, thinkingLevel, streamFn, env)
578
- : Promise.resolve("No prior history."),
579
- generateTurnPrefixSummary(turnPrefixMessages, model, settings.reserveTokens, apiKey, headers, env, signal, thinkingLevel, streamFn),
580
- ]);
574
+ const historyResult = messagesToSummarize.length > 0
575
+ ? await generateSummary(messagesToSummarize, model, settings.reserveTokens, apiKey, headers, signal, customInstructions, previousSummary, thinkingLevel, streamFn, env)
576
+ : "No prior history.";
577
+ const turnPrefixResult = await generateTurnPrefixSummary(turnPrefixMessages, model, settings.reserveTokens, apiKey, headers, env, signal, thinkingLevel, streamFn);
581
578
  // Merge into single summary
582
579
  summary = `${historyResult}\n\n---\n\n**Turn Context (split turn):**\n\n${turnPrefixResult}`;
583
580
  }
@@ -212,6 +212,11 @@ function createExtensionAPI(extension, runtime, cwd, eventBus) {
212
212
  runtime.assertActive();
213
213
  extension.messageRenderers.set(customType, renderer);
214
214
  },
215
+ registerEntryRenderer(customType, renderer) {
216
+ runtime.assertActive();
217
+ extension.entryRenderers ??= new Map();
218
+ extension.entryRenderers.set(customType, renderer);
219
+ },
215
220
  // Flag access - checks extension registered it, reads from runtime
216
221
  getFlag(name) {
217
222
  runtime.assertActive();
@@ -332,6 +337,7 @@ function createExtension(extensionPath, resolvedPath) {
332
337
  handlers: new Map(),
333
338
  tools: new Map(),
334
339
  messageRenderers: new Map(),
340
+ entryRenderers: new Map(),
335
341
  commands: new Map(),
336
342
  flags: new Map(),
337
343
  shortcuts: new Map(),