DiagramPilot v0.2.12
DiagramPilot v0.2.12
Issue: MCP Source Mutation
Issue Version: 0.2.12
Tag: v0.2.12
npm: https://www.npmjs.com/package/diagrampilot/v/0.2.12
Public Website: https://diagrampilot.com
Summary
Add MCP Source Mutation through Structured Diagram Operations, not raw YAML
replacement. Mutation should support fine-grained operations for nodes, edges,
groups, top-level title, description, direction, top-level metadata keys, and
object metadata keys.
Each tool call should be atomic: load valid YAML, apply the structured
operation, validate, and roll back invalid results. Targets use Stable IDs
only. Rewrites should use canonical YAML key order, preserve array order unless
the mutation changes it, and support optional beforeId or afterId
placement for top-level nodes, edges, and groups.
Implementation Notes
- Added
diagrampilot_mutate_sourcewith structured operations for top-level fields, top-level metadata, nodes, edges, groups, and object metadata. - Mutations load a valid source, apply one operation, validate before write, serialize through the canonical DiagramPilot serializer, and return structured summaries plus written paths.
- Unsupported raw YAML replacement and
containspositioning return structured errors without writing. - Added shared topology-line formatting and test assertion helpers to close the 10 recorded Fallow duplicate backlog items.
- Refreshed the duplicate baseline for remaining legacy duplicate groups surfaced after changed-file fingerprints moved; no new Fallow health or dead-code findings remain.
Validation Results
npm testpassed.node packages/cli/dist/index.js mcp --helppassed.git diff --checkpassed.npm run audit:fallowpassed.npm run audit:fallow:changedpassed.