@contractspec/bundle.library 3.5.4 → 3.5.5

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.
@@ -3,7 +3,7 @@ $ bun run prebuild && bun run build:bundle && bun run build:types
3
3
  $ contractspec-bun-build prebuild
4
4
  $ contractspec-bun-build transpile
5
5
  [contractspec-bun-build] transpile target=bun root=src entries=297 noBundle=false
6
- Bundled 297 modules in 120ms
6
+ Bundled 297 modules in 138ms
7
7
 
8
8
  application/context-storage/index.js 1.0 KB (entry point)
9
9
  presentation/features/templates/types.js 8 bytes (entry point)
@@ -288,13 +288,13 @@ Bundled 297 modules in 120ms
288
288
  bundles/LibraryBundle.js 4.0 KB (entry point)
289
289
  components/docs/DocsIndexPage.js 10.60 KB (entry point)
290
290
  components/docs/advanced/AdvancedMCPPage.js 12.95 KB (entry point)
291
- application/index.js 45.52 KB (entry point)
292
- application/mcp/index.js 44.54 KB (entry point)
291
+ application/index.js 46.22 KB (entry point)
292
+ application/mcp/index.js 45.24 KB (entry point)
293
293
  application/mcp/docsMcp.js 10.46 KB (entry point)
294
294
  features/docs/index.js 443 bytes (entry point)
295
295
  features/docs/docs.contracts.js 443 bytes (entry point)
296
296
  application/mcp/internalMcp.js 11.50 KB (entry point)
297
- application/mcp/providerRankingMcp.js 14.80 KB (entry point)
297
+ application/mcp/providerRankingMcp.js 15.51 KB (entry point)
298
298
  application/mcp/cliMcp.js 12.81 KB (entry point)
299
299
  application/mcp/contractsMcp.js 16.0 KB (entry point)
300
300
  infrastructure/elysia/logger.js 0.77 KB (entry point)
@@ -304,7 +304,7 @@ Bundled 297 modules in 120ms
304
304
  application/mcp/contractsMcpTypes.js 8 bytes (entry point)
305
305
 
306
306
  [contractspec-bun-build] transpile target=node root=src entries=297 noBundle=false
307
- Bundled 297 modules in 116ms
307
+ Bundled 297 modules in 120ms
308
308
 
309
309
  application/context-storage/index.js 0.99 KB (entry point)
310
310
  presentation/features/templates/types.js 0 KB (entry point)
@@ -589,13 +589,13 @@ Bundled 297 modules in 116ms
589
589
  bundles/LibraryBundle.js 4.0 KB (entry point)
590
590
  components/docs/DocsIndexPage.js 10.59 KB (entry point)
591
591
  components/docs/advanced/AdvancedMCPPage.js 12.94 KB (entry point)
592
- application/index.js 45.52 KB (entry point)
593
- application/mcp/index.js 44.54 KB (entry point)
592
+ application/index.js 46.23 KB (entry point)
593
+ application/mcp/index.js 45.24 KB (entry point)
594
594
  application/mcp/docsMcp.js 10.46 KB (entry point)
595
595
  features/docs/index.js 435 bytes (entry point)
596
596
  features/docs/docs.contracts.js 435 bytes (entry point)
597
597
  application/mcp/internalMcp.js 11.49 KB (entry point)
598
- application/mcp/providerRankingMcp.js 14.80 KB (entry point)
598
+ application/mcp/providerRankingMcp.js 15.50 KB (entry point)
599
599
  application/mcp/cliMcp.js 12.82 KB (entry point)
600
600
  application/mcp/contractsMcp.js 16.0 KB (entry point)
601
601
  infrastructure/elysia/logger.js 0.77 KB (entry point)
package/CHANGELOG.md CHANGED
@@ -1,5 +1,41 @@
1
1
  # @contractspec/bundle.library
2
2
 
3
+ ## 3.5.5
4
+
5
+ ### Patch Changes
6
+
7
+ - 27b77db: feat(ai-models): add latest models and align defaults
8
+ - Add claude-opus-4-6, claude-sonnet-4-6, claude-haiku-4-5, gpt-5.4, gpt-5-mini
9
+ - Add mistral-large-2512, mistral-medium-2508, mistral-small-2506, devstral-2512
10
+ - Add gemini-3.1-pro-preview, gemini-3.1-flash-lite-preview, gemini-3-flash-preview
11
+ - Fix GPT-5.4 cost and context window; update default models to claude-sonnet-4-6
12
+ - Enrich provider-ranking MCP with cost from ai-providers when store has none
13
+ - Update model allowlist for gpt-5 and gemini 3.x; align agentpacks templates
14
+
15
+ - 693eedd: chore: improve ai models
16
+ - Updated dependencies [27b77db]
17
+ - Updated dependencies [693eedd]
18
+ - @contractspec/lib.ai-providers@3.5.5
19
+ - @contractspec/lib.contracts-spec@3.5.5
20
+ - @contractspec/lib.contracts-runtime-server-graphql@3.5.5
21
+ - @contractspec/lib.contracts-runtime-server-rest@3.5.5
22
+ - @contractspec/lib.contracts-runtime-server-mcp@3.5.5
23
+ - @contractspec/lib.contracts-integrations@3.5.5
24
+ - @contractspec/module.context-storage@0.5.5
25
+ - @contractspec/lib.contracts-library@3.5.5
26
+ - @contractspec/lib.example-shared-ui@4.0.5
27
+ - @contractspec/lib.provider-ranking@0.5.5
28
+ - @contractspec/lib.runtime-sandbox@2.5.5
29
+ - @contractspec/lib.surface-runtime@0.3.5
30
+ - @contractspec/lib.design-system@3.5.5
31
+ - @contractspec/lib.content-gen@3.5.5
32
+ - @contractspec/module.examples@3.5.5
33
+ - @contractspec/lib.ui-kit-web@3.5.5
34
+ - @contractspec/lib.knowledge@3.5.5
35
+ - @contractspec/lib.ui-link@3.5.5
36
+ - @contractspec/lib.logger@3.5.5
37
+ - @contractspec/lib.schema@3.5.5
38
+
3
39
  ## 3.5.4
4
40
 
5
41
  ### Patch Changes
@@ -829,6 +829,7 @@ import {
829
829
  RankingRefreshCommand
830
830
  } from "@contractspec/lib.contracts-spec/provider-ranking";
831
831
  import z4 from "zod";
832
+ import { getModelInfo } from "@contractspec/lib.ai-providers/models";
832
833
  import { InMemoryProviderRankingStore } from "@contractspec/lib.provider-ranking/in-memory-store";
833
834
  import { createDefaultIngesterRegistry } from "@contractspec/lib.provider-ranking/ingesters";
834
835
  import { computeModelRankings } from "@contractspec/lib.provider-ranking/scoring";
@@ -927,10 +928,25 @@ function buildRankingResources() {
927
928
  data: JSON.stringify({ error: "not_found", modelId })
928
929
  };
929
930
  }
931
+ const enriched = profile.costPerMillion == null ? (() => {
932
+ const info = getModelInfo(profile.modelId);
933
+ return info?.costPerMillion ? {
934
+ ...profile,
935
+ costPerMillion: info.costPerMillion,
936
+ displayName: info.name,
937
+ contextWindow: info.contextWindow,
938
+ capabilities: [
939
+ ...info.capabilities.vision ? ["vision"] : [],
940
+ ...info.capabilities.tools ? ["tools"] : [],
941
+ ...info.capabilities.reasoning ? ["reasoning"] : [],
942
+ ...info.capabilities.streaming ? ["streaming"] : []
943
+ ]
944
+ } : profile;
945
+ })() : profile;
930
946
  return {
931
947
  uri: `ranking://model/${encodeURIComponent(modelId)}`,
932
948
  mimeType: "application/json",
933
- data: JSON.stringify(profile, null, 2)
949
+ data: JSON.stringify(enriched, null, 2)
934
950
  };
935
951
  }
936
952
  }));
@@ -803,6 +803,7 @@ import {
803
803
  RankingRefreshCommand
804
804
  } from "@contractspec/lib.contracts-spec/provider-ranking";
805
805
  import z4 from "zod";
806
+ import { getModelInfo } from "@contractspec/lib.ai-providers/models";
806
807
  import { InMemoryProviderRankingStore } from "@contractspec/lib.provider-ranking/in-memory-store";
807
808
  import { createDefaultIngesterRegistry } from "@contractspec/lib.provider-ranking/ingesters";
808
809
  import { computeModelRankings } from "@contractspec/lib.provider-ranking/scoring";
@@ -901,10 +902,25 @@ function buildRankingResources() {
901
902
  data: JSON.stringify({ error: "not_found", modelId })
902
903
  };
903
904
  }
905
+ const enriched = profile.costPerMillion == null ? (() => {
906
+ const info = getModelInfo(profile.modelId);
907
+ return info?.costPerMillion ? {
908
+ ...profile,
909
+ costPerMillion: info.costPerMillion,
910
+ displayName: info.name,
911
+ contextWindow: info.contextWindow,
912
+ capabilities: [
913
+ ...info.capabilities.vision ? ["vision"] : [],
914
+ ...info.capabilities.tools ? ["tools"] : [],
915
+ ...info.capabilities.reasoning ? ["reasoning"] : [],
916
+ ...info.capabilities.streaming ? ["streaming"] : []
917
+ ]
918
+ } : profile;
919
+ })() : profile;
904
920
  return {
905
921
  uri: `ranking://model/${encodeURIComponent(modelId)}`,
906
922
  mimeType: "application/json",
907
- data: JSON.stringify(profile, null, 2)
923
+ data: JSON.stringify(enriched, null, 2)
908
924
  };
909
925
  }
910
926
  }));
@@ -213,6 +213,7 @@ import {
213
213
  RankingRefreshCommand
214
214
  } from "@contractspec/lib.contracts-spec/provider-ranking";
215
215
  import z from "zod";
216
+ import { getModelInfo } from "@contractspec/lib.ai-providers/models";
216
217
  import { InMemoryProviderRankingStore } from "@contractspec/lib.provider-ranking/in-memory-store";
217
218
  import { createDefaultIngesterRegistry } from "@contractspec/lib.provider-ranking/ingesters";
218
219
  import { computeModelRankings } from "@contractspec/lib.provider-ranking/scoring";
@@ -311,10 +312,25 @@ function buildRankingResources() {
311
312
  data: JSON.stringify({ error: "not_found", modelId })
312
313
  };
313
314
  }
315
+ const enriched = profile.costPerMillion == null ? (() => {
316
+ const info = getModelInfo(profile.modelId);
317
+ return info?.costPerMillion ? {
318
+ ...profile,
319
+ costPerMillion: info.costPerMillion,
320
+ displayName: info.name,
321
+ contextWindow: info.contextWindow,
322
+ capabilities: [
323
+ ...info.capabilities.vision ? ["vision"] : [],
324
+ ...info.capabilities.tools ? ["tools"] : [],
325
+ ...info.capabilities.reasoning ? ["reasoning"] : [],
326
+ ...info.capabilities.streaming ? ["streaming"] : []
327
+ ]
328
+ } : profile;
329
+ })() : profile;
314
330
  return {
315
331
  uri: `ranking://model/${encodeURIComponent(modelId)}`,
316
332
  mimeType: "application/json",
317
- data: JSON.stringify(profile, null, 2)
333
+ data: JSON.stringify(enriched, null, 2)
318
334
  };
319
335
  }
320
336
  }));
@@ -828,6 +828,7 @@ import {
828
828
  RankingRefreshCommand
829
829
  } from "@contractspec/lib.contracts-spec/provider-ranking";
830
830
  import z4 from "zod";
831
+ import { getModelInfo } from "@contractspec/lib.ai-providers/models";
831
832
  import { InMemoryProviderRankingStore } from "@contractspec/lib.provider-ranking/in-memory-store";
832
833
  import { createDefaultIngesterRegistry } from "@contractspec/lib.provider-ranking/ingesters";
833
834
  import { computeModelRankings } from "@contractspec/lib.provider-ranking/scoring";
@@ -926,10 +927,25 @@ function buildRankingResources() {
926
927
  data: JSON.stringify({ error: "not_found", modelId })
927
928
  };
928
929
  }
930
+ const enriched = profile.costPerMillion == null ? (() => {
931
+ const info = getModelInfo(profile.modelId);
932
+ return info?.costPerMillion ? {
933
+ ...profile,
934
+ costPerMillion: info.costPerMillion,
935
+ displayName: info.name,
936
+ contextWindow: info.contextWindow,
937
+ capabilities: [
938
+ ...info.capabilities.vision ? ["vision"] : [],
939
+ ...info.capabilities.tools ? ["tools"] : [],
940
+ ...info.capabilities.reasoning ? ["reasoning"] : [],
941
+ ...info.capabilities.streaming ? ["streaming"] : []
942
+ ]
943
+ } : profile;
944
+ })() : profile;
929
945
  return {
930
946
  uri: `ranking://model/${encodeURIComponent(modelId)}`,
931
947
  mimeType: "application/json",
932
- data: JSON.stringify(profile, null, 2)
948
+ data: JSON.stringify(enriched, null, 2)
933
949
  };
934
950
  }
935
951
  }));
@@ -802,6 +802,7 @@ import {
802
802
  RankingRefreshCommand
803
803
  } from "@contractspec/lib.contracts-spec/provider-ranking";
804
804
  import z4 from "zod";
805
+ import { getModelInfo } from "@contractspec/lib.ai-providers/models";
805
806
  import { InMemoryProviderRankingStore } from "@contractspec/lib.provider-ranking/in-memory-store";
806
807
  import { createDefaultIngesterRegistry } from "@contractspec/lib.provider-ranking/ingesters";
807
808
  import { computeModelRankings } from "@contractspec/lib.provider-ranking/scoring";
@@ -900,10 +901,25 @@ function buildRankingResources() {
900
901
  data: JSON.stringify({ error: "not_found", modelId })
901
902
  };
902
903
  }
904
+ const enriched = profile.costPerMillion == null ? (() => {
905
+ const info = getModelInfo(profile.modelId);
906
+ return info?.costPerMillion ? {
907
+ ...profile,
908
+ costPerMillion: info.costPerMillion,
909
+ displayName: info.name,
910
+ contextWindow: info.contextWindow,
911
+ capabilities: [
912
+ ...info.capabilities.vision ? ["vision"] : [],
913
+ ...info.capabilities.tools ? ["tools"] : [],
914
+ ...info.capabilities.reasoning ? ["reasoning"] : [],
915
+ ...info.capabilities.streaming ? ["streaming"] : []
916
+ ]
917
+ } : profile;
918
+ })() : profile;
903
919
  return {
904
920
  uri: `ranking://model/${encodeURIComponent(modelId)}`,
905
921
  mimeType: "application/json",
906
- data: JSON.stringify(profile, null, 2)
922
+ data: JSON.stringify(enriched, null, 2)
907
923
  };
908
924
  }
909
925
  }));
@@ -212,6 +212,7 @@ import {
212
212
  RankingRefreshCommand
213
213
  } from "@contractspec/lib.contracts-spec/provider-ranking";
214
214
  import z from "zod";
215
+ import { getModelInfo } from "@contractspec/lib.ai-providers/models";
215
216
  import { InMemoryProviderRankingStore } from "@contractspec/lib.provider-ranking/in-memory-store";
216
217
  import { createDefaultIngesterRegistry } from "@contractspec/lib.provider-ranking/ingesters";
217
218
  import { computeModelRankings } from "@contractspec/lib.provider-ranking/scoring";
@@ -310,10 +311,25 @@ function buildRankingResources() {
310
311
  data: JSON.stringify({ error: "not_found", modelId })
311
312
  };
312
313
  }
314
+ const enriched = profile.costPerMillion == null ? (() => {
315
+ const info = getModelInfo(profile.modelId);
316
+ return info?.costPerMillion ? {
317
+ ...profile,
318
+ costPerMillion: info.costPerMillion,
319
+ displayName: info.name,
320
+ contextWindow: info.contextWindow,
321
+ capabilities: [
322
+ ...info.capabilities.vision ? ["vision"] : [],
323
+ ...info.capabilities.tools ? ["tools"] : [],
324
+ ...info.capabilities.reasoning ? ["reasoning"] : [],
325
+ ...info.capabilities.streaming ? ["streaming"] : []
326
+ ]
327
+ } : profile;
328
+ })() : profile;
313
329
  return {
314
330
  uri: `ranking://model/${encodeURIComponent(modelId)}`,
315
331
  mimeType: "application/json",
316
- data: JSON.stringify(profile, null, 2)
332
+ data: JSON.stringify(enriched, null, 2)
317
333
  };
318
334
  }
319
335
  }));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contractspec/bundle.library",
3
- "version": "3.5.4",
3
+ "version": "3.5.5",
4
4
  "type": "module",
5
5
  "scripts": {
6
6
  "clean": "rm -rf dist",
@@ -2161,22 +2161,23 @@
2161
2161
  },
2162
2162
  "dependencies": {
2163
2163
  "@apollo/client": "^4.1.6",
2164
- "@contractspec/lib.contracts-spec": "3.5.4",
2165
- "@contractspec/lib.contracts-library": "3.5.4",
2166
- "@contractspec/lib.content-gen": "3.5.4",
2167
- "@contractspec/lib.contracts-runtime-server-mcp": "3.5.4",
2168
- "@contractspec/lib.design-system": "3.5.4",
2169
- "@contractspec/lib.surface-runtime": "0.3.4",
2170
- "@contractspec/lib.provider-ranking": "0.5.4",
2171
- "@contractspec/lib.example-shared-ui": "4.0.4",
2172
- "@contractspec/lib.knowledge": "3.5.4",
2173
- "@contractspec/lib.logger": "3.5.4",
2174
- "@contractspec/lib.runtime-sandbox": "2.5.4",
2175
- "@contractspec/lib.schema": "3.5.4",
2176
- "@contractspec/lib.ui-kit-web": "3.5.4",
2177
- "@contractspec/lib.ui-link": "3.5.4",
2178
- "@contractspec/module.context-storage": "0.5.4",
2179
- "@contractspec/module.examples": "3.5.4",
2164
+ "@contractspec/lib.ai-providers": "3.5.5",
2165
+ "@contractspec/lib.contracts-spec": "3.5.5",
2166
+ "@contractspec/lib.contracts-library": "3.5.5",
2167
+ "@contractspec/lib.content-gen": "3.5.5",
2168
+ "@contractspec/lib.contracts-runtime-server-mcp": "3.5.5",
2169
+ "@contractspec/lib.design-system": "3.5.5",
2170
+ "@contractspec/lib.surface-runtime": "0.3.5",
2171
+ "@contractspec/lib.provider-ranking": "0.5.5",
2172
+ "@contractspec/lib.example-shared-ui": "4.0.5",
2173
+ "@contractspec/lib.knowledge": "3.5.5",
2174
+ "@contractspec/lib.logger": "3.5.5",
2175
+ "@contractspec/lib.runtime-sandbox": "2.5.5",
2176
+ "@contractspec/lib.schema": "3.5.5",
2177
+ "@contractspec/lib.ui-kit-web": "3.5.5",
2178
+ "@contractspec/lib.ui-link": "3.5.5",
2179
+ "@contractspec/module.context-storage": "0.5.5",
2180
+ "@contractspec/module.examples": "3.5.5",
2180
2181
  "@dnd-kit/core": "^6.1.0",
2181
2182
  "@dnd-kit/sortable": "^10.0.0",
2182
2183
  "@dnd-kit/utilities": "^3.2.2",
@@ -2191,16 +2192,16 @@
2191
2192
  "posthog-react-native": "^4.37.1",
2192
2193
  "react-hook-form": "^7.71.2",
2193
2194
  "zod": "^4.3.5",
2194
- "@contractspec/lib.contracts-integrations": "3.5.4",
2195
- "@contractspec/lib.contracts-runtime-server-rest": "3.5.4",
2196
- "@contractspec/lib.contracts-runtime-server-graphql": "3.5.4"
2195
+ "@contractspec/lib.contracts-integrations": "3.5.5",
2196
+ "@contractspec/lib.contracts-runtime-server-rest": "3.5.5",
2197
+ "@contractspec/lib.contracts-runtime-server-graphql": "3.5.5"
2197
2198
  },
2198
2199
  "devDependencies": {
2199
2200
  "@types/react": "~19.2.14",
2200
- "@contractspec/tool.typescript": "3.5.4",
2201
+ "@contractspec/tool.typescript": "3.5.5",
2201
2202
  "typescript": "^5.9.3",
2202
2203
  "@types/bun": "~1.3.10",
2203
- "@contractspec/tool.bun": "3.5.4"
2204
+ "@contractspec/tool.bun": "3.5.5"
2204
2205
  },
2205
2206
  "publishConfig": {
2206
2207
  "access": "public",
@@ -19,6 +19,7 @@ import type {
19
19
  ProviderTransportSupport,
20
20
  ProviderAuthSupport,
21
21
  } from '@contractspec/lib.provider-ranking/types';
22
+ import { getModelInfo } from '@contractspec/lib.ai-providers/models';
22
23
  import { InMemoryProviderRankingStore } from '@contractspec/lib.provider-ranking/in-memory-store';
23
24
  import { createDefaultIngesterRegistry } from '@contractspec/lib.provider-ranking/ingesters';
24
25
  import { computeModelRankings } from '@contractspec/lib.provider-ranking/scoring';
@@ -145,10 +146,31 @@ function buildRankingResources() {
145
146
  data: JSON.stringify({ error: 'not_found', modelId }),
146
147
  };
147
148
  }
149
+ // Enrich with cost from ai-providers when store has none
150
+ const enriched =
151
+ profile.costPerMillion == null
152
+ ? (() => {
153
+ const info = getModelInfo(profile.modelId);
154
+ return info?.costPerMillion
155
+ ? {
156
+ ...profile,
157
+ costPerMillion: info.costPerMillion,
158
+ displayName: info.name,
159
+ contextWindow: info.contextWindow,
160
+ capabilities: [
161
+ ...(info.capabilities.vision ? ['vision'] : []),
162
+ ...(info.capabilities.tools ? ['tools'] : []),
163
+ ...(info.capabilities.reasoning ? ['reasoning'] : []),
164
+ ...(info.capabilities.streaming ? ['streaming'] : []),
165
+ ],
166
+ }
167
+ : profile;
168
+ })()
169
+ : profile;
148
170
  return {
149
171
  uri: `ranking://model/${encodeURIComponent(modelId)}`,
150
172
  mimeType: 'application/json',
151
- data: JSON.stringify(profile, null, 2),
173
+ data: JSON.stringify(enriched, null, 2),
152
174
  };
153
175
  },
154
176
  })