@oh-my-pi/pi-catalog 18.14.0 → 18.14.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 CHANGED
@@ -2,6 +2,18 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [18.14.1] - 2026-10-31
6
+
7
+ ### Changed
8
+
9
+ - Clamping a requested thinking effort now resolves through the model's `effortMap` alias first, so the request lands on the tier the model serves instead of the nearest lower one ([#17395](https://github.com/can1357/oh-my-pi/pull/17395) by [@Maziar123](https://github.com/Maziar123))
10
+ - Long image-heavy conversations on the official Anthropic API now keep up to 120 MB of inline images before evicting older ones, following the Messages API request limit increase from 32 MB to 128 MB
11
+ - The official Anthropic API now records its 128 MB request limit (`request-body-byte-limit`), so the newest message's images can use the 8 MB reserve and long text cannot push images past the limit ([#17492](https://github.com/can1357/oh-my-pi/pull/17492) by [@will-bogusz](https://github.com/will-bogusz))
12
+
13
+ ### Fixed
14
+
15
+ - Fixed Cursor's DeepSeek V4.1 Flash 1017 reporting zero cost; every effort level now bills at Cursor's API rate of $0.30/$1.20 per million tokens, with cache reads at $0.006 ([#17390](https://github.com/can1357/oh-my-pi/pull/17390) by [@eggpeat](https://github.com/eggpeat))
16
+
5
17
  ## [18.14.0] - 2026-10-29
6
18
 
7
19
  ### Breaking Changes
@@ -2514,6 +2514,9 @@ export interface InteractionUpdate extends ProtoMessage {
2514
2514
  } | {
2515
2515
  case: "stepCompleted";
2516
2516
  value: StepCompletedUpdate;
2517
+ } | {
2518
+ case: "toolRequestsListed";
2519
+ value: ToolRequestsListedUpdate;
2517
2520
  };
2518
2521
  }
2519
2522
  export declare const InteractionUpdateSchema: MessageCodec<InteractionUpdate>;
@@ -5318,6 +5321,11 @@ export interface ToolCallStartedUpdate extends ProtoMessage {
5318
5321
  modelCallId: string;
5319
5322
  }
5320
5323
  export declare const ToolCallStartedUpdateSchema: MessageCodec<ToolCallStartedUpdate>;
5324
+ /** Cursor agent message agent.v1.ToolRequestsListedUpdate. */
5325
+ export interface ToolRequestsListedUpdate extends ProtoMessage {
5326
+ callCount: number;
5327
+ }
5328
+ export declare const ToolRequestsListedUpdateSchema: MessageCodec<ToolRequestsListedUpdate>;
5321
5329
  /** Cursor agent message agent.v1.TruncatedToolCall. */
5322
5330
  export interface TruncatedToolCall extends ProtoMessage {
5323
5331
  originalStepBlobId: Uint8Array;
@@ -32,6 +32,10 @@ export declare function withoutUnverifiedThinking<T extends {
32
32
  /**
33
33
  * Clamps a requested thinking level against explicit model metadata.
34
34
  *
35
+ * An unserved level first follows `thinking.effortMap` when the map sends it to
36
+ * a served tier that reaches the wire unchanged (a gateway answering `medium`
37
+ * as `high`); otherwise it climbs down to the nearest lower tier.
38
+ *
35
39
  * Non-reasoning models always resolve to `undefined`.
36
40
  */
37
41
  export declare function clampThinkingLevelForModel<TApi extends Api>(model: ApiModel<TApi> | undefined, requested: Effort | undefined): Effort | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oh-my-pi/pi-catalog",
3
- "version": "18.14.0",
3
+ "version": "18.14.1",
4
4
  "description": "Model catalog for omp: bundled model database, provider discovery descriptors, model identity, classification, and equivalence",
5
5
  "keywords": [
6
6
  "ai",
@@ -88,12 +88,12 @@
88
88
  "gen:proto": "bun scripts/generate-protocols.ts"
89
89
  },
90
90
  "dependencies": {
91
- "@oh-my-pi/omptype": "18.14.0",
92
- "@oh-my-pi/pi-utils": "18.14.0"
91
+ "@oh-my-pi/omptype": "18.14.1",
92
+ "@oh-my-pi/pi-utils": "18.14.1"
93
93
  },
94
94
  "devDependencies": {
95
95
  "@bgotink/kdl": "0.4.0",
96
- "@oh-my-pi/pi-ai": "18.14.0",
96
+ "@oh-my-pi/pi-ai": "18.14.1",
97
97
  "@types/bun": "^1.3.14"
98
98
  },
99
99
  "engines": {
@@ -502,8 +502,9 @@ export const AXES: Readonly<Record<string, AxisDef>> = {
502
502
  "image-max-edge": { key: "imageMaxEdge", set: "catalog", shape: "scalar" },
503
503
  "inline-image-byte-budget": { key: "inlineImageByteBudget", set: "catalog", shape: "scalar" },
504
504
  /**
505
- * Largest request body the host accepts. Where set, the inline-image byte clamp keeps the newest user message's
506
- * and newest tool result's images past `inline-image-byte-budget` while they alone fit this limit.
505
+ * Largest request body the host accepts. Where set, the inline-image byte clamp keeps images within what the
506
+ * request's other bytes leave of it, and keeps the newest user message's and newest tool result's images past
507
+ * `inline-image-byte-budget` while they fit that room.
507
508
  */
508
509
  "request-body-byte-limit": { key: "requestBodyByteLimit", set: "catalog", shape: "scalar" },
509
510
  /**
@@ -227,7 +227,7 @@ One object axis carries a computed form: `long-context-cost` accepts either the
227
227
 
228
228
  `inline-image-byte-budget` caps retained base64 image characters for a deployment's request body. It leaves room for tool schemas and text beneath the provider's body-size limit; the coding agent reads it through `resolveInlineImageByteBudget` before sending live history, and snapcompact gives its archive frames half of it (`frameDataBytesBudget`). The budget applies only while the request reaches the host the rules describe (the Anthropic API, first-party OpenAI, the Codex backend at its default URL, DeepSeek's API, or Factory Droid's own global or EU API host), which callers decide with pi-ai's `reachesBudgetedHost`: `compat.officialEndpoint` for the configured `baseUrl`, for first-party Anthropic models also the `ANTHROPIC_BASE_URL` or Foundry `FOUNDRY_BASE_URL` reroute applied at request time, and for Factory Droid models the `baseUrl` origin. A custom or rerouted endpoint imposes its own body limit.
229
229
 
230
- `request-body-byte-limit` is the largest request body the host accepts (Factory Droid's hosted routes: 4,500,000 bytes), under the same gate. Where it is set, the byte clamp keeps the inline images of the newest user message and then of the newest image-bearing tool result even past `inline-image-byte-budget`, each only while the kept images fit the limit less the request's other serialized bytes, and evicts older images instead; read through `resolveRequestBodyByteLimit`.
230
+ `request-body-byte-limit` is the largest request body the host accepts (Factory Droid's hosted routes: 4,500,000 bytes; Anthropic's Messages API: 128,000,000 bytes), under the same gate. Where it is set, the byte clamp also keeps inline images within what the request's other serialized bytes leave of the limit, and keeps the inline images of the newest user message and then of the newest image-bearing tool result even past `inline-image-byte-budget`, each only while the kept images fit the limit less the request's other serialized bytes, and evicts older images instead; read through `resolveRequestBodyByteLimit`.
231
231
 
232
232
  `catalog-endpoint-budgets #true` makes these host budgets apply whenever a request reaches the provider's own catalog endpoint (an unset `baseUrl`, or an `endpoint-hosts` host; see `isCatalogEndpointUrl`), for a hosted gateway such as Factory Droid whose compat names no official endpoint, or a first-party provider such as DeepSeek whose `openai-completions` compat resolves no `officialEndpoint`. Unassigned, they apply only on the official endpoint.
233
233
 
@@ -78,12 +78,16 @@ provider "anthropic" {
78
78
  // Code's `CLAUDE_CODE_DISABLE_EXPERIMENTAL_BETAS` kill switch for gateways
79
79
  // that reject experimental beta fields.
80
80
  honors-claude-code-beta-kill-switch #true
81
- // Messages requests cap at 32 MB. Reserve 8 MB for text, tools, and JSON
82
- // framing when retaining inline base64 images in a long conversation.
83
- // Applied only on the official endpoint; a custom baseUrl has its own limit.
81
+ // Messages requests cap at 128 MB. Reserve 8 MB for text, tools, and JSON
82
+ // framing when retaining inline base64 images in a long conversation; the
83
+ // body limit keeps images within what the other bytes leave, and lets the
84
+ // newest user message's and tool result's images use the reserve.
85
+ // Applied only on the official endpoint; a custom baseUrl has its own limit
86
+ // (Bedrock 20 MB; Vertex, Foundry, and Claude Platform on AWS 30-32 MB).
84
87
  // https://platform.claude.com/docs/en/api/overview#request-size-limits
85
88
  on-api "anthropic-messages" {
86
- inline-image-byte-budget 24000000
89
+ inline-image-byte-budget 120000000
90
+ request-body-byte-limit 128000000
87
91
  }
88
92
  // The official endpoint carries at most 600 images and documents per
89
93
  // request, 100 on models with a 200k-token window: every Claude line before
@@ -387,6 +387,16 @@ provider "cursor" {
387
387
  cache-write 0
388
388
  }
389
389
  }
390
+ // DeepSeek V4.1 Flash 1017: $0.30/$1.20, cache read $0.006, no write fee.
391
+ // The bare id and every reasoning-effort wire id share one card.
392
+ models "deepseek-v41-flash-1017*" {
393
+ cost-patch {
394
+ input 0.3
395
+ output 1.2
396
+ cache-read 0.006
397
+ cache-write 0
398
+ }
399
+ }
390
400
  // Gemini 3 Flash: $0.50/$3.00, cache read $0.05.
391
401
  models "gemini-3-flash" {
392
402
  cost-patch {
@@ -7,8 +7,8 @@ provider "deepseek" {
7
7
 
8
8
  // DeepSeek's vision guide documents 600 images per request and a 48 MiB
9
9
  // request body. OMP reserves 8 MiB for text, tools, and the JSON envelope
10
- // (48 MiB - 8 MiB = 40 MiB); Anthropic's 24,000,000-byte image budget under
11
- // its 32 MB body uses an 8 MB reserve. DeepSeek documents MiB, so this uses
10
+ // (48 MiB - 8 MiB = 40 MiB); Anthropic's 120,000,000-byte image budget under
11
+ // its 128 MB body uses an 8 MB reserve. DeepSeek documents MiB, so this uses
12
12
  // an 8 MiB reserve. The split is OMP's conservative margin, not a
13
13
  // DeepSeek-documented figure. A custom baseUrl keeps the conservative
14
14
  // catalog floor because the gateway's own limits are unknown.
@@ -16,7 +16,7 @@ provider "openai-codex" {
16
16
 
17
17
  // Policy budgets: the Codex backend documents no request-size or image
18
18
  // limit, and requests with several thousand images fail mid-stream at
19
- // random. Inline images keep Anthropic's 24 MB; the official endpoint's
19
+ // random. Inline images keep a 24 MB budget; the official endpoint's
20
20
  // image count stays well below those failures. A custom baseUrl keeps 200.
21
21
  inline-image-byte-budget 24000000
22
22
  image-count-budget 200