Feat/plan tools#2
Merged
Merged
Conversation
Add a `forgewisp.plans` localStorage-backed scratchpad with seven read-tier tools (listPlans, getPlan, createPlan, addPlanItem, updatePlanItem, removePlanItem, deletePlan) so the agent can lay out and track its own job without onConfirmRequired prompts. The store is an internal helper (`plan-store.ts`, not re-exported as a value, mirroring `eval-math.ts`); reads never throw on corrupt state, mutations surface as function_errored. Extend `JSONSchemaProperty` with minItems/maxItems/additionalProperties so the plan tool schemas can bound arrays and close objects. Ship `apps/planning-demo`, a vanilla-TS + Vite showcase exercising the planning tools with a plan board UI, DOMPurify-sanitized sinks, and tests (a11y, plan-board, sanitize, submit). Co-Authored-By: Claude <noreply@anthropic.com>
Introduce a named, ordered group of tools (`ToolSet`) that registers in a single call. `tools` is typed `readonly FunctionDefinition<never>[]` so a heterogeneous tuple of `FunctionDefinition<SpecificArgs>` tools is accepted without an `as unknown as` cast — the handler is contravariant in `TArgs` and `never` is the bottom type. Registration delegates to `registerFunction` per tool, preserving the write/destructive tier invariant (throws at registration time if `onConfirmRequired` is unset). - core: `ToolSet` type, `defineToolSet` helper, `registerToolSet` on the agent - bundled-tools: export `PLANNING_TOOLS` (the 7 plan-management tools as a ready-to-register set), keeping a types-only relationship with core - planning-demo: register sets instead of looping a cast tuple; compose the sidebar list from `PLANNING_TOOLS.tools` + a `planning-extras` set Co-Authored-By: Claude <noreply@anthropic.com>
Lockstep minor bump for the planning tools and ToolSet/defineToolSet feature additions. Co-Authored-By: Claude <noreply@anthropic.com>
Fix CI format:check failure. Co-Authored-By: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.