PNML DoC is a free and open source tool which validates PNML Documents against the Petri Net Standard specifications. You can use it as a dependency in your application, or run it on the command line, or launch it as a server to which you may connect to.

PNML DoC relies on PNML Framework to perform the validation of PNML Documents.

Execution modes

PNML DoC supports 2 executions modes: it can simply run as a standalone application upon invocation on the command line, with a list of PNML Documents to check, or be launched as a server to listen for incoming validation requests.


PNML Check can be simply run on the command line and returns as soon as it finishes checking the provided documents. This is the recommended way. Simply provide a list of PNML Documents to check. Of course, you may also provide just a single document.


This application can also be run in a server mode, by default on port 10002.

As a server, it provides a one-shot (synchronous) service, meaning:

  • open a connection to the server;
  • send your PNML document;
  • get the result of the service;
  • close the connection. That's it.

The result is composed of:

  • a HTTP status code; the list of the codes used is provided on the usage page,
  • a message explaining the result of the service,
  • and some basic stats about the PNML Document (how many nets, nodes, and arcs).

Standard support

All Petri Net types defined in the Standard are supported:

  • Core Model,
  • P/T Nets,
  • Symmetric Nets,
  • High-Level Petri Nets,
  • P/T Nets in High-level notation (known as PT-HLPNG).

Alternative way to check PNML Documents

To check PNML Documents, you might also want to use the method explained on the PNML reference site. We have encoded and contributed as Schematron rules all OCL constraints in the PNML Standard metamodels.

However, remember to start the check with a regular one first against the PNML grammar (e.g using XML Lint) before proceeding with the schematron rules.