You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -323,20 +326,24 @@ go install github.com/felixgeelhaar/statekit/cmd/statekit-mcp@latest
323
326
|`validate_machine`| Validate a definition using lint rules |
324
327
|`export_machine`| Export as JSON, Mermaid, or ASCII |
325
328
329
+
**Inverting the loop:** if you already have a typed `*statekit.Interpreter[C]` running in your service, `mcp.ExposeInterpreter` registers `<prefix>.send_event`, `<prefix>.get_state`, `<prefix>.get_context`, and `<prefix>.matches` so an MCP-speaking agent can drive your machine from outside.
330
+
326
331
The `visualize_machine` tool includes an interactive Vue.js + Cytoscape.js visualizer that MCP Apps hosts render inline — with dark mode, transition animations, and a full state history log. All JS dependencies are bundled inline for CSP-compatible rendering in any MCP host.
327
332
328
333
## Additional Packages
329
334
330
335
| Package | Description |
331
336
|---------|-------------|
332
-
|[`mcp`](./mcp)| MCP server for AI-assisted state machine management |
Copy file name to clipboardExpand all lines: docs/migration-from-looplab-fsm.md
+3-1Lines changed: 3 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -179,7 +179,9 @@ When you exit `loading` (e.g., user cancels), the service's `context.Context` is
179
179
-**Delayed transitions** — `.After(30 * time.Second).Target("timeout")`. No goroutine bookkeeping.
180
180
-**Visualization** — `statekit viz door.json` (or via Go package) gives you a Mermaid / HTML / TUI diagram.
181
181
-**Lint** — `lint.Lint(machine)` reports unreachable states, dead ends, non-determinism, missing OnError on Invoke, etc.
182
-
-**Snapshots** — pause/resume long-running workflows, persist them to a database.
182
+
-**Snapshots** — pause/resume long-running workflows, persist them to a database. `Snapshot[C]` round-trips through `encoding/json` and `encoding/gob` (see [snapshot serialization tests](../snapshot_serialization_test.go)) — no more "FSM has no exported fields" pain ([looplab/fsm #40](https://github.com/looplab/fsm/issues/40)).
183
+
-**Clean recovery from errors** — service errors route via `OnError`; the interpreter accepts events again immediately, no stuck `InTransitionError` ([looplab/fsm #115](https://github.com/looplab/fsm/issues/115)).
184
+
-**Runaway prevention** — `aiplugin.TransitionBudget` halts a misbehaving machine after N transitions.
Copy file name to clipboardExpand all lines: docs/migration-from-qmuntal-stateless.md
+1Lines changed: 1 addition & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -182,6 +182,7 @@ Done().
182
182
-**Lint** — catch structural bugs at build time.
183
183
-**Visualization formats** — Mermaid, HTML, TUI, ASCII (not just DOT).
184
184
-**MCP integration** — drive a running machine from a Claude / agent via tools.
185
+
-**Runaway prevention out of the box** — `aiplugin.TransitionBudget` halts a misbehaving machine after N transitions; addresses the pattern in [qmuntal/stateless #77](https://github.com/qmuntal/stateless/issues/77) directly.
0 commit comments