pflow.xyz MCP connector

Snap parts together into a system you can see, run and check, from Claude or any MCP client.

What it does

Under the hood every model is a Petri net, so runs replay and proofs check. You don't need to know that to use it. The tools below say "net" for a single model and "composition" for parts joined together.

Connector URL:

https://pflow.xyz/mcp

Set it up

Claude (web, desktop and mobile): open Customize, then Connectors, add a custom connector, and paste the URL above. No sign-in is needed to start.

Claude Code:

claude mcp add --transport http pflow https://pflow.xyz/mcp

Other clients: it is a stateless Streamable HTTP server. POST JSON-RPC to the URL; there is no event stream.

Looking up terms

A separate, read-only MCP server answers questions about the pflow vocabulary and its software components (terms, definitions, class hierarchy, dependencies). No sign-in, nothing is saved.

claude mcp add --transport http pflow-ontology https://ontology.pflow.xyz/mcp

Details, SPARQL endpoint and downloads: ontology.pflow.xyz.

Signing in

Every tool works without an account except pflow_save. The first time you save, your client opens a pflow.xyz page where you sign in with GitHub or Google. The saved model is then recorded as yours. Saved models are public, so don't save anything private. pflow.xyz keeps only your account id (and your GitHub username), never a password; see the privacy policy.

Try asking

Tools

pflow_canvasOpen a composition for a person to join parts by hand: each part's ports, the links a port could legally take, and scenario runs. A client that cannot show it reads the same result as text.
pflow_bundle_exampleThe catalog of parts and a composition of them to start from: an order queue, a worker pool and a payment saga as one bundle of subnets, joined by the three idioms or by links you give, with the page's four scenarios. A composition is a PetriNetBundle: independently authored subnets, the ports on their boundaries and the typed links between them (token, data, event, guard).
pflow_bundle_validateCheck a composition: its subnets, then every link (endpoints, net types, port schemas, direction), with errors and warnings that name the link. A subnet that declares no ports has one per exported place.
pflow_bundle_candidatesThe links a port could take: every other port (of the ports a subnet declares) judged as the far end, the first legal kind winning, each with its verdict; only_ok lists just the legal ones.
pflow_bundle_add_linkSnap two parts together: add a link to a composition if it is legal (go-pflow's rules, and that a link joins two subnets and is not repeated); a refusal lists each reason and the ports its subnet has. It sets the kind and the two ends only: add a link's id or a guard's condition to the returned link yourself.
pflow_bundle_flattenFlatten a composition into one net: fused places and transitions with the members they came from, arcs, constraints, the maps and the warnings. This listing is not a pflow.xyz net: pflow_simulate, pflow_fire and the other net tools cannot read it (pflow_bundle_net returns the same net in the format they read). Give every arc an explicit weight: an arc with none fires as 1, but a lone subnet is returned as written, with weight 0.
pflow_bundle_runFire a script of subnet/transition members on the flat net, or one of the example's scenarios; it stops where a member cannot fire and says why. A member is the transition's own id in its subnet (payment/do_charge), not the port id a link names (do:charge). A negative arc weight never enables, as in pflow-rs.
pflow_bundle_incidenceThe flat net's incidence matrix, each subnet's block, and whether each declared constraint is a conservation law of the composition. An arc with no weight counts as 0 in a subnet's block (and everywhere for a lone subnet) but fires as 1, so give every arc an explicit weight; a notes entry says when that happens.
pflow_bundle_netThe flat net as an ordinary pflow.xyz net, in the editor's JSON-LD, with the members each flat place and transition came from. It loads in the other net tools: pflow_fire, pflow_simulate, pflow_reachability, pflow_invariants, pflow_verify, pflow_cid and pflow_export read a composite as they read any net. A guard or a data place, which the editor's format cannot say, is refused and named rather than dropped.
pflow_bundle_partsA 13-part catalog (queue, resource pool, saga, lock, token bucket, circuit breaker, batcher, approval desk, inventory, failover, SIR, kanban stage, traffic light) with parameters, ports, the law each carries and the joins that are legal; given instances and links it builds a composition.
pflow_bundle_proveDo the links keep their promises? Each part's conservation laws lifted onto the composite and classified preserved, extended or changed (a declared law is also tried on every reachable marking, with a replayable counterexample); bounded, deadlock-free and quasi-live claims, never proved by a search that stopped; a verdict per link found by taking it out and searching again; and a proof record that pflow_bundle_check_proof re-checks.
pflow_bundle_check_proofRe-check a proof record against a composition: certificate arithmetic (y·C, z·C = 0, bounds), replay of every counterexample and witness, and a recomputation of the engine's own answers. A tampered record, or one for another composition, is not valid.
pflow_editBuild a net or change one with a list of edits, applied all together or not at all.
pflow_infoSummarise a net: places, transitions, arcs, marking and what is enabled.
pflow_checkParse a net and report its size and anything it refuses.
pflow_validateStructural checks: connectivity, deadlocks, boundedness, conservation.
pflow_verifyProve or refute properties, with an invariant proof or a replayable counterexample.
pflow_firePlay the token game: fire a sequence of transitions.
pflow_reachabilityExplore reachable markings: state count, dead transitions, and whether the net is deadlock-free, live (every transition can still fire from every marking) and quasi-live (every transition fires somewhere), with a firing sequence that replays to the failure. A search stopped by its budget answers unknown, never yes.
pflow_invariantsP- and T-invariants (conservation laws and cycles).
pflow_incidenceThe incidence matrix.
pflow_simulateMass-action ODE simulation with a sampled trajectory.
pflow_ssaSeeded stochastic (Gillespie) simulation.
pflow_sdeSeeded chemical Langevin (SDE) simulation: continuous, with the net's own noise. Refuses nets with inhibitor or read arcs, or with a capacity on a place that some firing adds tokens to (other capacities cannot bind, and are ignored).
pflow_what_ifThe same seeded stochastic runs with and without a few more tokens in one place, side by side.
pflow_optimizeSeeded Monte Carlo over transition rates, with the Pareto front of the objectives you name.
pflow_game_valueThe exact value of a position of a two-sided game played on a net (tic-tac-toe, Connect-4, Nim, any net whose moves belong to two sides), by alpha-beta search over the firing rule. The net's marking is the position. A search plan picks the move order, filters and drivers, and a root estimate that ranks the first moves by solving the net's mass-action ODE; a net with several token colours is searched on its colour copies.
pflow_game_moveA best move at such a position and its exact value.
pflow_rate_scanSweep one rate and see how the outcome moves.
pflow_artifactA net as an interactive page to publish (a claude.ai Artifact, or any page host): the net drawn from its own layout, the token game (click or press Enter on an enabled transition, random step, reset), the reachability verdicts with a replay of the deadlock, the P-invariants re-checked after every firing, the ontology.pflow.xyz classes the net earns (behaviour: LiveNet, DeadlockFreeNet, BoundedNet, UnboundedNet; shape: StateMachineNet, MarkedGraphNet, ConservativeNet), a graph view (every place over time and a phase plane, from the net’s optional per-transition rate), the CID and an editor link. The page leads with the view that suits the net (views.lead in the summary: dynamics for a few places and transitions or an unbounded net, play for a small bounded one, analysis for about 60 nodes or more); every other view is a tick box at the bottom, and Explore this model opens a dialog to edit the marking, rates and arc weights, re-analyze, export and open the editor. One HTML fragment. Takes the net inline (net) or a stored one by cid; with a cid the editor link is ?cid= instead of the net inline. engine: "wasm" (default, about 50 KB plus the net) loads the pflow-rs engine as one script, @pflow-xyz/engine on cdn.jsdelivr.net pinned to an exact version with an SRI hash, so the page can re-analyze an edited initial marking; if the script cannot load, the baked verdicts stand and the page says so. "baked" (about 1 KB less, loads nothing) fixes the verdicts at the net's marking, for hosts that block scripts from cdn.jsdelivr.net. "wasm-inline" (about 500 KB) embeds the same engine instead and loads nothing, but most chat clients truncate a tool result that large. Coloured nets are drawn too, in their colours, from their unfolding.
pflow_exportThe net as normalised JSON-LD or as an SVG drawing.
pflow_cidThe content id a net seals to.
pflow_linksLinks to see a model: the editor, its SVG and its JSON-LD. A stored composition opens on the composition page.
pflow_getFetch a stored model by its content id: a net, or a composition or plan as stored.
pflow_skillA ready-to-save Claude skill (SKILL.md) for modelling, checking and showing a process with pflow: the procedure, this server's tool list filled in live, and install notes for Claude Code, claude.ai or any client. Optional client and focus (artifact, verify, compose). Saved only if you agree.
pflow_saveStore a net on pflow.xyz as yours (needs sign-in; stored nets are public).

Limits

Troubleshooting

On the way

These are not available yet:

Support

Report problems or ask questions at github.com/pflow-xyz/pflow-xyz/issues. Use of the connector is covered by the terms and privacy policy.