@metamesh/cli 0.19.0 → 0.20.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 (59) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/README.md +6 -4
  3. package/dist/authoring/artifacts.d.ts.map +1 -1
  4. package/dist/authoring/artifacts.js +2 -1
  5. package/dist/authoring/artifacts.js.map +1 -1
  6. package/dist/authoring/render/client-bundle.js +172 -172
  7. package/dist/authoring/render/client-bundle.js.map +4 -4
  8. package/dist/authoring/render/scene.d.ts.map +1 -1
  9. package/dist/authoring/render/scene.js +2 -1
  10. package/dist/authoring/render/scene.js.map +1 -1
  11. package/dist/authoring/types.d.ts +2 -1
  12. package/dist/authoring/types.d.ts.map +1 -1
  13. package/dist/authoring/types.js.map +1 -1
  14. package/dist/docs/guides/agent-authoring.md +45 -245
  15. package/dist/docs/guides/local-authoring.md +216 -0
  16. package/dist/docs/guides/package.md +6 -4
  17. package/dist/docs/manifest.json +74 -56
  18. package/dist/docs/reference/authoring/AUTHORING_PROTOCOL_VERSION.md +1 -1
  19. package/dist/docs/reference/authoring/AuthoringDiagnostic.md +1 -1
  20. package/dist/docs/reference/authoring/AuthoringEnvironment.md +1 -1
  21. package/dist/docs/reference/authoring/AuthoringError.md +1 -1
  22. package/dist/docs/reference/authoring/AuthoringFailure-type.md +1 -1
  23. package/dist/docs/reference/authoring/AuthoringKind.md +1 -1
  24. package/dist/docs/reference/authoring/AuthoringPhase.md +1 -1
  25. package/dist/docs/reference/authoring/CaptureExportFormat.md +1 -1
  26. package/dist/docs/reference/authoring/CaptureExportOptions.md +1 -1
  27. package/dist/docs/reference/authoring/CaptureExportResult.md +1 -1
  28. package/dist/docs/reference/authoring/CapturedBuffer.md +1 -1
  29. package/dist/docs/reference/authoring/CapturedGeometry.md +1 -1
  30. package/dist/docs/reference/authoring/CapturedPart.md +1 -1
  31. package/dist/docs/reference/authoring/CapturedResource.md +1 -1
  32. package/dist/docs/reference/authoring/CapturedRun.md +1 -1
  33. package/dist/docs/reference/authoring/CapturedRunManifest.md +1 -1
  34. package/dist/docs/reference/authoring/CheckOptions.md +1 -1
  35. package/dist/docs/reference/authoring/CheckSuccess.md +1 -1
  36. package/dist/docs/reference/authoring/DocumentationEntry.md +1 -1
  37. package/dist/docs/reference/authoring/DocumentationManifest.md +1 -1
  38. package/dist/docs/reference/authoring/DocumentationSearchResult.md +1 -1
  39. package/dist/docs/reference/authoring/InstalledAuthoringPackage.md +1 -1
  40. package/dist/docs/reference/authoring/RenderCamera.md +1 -1
  41. package/dist/docs/reference/authoring/RenderFormat.md +1 -1
  42. package/dist/docs/reference/authoring/RenderOptions.md +1 -1
  43. package/dist/docs/reference/authoring/RenderResult.md +1 -1
  44. package/dist/docs/reference/authoring/RenderView.md +1 -1
  45. package/dist/docs/reference/authoring/RenderedImage.md +1 -1
  46. package/dist/docs/reference/authoring/RunOptions.md +1 -1
  47. package/dist/docs/reference/authoring/RunSuccess.md +1 -1
  48. package/dist/docs/reference/authoring/authoringFailure-value.md +1 -1
  49. package/dist/docs/reference/authoring/checkAuthoringSource.md +1 -1
  50. package/dist/docs/reference/authoring/discoverAuthoringEnvironment.md +1 -1
  51. package/dist/docs/reference/authoring/exportCapturedRun.md +1 -1
  52. package/dist/docs/reference/authoring/inspectCapturedRun.md +1 -1
  53. package/dist/docs/reference/authoring/installAuthoringBrowser.md +1 -1
  54. package/dist/docs/reference/authoring/readCapturedRun.md +1 -1
  55. package/dist/docs/reference/authoring/renderCapturedRun.md +1 -1
  56. package/dist/docs/reference/authoring/runAuthoringSource.md +1 -1
  57. package/dist/docs/reference/authoring/searchAuthoringDocumentation.md +1 -1
  58. package/dist/docs/reference/authoring/showAuthoringDocumentation.md +1 -1
  59. package/package.json +6 -6
@@ -1 +1 @@
1
- {"version":3,"file":"scene.d.ts","sourceRoot":"","sources":["../../../src/authoring/render/scene.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,IAAI,EAKJ,KAAK,E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AC/B;AAED,UAAU,qBAAqB;IAC7B,QAAQ,CAAC,KAAK,EAAE,KAAK,CAAC;IACtB,QAAQ,CAAC,KAAK,EAAE,KAAK,CAAC;IACtB,QAAQ,CAAC,MAAM,EAAE,IAAI,CAAC;IACtB,QAAQ,CAAC,OAAO,EAAE,MAAM,IAAI,CAAC;CAC9B;AAED,oEAAoE;AACpE,wBAAgB,kBAAkB,CAChC,KAAK,EAAE,YAAY,EACnB,SAAS,EAAE,SAAS,cAAc,EAAE,GACnC,qBAAqB,CAwEvB;AAED,kFAAkF;AAClF,wBAAgB,mBAAmB,CACjC,MAAM,EAAE,IAAI,EACZ,IAAI,EAAE,UAAU,EAChB,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM,GACb;IAAE,MAAM,EAAE,kBAAkB,CAAC;IAAC,MAAM,EAAE,YAAY,CAAA;CAAE,CA6CtD"}
@@ -1,5 +1,6 @@
1
1
  import { Box3, BufferAttribute, BufferGeometry, Color, DirectionalLight, Group, HemisphereLight, Mesh, MeshStandardMaterial, OrthographicCamera, Scene, Vector3, } from "three";
2
- import { transform3, validateRigidTransform3 } from "@metamesh/modeling/geometry";
2
+ import { transform3 } from "@metamesh/modeling/geometry";
3
+ import { validateRigidTransform3 } from "@metamesh/modeling/geometry/math";
3
4
  /** @internal Owns one capture's GPU-independent scene resources. */
4
5
  export function createCaptureScene(input, resources) {
5
6
  const scene = new Scene();
@@ -1 +1 @@
1
- {"version":3,"file":"scene.js","sourceRoot":"","sources":["../../../src/authoring/render/scene.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,IAAI,EACJ,eAAe,EACf,cAAc,EACd,KAAK,EACL,gBAAgB,EAChB,KAAK,EACL,eAAe,EACf,IAAI,EACJ,oBAAoB,EACpB,kBAAkB,EAClB,KAAK,EACL,OAAO,GACR,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,UAAU,EAAE,uBAAuB,EAAE,MAAM,6BAA6B,CAAC;AAiBlF,oEAAoE;AACpE,MAAM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L,MAAM;QACN,MAAM,EAAE;YACN,QAAQ,EAAE,MAAM,CAAC,QAAQ,CAAC,OAAO,EAAE;YACnC,MAAM,EAAE,MAAM,CAAC,OAAO,EAAE;YACxB,EAAE,EAAE,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE;YACvB,OAAO,EAAE;gBACP,IAAI,EAAE,MAAM,CAAC,IAAI;gBACjB,KAAK,EAAE,MAAM,CAAC,KAAK;gBACnB,GAAG,EAAE,MAAM,CAAC,GAAG;gBACf,MAAM,EAAE,MAAM,CAAC,MAAM;gBACrB,IAAI,EAAE,MAAM,CAAC,IAAI;gBACjB,GAAG,EAAE,MAAM,CAAC,GAAG;aAChB;SACF;KACF,CAAC;AACJ,CAAC;AAED,SAAS,aAAa,CAAC,IAAgB;IACrC,QAAQ,IAAI,EAAE,CAAC;QACb,KAAK,WAAW;YACd,OAAO,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;QACpB,KAAK,OAAO;YACV,OAAO,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;QACpB,KAAK,KAAK;YACR,OAAO,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;QACnB,KAAK,OAAO;YACV,OAAO,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;IACrB,CAAC;AACH,CAAC"}
1
+ {"version":3,"file":"scene.js","sourceRoot":"","sources":["../../../src/authoring/render/scene.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,IAAI,EACJ,eAAe,EACf,cAAc,EACd,KAAK,EACL,gBAAgB,EAChB,KAAK,EACL,eAAe,EACf,IAAI,EACJ,oBAAoB,EACpB,kBAAkB,EAClB,KAAK,EACL,OAAO,GACR,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AACzD,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAiB3E,oEAAoE;AACpE,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O;QACL,MAAM;QACN,MAAM,EAAE;YACN,QAAQ,EAAE,MAAM,CAAC,QAAQ,CAAC,OAAO,EAAE;YACnC,MAAM,EAAE,MAAM,CAAC,OAAO,EAAE;YACxB,EAAE,EAAE,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE;YACvB,OAAO,EAAE;gBACP,IAAI,EAAE,MAAM,CAAC,IAAI;gBACjB,KAAK,EAAE,MAAM,CAAC,KAAK;gBACnB,GAAG,EAAE,MAAM,CAAC,GAAG;gBACf,MAAM,EAAE,MAAM,CAAC,MAAM;gBACrB,IAAI,EAAE,MAAM,CAAC,IAAI;gBACjB,GAAG,EAAE,MAAM,CAAC,GAAG;aAChB;SACF;KACF,CAAC;AACJ,CAAC;AAED,SAAS,aAAa,CAAC,IAAgB;IACrC,QAAQ,IAAI,EAAE,CAAC;QACb,KAAK,WAAW;YACd,OAAO,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;QACpB,KAAK,OAAO;YACV,OAAO,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;QACpB,KAAK,KAAK;YACR,OAAO,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;QACnB,KAAK,OAAO;YACV,OAAO,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC,CAAC;IACrB,CAAC;AACH,CAAC"}
@@ -1,5 +1,6 @@
1
- import type { Bounds3Data, GenerationDiagnostic, ModelingLimits, Transform3Data } from "@metamesh/modeling";
1
+ import type { GenerationDiagnostic } from "@metamesh/modeling";
2
2
  import type { ModelDependencies, ModelPart, ModelResult } from "@metamesh/modeling/engine";
3
+ import type { Bounds3Data, ModelingLimits, Transform3Data } from "@metamesh/modeling/geometry";
3
4
  /** Version of the CLI authoring protocol, independent of package SemVer and engine compatibility. */
4
5
  export declare const AUTHORING_PROTOCOL_VERSION = 1;
5
6
  /** Selects a standalone ModelProgram entry or an SDK Generator module with a definition. */
@@ -1 +1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,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,MAAM,EAAE,cAAc,CAAA;KAAE,CAAC;IACjF,QAAQ,CAAC,WAAW,EAAE,SAAS,oBAAoB,EAAE,CAAC;IACtD,QAAQ,CAAC,MAAM,EAAE,WAAW,CAAC;IAC7B,QAAQ,CAAC,KAAK,EAAE,WAAW,CAAC,OAAO,CAAC,CAAC;IACrC,QAAQ,CAAC,YAAY,EAAE,iBAAiB,CAAC;IACzC,QAAQ,CAAC,SAAS,EAAE,SAAS,gBAAgB,EAAE,CAAC;IAChD,QAAQ,CAAC,KAAK,EAAE,SAAS,YAAY,EAAE,CAAC;CACzC;AACD,oFAAoF;AACpF,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,SAAS,EAAE,YAAY,CAAC;IACjC,QAAQ,CAAC,OAAO,EAAE,WAAW,CAAC;CAC/B;AACD,0FAA0F;AAC1F,MAAM,WAAW,WAAW;IAC1B,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,QAAQ,EAAE,mBAAmB,CAAC;IACvC,QAAQ,CAAC,SAAS,EAAE,SAAS,gBAAgB,EAAE,CAAC;CACjD;AACD,wGAAwG;AACxG,MAAM,WAAW,UAAU;IACzB,QAAQ,CAAC,OAAO,EAAE,IAAI,CAAC;IACvB,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,QAAQ,EAAE,mBAAmB,CAAC;CACxC"}
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/authoring/types.ts"],"names":[],"mappings":"AAQA,qGAAqG;AACrG,MAAM,CAAC,MAAM,0BAA0B,GAAG,CAAC,CAAC"}
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/authoring/types.ts"],"names":[],"mappings":"AAIA,qGAAqG;AACrG,MAAM,CAAC,MAAM,0BAA0B,GAAG,CAAC,CAAC"}
@@ -1,274 +1,74 @@
1
- # Author and inspect models with an agent
1
+ # Work with a coding agent
2
2
 
3
- Use the CLI to find installed docs, check TypeScript, capture a model, and inspect measurements and rendered views.
3
+ Combine portable skills, installed API knowledge, and CLI tools in your own modeling workflow.
4
4
 
5
- Use the `metamesh` CLI to build a model and check what it actually produced. You or your agent can
6
- look up the installed API, check TypeScript, run the model, and inspect measurements and views of
7
- the captured result. The CLI runs trusted local source with your ordinary Node permissions. Its
8
- disposable child process isn't a security sandbox.
5
+ MetaMesh gives coding agents a layer of modeling guidance and executable tools. Use them with
6
+ your preferred editor, agent, and project workflow to create TypeScript models, inspect their
7
+ dimensions, and review what they look like.
9
8
 
10
- ## Install and discover the environment
9
+ ## Two pieces that work together
11
10
 
12
- Use Node.js 24 or newer. The package APIs publish ES modules only. TypeScript API consumers
13
- use TypeScript 6.0 or newer with `strict` checking and `NodeNext` or `Bundler` resolution;
14
- the CLI includes its source-checking compiler.
11
+ | Piece | What it gives your agent | Start here |
12
+ | ------------------- | ----------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------- |
13
+ | **CLI tools** | Installed documentation lookup, TypeScript checks, model execution, inspection, rendering, and export | [CLI guide](local-authoring.md) |
14
+ | **Portable skills** | A repeatable process for discovering APIs, authoring models, and verifying results | [metamesh-skills](https://github.com/metamesh-studio/metamesh-skills) |
15
15
 
16
- Install Modeling for your model code and the CLI for the local authoring workflow:
16
+ The CLI works from a terminal or script without an agent. Skills add guidance to a compatible
17
+ agent; they don't choose your editor, orchestrate your project, or replace your existing checks.
18
+ Both are optional alongside the Modeling API.
17
19
 
18
- ```bash
19
- pnpm add @metamesh/modeling
20
- pnpm add -D @metamesh/cli
21
- pnpm exec metamesh environment --json
22
- pnpm exec metamesh setup
23
- ```
24
-
25
- `environment` reports project-resolved versions, documentation locations, available capabilities,
26
- and `authoringProtocolVersion: 1`. An agent integration should check that protocol value before
27
- using the commands. Fix missing packages, mismatched releases, or an unsupported protocol before
28
- authoring.
29
-
30
- Add the Generator SDK as a direct dependency when defining Generators, and Testkit when writing
31
- automated tests. Ordinary models need only Modeling and the CLI as direct dependencies. Keep
32
- installed MetaMesh packages on matching releases.
33
-
34
- | Component | Responsibility |
35
- | ------------------------- | --------------------------------------------------------------------------------------------- |
36
- | `@metamesh/modeling` | Geometry operations, synchronous generation, engine sessions, and completed snapshots |
37
- | `@metamesh/generator-sdk` | Serializable controls, parameter types and validation, and Generator module envelopes |
38
- | `@metamesh/cli` | Installed documentation lookup, TypeScript checking, captured runs, inspection, and rendering |
39
- | `@metamesh/testkit` | Generation runners, fixtures, and assertions for your test framework |
40
-
41
- Every public package exposes its offline documentation manifest through `./docs/manifest.json`.
42
- The CLI searches the packages installed in the selected project. Find a topic in the bounded index,
43
- then read the returned document ID:
44
-
45
- ```bash
46
- pnpm exec metamesh docs show modeling/guide/standalone-model
47
- pnpm exec metamesh docs search "cylinder"
48
- pnpm exec metamesh docs show modeling/reference/model/cylinder
49
- ```
50
-
51
- Start with the [standalone model example](https://metamesh.studio/docs/develop/standalone-model), or use the
52
- [construction map](https://metamesh.studio/docs/develop/geometry-recipes#choose-a-technique) to choose an approach
53
- for your shape. You can also search for a shape or symbol and read its recipe or reference.
54
- Search matches distinct words in titles, headings, keywords, and summaries. Exact titles, IDs, and imports take priority;
55
- equally complete intent matches favor guides.
56
-
57
- Documentation is resolved from the selected project through package exports. No global installation
58
- or documentation fetched from a moving Git branch replaces the installed version.
59
-
60
- ### Give an agent the same workflow
61
-
62
- `setup` prints skill installation guidance and a project-instruction snippet for review without
63
- modifying files, installing skills, or initializing a model. The optional `metamesh-developer` skill
64
- covers authoring and verification; `metamesh-docs` covers documentation. Both are maintained in
65
- `metamesh-studio/metamesh-skills`.
66
-
67
- Use a reviewed skill snapshot provided by your project or installed through your agent's skill
68
- tooling. The printed GitHub installation source must be published before that command can work;
69
- a skill is optional for the CLI workflow below. Skills teach the process. The installed npm
70
- documentation supplies exact signatures, import paths, units, execution rules, and availability.
71
20
 
72
- Project instructions should require environment discovery, relevant documentation lookup, source
73
- checking and execution, then measurement inspection and useful rendered views from that same run.
74
- Include your project’s commands and required checks. Pass `--project PATH` consistently when
75
- targeting another directory so every step resolves the same installation.
76
21
 
77
- ## Model entries
22
+ **Skills teach the process; installed docs supply the API**
78
23
 
79
- A model entry default-exports a `ModelProgram` and imports the installed package directly.
80
- Studio's virtual `@metamesh/project` module isn't available in local Node projects.
24
+ Let the skill guide the next step. Look up exact signatures, imports, units, and supported
25
+ behavior in the packages installed in your project so the code matches the version you run.
81
26
 
82
27
 
83
28
 
84
- ```ts
85
- import { box, cylinder, generate } from "@metamesh/modeling";
29
+ ## Set up your agent
86
30
 
87
- export default generate<Record<never, never>>(({ part }) => {
88
- const body = box({ size: [30, 20, 6] });
89
- const bore = cylinder({ height: 8, radius: 3, sizing: "face" });
90
- return part("plate", body.subtract(bore));
91
- });
92
- ```
93
-
94
-
95
-
96
- Save this as `model.ts`, then check and run it:
31
+ First [install Modeling and the CLI](local-authoring.md#install-and-discover-the-environment).
32
+ Then print the available skill installation guidance and a suggested project-instruction snippet:
97
33
 
98
34
  ```bash
99
- pnpm exec metamesh typecheck model.ts --kind model
100
- pnpm exec metamesh run model.ts --kind model
101
- ```
102
-
103
- Both commands check TypeScript types using the nearest project TypeScript configuration, or an
104
- explicit `--tsconfig`, with strict checking enforced. You can use ordinary local imports and
105
- installed dependencies. `typecheck` doesn't evaluate your source.
106
-
107
- Use `--params values.json` for a model's JSON parameter map; the default is `{}`. Models do not
108
- receive injected Generator services. A standalone module can prepare licensed local fonts before
109
- constructing its synchronous generation program.
110
-
111
- To record which local fonts you used, also pass `--font-fixtures fonts.json`. The CLI verifies those
112
- bytes and records their declared font selections and immutable revisions in the capture; the model
113
- still prepares its own fonts and receives no injected services. Arbitrary filesystem or network
114
- reads aren't intercepted, so the CLI can't infer their asset identities. The source fingerprint
115
- covers bundled source, while fixture descriptors provide explicit asset provenance.
116
-
117
- ## Generator entries
118
-
119
- Install the Generator SDK alongside Modeling and the CLI to define controls and package metadata:
120
-
121
- ```bash
122
- pnpm add @metamesh/generator-sdk
123
- ```
124
-
125
- A Generator entry named-exports `definition` and default-exports its module envelope:
126
-
127
-
128
-
129
- ```ts
130
- import { defineGenerator } from "@metamesh/generator-sdk";
131
- import { defineGeneratorModel } from "@metamesh/generator-sdk/modeling";
132
- import { box } from "@metamesh/modeling";
133
-
134
- export const definition = defineGenerator({
135
- id: "plate",
136
- version: "0.1.0",
137
- title: "Plate",
138
- groups: [],
139
- parameters: [{ id: "width", label: "Width", type: "number", default: 30, min: 1 }],
140
- });
141
-
142
- export default defineGeneratorModel(definition, ({ params, part }) =>
143
- part("plate", box({ size: [params.width, 20, 6] }))
144
- );
145
- ```
146
-
147
-
148
-
149
- `defineGeneratorModel` from the optional SDK `/modeling` adapter infers controls, prepared services,
150
- and assertion parameter IDs. It declares the ordinary Modeling program and package identity;
151
- the host still owns normalization, asset preparation, execution, and cleanup.
152
-
153
- ```bash
154
- pnpm exec metamesh typecheck generator.ts --kind generator
155
- pnpm exec metamesh run generator.ts --kind generator --overrides values.json
156
- ```
157
-
158
- Generator runs merge declared defaults with explicit overrides, then validate strictly. Unknown
159
- keys, invalid values, and unsupported combinations produce diagnostics. They are not silently
160
- clamped or repaired. Use assertions for relationships between parameters.
161
-
162
- Generators with Font controls supply a local font-fixture descriptor with `--font-fixtures fonts.json`.
163
- Fixtures resolve beside that descriptor and must match their immutable revisions. Missing
164
- bytes and revision mismatches fail before generation; the CLI does not fetch catalog fonts.
165
-
166
- ## Inspect the captured result
167
-
168
- Each run creates a unique directory under `.metamesh/runs`, or the explicit output parent. Use the
169
- run directory reported by that command as `RUN_DIRECTORY` below:
170
-
171
- ```bash
172
- pnpm exec metamesh inspect RUN_DIRECTORY
173
- pnpm exec metamesh inspect RUN_DIRECTORY --part plate
174
- pnpm exec metamesh export RUN_DIRECTORY --format 3mf --output plate.3mf
175
- pnpm exec metamesh browser install
176
- pnpm exec metamesh render RUN_DIRECTORY
177
- pnpm exec metamesh render RUN_DIRECTORY --views top --format webp --transparent
178
- ```
179
-
180
- Inspection reads the completed model's part IDs, placements, colors, measurements, diagnostics,
181
- and execution provenance. Rendering uses the same captured buffers without rerunning the model,
182
- so the dimensions you inspect and the views you render belong to the same result. Captures remain
183
- usable after the engine session is disposed or the directory moves. Corrupt or incomplete
184
- artifacts are rejected.
185
-
186
- Rendering requires the separately installed pinned Chromium. It is never downloaded implicitly;
187
- checking, generation, and inspection work without it. Standard orthographic views are isometric,
188
- front, top, and right. The default is an isometric 1024 × 1024 PNG on a neutral background. WebP is
189
- lossless; PNG and WebP both support explicit transparent output. Images record their run, camera,
190
- renderer, and browser versions. Compare pixels only within the pinned capture environment.
191
-
192
- `export` reads the completed capture and writes `3mf`, `stl`, or `glb` without rerunning source.
193
- The required `--output` selects the destination file; the result reports format limitations as
194
- structured diagnostics. A failed attempt never exposes an older successful result as its output.
195
- Match the captured parameters and source fingerprint to the revision you intended to verify.
196
-
197
- ## Test models
198
-
199
- Install Testkit separately when you want assertions and fixtures for your existing test runner:
200
-
201
- ```bash
202
- pnpm add -D @metamesh/testkit
35
+ pnpm exec metamesh setup
203
36
  ```
204
37
 
205
- Use `await runModel(({ part }) => part("body", box({ size: 2 })))` for a one-off model, or
206
- pass an existing program directly with `await runModel(program, parameters)`. Use
207
- `await runModel({ definition, runtime }, parameters)` for a Generator. The returned result remains
208
- usable after the helper releases its temporary session; no cleanup is required.
209
- For cached Generators, exercise representative edits through
210
- `createGeneratorTestRunner(definition, runtime, { verifyCache: true })` and its `run` method.
211
- One-shot tests and declaration checks do not verify reuse across edits. Use `cache: false` for
212
- an uncached output baseline; keep prepared services stable when testing reuse in the same session.
213
- Callbacks run synchronously and return a part or an array of parts. Declare typed inline inputs
214
- with `runModel<Parameters, Services>(callback, parameters, options)`, or reuse a
215
- `GenerateCallback<Parameters, Services>`. Parameterless callbacks and Generator defaults can omit parameters. Options stay in the third
216
- argument: use `undefined` for omitted parameters when supplying a test-owned engine, generation
217
- policy, prepared model services, or a Generator's asynchronous `prepareServices` adapter.
38
+ This command prints guidance for review. It does not modify files or install skills.
39
+ Use your agent's skill tooling to install a reviewed snapshot from
40
+ [metamesh-studio/metamesh-skills](https://github.com/metamesh-studio/metamesh-skills):
218
41
 
219
- For Generator integration tests, import the definition and default runtime from the real entry
220
- point instead of repeating its input resolution and builder calls. Use direct callbacks to isolate
221
- construction, reconstruct a mesh, or deliberately bypass schema validation.
42
+ - **`metamesh-developer`** guides model and Generator authoring, execution, and verification.
43
+ - **`metamesh-docs`** guides documentation work when your project needs it.
222
44
 
223
- Use `createGeneratorTestRunner(definition, runtime)` for a Generator's persistent generation
224
- session. `runner.run(parameters)` normalizes inputs, prepares assets, and returns a discriminated
225
- result. Handle `type: "invalid"`
226
- before reading a generated `model`. Successful results remain usable after later runs and runner
227
- disposal. Dispose the runner to release its session and caches. Use `engine.createSession(program, options)`
228
- for repeated plain-model edits or cache tests and dispose the session in `finally`; its returned
229
- results also remain usable. Unexpected execution or malformed-output errors reject.
45
+ Keep your project's build and test commands in its normal agent instructions. Teams integrating
46
+ the CLI programmatically should also check the environment's reported authoring protocol before
47
+ issuing commands; the [CLI guide](local-authoring.md#install-and-discover-the-environment) explains discovery.
230
48
 
231
- The runner normalizes saved values. To probe deliberately invalid typed inputs without that
232
- recovery, call `runner.check(parameters, { validateInput: false })`. Validation checks declarations
233
- and reached assertions without finalizing output; execute representative valid combinations too.
234
- The CLI's strict overrides serve a different purpose: they reject invalid or unknown values
235
- before execution instead of recovering saved state.
49
+ ## Give the agent a result to verify
236
50
 
237
- | Helper | What to check |
238
- | ------------------------ | ------------------------------------------------------------------ |
239
- | `assertValidDefinition` | Strict definition parsing and a canonical JSON round trip |
240
- | `assertValidDefaults` | Strict parameter decoding and agreement with defaults |
241
- | `assertValidPresets` | Serializable preset metadata; execute presets for domain rules |
242
- | `assertValidParts` | Part metadata, closed oriented topology, and native reconstruction |
243
- | `assertMeshMeasurements` | Bounds, area, signed volume, and connected-component count |
51
+ Describe the intended part, dimensions, adjustable inputs, and constraints. Ask for evidence from
52
+ the generated result as well as source. A useful request is:
244
53
 
245
- Compare physical measurements with explicit absolute tolerances: bounds use millimetres, area
246
- square millimetres, and volume cubic millimetres. Component counts are exact. Use rendered views
247
- alongside those assertions to check the shape. A valid solid alone doesn't prove a suitable fit or
248
- manufacturable wall thickness.
54
+ > Build a 30 × 20 × 6 mm plate with a central 6 mm through-hole. Check the source, run the model,
55
+ > inspect its bounds and volume, and render an isometric and top view from that run.
249
56
 
250
- For Font controls, supply the runner's `prepareServices` option using checked-in licensed bytes.
251
- `prepareFontTestServices` from `@metamesh/testkit/fonts` verifies immutable font revisions and
252
- prepares services without catalog downloads. Modeling's optional font peers are still required.
253
- Use installed documentation for the exact runner and fixture signatures:
254
-
255
- ```bash
256
- pnpm exec metamesh docs show testkit/guide/testing
257
- ```
57
+ Adapt the verification loop to your project:
258
58
 
259
- Testkit has no compiler, renderer, or browser dependencies. The CLI owns those tools and its
260
- reusable Node functions under `@metamesh/cli/authoring`; integrations can call them without
261
- spawning the command.
59
+ 1. **Discover:** inspect installed versions and read the relevant guides and symbols.
60
+ 2. **Build:** start with a [complete model](https://metamesh.studio/docs/develop/standalone-model) and check its TypeScript.
61
+ 3. **Run:** generate representative parameter combinations and inspect diagnostics and measurements.
62
+ 4. **Review:** render useful views from the same capture; check proportions, feature placement,
63
+ and anything the measurements don't establish.
262
64
 
263
- ## Command results
65
+ The [CLI guide](local-authoring.md#inspect-the-captured-result) owns the commands and capture details.
66
+ Add [automated assertions](local-authoring.md#test-models) when you need repeatable regression checks.
67
+ For interactive editing and controls, use [Studio code Projects](https://metamesh.studio/docs/develop/code-projects).
264
68
 
265
- Add `--json` for one structured result on stdout; bounded author logs go to stderr. The default
266
- output is concise text. Exit codes are:
267
69
 
268
- - `0`: success;
269
- - `1`: source, parameter, or generation failure;
270
- - `2`: invocation, environment, artifact, or tooling failure.
271
70
 
272
- Runs default to a 30-second execution deadline and can lower engine resource ceilings.
71
+ **Set physical requirements explicitly**
273
72
 
274
- Modeling and the Generator SDK remain independent of the CLI and its local Node tooling.
73
+ A successful run cannot establish the right fit, load capacity, or manufacturing process. Give the
74
+ agent measurable constraints, review its assumptions, and test a representative part.
@@ -0,0 +1,216 @@
1
+ # Check and render with the CLI
2
+
3
+ Look up installed APIs, check TypeScript, run local models, and inspect, render, or export the captured result.
4
+
5
+ Use the `metamesh` CLI from your terminal, scripts, or coding agent. It finds the installed API
6
+ documentation, checks TypeScript, runs models, and produces captures you can inspect, render,
7
+ and export. You choose how these tools fit into your workflow.
8
+
9
+
10
+
11
+ **Run source you trust**
12
+
13
+ Local model code runs with your ordinary Node permissions. The disposable child process is not a
14
+ security sandbox.
15
+
16
+
17
+
18
+ ## Install and discover the environment
19
+
20
+ Use Node.js 24 or newer. The package APIs publish ES modules only. TypeScript API consumers
21
+ use TypeScript 6.0 or newer with `strict` checking and `NodeNext` or `Bundler` resolution;
22
+ the CLI includes its source-checking compiler.
23
+
24
+ Install Modeling for your model code and the CLI for the local authoring workflow:
25
+
26
+ ```bash
27
+ pnpm add @metamesh/modeling
28
+ pnpm add -D @metamesh/cli
29
+ pnpm exec metamesh environment --json
30
+ ```
31
+
32
+ `environment` reports project-resolved versions, documentation locations, available capabilities,
33
+ and `authoringProtocolVersion: 1`. An agent integration should check that protocol value before
34
+ using the commands. Fix missing packages, mismatched releases, or an unsupported protocol before
35
+ authoring.
36
+
37
+ Add the Generator SDK as a direct dependency when defining Generators, and Testkit when writing
38
+ automated tests. Ordinary models need only Modeling and the CLI as direct dependencies. Keep
39
+ installed MetaMesh packages on matching releases.
40
+
41
+ | Component | Responsibility |
42
+ | ------------------------- | --------------------------------------------------------------------------------------------- |
43
+ | `@metamesh/modeling` | Geometry operations, synchronous generation, engine sessions, and completed snapshots |
44
+ | `@metamesh/generator-sdk` | Serializable controls, parameter types and validation, and Generator module envelopes |
45
+ | `@metamesh/cli` | Installed documentation lookup, TypeScript checking, captured runs, inspection, and rendering |
46
+ | `@metamesh/testkit` | Generation runners, fixtures, and assertions for your test framework |
47
+
48
+ Every public package exposes its offline documentation manifest through `./docs/manifest.json`.
49
+ The CLI searches the packages installed in the selected project. Find a topic in the bounded index,
50
+ then read the returned document ID:
51
+
52
+ ```bash
53
+ pnpm exec metamesh docs show modeling/guide/standalone-model
54
+ pnpm exec metamesh docs search "cylinder"
55
+ pnpm exec metamesh docs show modeling/reference/model/cylinder
56
+ ```
57
+
58
+ Start with the [standalone model example](https://metamesh.studio/docs/develop/standalone-model), or use the
59
+ [construction map](https://metamesh.studio/docs/develop/geometry-recipes#choose-a-technique) to choose an approach
60
+ for your shape. You can also search for a shape or symbol and read its recipe or reference.
61
+ Search matches distinct words in titles, headings, keywords, and summaries. Exact titles, IDs, and imports take priority;
62
+ equally complete intent matches favor guides.
63
+
64
+ Documentation is resolved from the selected project through package exports. No global installation
65
+ or documentation fetched from a moving Git branch replaces the installed version.
66
+
67
+ For optional portable skills and project instructions, see
68
+ [Work with a coding agent](agent-authoring.md). Use `--project PATH` consistently when
69
+ targeting another directory so discovery, lookup, and execution resolve the same installation.
70
+
71
+ ## Model entries
72
+
73
+ A model entry default-exports a `ModelProgram` and imports the installed package directly.
74
+ Studio's virtual `@metamesh/project` module isn't available in local Node projects.
75
+
76
+ Save the complete, rendered [standalone example](https://metamesh.studio/docs/develop/standalone-model) as `model.ts`,
77
+ then check and run it:
78
+
79
+ ```bash
80
+ pnpm exec metamesh typecheck model.ts --kind model
81
+ pnpm exec metamesh run model.ts --kind model
82
+ ```
83
+
84
+ Both commands check TypeScript types using the nearest project TypeScript configuration, or an
85
+ explicit `--tsconfig`, with strict checking enforced. You can use ordinary local imports and
86
+ installed dependencies. `typecheck` doesn't evaluate your source.
87
+
88
+ Use `--params values.json` for a model's JSON parameter map; the default is `{}`. Models do not
89
+ receive injected Generator services. A standalone module can prepare licensed local fonts before
90
+ constructing its synchronous generation program.
91
+
92
+ To record which local fonts you used, also pass `--font-fixtures fonts.json`. The CLI verifies those
93
+ bytes and records their declared font selections and immutable revisions in the capture; the model
94
+ still prepares its own fonts and receives no injected services. Arbitrary filesystem or network
95
+ reads aren't intercepted, so the CLI can't infer their asset identities. The source fingerprint
96
+ covers bundled source, while fixture descriptors provide explicit asset provenance.
97
+
98
+ ## Generator entries
99
+
100
+ Install the Generator SDK alongside Modeling and the CLI to define controls and package metadata:
101
+
102
+ ```bash
103
+ pnpm add @metamesh/generator-sdk
104
+ ```
105
+
106
+ A Generator entry named-exports `definition` and default-exports its module envelope:
107
+
108
+
109
+
110
+ ```ts
111
+ import { defineGenerator } from "@metamesh/generator-sdk";
112
+ import { defineGeneratorModel } from "@metamesh/generator-sdk/modeling";
113
+ import { box } from "@metamesh/modeling";
114
+
115
+ export const definition = defineGenerator({
116
+ id: "plate",
117
+ version: "0.1.0",
118
+ title: "Plate",
119
+ groups: [],
120
+ parameters: [{ id: "width", label: "Width", type: "number", default: 30, min: 1 }],
121
+ });
122
+
123
+ export default defineGeneratorModel(definition, ({ params, part }) =>
124
+ part("plate", box({ size: [params.width, 20, 6] }))
125
+ );
126
+ ```
127
+
128
+
129
+
130
+ `defineGeneratorModel` from the optional SDK `/modeling` adapter infers controls, prepared services,
131
+ and assertion parameter IDs. It declares the ordinary Modeling program and package identity;
132
+ the host still owns normalization, asset preparation, execution, and cleanup.
133
+
134
+ ```bash
135
+ pnpm exec metamesh typecheck generator.ts --kind generator
136
+ pnpm exec metamesh run generator.ts --kind generator --overrides values.json
137
+ ```
138
+
139
+ Generator runs merge declared defaults with explicit overrides, then validate strictly. Unknown
140
+ keys, invalid values, and unsupported combinations produce diagnostics. They are not silently
141
+ clamped or repaired. Use assertions for relationships between parameters.
142
+
143
+ Generators with Font controls supply a local font-fixture descriptor with `--font-fixtures fonts.json`.
144
+ Fixtures resolve beside that descriptor and must match their immutable revisions. Missing
145
+ bytes and revision mismatches fail before generation; the CLI does not fetch catalog fonts.
146
+
147
+ ## Inspect the captured result
148
+
149
+ Each run creates a unique directory under `.metamesh/runs`, or the explicit output parent. Use the
150
+ run directory reported by that command as `RUN_DIRECTORY` below:
151
+
152
+ ```bash
153
+ pnpm exec metamesh inspect RUN_DIRECTORY
154
+ pnpm exec metamesh inspect RUN_DIRECTORY --part plate
155
+ pnpm exec metamesh export RUN_DIRECTORY --format 3mf --output plate.3mf
156
+ pnpm exec metamesh browser install
157
+ pnpm exec metamesh render RUN_DIRECTORY
158
+ pnpm exec metamesh render RUN_DIRECTORY --views top --format webp --transparent
159
+ ```
160
+
161
+
162
+
163
+ **Inspect and render the same result**
164
+
165
+ Both commands read the captured geometry without rerunning source. Your measurements and images
166
+ describe one completed run, even after its engine session has closed.
167
+
168
+
169
+
170
+ Inspection reports part IDs, placements, colors, measurements, diagnostics, and execution provenance.
171
+ Captures remain usable when their directory moves. Corrupt or incomplete artifacts are rejected.
172
+
173
+ Rendering requires the separately installed pinned Chromium. It is never downloaded implicitly;
174
+ checking, generation, and inspection work without it. Standard orthographic views are isometric,
175
+ front, top, and right. The default is an isometric 1024 × 1024 PNG on a neutral background. WebP is
176
+ lossless; PNG and WebP both support explicit transparent output. Images record their run, camera,
177
+ renderer, and browser versions. Compare pixels only within the pinned capture environment.
178
+
179
+ `export` reads the completed capture and writes `3mf`, `stl`, or `glb` without rerunning source.
180
+ The required `--output` selects the destination file; the result reports format limitations as
181
+ structured diagnostics. A failed attempt never exposes an older successful result as its output.
182
+ Match the captured parameters and source fingerprint to the revision you intended to verify.
183
+
184
+ ## Test models
185
+
186
+ Add Testkit when you want repeatable assertions in your own test runner:
187
+
188
+ ```bash
189
+ pnpm add -D @metamesh/testkit
190
+ pnpm exec metamesh docs show testkit/guide/testing
191
+ ```
192
+
193
+ Testkit runs plain models and Generator entries and supplies geometry assertions. Test the real
194
+ entry point with defaults, limits, and representative combinations. For cached models, exercise
195
+ edits within one session and compare with uncached output; isolated runs cannot verify reuse.
196
+ The installed testing guide owns the runner, fixture, and assertion signatures.
197
+
198
+ Compare bounds in millimetres, area in square millimetres, and volume in cubic millimetres with
199
+ explicit absolute tolerances. Use renders alongside assertions: closed topology alone does not
200
+ establish fit, strength, or adequate wall thickness.
201
+
202
+ Testkit has no compiler, renderer, or browser dependency. The CLI owns those tools and exposes
203
+ reusable Node functions under `@metamesh/cli/authoring` for integrations that don't spawn a command.
204
+
205
+ ## Command results
206
+
207
+ Add `--json` for one structured result on stdout; bounded author logs go to stderr. The default
208
+ output is concise text. Exit codes are:
209
+
210
+ - `0`: success;
211
+ - `1`: source, parameter, or generation failure;
212
+ - `2`: invocation, environment, artifact, or tooling failure.
213
+
214
+ Runs default to a 30-second execution deadline and can lower engine resource ceilings.
215
+
216
+ Modeling and the Generator SDK remain independent of the CLI and its local Node tooling.