@polypad/mcp 0.1.6 → 0.1.7

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 (2) hide show
  1. package/dist/index.js +9 -3
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -34703,6 +34703,10 @@ var inputs = {
34703
34703
  name: external_exports.string().trim().min(1).max(120).default("Untitled").describe("Name of the new project"),
34704
34704
  template: external_exports.enum(templateIds).optional().describe(`Start from a template (${PROJECT_TEMPLATES.map((t) => `${t.id}: ${t.description}`).join(" ")}). Omit for an empty project.`)
34705
34705
  }),
34706
+ list_projects: external_exports.object({}),
34707
+ open_project: external_exports.object({
34708
+ id: external_exports.string().min(1).describe("Id of the project to open (from list_projects)")
34709
+ }),
34706
34710
  set_parameter: external_exports.object({
34707
34711
  name: external_exports.string().min(1).describe("Parameter name: letters, digits and _, not starting with a digit. Created when it does not exist yet."),
34708
34712
  value: external_exports.union([external_exports.number(), external_exports.string().min(1)]).describe(`Value in mm (or degrees where it is used as an angle)${EXPR}. Other fields can refer to the parameter by name.`)
@@ -34857,7 +34861,9 @@ var inputs = {
34857
34861
  })
34858
34862
  };
34859
34863
  var descriptions = {
34860
- new_project: "Start a new, empty Polypad project (optionally from a template), replacing the open one. All lengths in Polypad are millimetres and angles are degrees; Z is up.",
34864
+ new_project: "Start a new, empty Polypad project (optionally from a template), after saving the open one (it stays in the projects list: list_projects, open_project). All lengths in Polypad are millimetres and angles are degrees; Z is up.",
34865
+ list_projects: "List the projects saved in this browser (name, id, number of features, when last saved, which one is open), newest first. Use open_project to go back to one.",
34866
+ open_project: "Open a project saved in this browser (its id is listed by list_projects), after saving the open one. Nothing is lost; call get_project afterwards to see the project that is open now.",
34861
34867
  set_parameter: "Create or change a named parameter (a number or an expression). Any length field of any feature can use the name, so one change resizes everything bound to it. Reports features that no longer build. Set the sizes up front, then use the names in fields.",
34862
34868
  add_primitive: "Add a solid box, cylinder, tube, sphere, cone, torus or wedge as a new body. Returns the new feature's id, which is also the body id for later commands. Sizes in mm.",
34863
34869
  add_sketch: "Add a 2D sketch on a base plane or on a flat face and draw shapes in it (rectangle, circle, line, polyline, arc, slot, polygon). The sketch is solved and its remaining degrees of freedom reported. Use extrude or revolve to turn closed shapes into a solid.",
@@ -35501,7 +35507,7 @@ var SERVER_INSTRUCTIONS = `Polypad is a parametric CAD editor. These tools build
35501
35507
  Units and axes: lengths are millimetres, angles degrees, Z is up. Any length field accepts a number or an expression over the project's parameters ("width / 2"); prefer set_parameter for sizes that belong together.
35502
35508
 
35503
35509
  Workflow:
35504
- 1. Start with get_project to see what is already there (the user may have work open). new_project replaces the open project: if it has features, ask the user first and never call it over their work; use it freely only when the project is empty.
35510
+ 1. Start with get_project to see what is already there (the user may have work open). new_project and open_project save the open project first, so nothing is lost: list_projects and open_project go back to earlier work. Still ask the user before switching away from a project they have open with features.
35505
35511
  2. Build with add_primitive, or add_sketch then extrude / revolve. Ids returned by a command are the feature and body ids for later calls.
35506
35512
  3. For hole, shell, fillet, chamfer and for sketching on a face, call list_faces or list_edges first. Pass the indices they return together with the same rebuildId. The rebuildId changes whenever the model changes, so after any change list again; a stale one is refused ("Call list_edges again").
35507
35513
  4. A feature that does not build stays in the project with its error: fix it with update_feature, or remove it with delete_feature or undo.
@@ -35548,7 +35554,7 @@ function createPolypadMcp(options = {}) {
35548
35554
  }
35549
35555
 
35550
35556
  // src/index.ts
35551
- var VERSION = true ? "0.1.6" : "0.0.0-dev";
35557
+ var VERSION = true ? "0.1.7" : "0.0.0-dev";
35552
35558
  var err = (line2) => process.stderr.write(`${line2}
35553
35559
  `);
35554
35560
  async function main() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@polypad/mcp",
3
- "version": "0.1.6",
3
+ "version": "0.1.7",
4
4
  "type": "module",
5
5
  "description": "MCP server that lets Claude, Cursor or another AI assistant build and inspect 3D models in your open Polypad tab (polypad.ink). Runs locally, nothing is uploaded.",
6
6
  "license": "MIT",