@sentropic/llm-mesh 0.24.1 → 0.26.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.
Files changed (99) hide show
  1. package/README.md +192 -0
  2. package/dist/catalog.d.ts +92 -0
  3. package/dist/catalog.d.ts.map +1 -1
  4. package/dist/catalog.js +47 -0
  5. package/dist/catalog.js.map +1 -1
  6. package/dist/enrollment/claude-code.d.ts +27 -5
  7. package/dist/enrollment/claude-code.d.ts.map +1 -1
  8. package/dist/enrollment/claude-code.js +224 -10
  9. package/dist/enrollment/claude-code.js.map +1 -1
  10. package/dist/enrollment/codex.d.ts +7 -0
  11. package/dist/enrollment/codex.d.ts.map +1 -1
  12. package/dist/enrollment/codex.js +74 -19
  13. package/dist/enrollment/codex.js.map +1 -1
  14. package/dist/enrollment/index.d.ts +1 -1
  15. package/dist/enrollment/index.d.ts.map +1 -1
  16. package/dist/enrollment/pkce.js +1 -1
  17. package/dist/errors.d.ts +19 -0
  18. package/dist/errors.d.ts.map +1 -1
  19. package/dist/errors.js +51 -4
  20. package/dist/errors.js.map +1 -1
  21. package/dist/execution-features.d.ts +34 -0
  22. package/dist/execution-features.d.ts.map +1 -0
  23. package/dist/execution-features.js +84 -0
  24. package/dist/execution-features.js.map +1 -0
  25. package/dist/generated-model-council.d.ts +2 -2
  26. package/dist/generated-model-council.d.ts.map +1 -1
  27. package/dist/generated-model-council.js +5 -1
  28. package/dist/generated-model-council.js.map +1 -1
  29. package/dist/index.d.ts +4 -0
  30. package/dist/index.d.ts.map +1 -1
  31. package/dist/index.js +4 -0
  32. package/dist/index.js.map +1 -1
  33. package/dist/native-messages.d.ts +130 -0
  34. package/dist/native-messages.d.ts.map +1 -0
  35. package/dist/native-messages.js +66 -0
  36. package/dist/native-messages.js.map +1 -0
  37. package/dist/providers.d.ts +5 -5
  38. package/dist/providers.d.ts.map +1 -1
  39. package/dist/providers.js +12 -5
  40. package/dist/providers.js.map +1 -1
  41. package/dist/responses-wire.d.ts +76 -0
  42. package/dist/responses-wire.d.ts.map +1 -0
  43. package/dist/responses-wire.js +35 -0
  44. package/dist/responses-wire.js.map +1 -0
  45. package/dist/route-attempt.d.ts +4 -0
  46. package/dist/route-attempt.d.ts.map +1 -1
  47. package/dist/route-attempt.js +8 -1
  48. package/dist/route-attempt.js.map +1 -1
  49. package/dist/route-health.d.ts +11 -0
  50. package/dist/route-health.d.ts.map +1 -1
  51. package/dist/route-health.js +32 -0
  52. package/dist/route-health.js.map +1 -1
  53. package/dist/route-planner-state.d.ts +33 -2
  54. package/dist/route-planner-state.d.ts.map +1 -1
  55. package/dist/route-planner-state.js +20 -1
  56. package/dist/route-planner-state.js.map +1 -1
  57. package/dist/route-planner.d.ts +21 -1
  58. package/dist/route-planner.d.ts.map +1 -1
  59. package/dist/route-planner.js +112 -33
  60. package/dist/route-planner.js.map +1 -1
  61. package/dist/route-quote.d.ts +16 -2
  62. package/dist/route-quote.d.ts.map +1 -1
  63. package/dist/route-quote.js +31 -5
  64. package/dist/route-quote.js.map +1 -1
  65. package/dist/route-selection.d.ts +13 -0
  66. package/dist/route-selection.d.ts.map +1 -1
  67. package/dist/route-selection.js +30 -5
  68. package/dist/route-selection.js.map +1 -1
  69. package/dist/routing-contracts.d.ts +42 -3
  70. package/dist/routing-contracts.d.ts.map +1 -1
  71. package/dist/routing-targets.d.ts +26 -0
  72. package/dist/routing-targets.d.ts.map +1 -1
  73. package/dist/routing-targets.js +96 -23
  74. package/dist/routing-targets.js.map +1 -1
  75. package/dist/service/facade.d.ts +3 -0
  76. package/dist/service/facade.d.ts.map +1 -1
  77. package/dist/service/facade.js +7 -1
  78. package/dist/service/facade.js.map +1 -1
  79. package/dist/service/local-account-transport-service.d.ts +18 -0
  80. package/dist/service/local-account-transport-service.d.ts.map +1 -1
  81. package/dist/service/local-account-transport-service.js +284 -46
  82. package/dist/service/local-account-transport-service.js.map +1 -1
  83. package/dist/transport/claude-code-runtime-client.d.ts +88 -0
  84. package/dist/transport/claude-code-runtime-client.d.ts.map +1 -0
  85. package/dist/transport/claude-code-runtime-client.js +305 -0
  86. package/dist/transport/claude-code-runtime-client.js.map +1 -0
  87. package/dist/transport/codex-runtime-client.d.ts.map +1 -1
  88. package/dist/transport/codex-runtime-client.js +24 -4
  89. package/dist/transport/codex-runtime-client.js.map +1 -1
  90. package/dist/transport/codex-runtime-wire.d.ts.map +1 -1
  91. package/dist/transport/codex-runtime-wire.js +131 -27
  92. package/dist/transport/codex-runtime-wire.js.map +1 -1
  93. package/dist/transport/mistral-runtime-client.d.ts.map +1 -1
  94. package/dist/transport/mistral-runtime-client.js +191 -9
  95. package/dist/transport/mistral-runtime-client.js.map +1 -1
  96. package/dist/transport/muse-runtime-client.d.ts.map +1 -1
  97. package/dist/transport/muse-runtime-client.js +221 -10
  98. package/dist/transport/muse-runtime-client.js.map +1 -1
  99. package/package.json +1 -1
@@ -0,0 +1,34 @@
1
+ /**
2
+ * Execution features (spec §16.3): request requirements finer than the
3
+ * existing `requiredCapabilities`, derived by the gateway from validated
4
+ * Responses input — never from a caller-supplied feature list:
5
+ * named/parallel tool control, strict schema, structured output, reasoning
6
+ * controls, native reasoning replay, verbosity and an explicit output
7
+ * ceiling.
8
+ *
9
+ * This module holds capability facts only: the feature taxonomy, the
10
+ * mesh-known per-transport support table and one pure predicate. It copies
11
+ * no route map (keyed by transport, never by model, account or affinity).
12
+ * Unknown support is not support: a transport with no proven declaration
13
+ * for a required feature is ineligible, before acquisition.
14
+ *
15
+ * Two taxonomy items are bounded extensions from pinned CLI captures
16
+ * (spec §16.9): `reasoning-context` (Codex `reasoning.context`, a
17
+ * server-side retention semantic only native Codex execution can honor)
18
+ * and `custom-tools` (Codex freeform tools, carried opaquely for native
19
+ * execution only). Translated adapters never declare them.
20
+ */
21
+ export type ExecutionFeature = 'named-tool-choice' | 'parallel-tool-control' | 'strict-schema' | 'structured-output' | 'reasoning-controls' | 'reasoning-context' | 'custom-tools' | 'native-reasoning-replay' | 'verbosity' | 'explicit-output-ceiling';
22
+ export declare const EXECUTION_FEATURES: readonly ExecutionFeature[];
23
+ /** Mesh-known support for a transport; empty when unknown (fail closed). */
24
+ export declare const declaredExecutionFeatures: (transportProviderId: string) => readonly ExecutionFeature[];
25
+ /**
26
+ * Pure eligibility of one actual model/transport pair. Shared by planning
27
+ * and quoting, including quote identity/revalidation:
28
+ * - no required features: eligible (no behavior change for existing wires);
29
+ * - unpinned transport: kept — the plan-time account check decides;
30
+ * - pinned transport: every required feature must be in the trusted
31
+ * declaration (per-account override when supplied, else the mesh table).
32
+ */
33
+ export declare const transportSupportsExecutionFeatures: (transportProviderId: string | undefined, required: readonly ExecutionFeature[] | undefined, declared?: readonly ExecutionFeature[] | undefined) => boolean;
34
+ //# sourceMappingURL=execution-features.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"execution-features.d.ts","sourceRoot":"","sources":["../src/execution-features.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,MAAM,MAAM,gBAAgB,GACxB,mBAAmB,GACnB,uBAAuB,GACvB,eAAe,GACf,mBAAmB,GACnB,oBAAoB,GACpB,mBAAmB,GACnB,cAAc,GACd,yBAAyB,GACzB,WAAW,GACX,yBAAyB,CAAC;AAE9B,eAAO,MAAM,kBAAkB,EAAE,SAAS,gBAAgB,EAWzD,CAAC;AAoCF,4EAA4E;AAC5E,eAAO,MAAM,yBAAyB,wBACf,MAAM,KAC1B,SAAS,gBAAgB,EAC6B,CAAC;AAE1D;;;;;;;GAOG;AACH,eAAO,MAAM,kCAAkC,wBACxB,MAAM,GAAG,SAAS,YAC7B,SAAS,gBAAgB,EAAE,GAAG,SAAS,aACtC,SAAS,gBAAgB,EAAE,GAAG,SAAS,KACjD,OAOF,CAAC"}
@@ -0,0 +1,84 @@
1
+ /**
2
+ * Execution features (spec §16.3): request requirements finer than the
3
+ * existing `requiredCapabilities`, derived by the gateway from validated
4
+ * Responses input — never from a caller-supplied feature list:
5
+ * named/parallel tool control, strict schema, structured output, reasoning
6
+ * controls, native reasoning replay, verbosity and an explicit output
7
+ * ceiling.
8
+ *
9
+ * This module holds capability facts only: the feature taxonomy, the
10
+ * mesh-known per-transport support table and one pure predicate. It copies
11
+ * no route map (keyed by transport, never by model, account or affinity).
12
+ * Unknown support is not support: a transport with no proven declaration
13
+ * for a required feature is ineligible, before acquisition.
14
+ *
15
+ * Two taxonomy items are bounded extensions from pinned CLI captures
16
+ * (spec §16.9): `reasoning-context` (Codex `reasoning.context`, a
17
+ * server-side retention semantic only native Codex execution can honor)
18
+ * and `custom-tools` (Codex freeform tools, carried opaquely for native
19
+ * execution only). Translated adapters never declare them.
20
+ */
21
+ export const EXECUTION_FEATURES = [
22
+ 'named-tool-choice',
23
+ 'parallel-tool-control',
24
+ 'strict-schema',
25
+ 'structured-output',
26
+ 'reasoning-controls',
27
+ 'reasoning-context',
28
+ 'custom-tools',
29
+ 'native-reasoning-replay',
30
+ 'verbosity',
31
+ 'explicit-output-ceiling',
32
+ ];
33
+ /**
34
+ * Mesh-known execution support per account transport. Populated only with
35
+ * proven adapter controls as their fixes land with tests (D16-C); a
36
+ * transport absent here has unknown support and is ineligible for any
37
+ * required feature. Never a model route map — transport keys only.
38
+ *
39
+ * D16-C proofs: Codex projects named choice, parallel control, reasoning
40
+ * (including `reasoning.context`), strict schemas, `text.verbosity`,
41
+ * `prompt_cache_key`, custom tools with their namespace and completed
42
+ * reasoning items natively (it cannot enforce an explicit output ceiling —
43
+ * no `max_output_tokens` slot, spec §16.4). The translated Chat clients
44
+ * project named choice and parallel control with tests; Mistral
45
+ * additionally forwards the Vibe-proven `reasoning_effort` slot. Meta has
46
+ * no proven reasoning slot on the Chat egress (spec §16.4, R5-MAJ-1):
47
+ * unauthenticated probes are auth-first (401 for every variant), Meta 400s
48
+ * unknown params (`max_output_tokens` precedent), and the binary
49
+ * `reasoningEffort` belongs to the native TBH `/responses` transport, not
50
+ * this OpenAI-compat shim — so `muse` declares no `reasoning-controls` and
51
+ * reasoning requests fail closed until a slot is proven by an authenticated
52
+ * probe. `max_tokens` is projected, so `explicit-output-ceiling` holds.
53
+ * Both translated clients forward the validated `strict` flag on function
54
+ * tools (standard OpenAI function shape); a provider that rejects it fails
55
+ * visibly as a provider 400, never as a silent drop.
56
+ */
57
+ const TRANSPORT_EXECUTION_FEATURES = {
58
+ codex: ['named-tool-choice', 'parallel-tool-control', 'reasoning-controls', 'strict-schema',
59
+ 'reasoning-context', 'custom-tools', 'verbosity'],
60
+ muse: ['named-tool-choice', 'parallel-tool-control', 'explicit-output-ceiling',
61
+ 'strict-schema'],
62
+ 'mistral-vibe': ['named-tool-choice', 'parallel-tool-control', 'reasoning-controls', 'strict-schema'],
63
+ };
64
+ /** Mesh-known support for a transport; empty when unknown (fail closed). */
65
+ export const declaredExecutionFeatures = (transportProviderId) => TRANSPORT_EXECUTION_FEATURES[transportProviderId] ?? [];
66
+ /**
67
+ * Pure eligibility of one actual model/transport pair. Shared by planning
68
+ * and quoting, including quote identity/revalidation:
69
+ * - no required features: eligible (no behavior change for existing wires);
70
+ * - unpinned transport: kept — the plan-time account check decides;
71
+ * - pinned transport: every required feature must be in the trusted
72
+ * declaration (per-account override when supplied, else the mesh table).
73
+ */
74
+ export const transportSupportsExecutionFeatures = (transportProviderId, required, declared) => {
75
+ if (!required || required.length === 0)
76
+ return true;
77
+ if (transportProviderId === undefined)
78
+ return true;
79
+ const support = declared
80
+ ?? TRANSPORT_EXECUTION_FEATURES[transportProviderId]
81
+ ?? [];
82
+ return required.every((feature) => support.includes(feature));
83
+ };
84
+ //# sourceMappingURL=execution-features.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"execution-features.js","sourceRoot":"","sources":["../src/execution-features.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAcH,MAAM,CAAC,MAAM,kBAAkB,GAAgC;IAC7D,mBAAmB;IACnB,uBAAuB;IACvB,eAAe;IACf,mBAAmB;IACnB,oBAAoB;IACpB,mBAAmB;IACnB,cAAc;IACd,yBAAyB;IACzB,WAAW;IACX,yBAAyB;CAC1B,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,4BAA4B,GAE9B;IACF,KAAK,EAAE,CAAC,mBAAmB,EAAE,uBAAuB,EAAE,oBAAoB,EAAE,eAAe;QACzF,mBAAmB,EAAE,cAAc,EAAE,WAAW,CAAC;IACnD,IAAI,EAAE,CAAC,mBAAmB,EAAE,uBAAuB,EAAE,yBAAyB;QAC5E,eAAe,CAAC;IAClB,cAAc,EAAE,CAAC,mBAAmB,EAAE,uBAAuB,EAAE,oBAAoB,EAAE,eAAe,CAAC;CACtG,CAAC;AAEF,4EAA4E;AAC5E,MAAM,CAAC,MAAM,yBAAyB,GAAG,CACvC,mBAA2B,EACE,EAAE,CAC/B,4BAA4B,CAAC,mBAAmB,CAAC,IAAI,EAAE,CAAC;AAE1D;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,kCAAkC,GAAG,CAChD,mBAAuC,EACvC,QAAiD,EACjD,QAAkD,EACzC,EAAE;IACX,IAAI,CAAC,QAAQ,IAAI,QAAQ,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,IAAI,CAAC;IACpD,IAAI,mBAAmB,KAAK,SAAS;QAAE,OAAO,IAAI,CAAC;IACnD,MAAM,OAAO,GAAG,QAAQ;WACnB,4BAA4B,CAAC,mBAAmB,CAAC;WACjD,EAAE,CAAC;IACR,OAAO,QAAQ,CAAC,KAAK,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC;AAChE,CAAC,CAAC"}
@@ -1,10 +1,10 @@
1
1
  export declare const GENERATED_MODEL_COUNCIL_SOURCE: {
2
2
  readonly revision: "2026-10-07.1";
3
- readonly digest: "sha256:d5dddbf432757b74860febd7bd8721d343a08d804b747e09b2d712d56a78da7e";
3
+ readonly digest: "sha256:7b77e4f444f9ee6cfaf69ac320a6ac264b24bc527a518e9d2e795acdccc6814a";
4
4
  readonly expiresAt: "2027-03-03T00:00:00.000Z";
5
5
  readonly reason: "No pinned benchmark evidence authorizes automatic substitution.";
6
6
  readonly reviewer: "GPT-6.1 Sol catalog owner directive";
7
7
  readonly provenance: "feat/llm-mesh-mistral-vibe-glm53 owner task; inherited capabilities unverified; no benchmark evidence";
8
- readonly excludedModelKeys: readonly ["anthropic:claude-fable-5", "anthropic:claude-fable-5-1", "anthropic:claude-opus-4-8", "anthropic:claude-opus-5", "anthropic:claude-sonnet-5", "cohere:command-a-03-2025", "cohere:command-a-reasoning-08-2025", "gcp:anthropic/claude-opus-4-6@gcp", "gcp:anthropic/claude-sonnet-4-6@gcp", "gcp:google/gemini-3.1-flash-lite@gcp", "gcp:google/gemini-3.5-flash@gcp", "gemini:gemini-3.1-flash-lite", "gemini:gemini-3.5-flash", "gemini:gemini-3.7-flash", "gemini:gemini-3.8-flash", "mistral:magistral-medium-2509", "mistral:mistral-large-4", "mistral:mistral-small-2603", "mistral:zai-glm-5-3", "muse:muse-spark-1.3", "muse:muse-spark-1.3-contributor", "openai:gpt-4.1-nano", "openai:gpt-5.4-nano", "openai:gpt-5.5", "openai:gpt-5.6-luna", "openai:gpt-5.6-sol", "openai:gpt-5.6-terra", "openai:gpt-6-astra", "openai:gpt-6-luna", "openai:gpt-6-sol", "openai:gpt-6.1-sol"];
8
+ readonly excludedModelKeys: readonly ["anthropic:claude-fable-5", "anthropic:claude-fable-5-1", "anthropic:claude-opus-4-8", "anthropic:claude-opus-5", "anthropic:claude-sonnet-5", "cohere:command-a-03-2025", "cohere:command-a-reasoning-08-2025", "gcp:anthropic/claude-opus-4-6@gcp", "gcp:anthropic/claude-sonnet-4-6@gcp", "gcp:google/gemini-3.1-flash-lite@gcp", "gcp:google/gemini-3.5-flash@gcp", "gemini:gemini-3.1-flash-lite", "gemini:gemini-3.5-flash", "gemini:gemini-3.7-flash", "gemini:gemini-3.8-flash", "gemini:gemini-4-argon", "mistral:magistral-medium-2509", "mistral:mistral-large-4", "mistral:mistral-medium-3.5", "mistral:mistral-small-2603", "mistral:zai-glm-5-3", "muse:muse-spark-1.3", "muse:muse-spark-1.3-contributor", "muse:muse-wonder-1.0", "muse:muse-wonder-full-1.0", "openai:gpt-4.1-nano", "openai:gpt-5.4-nano", "openai:gpt-5.5", "openai:gpt-5.6-luna", "openai:gpt-5.6-sol", "openai:gpt-5.6-terra", "openai:gpt-6-astra", "openai:gpt-6-luna", "openai:gpt-6-sol", "openai:gpt-6.1-sol"];
9
9
  };
10
10
  //# sourceMappingURL=generated-model-council.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"generated-model-council.d.ts","sourceRoot":"","sources":["../src/generated-model-council.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,8BAA8B;;;;;;;;CAwCjC,CAAC"}
1
+ {"version":3,"file":"generated-model-council.d.ts","sourceRoot":"","sources":["../src/generated-model-council.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,8BAA8B;;;;;;;;CA4CjC,CAAC"}
@@ -1,7 +1,7 @@
1
1
  // Generated by make refresh-llm-model-equivalences. Do not edit.
2
2
  export const GENERATED_MODEL_COUNCIL_SOURCE = {
3
3
  revision: "2026-10-07.1",
4
- digest: "sha256:d5dddbf432757b74860febd7bd8721d343a08d804b747e09b2d712d56a78da7e",
4
+ digest: "sha256:7b77e4f444f9ee6cfaf69ac320a6ac264b24bc527a518e9d2e795acdccc6814a",
5
5
  expiresAt: "2027-03-03T00:00:00.000Z",
6
6
  reason: "No pinned benchmark evidence authorizes automatic substitution.",
7
7
  reviewer: "GPT-6.1 Sol catalog owner directive",
@@ -22,12 +22,16 @@ export const GENERATED_MODEL_COUNCIL_SOURCE = {
22
22
  "gemini:gemini-3.5-flash",
23
23
  "gemini:gemini-3.7-flash",
24
24
  "gemini:gemini-3.8-flash",
25
+ "gemini:gemini-4-argon",
25
26
  "mistral:magistral-medium-2509",
26
27
  "mistral:mistral-large-4",
28
+ "mistral:mistral-medium-3.5",
27
29
  "mistral:mistral-small-2603",
28
30
  "mistral:zai-glm-5-3",
29
31
  "muse:muse-spark-1.3",
30
32
  "muse:muse-spark-1.3-contributor",
33
+ "muse:muse-wonder-1.0",
34
+ "muse:muse-wonder-full-1.0",
31
35
  "openai:gpt-4.1-nano",
32
36
  "openai:gpt-5.4-nano",
33
37
  "openai:gpt-5.5",
@@ -1 +1 @@
1
- {"version":3,"file":"generated-model-council.js","sourceRoot":"","sources":["../src/generated-model-council.ts"],"names":[],"mappings":"AAAA,iEAAiE;AACjE,MAAM,CAAC,MAAM,8BAA8B,GAAG;IAC5C,QAAQ,EAAE,cAAc;IACxB,MAAM,EAAE,yEAAyE;IACjF,SAAS,EAAE,0BAA0B;IACrC,MAAM,EAAE,iEAAiE;IACzE,QAAQ,EAAE,qCAAqC;IAC/C,UAAU,EAAE,uGAAuG;IACnH,iBAAiB,EAAE;QACjB,0BAA0B;QAC1B,4BAA4B;QAC5B,2BAA2B;QAC3B,yBAAyB;QACzB,2BAA2B;QAC3B,0BAA0B;QAC1B,oCAAoC;QACpC,mCAAmC;QACnC,qCAAqC;QACrC,sCAAsC;QACtC,iCAAiC;QACjC,8BAA8B;QAC9B,yBAAyB;QACzB,yBAAyB;QACzB,yBAAyB;QACzB,+BAA+B;QAC/B,yBAAyB;QACzB,4BAA4B;QAC5B,qBAAqB;QACrB,qBAAqB;QACrB,iCAAiC;QACjC,qBAAqB;QACrB,qBAAqB;QACrB,gBAAgB;QAChB,qBAAqB;QACrB,oBAAoB;QACpB,sBAAsB;QACtB,oBAAoB;QACpB,mBAAmB;QACnB,kBAAkB;QAClB,oBAAoB;KACrB;CACO,CAAC"}
1
+ {"version":3,"file":"generated-model-council.js","sourceRoot":"","sources":["../src/generated-model-council.ts"],"names":[],"mappings":"AAAA,iEAAiE;AACjE,MAAM,CAAC,MAAM,8BAA8B,GAAG;IAC5C,QAAQ,EAAE,cAAc;IACxB,MAAM,EAAE,yEAAyE;IACjF,SAAS,EAAE,0BAA0B;IACrC,MAAM,EAAE,iEAAiE;IACzE,QAAQ,EAAE,qCAAqC;IAC/C,UAAU,EAAE,uGAAuG;IACnH,iBAAiB,EAAE;QACjB,0BAA0B;QAC1B,4BAA4B;QAC5B,2BAA2B;QAC3B,yBAAyB;QACzB,2BAA2B;QAC3B,0BAA0B;QAC1B,oCAAoC;QACpC,mCAAmC;QACnC,qCAAqC;QACrC,sCAAsC;QACtC,iCAAiC;QACjC,8BAA8B;QAC9B,yBAAyB;QACzB,yBAAyB;QACzB,yBAAyB;QACzB,uBAAuB;QACvB,+BAA+B;QAC/B,yBAAyB;QACzB,4BAA4B;QAC5B,4BAA4B;QAC5B,qBAAqB;QACrB,qBAAqB;QACrB,iCAAiC;QACjC,sBAAsB;QACtB,2BAA2B;QAC3B,qBAAqB;QACrB,qBAAqB;QACrB,gBAAgB;QAChB,qBAAqB;QACrB,oBAAoB;QACpB,sBAAsB;QACtB,oBAAoB;QACpB,mBAAmB;QACnB,kBAAkB;QAClB,oBAAoB;KACrB;CACO,CAAC"}
package/dist/index.d.ts CHANGED
@@ -5,11 +5,14 @@ export * from './capabilities.js';
5
5
  export * from './catalog.js';
6
6
  export * from './errors.js';
7
7
  export * from './equivalence-council.js';
8
+ export * from './execution-features.js';
8
9
  export * from './generation.js';
9
10
  export * from './messages.js';
11
+ export * from './native-messages.js';
10
12
  export * from './mesh.js';
11
13
  export * from './providers.js';
12
14
  export * from './registry.js';
15
+ export * from './responses-wire.js';
13
16
  export * from './routing-targets.js';
14
17
  export * from './routing-policy.js';
15
18
  export * from './routing-contracts.js';
@@ -21,6 +24,7 @@ export * from './codex.js';
21
24
  export * from './transport/codex-runtime-client.js';
22
25
  export * from './transport/codex-runtime-wire.js';
23
26
  export * from './transport/cloud-code-runtime-client.js';
27
+ export * from './transport/claude-code-runtime-client.js';
24
28
  export * from './transport/muse-runtime-client.js';
25
29
  export * from './transport/mistral-runtime-client.js';
26
30
  export * from './streaming.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,yBAAyB,CAAC;AACxC,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC;AAC1B,cAAc,mBAAmB,CAAC;AAClC,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,0BAA0B,CAAC;AACzC,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC;AAC1B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC;AACpC,cAAc,wBAAwB,CAAC;AACvC,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC;AACnC,OAAO,EACL,0BAA0B,EAAE,eAAe,EAAE,UAAU,EAAE,KAAK,iBAAiB,GAChF,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC1D,cAAc,YAAY,CAAC;AAC3B,cAAc,qCAAqC,CAAC;AACpD,cAAc,mCAAmC,CAAC;AAClD,cAAc,0CAA0C,CAAC;AACzD,cAAc,oCAAoC,CAAC;AACnD,cAAc,uCAAuC,CAAC;AACtD,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,yBAAyB,CAAC;AACxC,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC;AAC1B,cAAc,mBAAmB,CAAC;AAClC,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,0BAA0B,CAAC;AACzC,cAAc,yBAAyB,CAAC;AACxC,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,sBAAsB,CAAC;AACrC,cAAc,WAAW,CAAC;AAC1B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,eAAe,CAAC;AAC9B,cAAc,qBAAqB,CAAC;AACpC,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC;AACpC,cAAc,wBAAwB,CAAC;AACvC,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC;AACnC,OAAO,EACL,0BAA0B,EAAE,eAAe,EAAE,UAAU,EAAE,KAAK,iBAAiB,GAChF,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC1D,cAAc,YAAY,CAAC;AAC3B,cAAc,qCAAqC,CAAC;AACpD,cAAc,mCAAmC,CAAC;AAClD,cAAc,0CAA0C,CAAC;AACzD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,oCAAoC,CAAC;AACnD,cAAc,uCAAuC,CAAC;AACtD,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC"}
package/dist/index.js CHANGED
@@ -5,11 +5,14 @@ export * from './capabilities.js';
5
5
  export * from './catalog.js';
6
6
  export * from './errors.js';
7
7
  export * from './equivalence-council.js';
8
+ export * from './execution-features.js';
8
9
  export * from './generation.js';
9
10
  export * from './messages.js';
11
+ export * from './native-messages.js';
10
12
  export * from './mesh.js';
11
13
  export * from './providers.js';
12
14
  export * from './registry.js';
15
+ export * from './responses-wire.js';
13
16
  export * from './routing-targets.js';
14
17
  export * from './routing-policy.js';
15
18
  export * from './routing-contracts.js';
@@ -21,6 +24,7 @@ export * from './codex.js';
21
24
  export * from './transport/codex-runtime-client.js';
22
25
  export * from './transport/codex-runtime-wire.js';
23
26
  export * from './transport/cloud-code-runtime-client.js';
27
+ export * from './transport/claude-code-runtime-client.js';
24
28
  export * from './transport/muse-runtime-client.js';
25
29
  export * from './transport/mistral-runtime-client.js';
26
30
  export * from './streaming.js';
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts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Ac,qBAAqB,CAAC;AACpC,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC;AACpC,cAAc,wBAAwB,CAAC;AACvC,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC;AACnC,OAAO,EACL,0BAA0B,EAAE,eAAe,EAAE,UAAU,GACxD,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC1D,cAAc,YAAY,CAAC;AAC3B,cAAc,qCAAqC,CAAC;AACpD,cAAc,mCAAmC,CAAC;AAClD,cAAc,0CAA0C,CAAC;AACzD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,oCAAoC,CAAC;AACnD,cAAc,uCAAuC,CAAC;AACtD,cAAc,gBAAgB,CAAC;AAC/B,cAAc,YAAY,CAAC"}
@@ -0,0 +1,130 @@
1
+ import type { RouteAttemptUsage } from './routing-contracts.js';
2
+ import { type RequestSizeDetail } from './errors.js';
3
+ export type NativeInputUsageSource = 'json' | 'message_start' | 'message_delta';
4
+ export type NativeUsageUncertainty = 'incomplete_input' | 'invalid_input' | 'cache_write_split_unknown' | 'served_model_unverified' | 'served_model_mismatch' | 'input_breakdown_changed' | 'incomplete_output' | 'invalid_output' | 'missing_usage';
5
+ export type NativeCacheWriteSplitReason = 'cache_write_split_inferred';
6
+ export type NativePricingPolicy = 'anthropic-cache-2026-10-02';
7
+ export type NativeUsageTermination = 'completed' | 'cancelled' | 'upstream_error' | 'commit_failed' | 'missing_message_stop' | 'frame_overflow' | 'timeout' | 'reader_error' | 'protocol_error';
8
+ /** Trusted observer evidence, never populated from caller body/header fields. */
9
+ export interface NativeUsagePricing {
10
+ readonly nativeInputPriceUnits40?: number;
11
+ readonly nativePricingPolicy?: NativePricingPolicy;
12
+ readonly nativeServedModelId?: string;
13
+ readonly nativeInputUsageValidated?: boolean;
14
+ readonly nativeInputUsageSource?: NativeInputUsageSource;
15
+ readonly nativeUsageUncertainty?: NativeUsageUncertainty;
16
+ /** Inferred growth allocation alone does not make a valid clean turn estimated. */
17
+ readonly nativeCacheWriteSplitReason?: NativeCacheWriteSplitReason;
18
+ }
19
+ /** Safe provider-reported categories only; inferred TTL allocation is never raw. */
20
+ export interface NativeUsageRaw {
21
+ readonly input_tokens?: number;
22
+ readonly cache_read_input_tokens?: number;
23
+ readonly cache_creation_input_tokens?: number;
24
+ readonly cache_creation?: {
25
+ readonly ephemeral_5m_input_tokens?: number;
26
+ readonly ephemeral_1h_input_tokens?: number;
27
+ };
28
+ readonly output_tokens?: number;
29
+ }
30
+ /**
31
+ * One immutable pre-financial-floor snapshot, shared by settlement and observation.
32
+ * Counts are physical and optional: missing evidence never becomes zero/allowance.
33
+ * The gateway freezes the snapshot and nested raw categories at terminal ownership.
34
+ * Malformed/decreasing/conflicting input permanently loses its pricing proof (N5).
35
+ */
36
+ export interface NativeUsageSnapshot extends NativeUsagePricing {
37
+ readonly inputTokens?: number;
38
+ readonly outputTokens?: number;
39
+ readonly totalTokens?: number;
40
+ readonly rawUsage?: NativeUsageRaw;
41
+ readonly estimated: boolean;
42
+ readonly finalOutputObserved: boolean;
43
+ readonly termination: NativeUsageTermination;
44
+ readonly nativeSelectedModelId: string;
45
+ readonly fallbackPresent: boolean;
46
+ readonly iterationsPresent: boolean;
47
+ }
48
+ export interface NativeMessagesFeatureHeaders {
49
+ /** Resolved supported version before execute; never an unresolved caller hint. */
50
+ readonly anthropicVersion: string;
51
+ /** Sanitized end-to-end headers; caller beta values remain opaque. */
52
+ readonly forwarded: Readonly<Record<string, string>>;
53
+ }
54
+ export interface NativeMessagesRequest {
55
+ readonly body: Readonly<Record<string, unknown>>;
56
+ readonly stream: boolean;
57
+ readonly headers: NativeMessagesFeatureHeaders;
58
+ readonly signal: AbortSignal;
59
+ /** Server gateway request ID, distinct from the cost correlation ID. */
60
+ readonly requestId: string;
61
+ /** Bound to the prepared host hook; only the gateway invokes it, once per attempt. */
62
+ readonly finalize?: (snapshot: NativeUsageSnapshot) => void | Promise<void>;
63
+ }
64
+ /** Credential-free advertisement; executable closures remain in the trusted host. */
65
+ export interface NativeMessagesAdvertisement {
66
+ readonly contractVersion: 1;
67
+ readonly protocol: 'anthropic-messages';
68
+ }
69
+ export interface PreparedNativeMessages extends NativeMessagesAdvertisement {
70
+ readonly modelId: string;
71
+ readonly apiVersions: readonly string[];
72
+ readonly requiredBetas: readonly string[];
73
+ /** Trusted, body-free observation hook; settlement/cleanup never await this hook. */
74
+ readonly finalize?: (snapshot: NativeUsageSnapshot) => void | Promise<void>;
75
+ /** Complete/cancel upload and detach request references before exposing a result. */
76
+ execute(request: NativeMessagesRequest): Promise<NativeMessagesResult>;
77
+ }
78
+ export type NativeMessagesResult = ({
79
+ readonly kind: 'json';
80
+ readonly status: 200;
81
+ readonly body: Readonly<Record<string, unknown>>;
82
+ readonly headers: Readonly<Record<string, string>>;
83
+ } | {
84
+ readonly kind: 'stream';
85
+ readonly status: 200;
86
+ readonly body: AsyncIterable<Uint8Array>;
87
+ readonly headers: Readonly<Record<string, string>>;
88
+ }) & {
89
+ /** Host-measured outgoing bytes, retained for numeric pre/late SSE 413 errors. */
90
+ readonly requestSize?: RequestSizeDetail;
91
+ };
92
+ /** Empty until real qualification; trusted hosts may supply a code-only override. */
93
+ export declare const NATIVE_ANTHROPIC_MESSAGES_MODEL_IDS: readonly string[];
94
+ export declare const validateNativeModelAllowlist: (modelIds: readonly string[]) => readonly string[];
95
+ /** Pure provider/model identity check; account advertisement is a separate gate. */
96
+ export declare const isNativeMessagesTarget: (target: {
97
+ readonly providerId: string;
98
+ readonly modelId: string;
99
+ }, modelIds?: readonly string[]) => boolean;
100
+ export declare const isPreparedNativeMessages: (value: unknown) => value is PreparedNativeMessages;
101
+ /** Lot 2 required betas are empty: preserve the caller's parser-retained value exactly. */
102
+ export declare const composeAnthropicBeta: (callerValue: string | undefined, requiredBetas?: readonly string[]) => string | undefined;
103
+ export type NativeMessagesProviderErrorType = 'invalid_request_error' | 'authentication_error' | 'permission_error' | 'not_found_error' | 'request_too_large' | 'rate_limit_error' | 'api_error' | 'overloaded_error';
104
+ export type NativeMessagesTransportCode = 'timeout' | 'account_unavailable' | 'native_protocol_error';
105
+ export interface NativeValidationPublicDetail {
106
+ readonly type: string;
107
+ readonly message: string;
108
+ }
109
+ export interface NativeMessagesUpstreamErrorOptions {
110
+ readonly requestSize?: RequestSizeDetail;
111
+ readonly status: number;
112
+ readonly type?: NativeMessagesProviderErrorType;
113
+ readonly code?: NativeMessagesTransportCode;
114
+ readonly retryAfterMs?: number;
115
+ /** Operational evidence; dispatched pre-fetch zeros do not exempt billing. */
116
+ readonly usage?: RouteAttemptUsage;
117
+ readonly validation?: NativeValidationPublicDetail;
118
+ }
119
+ /** Never place upstream validation prose, payloads or credentials in this error. */
120
+ export declare class NativeMessagesUpstreamError extends Error {
121
+ readonly requestSize?: RequestSizeDetail;
122
+ readonly status: number;
123
+ readonly type?: NativeMessagesProviderErrorType;
124
+ readonly code?: NativeMessagesTransportCode;
125
+ readonly retryAfterMs?: number;
126
+ readonly usage?: RouteAttemptUsage;
127
+ readonly validation?: NativeValidationPublicDetail;
128
+ constructor(options: NativeMessagesUpstreamErrorOptions);
129
+ }
130
+ //# sourceMappingURL=native-messages.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"native-messages.d.ts","sourceRoot":"","sources":["../src/native-messages.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAChE,OAAO,EAAyB,KAAK,iBAAiB,EAAE,MAAM,aAAa,CAAC;AAI5E,MAAM,MAAM,sBAAsB,GAAG,MAAM,GAAG,eAAe,GAAG,eAAe,CAAC;AAChF,MAAM,MAAM,sBAAsB,GAC9B,kBAAkB,GAAG,eAAe,GAAG,2BAA2B,GAClE,yBAAyB,GAAG,uBAAuB,GAAG,yBAAyB,GAC/E,mBAAmB,GAAG,gBAAgB,GAAG,eAAe,CAAC;AAC7D,MAAM,MAAM,2BAA2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AAC;IAChD,QAAQ,CAAC,IAAI,CAAC,EAAE,2BAA2B,CAAC;IAC5C,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;IAC/B,QAAQ,CAAC,KAAK,CAAC,EAAE,iBAAiB,CAAC;IACnC,QAAQ,CAAC,UAAU,CAAC,EAAE,4BAA4B,CAAC;gBAEvC,OAAO,EAAE,kCAAkC;CAWxD"}
@@ -0,0 +1,66 @@
1
+ import { readRequestSizeDetail } from './errors.js';
2
+ import { modelProfiles } from './catalog.js';
3
+ import { LAUNCH_ALIAS_ROUTE_MAPPINGS } from './routing-targets.js';
4
+ /** Empty until real qualification; trusted hosts may supply a code-only override. */
5
+ export const NATIVE_ANTHROPIC_MESSAGES_MODEL_IDS = Object.freeze([]);
6
+ const isExactAnthropicCatalogModel = (modelId) => modelProfiles.some((profile) => profile.providerId === 'anthropic' && profile.modelId === modelId);
7
+ export const validateNativeModelAllowlist = (modelIds) => {
8
+ for (const modelId of modelIds) {
9
+ // W port of R's exclusive-alias rejection: R keyed its single-target
10
+ // `EXCLUSIVE_LAUNCH_ALIAS_TARGET_MAPPINGS`; W folds every launch alias
11
+ // into `LAUNCH_ALIAS_ROUTE_MAPPINGS`, so any alias key without its own
12
+ // exact Anthropic catalog entry is rejected. Bare ids that are exact
13
+ // catalog models (e.g. `claude-sonnet-5`) remain accepted.
14
+ if (!isExactAnthropicCatalogModel(modelId)
15
+ || Object.hasOwn(LAUNCH_ALIAS_ROUTE_MAPPINGS, modelId) && !isExactAnthropicCatalogModel(modelId)) {
16
+ throw new Error('Native Messages allowlist requires exact non-exclusive Anthropic model IDs');
17
+ }
18
+ }
19
+ return Object.freeze([...modelIds]);
20
+ };
21
+ /** Pure provider/model identity check; account advertisement is a separate gate. */
22
+ export const isNativeMessagesTarget = (target, modelIds = NATIVE_ANTHROPIC_MESSAGES_MODEL_IDS) => target.providerId === 'anthropic' && modelIds.includes(target.modelId);
23
+ const isNonemptyString = (value) => typeof value === 'string' && value.trim().length > 0;
24
+ export const isPreparedNativeMessages = (value) => {
25
+ if (!value || typeof value !== 'object' || Array.isArray(value))
26
+ return false;
27
+ const capability = value;
28
+ return capability.contractVersion === 1
29
+ && capability.protocol === 'anthropic-messages'
30
+ && isNonemptyString(capability.modelId)
31
+ && Array.isArray(capability.apiVersions) && capability.apiVersions.length > 0
32
+ && [...capability.apiVersions].every(isNonemptyString)
33
+ && Array.isArray(capability.requiredBetas)
34
+ && [...capability.requiredBetas].every((beta) => typeof beta === 'string')
35
+ && typeof capability.execute === 'function'
36
+ && (capability.finalize === undefined || typeof capability.finalize === 'function');
37
+ };
38
+ /** Lot 2 required betas are empty: preserve the caller's parser-retained value exactly. */
39
+ export const composeAnthropicBeta = (callerValue, requiredBetas = []) => {
40
+ if (requiredBetas.length === 0)
41
+ return callerValue;
42
+ const required = requiredBetas.join(',');
43
+ return callerValue === undefined ? required : `${callerValue},${required}`;
44
+ };
45
+ /** Never place upstream validation prose, payloads or credentials in this error. */
46
+ export class NativeMessagesUpstreamError extends Error {
47
+ requestSize;
48
+ status;
49
+ type;
50
+ code;
51
+ retryAfterMs;
52
+ usage;
53
+ validation;
54
+ constructor(options) {
55
+ super('Native Anthropic Messages request failed');
56
+ this.name = 'NativeMessagesUpstreamError';
57
+ this.status = options.status;
58
+ this.type = options.type;
59
+ this.code = options.code;
60
+ this.retryAfterMs = options.retryAfterMs;
61
+ this.usage = options.usage;
62
+ this.validation = options.validation;
63
+ this.requestSize = readRequestSizeDetail(options.requestSize);
64
+ }
65
+ }
66
+ //# sourceMappingURL=native-messages.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"native-messages.js","sourceRoot":"","sources":["../src/native-messages.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,qBAAqB,EAA0B,MAAM,aAAa,CAAC;AAC5E,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC7C,OAAO,EAAE,2BAA2B,EAAE,MAAM,sBAAsB,CAAC;AAsGnE,qFAAqF;AACrF,M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CAA+B;IACnC,YAAY,CAAU;IACtB,KAAK,CAAqB;IAC1B,UAAU,CAAgC;IAEnD,YAAY,OAA2C;QACrD,KAAK,CAAC,0CAA0C,CAAC,CAAC;QAClD,IAAI,CAAC,IAAI,GAAG,6BAA6B,CAAC;QAC1C,IAAI,CAAC,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;QAC7B,IAAI,CAAC,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC;QACzB,IAAI,CAAC,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC;QACzB,IAAI,CAAC,YAAY,GAAG,OAAO,CAAC,YAAY,CAAC;QACzC,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC,KAAK,CAAC;QAC3B,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC;QACrC,IAAI,CAAC,WAAW,GAAG,qBAAqB,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC;IAChE,CAAC;CACF"}
@@ -4,19 +4,19 @@ export type ProviderStatus = 'ready' | 'planned';
4
4
  export type ProviderFamily = 'openai' | 'google' | 'anthropic' | 'mistral' | 'cohere' | 'meta';
5
5
  export type ReasoningTier = 'none' | 'light' | 'standard' | 'advanced';
6
6
  export type ModelTaskHint = 'chat' | 'structured' | 'summary' | 'doc';
7
- export declare const knownModelIds: readonly ["gpt-5.6-sol", "gpt-6-sol", "gpt-6.1-sol", "gpt-6-astra", "gpt-5.6-terra", "gpt-5.6-luna", "gpt-6-luna", "gpt-5.5", "gpt-5.4-nano", "gpt-4.1-nano", "gemini-3.7-flash", "gemini-3.8-flash", "gemini-3.5-flash", "gemini-3.1-flash-lite", "claude-sonnet-5", "claude-opus-5", "claude-opus-4-8", "claude-fable-5", "claude-fable-5-1", "mistral-small-2603", "magistral-medium-2509", "mistral-large-4", "zai-glm-5-3", "command-a-03-2025", "command-a-reasoning-08-2025", "google/gemini-3.5-flash@gcp", "google/gemini-3.1-flash-lite@gcp", "anthropic/claude-sonnet-4-6@gcp", "anthropic/claude-opus-4-6@gcp", "laneformer-2b-it", "muse-spark-1.3", "muse-spark-1.3-contributor"];
7
+ export declare const knownModelIds: readonly ["gpt-5.6-sol", "gpt-6-sol", "gpt-6.1-sol", "gpt-6-astra", "gpt-5.6-terra", "gpt-5.6-luna", "gpt-6-luna", "gpt-5.5", "gpt-5.4-nano", "gpt-4.1-nano", "gemini-3.7-flash", "gemini-3.8-flash", "gemini-4-argon", "gemini-3.5-flash", "gemini-3.1-flash-lite", "claude-sonnet-5", "claude-opus-5", "claude-opus-4-8", "claude-fable-5", "claude-fable-5-1", "mistral-small-2603", "magistral-medium-2509", "mistral-large-4", "mistral-medium-3.5", "zai-glm-5-3", "command-a-03-2025", "command-a-reasoning-08-2025", "google/gemini-3.5-flash@gcp", "google/gemini-3.1-flash-lite@gcp", "anthropic/claude-sonnet-4-6@gcp", "anthropic/claude-opus-4-6@gcp", "laneformer-2b-it", "muse-spark-1.3", "muse-spark-1.3-contributor", "muse-wonder-1.0", "muse-wonder-full-1.0"];
8
8
  export type KnownModelId = (typeof knownModelIds)[number];
9
9
  export type ModelId = KnownModelId | (string & {});
10
10
  export type QualifiedModelId = `${ProviderId}:${string}`;
11
11
  export declare const knownModelIdsByProvider: {
12
12
  readonly openai: readonly ["gpt-5.6-sol", "gpt-6-sol", "gpt-6.1-sol", "gpt-6-astra", "gpt-5.6-terra", "gpt-5.6-luna", "gpt-6-luna", "gpt-5.5", "gpt-5.4-nano", "gpt-4.1-nano"];
13
- readonly gemini: readonly ["gemini-3.7-flash", "gemini-3.8-flash", "gemini-3.5-flash", "gemini-3.1-flash-lite"];
13
+ readonly gemini: readonly ["gemini-3.7-flash", "gemini-3.8-flash", "gemini-4-argon", "gemini-3.5-flash", "gemini-3.1-flash-lite"];
14
14
  readonly anthropic: readonly ["claude-sonnet-5", "claude-opus-5", "claude-opus-4-8", "claude-fable-5", "claude-fable-5-1"];
15
- readonly mistral: readonly ["mistral-small-2603", "magistral-medium-2509", "mistral-large-4", "zai-glm-5-3"];
15
+ readonly mistral: readonly ["mistral-small-2603", "magistral-medium-2509", "mistral-large-4", "mistral-medium-3.5", "zai-glm-5-3"];
16
16
  readonly cohere: readonly ["command-a-03-2025", "command-a-reasoning-08-2025"];
17
17
  readonly gcp: readonly ["google/gemini-3.5-flash@gcp", "google/gemini-3.1-flash-lite@gcp", "anthropic/claude-sonnet-4-6@gcp", "anthropic/claude-opus-4-6@gcp"];
18
18
  readonly local: readonly ["laneformer-2b-it"];
19
- readonly muse: readonly ["muse-spark-1.3", "muse-spark-1.3-contributor"];
19
+ readonly muse: readonly ["muse-spark-1.3", "muse-spark-1.3-contributor", "muse-wonder-1.0", "muse-wonder-full-1.0"];
20
20
  };
21
21
  export interface ModelReference {
22
22
  providerId: ProviderId;
@@ -26,5 +26,5 @@ export declare const toQualifiedModelId: (model: ModelReference) => QualifiedMod
26
26
  export declare const antigravityModelFleet: readonly ["claude-sonnet-4-6", "claude-opus-4-6-thinking", "gemini-3-pro-high", "gemini-3-pro-low", "gpt-oss-120b-medium"];
27
27
  export type AntigravityFleetModelId = (typeof antigravityModelFleet)[number];
28
28
  export declare const isProviderId: (value: string) => value is "openai" | "gemini" | "anthropic" | "mistral" | "cohere" | "gcp" | "local" | "muse";
29
- export declare const isKnownModelId: (value: string) => value is "gpt-5.6-sol" | "gpt-6-sol" | "gpt-6.1-sol" | "gpt-6-astra" | "gpt-5.6-terra" | "gpt-5.6-luna" | "gpt-6-luna" | "gpt-5.5" | "gpt-5.4-nano" | "gpt-4.1-nano" | "gemini-3.7-flash" | "gemini-3.8-flash" | "gemini-3.5-flash" | "gemini-3.1-flash-lite" | "claude-sonnet-5" | "claude-opus-5" | "claude-opus-4-8" | "claude-fable-5" | "claude-fable-5-1" | "mistral-small-2603" | "magistral-medium-2509" | "mistral-large-4" | "zai-glm-5-3" | "command-a-03-2025" | "command-a-reasoning-08-2025" | "google/gemini-3.5-flash@gcp" | "google/gemini-3.1-flash-lite@gcp" | "anthropic/claude-sonnet-4-6@gcp" | "anthropic/claude-opus-4-6@gcp" | "laneformer-2b-it" | "muse-spark-1.3" | "muse-spark-1.3-contributor";
29
+ export declare const isKnownModelId: (value: string) => value is "gpt-5.6-sol" | "gpt-6-sol" | "gpt-6.1-sol" | "gpt-6-astra" | "gpt-5.6-terra" | "gpt-5.6-luna" | "gpt-6-luna" | "gpt-5.5" | "gpt-5.4-nano" | "gpt-4.1-nano" | "gemini-3.7-flash" | "gemini-3.8-flash" | "gemini-4-argon" | "gemini-3.5-flash" | "gemini-3.1-flash-lite" | "claude-sonnet-5" | "claude-opus-5" | "claude-opus-4-8" | "claude-fable-5" | "claude-fable-5-1" | "mistral-small-2603" | "magistral-medium-2509" | "mistral-large-4" | "mistral-medium-3.5" | "zai-glm-5-3" | "command-a-03-2025" | "command-a-reasoning-08-2025" | "google/gemini-3.5-flash@gcp" | "google/gemini-3.1-flash-lite@gcp" | "anthropic/claude-sonnet-4-6@gcp" | "anthropic/claude-opus-4-6@gcp" | "laneformer-2b-it" | "muse-spark-1.3" | "muse-spark-1.3-contributor" | "muse-wonder-1.0" | "muse-wonder-full-1.0";
30
30
  //# sourceMappingURL=providers.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"providers.d.ts","sourceRoot":"","sources":["../src/providers.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,WAAW,yFAA0F,CAAC;AAEnH,MAAM,MAAM,UAAU,GAAG,CAAC,OAAO,WAAW,CAAC,CAAC,MAAM,CAAC,CAAC;AAEtD,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG,SAAS,CAAC;AAEjD,MAAM,MAAM,cAAc,GAAG,QAAQ,GAAG,QAAQ,GAAG,WAAW,GAAG,SAAS,GAAG,QAAQ,GAAG,MAAM,CAAC;AAE/F,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,OAAO,GAAG,UAAU,GAAG,UAAU,CAAC;AAEvE,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,YAAY,GAAG,SAAS,GAAG,KAAK,CAAC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,ovBAiEhB,CAAC;AAEX,MAAM,MAAM,YAAY,GAAG,CAAC,OAAO,aAAa,CAAC,CAAC,MAAM,CAAC,CAAC;AAE1D,MAAM,MAAM,OAAO,GAAG,YAAY,GAAG,CAAC,MAAM,GAAG,EAAE,CAAC,CAAC;AAEnD,MAAM,MAAM,gBAAgB,GAAG,GAAG,UAAU,IAAI,MAAM,EAAE,CAAC;AAEzD,eAAO,MAAM,uBAAuB;;;;;;;;;CAoB4B,CAAC;AAEjE,MAAM,WAAW,cAAc;IAC7B,UAAU,EAAE,UAAU,CAAC;IACvB,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,eAAO,MAAM,kBAAkB,UAAW,cAAc,KAAG,gBAE1D,CAAC;AAUF,eAAO,MAAM,qBAAqB,4HAMxB,CAAC;AAEX,MAAM,MAAM,uBAAuB,GAAG,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,CAAC,CAAC;AAE7E,eAAO,MAAM,YAAY,UAAW,MAAM,iGAEzC,CAAC;AAEF,eAAO,MAAM,cAAc,UAAW,MAAM,wxBAE3C,CAAC"}
package/dist/providers.js CHANGED
@@ -12,6 +12,7 @@ export const knownModelIds = [
12
12
  'gpt-4.1-nano',
13
13
  'gemini-3.7-flash',
14
14
  'gemini-3.8-flash',
15
+ 'gemini-4-argon',
15
16
  'gemini-3.5-flash',
16
17
  'gemini-3.1-flash-lite',
17
18
  'claude-sonnet-5',
@@ -25,6 +26,7 @@ export const knownModelIds = [
25
26
  // active, natively multimodal, 1M context. Served on api.mistral.ai via the
26
27
  // `mistral-vibe` account transport (plan-billed key) or MISTRAL_API_KEY.
27
28
  'mistral-large-4',
29
+ 'mistral-medium-3.5',
28
30
  // Z.ai GLM 5.3: third-party open-weight model hosted by Mistral (EU,
29
31
  // served without Mistral modifications), long-horizon coding/agentic.
30
32
  // Mistral wire id is `zai-glm-5-3` — NOT the bare Z.ai `glm-5.3`, keeping
@@ -53,10 +55,15 @@ export const knownModelIds = [
53
55
  // transport-free). Multiple local models can be exposed under this provider.
54
56
  'laneformer-2b-it',
55
57
  // Meta Muse (Muse Code): `muse-spark-1.3` base + `-contributor` discounted
56
- // tier option (content may train product). invoked via the `muse` account
57
- // transport (CLI login) or MUSE_API_KEY; wire/transport lives in api/gateway.
58
+ // tier option (content may train product), plus `muse-wonder-1.0` /
59
+ // `muse-wonder-full-1.0` (owner request 2026-10-13, id corrected
60
+ // 2026-10-14 against the local Muse provider catalog). invoked via the
61
+ // `muse` account transport (CLI login) or MUSE_API_KEY; wire/transport
62
+ // lives in api/gateway.
58
63
  'muse-spark-1.3',
59
64
  'muse-spark-1.3-contributor',
65
+ 'muse-wonder-1.0',
66
+ 'muse-wonder-full-1.0',
60
67
  ];
61
68
  export const knownModelIdsByProvider = {
62
69
  openai: [
@@ -71,13 +78,13 @@ export const knownModelIdsByProvider = {
71
78
  'gpt-5.4-nano',
72
79
  'gpt-4.1-nano',
73
80
  ],
74
- gemini: ['gemini-3.7-flash', 'gemini-3.8-flash', 'gemini-3.5-flash', 'gemini-3.1-flash-lite'],
81
+ gemini: ['gemini-3.7-flash', 'gemini-3.8-flash', 'gemini-4-argon', 'gemini-3.5-flash', 'gemini-3.1-flash-lite'],
75
82
  anthropic: ['claude-sonnet-5', 'claude-opus-5', 'claude-opus-4-8', 'claude-fable-5', 'claude-fable-5-1'],
76
- mistral: ['mistral-small-2603', 'magistral-medium-2509', 'mistral-large-4', 'zai-glm-5-3'],
83
+ mistral: ['mistral-small-2603', 'magistral-medium-2509', 'mistral-large-4', 'mistral-medium-3.5', 'zai-glm-5-3'],
77
84
  cohere: ['command-a-03-2025', 'command-a-reasoning-08-2025'],
78
85
  gcp: ['google/gemini-3.5-flash@gcp', 'google/gemini-3.1-flash-lite@gcp', 'anthropic/claude-sonnet-4-6@gcp', 'anthropic/claude-opus-4-6@gcp'],
79
86
  local: ['laneformer-2b-it'],
80
- muse: ['muse-spark-1.3', 'muse-spark-1.3-contributor'],
87
+ muse: ['muse-spark-1.3', 'muse-spark-1.3-contributor', 'muse-wonder-1.0', 'muse-wonder-full-1.0'],
81
88
  };
82
89
  export const toQualifiedModelId = (model) => {
83
90
  return `${model.providerId}:${model.modelId}`;
@@ -1 +1 @@
1
- {"version":3,"file":"providers.js","sourceRoot":"","sources":["../src/providers.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,WAAW,GAAG,CAAC,QAAQ,EAAE,QAAQ,EAAE,WAAW,EAAE,SAAS,EAAE,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,CAAU,CAAC;AAYnH,MAAM,CAAC,MAAM,aAAa,GAAG;IAC3B,aAAa;IACb,WAAW;IACX,aAAa;IACb,aAAa;IACb,eAAe;IACf,cAAc;IACd,YAAY;IACZ,SAAS;IACT,cAAc;IACd,cAAc;IACd,kBAAkB;IAClB,kBAAkB;IAClB,kBAAkB;IAClB,uBAAuB;IACvB,iBAAiB;IACjB,eAAe;IACf,iBAAiB;IACjB,gBAAgB;IAChB,kBAAkB;IAClB,oBAAoB;IACpB,uBAAuB;IACvB,0EAA0E;IAC1E,4EAA4E;IAC5E,yEAAyE;IACzE,iBAAiB;IACjB,qEAAqE;IACrE,sEAAsE;IACtE,0EAA0E;IAC1E,uDAAuD;IACvD,aAAa;IACb,mBAAmB;IACnB,6BAA6B;IAC7B,8EAA8E;IAC9E,gFAAgF;IAChF,gFAAgF;IAChF,0EAA0E;IAC1E,8EAA8E;IAC9E,+DAA+D;IAC/D,6EAA6E;IAC7E,qEAAqE;IACrE,6CAA6C;IAC7C,4EAA4E;IAC5E,wCAAwC;IACxC,6BAA6B;IAC7B,kCAAkC;IAClC,iCAAiC;IACjC,+BAA+B;IAC/B,sEAAsE;IACtE,2EAA2E;IAC3E,8EAA8E;IAC9E,6EAA6E;IAC7E,kBAAkB;IAClB,2EAA2E;IAC3E,0EAA0E;IAC1E,8EAA8E;IAC9E,gBAAgB;IAChB,4BAA4B;CACpB,CAAC;AAQX,MAAM,CAAC,MAAM,uBAAuB,GAAG;I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