@bastani/atomic-ai 0.9.88-alpha.1 → 0.9.89-alpha.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.
- package/CHANGELOG.md +35 -0
- package/dist/api/anthropic-messages.js +2 -2
- package/dist/api/anthropic-messages.js.map +1 -1
- package/dist/compat.js +2 -2
- package/dist/compat.js.map +1 -1
- package/dist/env-api-keys.d.ts +3 -0
- package/dist/env-api-keys.d.ts.map +1 -1
- package/dist/env-api-keys.js +97 -35
- package/dist/env-api-keys.js.map +1 -1
- package/dist/models.d.ts.map +1 -1
- package/dist/models.js +10 -3
- package/dist/models.js.map +1 -1
- package/dist/providers/data/.manifest.json +1 -1
- package/dist/providers/data/azure.json +1 -1
- package/dist/providers/data/baseten.json +1 -1
- package/dist/providers/data/huggingface.json +1 -1
- package/dist/providers/data/nvidia.json +1 -1
- package/dist/providers/data/openai-codex.json +1 -1
- package/dist/providers/data/openai.json +1 -1
- package/dist/providers/data/opencode.json +1 -1
- package/dist/providers/data/openrouter.json +1 -1
- package/dist/providers/data/vercel-ai-gateway.json +1 -1
- package/dist/providers/openai-mid-convo-effort.d.ts.map +1 -1
- package/dist/providers/openai-mid-convo-effort.js +2 -0
- package/dist/providers/openai-mid-convo-effort.js.map +1 -1
- package/dist/providers/openai-subscription-models.d.ts.map +1 -1
- package/dist/providers/openai-subscription-models.js +13 -2
- package/dist/providers/openai-subscription-models.js.map +1 -1
- package/dist/utils/models-dev-catalog.d.ts.map +1 -1
- package/dist/utils/models-dev-catalog.js +89 -7
- package/dist/utils/models-dev-catalog.js.map +1 -1
- package/dist/utils/provider-env.d.ts.map +1 -1
- package/dist/utils/provider-env.js +21 -18
- package/dist/utils/provider-env.js.map +1 -1
- package/dist/utils/version.d.ts +1 -1
- package/dist/utils/version.js +1 -1
- package/dist/utils/version.js.map +1 -1
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,41 @@ This package is Atomic's fork of `@earendil-works/pi-ai`, published as `@bastani
|
|
|
4
4
|
|
|
5
5
|
## [Unreleased]
|
|
6
6
|
|
|
7
|
+
## [0.9.89-alpha.1] - 2026-11-18
|
|
8
|
+
|
|
9
|
+
### Added
|
|
10
|
+
|
|
11
|
+
- `getEnvApiKeyAsync()` checks environment-provided credentials without synchronous file access. `getEnvApiKey()` remains synchronous and recognizes a passed credentials file on its first call. The compatibility entry point also exports `getDirectEnvApiKey()` for environment-only lookups that never inspect a file
|
|
12
|
+
- Added GPT-6.2 Astra and GPT-6.2 Sol to the OpenAI (`openai`, `openai-api`), Azure OpenAI Responses and OpenAI Codex catalogs with OpenAI's published prices (Astra: $8 input, $0.40 cached input, $10 cache writes, $40 output per million tokens; Sol: $2, $0.10, $2.50, $10), the request-wide tier above 272K input tokens, Fast at 2x Standard, Ultrafast at 3x Standard (OpenAI's rate until March 1, 2027), tool search, additional tools, and mid-conversation effort changes. Both reject reasoning effort `none` and `minimal`, so `off` is unavailable. Azure serves them with a 1.05M context window; Codex and a ChatGPT sign-in on `openai` serve GPT-6.2 Sol with 500K and GPT-6.2 Astra with 272K (upstream [e56d35c](https://github.com/earendil-works/pi/commit/e56d35ce5eceedfa16eaf13a5f01a1f7b7271253), [cead615](https://github.com/earendil-works/pi/commit/cead615b48b80d1c61eecab2f0b576d16eeaf4c5))
|
|
13
|
+
|
|
14
|
+
## [0.9.88] - 2026-11-16
|
|
15
|
+
|
|
16
|
+
### Added
|
|
17
|
+
|
|
18
|
+
- Added `buildModelsDevChatModels()` and `finalizeChatModels()` in `@bastani/atomic-ai/utils/models-dev-catalog`, the transform from models.dev's `api.json` to the built-in chat catalog ([#5174](https://github.com/bastani-inc/atomic/issues/5174))
|
|
19
|
+
|
|
20
|
+
### Changed
|
|
21
|
+
|
|
22
|
+
- Renamed the package from `@bastani/pi-ai` to `@bastani/atomic-ai`. It now depends on Atomic's forks `@bastani/atomic-schema` and `@bastani/atomic-telemetry` instead of pi's packages. Atomic's extension loader still resolves `@bastani/pi-ai`, `@earendil-works/pi-ai` and `@mariozechner/pi-ai` imports to it ([#5174](https://github.com/bastani-inc/atomic/issues/5174))
|
|
23
|
+
- Requests now identify as Atomic by default: the default `User-Agent` is `atomic/<version>` (short form `atomic`), and the new `ATOMIC_ATTRIBUTION` attributes requests to Atomic for OpenRouter, NVIDIA and OpenCode. `PI_ATTRIBUTION` is deprecated and now equals `ATOMIC_ATTRIBUTION`. `ATOMIC_CACHE_RETENTION` and `ATOMIC_OAUTH_CALLBACK_HOST` replace `PI_CACHE_RETENTION` and `PI_OAUTH_CALLBACK_HOST`, which keep working as legacy names ([#5174](https://github.com/bastani-inc/atomic/issues/5174))
|
|
24
|
+
- OpenAI Codex requests and the Codex browser sign-in send `originator: atomic`, xAI OAuth sends `referrer: atomic`, and Bedrock's user-agent pair is `atomic/<version>`, all instead of `pi`. The OAuth client IDs are unchanged; if Codex or xAI sign-in or requests start failing, these identifiers are the change to revert ([#5174](https://github.com/bastani-inc/atomic/issues/5174))
|
|
25
|
+
|
|
26
|
+
### Fixed
|
|
27
|
+
|
|
28
|
+
- Google Gemini, Google Vertex, Anthropic, OpenAI Completions, OpenAI Responses, OpenAI Codex, Azure OpenAI Responses and Mistral failures now record the HTTP status, and Google's provider status such as `UNAVAILABLE`, in a `provider_response_failure` diagnostic on the failed message, so retry and fallback can decide on the status rather than the message text ([#4994](https://github.com/bastani-inc/atomic/issues/4994))
|
|
29
|
+
- Fixed requests failing when the conversation holds an image in a format providers do not accept inline, such as `image/svg+xml`: every provider now sends a text placeholder naming the type instead of the image, and Bedrock no longer throws "Unknown image type" ([#4908](https://github.com/bastani-inc/atomic/issues/4908)).
|
|
30
|
+
- Fixed Google Gemini, Google Vertex, Amazon Bedrock and Azure OpenAI Responses streams ignoring `streamDeadlineMs`: a stream that stalls after its first event is now cut at the deadline, closes its connection, and fails with the retryable "stream deadline exceeded" error so retry and model fallback run instead of the turn hanging ([#4904](https://github.com/bastani-inc/atomic/issues/4904))
|
|
31
|
+
- Fixed Anthropic, Mistral, OpenAI Codex, and pi-messages streams failing or losing events when a CRLF line ending, a multibyte character, or a `data:` prefix is split across network chunks. Every stream now parses the same way however it is chunked, and the OpenAI Codex and pi-messages streams accept CRLF and CR line endings ([#4899](https://github.com/bastani-inc/atomic/issues/4899))
|
|
32
|
+
- Fixed OpenAI-compatible streams merging parallel tool calls that a server sends with the same `index` into one call with malformed arguments; a named tool call delta with a new `id` now starts its own call ([#4899](https://github.com/bastani-inc/atomic/issues/4899))
|
|
33
|
+
- Fixed Anthropic tool calls losing their input when a server sends it complete in `content_block_start` with no `input_json_delta` events; the call now keeps that input ([#4899](https://github.com/bastani-inc/atomic/issues/4899))
|
|
34
|
+
- Fixed Anthropic, OpenAI Codex, OpenAI ChatGPT, Kimi Code, and Radius sign-ins asking you to run `/login` again after a token refresh whose response carries no new refresh token, which servers that don't rotate refresh tokens may send. The refresh now keeps the existing refresh token, and a response without `expires_in` takes its expiry from the access token's JWT `exp` claim or assumes one hour, instead of refreshing on every request ([#4959](https://github.com/bastani-inc/atomic/issues/4959))
|
|
35
|
+
- Fixed Gemini 2.x on Google and Vertex rejecting a parallel tool batch when a result other than the last one contains an image: every function response of the batch now stays in one turn, in call order, and the image turns follow it ([#5048](https://github.com/bastani-inc/atomic/issues/5048))
|
|
36
|
+
- Fixed `retryAssistantCall()` and `failureRetryDelayMs()` capping a server retry hint at `RetryPolicy.maxAgentDelayMs` when `maxRetryDelayMs` is not set. An unset `maxRetryDelayMs` now caps the hint at the documented 60 seconds, so a lower agent backoff cap no longer cuts a server's requested wait short; `maxRetryDelayMs: 0` still caps it at `maxAgentDelayMs`
|
|
37
|
+
|
|
38
|
+
### Removed
|
|
39
|
+
|
|
40
|
+
- Removed the `radius` provider, its OAuth flow and models, and the build-time fetch of its catalog from radius.pi.dev. The generic `pi-messages` API stays available for custom providers ([#5174](https://github.com/bastani-inc/atomic/issues/5174))
|
|
41
|
+
|
|
7
42
|
## [0.9.88-alpha.1] - 2026-11-16
|
|
8
43
|
|
|
9
44
|
### Changed
|
|
@@ -230,8 +230,8 @@ function shouldUseServerSideFallbackBeta(model) {
|
|
|
230
230
|
* the affected thinking blocks and answers the turn instead of failing the session.
|
|
231
231
|
*
|
|
232
232
|
* This covers live prefix mismatches *between* compaction boundaries. It is not what handles
|
|
233
|
-
* compaction itself: Atomic's client-side
|
|
234
|
-
*
|
|
233
|
+
* compaction itself: Atomic's client-side compaction replaces the context with a single boundary
|
|
234
|
+
* message, so no signed thinking block survives a
|
|
235
235
|
* boundary to be replayed behind it. That is Anthropic's documented keep-tail remedy applied
|
|
236
236
|
* structurally rather than a case `drop_block` has to catch.
|
|
237
237
|
* https://platform.claude.com/docs/en/build-with-claude/preserved-thinking
|