@grid-is/agent-tools 0.2.3 → 0.3.1

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 CHANGED
@@ -38,6 +38,25 @@ import { serveStdio, createGridTools } from "@grid-is/agent-tools";
38
38
  await serveStdio({ tools: createGridTools() });
39
39
  ```
40
40
 
41
+ ## The tools alone
42
+
43
+ `@grid-is/agent-tools/tools` exports the spreadsheet tools without the MCP
44
+ server and the file-based workbook session. They run against an in-memory
45
+ `Model`, in Node or in a browser bundle:
46
+
47
+ ```js
48
+ import { Model } from "@grid-is/apiary";
49
+ import { describeStructure, editCells, spreadsheetTools } from "@grid-is/agent-tools/tools";
50
+
51
+ await Model.preconditions;
52
+ const model = await Model.fromXLSX(bytes, "budget.xlsx");
53
+ const structure = describeStructure.execute({ model }, {});
54
+ ```
55
+
56
+ Each tool is `{ name, description, parameters, execute }`; `parameters` is a
57
+ zod schema, so `z.toJSONSchema(tool.parameters)` produces the JSON Schema an
58
+ agent SDK expects.
59
+
41
60
  ## Tools
42
61
 
43
62
  | Group | Tools |
@@ -70,8 +89,12 @@ npm run build # tsdown → dist/
70
89
  npm test # smoke test against test/fixtures/sample.xlsx
71
90
  npm run typecheck
72
91
  npm run gen:docs # regenerate the per-tool reference under docs/src/content/docs/tools/
92
+ npm run test:hosts # run the packed server under Claude Code and Codex, each in a fresh state directory
73
93
  ```
74
94
 
95
+ `test:hosts` needs the `claude` CLI with `ANTHROPIC_API_KEY`, and the `codex`
96
+ CLI with `CODEX_API_KEY` or a saved login. A host that is missing is skipped.
97
+
75
98
  ## Releasing
76
99
 
77
100
  Releases are managed with [changesets](https://github.com/changesets/changesets).