@linxiraos/pi-catalog 1.4.13 → 1.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,8 +1,8 @@
1
1
  ## [Unreleased]
2
2
 
3
- ## [1.4.13] - 2026-11-08
3
+ ## [1.5.0] - 2026-11-09
4
4
 
5
- - Released as part of Zeta 1.4.13.
5
+ - Released as part of Zeta 1.5.0; no package-specific user-visible changes.
6
6
 
7
7
  ## [1.4.12] - 2026-11-08
8
8
 
@@ -40,12 +40,13 @@ export interface AxisDef {
40
40
  export declare const EFFORT_TIERS: readonly string[];
41
41
  /**
42
42
  * How hard agent prompts push subagent delegation for a model lineage
43
- * (`delegation-bias` axis). `eager` is the unassigned default: the prompt
44
- * actively pushes fan-out. `restrained` keeps fan-out for genuinely parallel
45
- * slices but forbids reflexive scouts and single-agent babysitting. `gated`
46
- * forbids subagents unless the user or a skill asks.
43
+ * (`delegation-bias` axis). `eager` actively pushes fan-out. `balanced`, the
44
+ * unassigned default, neither pushes nor restricts fan-out beyond a light
45
+ * nudge to explore unfamiliar code with a scout. `restrained` keeps fan-out
46
+ * for genuinely parallel slices but forbids reflexive scouts and single-agent
47
+ * babysitting. `gated` forbids subagents unless the user or a skill asks.
47
48
  */
48
- export declare const DELEGATION_BIASES: readonly ["eager", "restrained", "gated"];
49
+ export declare const DELEGATION_BIASES: readonly ["eager", "balanced", "restrained", "gated"];
49
50
  /** Narrow a KDL string to an effort tier (`Effort` ∪ `"off"`). */
50
51
  export declare function isEffortTier(value: string): value is Effort | "off";
51
52
  /** Narrow a KDL string to a thinking control mode. */
@@ -13,7 +13,7 @@ import { DELEGATION_BIASES } from "./axes.js";
13
13
  /** One of `DELEGATION_BIASES`; see that constant for the semantics of each tier. */
14
14
  export type DelegationBias = (typeof DELEGATION_BIASES)[number];
15
15
  /**
16
- * Delegation bias for a built model; `eager` when no rule assigns one.
16
+ * Delegation bias for a built model; `balanced` when no rule assigns one.
17
17
  * Callers: system-prompt and tool-description rendering in the coding agent.
18
18
  *
19
19
  * Results are cached by model object. Every cascade input is checked before a
@@ -544,6 +544,8 @@ export interface CompiledAuthProvider {
544
544
  hook: string;
545
545
  };
546
546
  allowsMissingApiKey?: boolean;
547
+ /** Login-sourced API keys use the provider's subscription quota rather than metered billing. */
548
+ loginSubscription?: boolean;
547
549
  /** Qualify credential and usage-report identity by org when an email may have multiple subscriptions. */
548
550
  orgScopedIdentity?: boolean;
549
551
  /** Environment variables carrying this provider's own OAuth bearer, excluding borrowed API-key aliases. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@linxiraos/pi-catalog",
3
- "version": "1.4.13",
3
+ "version": "1.5.0",
4
4
  "description": "Model catalog for omp: bundled model database, provider discovery descriptors, model identity, classification, and equivalence",
5
5
  "keywords": [
6
6
  "ai",
@@ -86,12 +86,12 @@
86
86
  "gen:proto": "bun scripts/generate-protocols.ts"
87
87
  },
88
88
  "dependencies": {
89
- "@linxiraos/zeta-schema": "1.4.13",
90
- "@linxiraos/pi-utils": "1.4.13"
89
+ "@linxiraos/zeta-schema": "1.5.0",
90
+ "@linxiraos/pi-utils": "1.5.0"
91
91
  },
92
92
  "devDependencies": {
93
93
  "@bgotink/kdl": "0.4.0",
94
- "@linxiraos/pi-ai": "1.4.13",
94
+ "@linxiraos/pi-ai": "1.5.0",
95
95
  "@types/bun": "1.4.4"
96
96
  },
97
97
  "engines": {
@@ -40,12 +40,13 @@ export interface AxisDef {
40
40
  export declare const EFFORT_TIERS: readonly string[];
41
41
  /**
42
42
  * How hard agent prompts push subagent delegation for a model lineage
43
- * (`delegation-bias` axis). `eager` is the unassigned default: the prompt
44
- * actively pushes fan-out. `restrained` keeps fan-out for genuinely parallel
45
- * slices but forbids reflexive scouts and single-agent babysitting. `gated`
46
- * forbids subagents unless the user or a skill asks.
43
+ * (`delegation-bias` axis). `eager` actively pushes fan-out. `balanced`, the
44
+ * unassigned default, neither pushes nor restricts fan-out beyond a light
45
+ * nudge to explore unfamiliar code with a scout. `restrained` keeps fan-out
46
+ * for genuinely parallel slices but forbids reflexive scouts and single-agent
47
+ * babysitting. `gated` forbids subagents unless the user or a skill asks.
47
48
  */
48
- export declare const DELEGATION_BIASES: readonly ["eager", "restrained", "gated"];
49
+ export declare const DELEGATION_BIASES: readonly ["eager", "balanced", "restrained", "gated"];
49
50
  /** Narrow a KDL string to an effort tier (`Effort` ∪ `"off"`). */
50
51
  export declare function isEffortTier(value: string): value is Effort | "off";
51
52
  /** Narrow a KDL string to a thinking control mode. */
@@ -58,12 +58,13 @@ export const EFFORT_TIERS: readonly string[] = [...EFFORTS, "off"];
58
58
 
59
59
  /**
60
60
  * How hard agent prompts push subagent delegation for a model lineage
61
- * (`delegation-bias` axis). `eager` is the unassigned default: the prompt
62
- * actively pushes fan-out. `restrained` keeps fan-out for genuinely parallel
63
- * slices but forbids reflexive scouts and single-agent babysitting. `gated`
64
- * forbids subagents unless the user or a skill asks.
61
+ * (`delegation-bias` axis). `eager` actively pushes fan-out. `balanced`, the
62
+ * unassigned default, neither pushes nor restricts fan-out beyond a light
63
+ * nudge to explore unfamiliar code with a scout. `restrained` keeps fan-out
64
+ * for genuinely parallel slices but forbids reflexive scouts and single-agent
65
+ * babysitting. `gated` forbids subagents unless the user or a skill asks.
65
66
  */
66
- export const DELEGATION_BIASES = ["eager", "restrained", "gated"] as const;
67
+ export const DELEGATION_BIASES = ["eager", "balanced", "restrained", "gated"] as const;
67
68
  const THINKING_MODES = [
68
69
  "effort",
69
70
  "budget",
@@ -34,7 +34,7 @@ interface DelegationBiasCacheEntry {
34
34
  const delegationBiasCache = new WeakMap<Model, DelegationBiasCacheEntry>();
35
35
 
36
36
  /**
37
- * Delegation bias for a built model; `eager` when no rule assigns one.
37
+ * Delegation bias for a built model; `balanced` when no rule assigns one.
38
38
  * Callers: system-prompt and tool-description rendering in the coding agent.
39
39
  *
40
40
  * Results are cached by model object. Every cascade input is checked before a
@@ -67,7 +67,7 @@ export function resolveDelegationBias(model: Model): DelegationBias {
67
67
  ...(identity.family !== undefined && { family: identity.family }),
68
68
  ...(identity.revision !== undefined && { revision: identity.revision }),
69
69
  }).catalog.delegationBias;
70
- const bias = isDelegationBias(resolved) ? resolved : "eager";
70
+ const bias = isDelegationBias(resolved) ? resolved : "balanced";
71
71
  delegationBiasCache.set(model, {
72
72
  provider: model.provider,
73
73
  api: model.api,
@@ -939,6 +939,7 @@ function resolveAnthropicPolicy(
939
939
  // Present as keys so models.yml `compat` can set them; unset unless a rule assigns them.
940
940
  stripThinkingHistory: undefined,
941
941
  fastMode: undefined,
942
+ disabledThinking: undefined,
942
943
  streamIdleTimeoutMs: spec.compat?.streamIdleTimeoutMs,
943
944
  };
944
945
  applyWireAxes(compat, axes.wire, "anthropic-messages");
@@ -415,6 +415,8 @@ auth "anthropic" {
415
415
 
416
416
  `org-scoped-identity #true` keeps credentials and usage reports for different organizations separate even when they share an email; absent or `#false` uses ordinary account identity. `oauth-token-env` takes one or more ordered, non-empty env names carrying this provider's own OAuth bearer. When present, availability ignores other provider-env aliases, and usage probes accept only stored OAuth credentials or the first set bearer from that list; absent providers keep the ordinary API-key env behavior.
417
417
 
418
+ `login-subscription #true` marks login-sourced API keys as subscription billing, leaving pasted and environment keys metered; absent or `#false` keeps all API keys metered.
419
+
418
420
  Login kinds:
419
421
 
420
422
  - `login "api-key" { auth-url "…"; instructions "…"; prompt "…" placeholder="…"; empty-fallback "…"; normalize "strip-bearer"; validate … }` — `validate "chat-completions" base-url= model= tolerate-model-denied= max-tokens-field= max-tokens=`, `validate "anthropic-messages" base-url= model=`, or `validate "models-endpoint" url= base-url-env= base-url-path= headers-hook=` (`base-url-path`, default `/models`, is appended to the `base-url-env` value and needs it); all accept `label=` (error-message label, defaults to `name`), `optional=#true` (only auth failures reject), and `trust-forbidden=#true` (requires `optional=#true`; a 403 no longer rejects, so only a 401 does).
@@ -4,4 +4,5 @@ auth "mistral" {
4
4
  name "Mistral"
5
5
  env "MISTRAL_API_KEY"
6
6
  login "custom" hook="mistral-vibe-sign-in"
7
+ login-subscription #true
7
8
  }
@@ -80,13 +80,17 @@ class "deepseek" {
80
80
  // DeepSeek V4.1 Flash is natively multimodal (image-text-to-text), but its
81
81
  // id carries no `vision` token, so the class-wide strip above dropped
82
82
  // attachments the model reads on every deployment without its own carve-out.
83
- // The glob also spans `-vision`/`-ocr` ids, which already set the same value
84
- // below, so the explicit priority resolves that equal-rank tie instead of
85
- // throwing AmbiguousOverlapError. Only the strip is disabled; the declared
83
+ // Keyed on the classified family/revision, not the id spelling, so dotted
84
+ // (`v4.1-flash`) and hyphenated (`v4-1-flash`) release ids both match.
85
+ // The selector also spans `-vision`/`-ocr` ids, which already set the same
86
+ // value above, so the explicit priority resolves that equal-rank tie instead
87
+ // of throwing AmbiguousOverlapError. Only the strip is disabled; the declared
86
88
  // modality stays host-derived, so endpoints whose OpenAI-compatible surface
87
89
  // rejects `image_url` keep their text-only contract.
88
- models "*v4.1-flash*" priority=10 {
89
- strip-image-input #false
90
+ family "flash" {
91
+ revision ">=4.1 <4.2" priority=10 {
92
+ strip-image-input #false
93
+ }
90
94
  }
91
95
  // V4.1 Flash is natively multimodal (vision encoder + projector, image-text
92
96
  // pre-training) but its release id carries no `vision` token to key on.
@@ -13,6 +13,24 @@ class "xai" {
13
13
  }
14
14
  }
15
15
  }
16
+ // stencil.so prices the grok-4.20 `-beta-latest` aliases at the retired
17
+ // 4.5-generation card ($2 input / $6 output) instead of the 4.20-0309
18
+ // generation they resolve to; docs.x.ai/developers/pricing lists every 0309
19
+ // variant at $1.25 input / $0.20 cached / $2.50 output below 200K prompt
20
+ // tokens. The `grok-4.20-multi-agent-0309` entry is SuperGrok's id for the
21
+ // paid `grok-4.20-multi-agent-beta-latest` row its pricing peer mirrors, so
22
+ // both surfaces carry the same card (#18404).
23
+ on "xai" "xai-oauth" {
24
+ models "grok-4.20-beta-latest-reasoning" "grok-4.20-beta-latest-non-reasoning" \
25
+ "grok-4.20-multi-agent-beta-latest" "grok-4.20-multi-agent-0309" {
26
+ cost-patch {
27
+ input 1.25
28
+ output 2.5
29
+ cache-read 0.2
30
+ cache-write 0
31
+ }
32
+ }
33
+ }
16
34
  on "aimlapi" "kilo" "nanogpt" "opencode-go" "opencode-zen" "venice" "vercel-ai-gateway" \
17
35
  "zenmux" {
18
36
  family "grok" {
@@ -41,23 +41,23 @@ provider "devin" {
41
41
  }
42
42
 
43
43
 
44
- // Devin omits cost dimensions for plan-included models on lower tiers
45
- // (PRO reports $0 for SWE-2, SWE-1.7, and GLM-5.2 High). `cost-fallback`
46
- // seeds the enterprise-tier list price only when upstream reports no
47
- // token price, so accounts whose discovery does carry dimensions keep
48
- // their real rates. None of these models publishes a cache-write rate.
44
+ // Enterprise (ACUs) fallback prices: https://docs.devin.ai/desktop/models
45
+ // (as of 2026-11-05). Seed only when upstream reports no token price.
46
+ // Self-serve SWE-2 Flash is free until 2026-12-04 18:00 UTC; SWE-2 in
47
+ // Desktop/CLI through 2026-11-30. Account-specific token rates stay intact.
49
48
 
50
- // SWE-2: enterprise promo is 75% off list through 2026-12-31; list
51
- // pricing ($3/$15, $0.30 cache read) applies from 2027-01-01.
52
- models "swe-2*" {
49
+ // SWE-2 promo ends at 2027-01-01 08:00 UTC (midnight Pacific after 2026-12-31).
50
+ // residue: the family's logical id plus its raw effort uids, which stay
51
+ // standalone when a row arrives without `modelFamilyMetadata`.
52
+ models "swe-2" "swe-2-medium" "swe-2-high" "swe-2-max" {
53
53
  cost-fallback {
54
- input 0.75
55
- output 3.75
56
- cache-read 0.075
54
+ input 0.5
55
+ output 2.5
56
+ cache-read 0.05
57
57
  cache-write 0
58
58
  effective-rates {
59
59
  list-price {
60
- effective-from "2027-01-01T00:00:00Z"
60
+ effective-from "2027-01-01T08:00:00Z"
61
61
  input 3
62
62
  output 15
63
63
  cache-read 0.3
@@ -67,6 +67,42 @@ provider "devin" {
67
67
  }
68
68
  }
69
69
 
70
+ // SWE-2 Fast (wire uids `swe-2-<effort>-lightning`): the docs publish no
71
+ // price, but GetCliModelConfigs reports $1 input / $0.10 cached input /
72
+ // $5 output (2026-11-06), twice SWE-2's promo rate. No end date or list
73
+ // price is published for it.
74
+ // residue: the logical fast lane plus its raw uids, as for SWE-2 above.
75
+ models "swe-2-fast" "swe-2-medium-lightning" "swe-2-high-lightning" "swe-2-max-lightning" {
76
+ cost-fallback {
77
+ input 1
78
+ output 5
79
+ cache-read 0.1
80
+ cache-write 0
81
+ }
82
+ }
83
+
84
+ // SWE-2 Flash: enterprise promo is 25% off until 2026-11-18 18:00 UTC.
85
+ // All three variants then use the same list price. Discovery exposes the
86
+ // family as `swe-2-flash`, distinct from SWE-2 and Fusion pairings.
87
+ // residue: the logical id plus its raw effort uids, as for SWE-2 above.
88
+ models "swe-2-flash" "swe-2-flash-medium" "swe-2-flash-high" "swe-2-flash-max" {
89
+ cost-fallback {
90
+ input 0.075
91
+ output 0.375
92
+ cache-read 0.0075
93
+ cache-write 0.09375
94
+ effective-rates {
95
+ list-price {
96
+ effective-from "2026-11-18T18:00:00Z"
97
+ input 0.1
98
+ output 0.5
99
+ cache-read 0.01
100
+ cache-write 0.125
101
+ }
102
+ }
103
+ }
104
+ }
105
+
70
106
  // SWE-1.7 and GLM-5.2 High: plan-included on PRO, no published promo
71
107
  // schedule — enterprise list is the only published per-token price.
72
108
  models "swe-1-7" "swe-1-7-medium" {
@@ -91,7 +127,7 @@ provider "devin" {
91
127
  // `GetCliModelConfigs` and the v2alpha models endpoint carry none. Chat
92
128
  // usage reports cache-write tokens for Claude and GPT-5.6+ (Gemini
93
129
  // reports none), and the card bills them at 1.25x input. Earlier GPT,
94
- // Grok, Kimi, GLM, DeepSeek, and SWE rows publish no cache-write rate.
130
+ // Grok, Kimi, GLM, DeepSeek, and earlier SWE rows publish no cache-write rate.
95
131
  // The GPT selector stops at the next major generation, like the tiers
96
132
  // below, so an unpublished generation records no cache-write price.
97
133
  class "anthropic" {