@contractspec/bundle.library 3.5.3 → 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.
Files changed (66) hide show
  1. package/.turbo/turbo-build.log +8 -8
  2. package/CHANGELOG.md +64 -0
  3. package/dist/application/index.js +20 -4
  4. package/dist/application/mcp/cliMcp.js +1 -1
  5. package/dist/application/mcp/index.js +20 -4
  6. package/dist/application/mcp/internalMcp.js +2 -2
  7. package/dist/application/mcp/providerRankingMcp.js +17 -1
  8. package/dist/features/docs.feature.js +1 -1
  9. package/dist/features/index.js +1 -1
  10. package/dist/features/registry.js +1 -1
  11. package/dist/index.js +1 -1
  12. package/dist/node/application/index.js +20 -4
  13. package/dist/node/application/mcp/cliMcp.js +1 -1
  14. package/dist/node/application/mcp/index.js +20 -4
  15. package/dist/node/application/mcp/internalMcp.js +2 -2
  16. package/dist/node/application/mcp/providerRankingMcp.js +17 -1
  17. package/dist/node/features/docs.feature.js +1 -1
  18. package/dist/node/features/index.js +1 -1
  19. package/dist/node/features/registry.js +1 -1
  20. package/dist/node/index.js +1 -1
  21. package/dist/node/presentation/features/hooks/index.js +1 -1
  22. package/dist/node/presentation/features/hooks/useContractsRegistry.js +1 -1
  23. package/dist/node/presentation/features/hooks/useFeatureRegistry.js +1 -1
  24. package/dist/node/presentation/features/index.js +1 -1
  25. package/dist/node/presentation/features/organisms/FeatureDataViewsList.js +1 -1
  26. package/dist/node/presentation/features/organisms/FeatureDiscovery/FeatureDiscovery.js +1 -1
  27. package/dist/node/presentation/features/organisms/FeatureDiscovery/index.js +1 -1
  28. package/dist/node/presentation/features/organisms/FeatureEventsList.js +1 -1
  29. package/dist/node/presentation/features/organisms/FeatureFormsList.js +1 -1
  30. package/dist/node/presentation/features/organisms/FeaturePresentationsList.js +1 -1
  31. package/dist/node/presentation/features/organisms/index.js +1 -1
  32. package/dist/node/presentation/features/templates/FeatureDataViewsTemplate/FeatureDataViewsTemplate.js +1 -1
  33. package/dist/node/presentation/features/templates/FeatureDataViewsTemplate/index.js +1 -1
  34. package/dist/node/presentation/features/templates/FeatureEventsTemplate/FeatureEventsTemplate.js +1 -1
  35. package/dist/node/presentation/features/templates/FeatureEventsTemplate/index.js +1 -1
  36. package/dist/node/presentation/features/templates/FeatureFormsTemplate/FeatureFormsTemplate.js +1 -1
  37. package/dist/node/presentation/features/templates/FeatureFormsTemplate/index.js +1 -1
  38. package/dist/node/presentation/features/templates/FeaturePresentationsTemplate/FeaturePresentationsTemplate.js +1 -1
  39. package/dist/node/presentation/features/templates/FeaturePresentationsTemplate/index.js +1 -1
  40. package/dist/presentation/features/hooks/index.js +1 -1
  41. package/dist/presentation/features/hooks/useContractsRegistry.js +1 -1
  42. package/dist/presentation/features/hooks/useFeatureRegistry.js +1 -1
  43. package/dist/presentation/features/index.js +1 -1
  44. package/dist/presentation/features/organisms/FeatureDataViewsList.js +1 -1
  45. package/dist/presentation/features/organisms/FeatureDiscovery/FeatureDiscovery.js +1 -1
  46. package/dist/presentation/features/organisms/FeatureDiscovery/index.js +1 -1
  47. package/dist/presentation/features/organisms/FeatureEventsList.js +1 -1
  48. package/dist/presentation/features/organisms/FeatureFormsList.js +1 -1
  49. package/dist/presentation/features/organisms/FeaturePresentationsList.js +1 -1
  50. package/dist/presentation/features/organisms/index.js +1 -1
  51. package/dist/presentation/features/templates/FeatureDataViewsTemplate/FeatureDataViewsTemplate.js +1 -1
  52. package/dist/presentation/features/templates/FeatureDataViewsTemplate/index.js +1 -1
  53. package/dist/presentation/features/templates/FeatureEventsTemplate/FeatureEventsTemplate.js +1 -1
  54. package/dist/presentation/features/templates/FeatureEventsTemplate/index.js +1 -1
  55. package/dist/presentation/features/templates/FeatureFormsTemplate/FeatureFormsTemplate.js +1 -1
  56. package/dist/presentation/features/templates/FeatureFormsTemplate/index.js +1 -1
  57. package/dist/presentation/features/templates/FeaturePresentationsTemplate/FeaturePresentationsTemplate.js +1 -1
  58. package/dist/presentation/features/templates/FeaturePresentationsTemplate/index.js +1 -1
  59. package/package.json +23 -22
  60. package/src/application/mcp/cliMcp.ts +1 -1
  61. package/src/application/mcp/internalMcp.ts +2 -2
  62. package/src/application/mcp/providerRankingMcp.ts +23 -1
  63. package/src/components/docs/generated/docs-index._common.json +94 -445
  64. package/src/components/docs/generated/docs-index.platform-docs.json +5 -5
  65. package/src/components/docs/generated/docs-index.unknown.json +5 -5
  66. package/src/features/docs.feature.ts +1 -1
@@ -171,7 +171,7 @@ var DocsFeature = {
171
171
  stability: "stable"
172
172
  },
173
173
  operations: [
174
- { key: "docs.search", version: "1.0.0" },
174
+ { key: "docs_search", version: "1.0.0" },
175
175
  { key: "docs.navigate", version: "1.0.0" }
176
176
  ],
177
177
  events: [
@@ -171,7 +171,7 @@ var DocsFeature = {
171
171
  stability: "stable"
172
172
  },
173
173
  operations: [
174
- { key: "docs.search", version: "1.0.0" },
174
+ { key: "docs_search", version: "1.0.0" },
175
175
  { key: "docs.navigate", version: "1.0.0" }
176
176
  ],
177
177
  events: [
@@ -171,7 +171,7 @@ var DocsFeature = {
171
171
  stability: "stable"
172
172
  },
173
173
  operations: [
174
- { key: "docs.search", version: "1.0.0" },
174
+ { key: "docs_search", version: "1.0.0" },
175
175
  { key: "docs.navigate", version: "1.0.0" }
176
176
  ],
177
177
  events: [
@@ -171,7 +171,7 @@ var DocsFeature = {
171
171
  stability: "stable"
172
172
  },
173
173
  operations: [
174
- { key: "docs.search", version: "1.0.0" },
174
+ { key: "docs_search", version: "1.0.0" },
175
175
  { key: "docs.navigate", version: "1.0.0" }
176
176
  ],
177
177
  events: [
@@ -171,7 +171,7 @@ var DocsFeature = {
171
171
  stability: "stable"
172
172
  },
173
173
  operations: [
174
- { key: "docs.search", version: "1.0.0" },
174
+ { key: "docs_search", version: "1.0.0" },
175
175
  { key: "docs.navigate", version: "1.0.0" }
176
176
  ],
177
177
  events: [
@@ -171,7 +171,7 @@ var DocsFeature = {
171
171
  stability: "stable"
172
172
  },
173
173
  operations: [
174
- { key: "docs.search", version: "1.0.0" },
174
+ { key: "docs_search", version: "1.0.0" },
175
175
  { key: "docs.navigate", version: "1.0.0" }
176
176
  ],
177
177
  events: [
@@ -171,7 +171,7 @@ var DocsFeature = {
171
171
  stability: "stable"
172
172
  },
173
173
  operations: [
174
- { key: "docs.search", version: "1.0.0" },
174
+ { key: "docs_search", version: "1.0.0" },
175
175
  { key: "docs.navigate", version: "1.0.0" }
176
176
  ],
177
177
  events: [
@@ -171,7 +171,7 @@ var DocsFeature = {
171
171
  stability: "stable"
172
172
  },
173
173
  operations: [
174
- { key: "docs.search", version: "1.0.0" },
174
+ { key: "docs_search", version: "1.0.0" },
175
175
  { key: "docs.navigate", version: "1.0.0" }
176
176
  ],
177
177
  events: [
@@ -171,7 +171,7 @@ var DocsFeature = {
171
171
  stability: "stable"
172
172
  },
173
173
  operations: [
174
- { key: "docs.search", version: "1.0.0" },
174
+ { key: "docs_search", version: "1.0.0" },
175
175
  { key: "docs.navigate", version: "1.0.0" }
176
176
  ],
177
177
  events: [
@@ -171,7 +171,7 @@ var DocsFeature = {
171
171
  stability: "stable"
172
172
  },
173
173
  operations: [
174
- { key: "docs.search", version: "1.0.0" },
174
+ { key: "docs_search", version: "1.0.0" },
175
175
  { key: "docs.navigate", version: "1.0.0" }
176
176
  ],
177
177
  events: [
@@ -171,7 +171,7 @@ var DocsFeature = {
171
171
  stability: "stable"
172
172
  },
173
173
  operations: [
174
- { key: "docs.search", version: "1.0.0" },
174
+ { key: "docs_search", version: "1.0.0" },
175
175
  { key: "docs.navigate", version: "1.0.0" }
176
176
  ],
177
177
  events: [
@@ -171,7 +171,7 @@ var DocsFeature = {
171
171
  stability: "stable"
172
172
  },
173
173
  operations: [
174
- { key: "docs.search", version: "1.0.0" },
174
+ { key: "docs_search", version: "1.0.0" },
175
175
  { key: "docs.navigate", version: "1.0.0" }
176
176
  ],
177
177
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -12,7 +12,7 @@ var DocsFeature = {
12
12
  stability: "stable"
13
13
  },
14
14
  operations: [
15
- { key: "docs.search", version: "1.0.0" },
15
+ { key: "docs_search", version: "1.0.0" },
16
16
  { key: "docs.navigate", version: "1.0.0" }
17
17
  ],
18
18
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -12,7 +12,7 @@ var DocsFeature = {
12
12
  stability: "stable"
13
13
  },
14
14
  operations: [
15
- { key: "docs.search", version: "1.0.0" },
15
+ { key: "docs_search", version: "1.0.0" },
16
16
  { key: "docs.navigate", version: "1.0.0" }
17
17
  ],
18
18
  events: [
@@ -12,7 +12,7 @@ var DocsFeature = {
12
12
  stability: "stable"
13
13
  },
14
14
  operations: [
15
- { key: "docs.search", version: "1.0.0" },
15
+ { key: "docs_search", version: "1.0.0" },
16
16
  { key: "docs.navigate", version: "1.0.0" }
17
17
  ],
18
18
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
@@ -172,7 +172,7 @@ var DocsFeature = {
172
172
  stability: "stable"
173
173
  },
174
174
  operations: [
175
- { key: "docs.search", version: "1.0.0" },
175
+ { key: "docs_search", version: "1.0.0" },
176
176
  { key: "docs.navigate", version: "1.0.0" }
177
177
  ],
178
178
  events: [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contractspec/bundle.library",
3
- "version": "3.5.3",
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.3",
2165
- "@contractspec/lib.contracts-library": "3.5.3",
2166
- "@contractspec/lib.content-gen": "3.5.3",
2167
- "@contractspec/lib.contracts-runtime-server-mcp": "3.5.3",
2168
- "@contractspec/lib.design-system": "3.5.3",
2169
- "@contractspec/lib.surface-runtime": "0.3.3",
2170
- "@contractspec/lib.provider-ranking": "0.5.3",
2171
- "@contractspec/lib.example-shared-ui": "4.0.3",
2172
- "@contractspec/lib.knowledge": "3.5.3",
2173
- "@contractspec/lib.logger": "3.5.3",
2174
- "@contractspec/lib.runtime-sandbox": "2.5.3",
2175
- "@contractspec/lib.schema": "3.5.3",
2176
- "@contractspec/lib.ui-kit-web": "3.5.3",
2177
- "@contractspec/lib.ui-link": "3.5.3",
2178
- "@contractspec/module.context-storage": "0.5.3",
2179
- "@contractspec/module.examples": "3.5.3",
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.3",
2195
- "@contractspec/lib.contracts-runtime-server-rest": "3.5.3",
2196
- "@contractspec/lib.contracts-runtime-server-graphql": "3.5.3"
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.3",
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.3"
2204
+ "@contractspec/tool.bun": "3.5.5"
2204
2205
  },
2205
2206
  "publishConfig": {
2206
2207
  "access": "public",
@@ -203,7 +203,7 @@ function buildCliOps() {
203
203
 
204
204
  const suggestSpec = defineCommand({
205
205
  meta: {
206
- key: 'cli.suggestCommand',
206
+ key: 'cli_suggestCommand',
207
207
  version: '1.0.0',
208
208
  stability: 'stable',
209
209
  owners: CLI_OWNERS,
@@ -140,7 +140,7 @@ function buildInternalPrompts() {
140
140
  prompts.register(
141
141
  definePrompt({
142
142
  meta: {
143
- key: 'internal.bootstrap',
143
+ key: 'internal_bootstrap',
144
144
  version: '1.0.0',
145
145
  title: 'Bootstrap internal ContractSpec agent',
146
146
  description:
@@ -184,7 +184,7 @@ function buildInternalOps() {
184
184
 
185
185
  const describeSpec = defineCommand({
186
186
  meta: {
187
- key: 'internal.describe',
187
+ key: 'internal_describe',
188
188
  version: '1.0.0',
189
189
  stability: 'stable',
190
190
  owners: INTERNAL_OWNERS,
@@ -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
  })