geospec 0.1.0-beta.7 → 0.1.0-beta.9
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/README.md +41 -8
- package/agent/geospec-authoring/SKILL.md +12 -11
- package/agent/geospec-authoring/api-functions.md +1 -16
- package/agent/geospec-authoring/api-index.md +53 -46
- package/agent/geospec-authoring/api-types-2.md +85 -0
- package/agent/geospec-authoring/api-types.md +189 -251
- package/agent/geospec-authoring/public-api-functions.md +71 -23
- package/agent/geospec-authoring/public-api-index.md +243 -191
- package/agent/geospec-authoring/public-api-types-2.md +295 -401
- package/agent/geospec-authoring/public-api-types-3.md +412 -119
- package/agent/geospec-authoring/public-api-types.md +237 -126
- package/agent/resources.js +13 -12
- package/agent/skills.json +3 -2
- package/dist/assertion-client/client.d.mts +3 -1
- package/dist/cli/cli.d.mts +48 -0
- package/dist/cli/cli.mjs +30 -0
- package/dist/cli/index.d.mts +3 -0
- package/dist/cli/index.mjs +1 -0
- package/dist/cli/main.d.mts +1 -0
- package/dist/cli/main.mjs +2 -0
- package/dist/cli/node-host.d.mts +26 -0
- package/dist/cli/node-host.mjs +1 -0
- package/dist/cli/wire-value.mjs +1 -0
- package/dist/config/define-config.d.mts +15 -0
- package/dist/config/define-config.mjs +2 -0
- package/dist/config/index.d.mts +4 -3
- package/dist/config/index.mjs +1 -1
- package/dist/config/node/load.d.mts +2 -1
- package/dist/config/node/load.mjs +1 -1
- package/dist/config/read-geospec-config.d.mts +47 -0
- package/dist/config/read-geospec-config.mjs +3 -0
- package/dist/config/types.d.mts +11 -25
- package/dist/config/validate.mjs +1 -1
- package/dist/engine/client.d.mts +3 -1
- package/dist/mesh/index.d.mts +2 -2
- package/dist/model/index.d.mts +3 -3
- package/dist/model/index.mjs +1 -1
- package/dist/model/mesh-evidence-matchers.d.mts +12 -0
- package/dist/model/mesh-evidence-matchers.mjs +1 -0
- package/dist/model/native-model-loader.d.mts +8 -8
- package/dist/model/native-model-loader.mjs +1 -1
- package/dist/model/node/command-exporter.d.mts +33 -0
- package/dist/model/node/command-exporter.mjs +1 -0
- package/dist/model/node/index.d.mts +2 -0
- package/dist/model/node/index.mjs +1 -0
- package/dist/model/types.d.mts +111 -63
- package/dist/runner/collector.d.mts +0 -2
- package/dist/runner/index.d.mts +1 -1
- package/dist/runner/native/index.mjs +1 -1
- package/dist/runner/native/native-serial-runner.mjs +1 -1
- package/dist/runner/node/engine.d.mts +40 -0
- package/dist/runner/node/engine.mjs +1 -0
- package/dist/runner/node/index.d.mts +5 -0
- package/dist/runner/node/index.mjs +1 -0
- package/dist/runner/node/node-vm-filesystem.d.mts +22 -0
- package/dist/runner/node/node-vm-filesystem.mjs +1 -0
- package/dist/runner/node/pool-runner.d.mts +67 -0
- package/dist/runner/node/pool-runner.mjs +1 -0
- package/dist/runner/node/pool-worker-entry.d.mts +43 -0
- package/dist/runner/node/pool-worker-entry.mjs +1 -0
- package/dist/runner/pool/events.mjs +1 -0
- package/dist/runner/pool/pool-messages.d.mts +2 -10
- package/dist/runner/pool/pool.d.mts +36 -0
- package/dist/runner/pool/pool.mjs +1 -0
- package/dist/runner/pool/shard-planner.mjs +1 -0
- package/dist/runner/pool/shard-timings.d.mts +36 -0
- package/dist/runner/pool/transport.mjs +1 -0
- package/dist/runner/pool/worker-host.d.mts +36 -0
- package/dist/runner/pool/worker-host.mjs +1 -0
- package/dist/runner/run-geospec-module.mjs +7 -7
- package/dist/runner/types.d.mts +9 -10
- package/dist/runner/worker/index.d.mts +5 -2
- package/dist/runner/worker/index.mjs +1 -1
- package/dist/runner/worker/runner-types.d.mts +2 -14
- package/dist/runner/worker/serial-runner.mjs +1 -1
- package/package.json +28 -5
- package/dist/config/tau-project-artifact.d.mts +0 -54
- package/dist/config/tau-project-artifact.mjs +0 -3
- package/dist/model/export-intent.d.mts +0 -79
- package/dist/model/export-intent.mjs +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# geospec — Functions
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
46 top-level symbols. Signatures are verbatim typescript.
|
|
4
4
|
|
|
5
5
|
// GeoSpec suite helper used inside VM-executed test modules
|
|
6
6
|
// describe (function)
|
|
@@ -67,20 +67,11 @@ export declare function createModelLoader(defaults: CreateModelLoaderOptions): M
|
|
|
67
67
|
export declare function loadModel<Code extends Record<string, string> = Record<string, string>>(_options: LoadModelOptions<Code>): Promise<GeoSpecSubject>;
|
|
68
68
|
// _options: Source, code, or file model load options
|
|
69
69
|
|
|
70
|
-
//
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
meshAngularToleranceDegrees?: number;
|
|
76
|
-
/**
|
|
77
|
-
* The kernel that evaluates this source, when the host knows it. Routes are
|
|
78
|
-
* then chosen among that kernel's own, so a mesh-only kernel is told its
|
|
79
|
-
* BRep matchers are unsupported instead of being sent to another kernel's
|
|
80
|
-
* STEP route.
|
|
81
|
-
*/
|
|
82
|
-
kernelId?: string;
|
|
83
|
-
}): RuntimeExportIntent | RuntimeExportIntentFailure;
|
|
70
|
+
// Create a model exporter that runs a command speaking GeoSpec subprocess protocol 1
|
|
71
|
+
// Throws: TypeError when the options are incomplete or declare `inlineSources`.
|
|
72
|
+
// commandExporter (function)
|
|
73
|
+
export declare function commandExporter(options: CommandExporterOptions): GeoSpecModelExporter;
|
|
74
|
+
// options: The exporter's identity, command and declared capabilities
|
|
84
75
|
|
|
85
76
|
// clearCollectorGlobals (function)
|
|
86
77
|
export declare function clearCollectorGlobals(): void;
|
|
@@ -155,12 +146,52 @@ export declare function allocateNativePoolGrants(options: {
|
|
|
155
146
|
// Create a native model loader that admits actual STEP/GLB bytes and retains generation-checked handles until the owning runner finishes
|
|
156
147
|
// createGeoSpecNativeModelLoader (function)
|
|
157
148
|
export declare function createGeoSpecNativeModelLoader(defaults: CreateGeoSpecNativeModelLoaderOptions): ManagedGeoSpecNativeModelLoader;
|
|
158
|
-
// defaults: Native engine,
|
|
149
|
+
// defaults: Native engine, exporters, and optional source reader
|
|
150
|
+
|
|
151
|
+
// Create a Node `VmFileSystem` rooted at `root`
|
|
152
|
+
// createNodeVmFileSystem (function)
|
|
153
|
+
export declare function createNodeVmFileSystem(root: string): VmFileSystem;
|
|
154
|
+
// root: Absolute project root path
|
|
155
|
+
|
|
156
|
+
// Resolve one VM path to a real path under the root
|
|
157
|
+
// Throws: Error when the path escapes the root.
|
|
158
|
+
// resolveUnderRoot (function)
|
|
159
|
+
export declare function resolveUnderRoot(root: string, path: string): string;
|
|
160
|
+
// root: The project root
|
|
161
|
+
// path: A canonical path rooted by the supplied project capability
|
|
162
|
+
|
|
163
|
+
// Create a GeoSpec engine for this process
|
|
164
|
+
// Throws: Error when the native addon is installed but cannot load, or the permits are invalid.
|
|
165
|
+
// createNodeGeoSpecEngine (function)
|
|
166
|
+
export declare function createNodeGeoSpecEngine(options?: CreateNodeGeoSpecEngineOptions): Promise<NodeGeoSpecEngine>;
|
|
167
|
+
// options: CPU permits for the native addon
|
|
168
|
+
|
|
169
|
+
// Create a pool with one engine and one set of exporters constructed inside each worker
|
|
170
|
+
// Remarks: Workers are threads of this process and share one OCCT library instance and pool width, so inner parallelism is all-or-nothing: either several workers with one permit each, or one worker holding the whole budget. A budget above the worker count with more than one worker is refused before any worker starts rather than silently run serial.
|
|
171
|
+
// Throws: RangeError When the budget is invalid, exceeds the host cap, or gives any of several in-process workers more than one permit.
|
|
172
|
+
// createGeoSpecNodePoolRunner (function)
|
|
173
|
+
export declare function createGeoSpecNodePoolRunner(options: GeoSpecNodePoolOptions): GeoSpecRunner;
|
|
174
|
+
// options: Project, config, exporter modules, outer workers and caller-inclusive CPU budget
|
|
175
|
+
|
|
176
|
+
// Adapt a Node worker thread to the pool's host-agnostic handle
|
|
177
|
+
// createNodeWorkerHandle (function)
|
|
178
|
+
export declare function createNodeWorkerHandle(worker: NodeWorkerLike): GeoSpecPoolWorkerHandle;
|
|
179
|
+
// worker: The spawned worker
|
|
159
180
|
|
|
160
181
|
// Create a run-level issue when filters select no tests
|
|
161
182
|
// createNoMatchingGeoSpecTestsIssue (function)
|
|
162
183
|
export declare function createNoMatchingGeoSpecTestsIssue(): VmIssue;
|
|
163
184
|
|
|
185
|
+
// Create the host-agnostic pool runner
|
|
186
|
+
// createGeoSpecPoolRunner (function)
|
|
187
|
+
export declare function createGeoSpecPoolRunner(options: GeoSpecPoolOptions): GeoSpecRunner;
|
|
188
|
+
// options: Worker factory, worker count, telemetry and event hook
|
|
189
|
+
|
|
190
|
+
// Serve shards until the host says shutdown
|
|
191
|
+
// startGeoSpecPoolWorkerHost (function)
|
|
192
|
+
export declare function startGeoSpecPoolWorkerHost(options: GeoSpecPoolWorkerHostOptions): void;
|
|
193
|
+
// options: Worker filesystem, native engine, and message plumbing
|
|
194
|
+
|
|
164
195
|
// Create a standalone native GeoSpec assertion client
|
|
165
196
|
// createGeoSpecAssertionClient (function)
|
|
166
197
|
export declare function createGeoSpecAssertionClient(options: GeoSpecAssertionClientOptions): GeoSpecAssertionClient;
|
|
@@ -176,7 +207,7 @@ export declare function createGeoSpecMatcherMethods<Result>(options: {
|
|
|
176
207
|
// options: Subject, polarity and host invocation function
|
|
177
208
|
|
|
178
209
|
// Submit an ancillary query with positive polarity through the native core
|
|
179
|
-
// Remarks:
|
|
210
|
+
// Remarks: A query asserts nothing, so it never fails: when the evidence it reads is missing or cannot decide it returns a full refused report whose diagnostic names the reason, such as `GEOSPEC_UNSUPPORTED_EVIDENCE`. Protocol errors propagate unchanged. Rust owns defaults, validation and canonical encoding.
|
|
180
211
|
// evaluateGeoSpecNativeQuery (function)
|
|
181
212
|
export declare function evaluateGeoSpecNativeQuery(options: GeoSpecNativeQueryOptions): GeoSpecCanonicalClaimReport;
|
|
182
213
|
// options: Query identity, subject and authored payload
|
|
@@ -187,6 +218,17 @@ export declare function evaluateGeoSpecNativeQuery(options: GeoSpecNativeQueryOp
|
|
|
187
218
|
export declare function resolveGeoSpecMaximumWorkUnitLimit(maximum?: number): number;
|
|
188
219
|
// maximum: The host's configured maximum, when it sets one
|
|
189
220
|
|
|
221
|
+
// Run the CLI
|
|
222
|
+
// runGeoSpecCli (function)
|
|
223
|
+
export declare function runGeoSpecCli(argv: readonly string[], host: GeoSpecCliHost): Promise<number>;
|
|
224
|
+
// argv: Arguments after the executable and script
|
|
225
|
+
// host: The injected platform
|
|
226
|
+
|
|
227
|
+
// Build the Node CLI host
|
|
228
|
+
// createNodeGeoSpecCliHost (function)
|
|
229
|
+
export declare function createNodeGeoSpecCliHost(options?: NodeGeoSpecCliHostOptions): GeoSpecCliHost;
|
|
230
|
+
// options: Report sink and host-supplied exporter modules
|
|
231
|
+
|
|
190
232
|
// Create Vitest matchers over an existing runner-independent client
|
|
191
233
|
// createGeoSpecVitestAdapter (function)
|
|
192
234
|
export declare function createGeoSpecVitestAdapter(client: GeoSpecAssertionClient): GeoSpecVitestAdapter;
|
|
@@ -202,14 +244,20 @@ export declare function installGeoSpecVitest(client: GeoSpecAssertionClient): Ge
|
|
|
202
244
|
export declare function setupGeoSpecVitest(options: GeoSpecAssertionClientOptions): GeoSpecVitestAdapter;
|
|
203
245
|
// options: Flat native assertion-client options
|
|
204
246
|
|
|
205
|
-
//
|
|
206
|
-
// Remarks:
|
|
207
|
-
//
|
|
208
|
-
export declare function
|
|
209
|
-
//
|
|
247
|
+
// Type a `geospec.config.*` default export
|
|
248
|
+
// Remarks: An identity at runtime. The parameter is not generic, so an object literal gets the excess-property and contextual checks `satisfies GeoSpecConfig` gives, in `.ts` and `.js` alike.
|
|
249
|
+
// defineConfig (function)
|
|
250
|
+
export declare function defineConfig(config: GeoSpecConfig): GeoSpecConfig;
|
|
251
|
+
// config: The project configuration
|
|
252
|
+
|
|
253
|
+
// Read a project's `geospec.config.*` data fields through the spec VM, the same way on every host
|
|
254
|
+
// Remarks: Discovery is `loadGeoSpecConfig`'s: exactly one of `geospec.config.{ts,mts,js,mjs}`. The config may import `geospec/config` (for `defineConfig`) and project files, nothing from `node_modules`: imports are detected first, without a network call, so a config with exporters is `not-applied` rather than fetched. `exporters` are never returned; a host that reads the config holds its own.
|
|
255
|
+
// readGeoSpecConfig (function)
|
|
256
|
+
export declare function readGeoSpecConfig(options: ReadGeoSpecConfigOptions): Promise<ReadGeoSpecConfigResult>;
|
|
257
|
+
// options: The project filesystem and the rooted project directory
|
|
210
258
|
|
|
211
259
|
// Load one trusted project config using Node's native module loader
|
|
212
|
-
// Remarks: Explicit selection or exactly one geospec.config.js/.mjs/.ts/.mts is allowed. TypeScript must use erasable syntax; JSON imports use standard attributes. Executable config/imports are trusted developer code, not sandboxed code. Node's same-process module cache is unchanged: load once per run and use a fresh process when fresh executable imports are required. No reload guarantee or transitive-source identity is supplied here.
|
|
260
|
+
// Remarks: Explicit selection or exactly one geospec.config.js/.mjs/.ts/.mts is allowed. A config's `geospec/config` import resolves to this copy when the project has no install of its own. TypeScript must use erasable syntax; JSON imports use standard attributes. Executable config/imports are trusted developer code, not sandboxed code. Node's same-process module cache is unchanged: load once per run and use a fresh process when fresh executable imports are required. No reload guarantee or transitive-source identity is supplied here.
|
|
213
261
|
// loadGeoSpecConfig (function)
|
|
214
262
|
export declare function loadGeoSpecConfig(options: LoadGeoSpecConfigOptions): Promise<LoadedGeoSpecConfig>;
|
|
215
263
|
// options: Project, optional explicit config and defined option overrides
|