libpetri 2.10.5 → 2.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -247,6 +247,32 @@ declare function findMinimalSiphons(flatNet: FlatNet): ReadonlySet<number>[];
|
|
|
247
247
|
*/
|
|
248
248
|
declare function findMaximalTrapIn(flatNet: FlatNet, places: ReadonlySet<number>): ReadonlySet<number>;
|
|
249
249
|
|
|
250
|
+
/**
|
|
251
|
+
* Name-correlation fragment classifier for the ν-aware state class graph
|
|
252
|
+
* (NU-050, Route B). See the Rust/Java equivalents for the full contract.
|
|
253
|
+
*
|
|
254
|
+
* Identifies the coloured places (the correlated inputs of ν-joins) and the role
|
|
255
|
+
* of each transition in the supported fragment. Returns `null` when the net is
|
|
256
|
+
* not a ν-net or falls outside the admitted fragment (the caller falls back to
|
|
257
|
+
* the SMT / Route A path).
|
|
258
|
+
*
|
|
259
|
+
* {@link FragmentMode.base} (default) admits the shipped mint → matched-join
|
|
260
|
+
* fragment only: a non-match transition consuming a coloured place, or a join
|
|
261
|
+
* re-minting into one, rejects the net. {@link FragmentMode.extended} (opt-in,
|
|
262
|
+
* NU-051) additionally admits the coloured-consumer role ({@link Role} `consume`,
|
|
263
|
+
* drain/relay) and unions user-declared *carrier* places into the coloured set
|
|
264
|
+
* (fork-threaded co-mint). The one deliberate tightening shared by both modes is
|
|
265
|
+
* the reset/read/inhibitor-on-coloured guard below.
|
|
266
|
+
*/
|
|
267
|
+
|
|
268
|
+
/**
|
|
269
|
+
* Selects which coloured-place fragment {@link classify} admits. `base` (default)
|
|
270
|
+
* reproduces the shipped mint → matched-join fragment exactly; `extended`
|
|
271
|
+
* additionally admits the coloured-consumer (drain/relay) role and carrier
|
|
272
|
+
* places (NU-051).
|
|
273
|
+
*/
|
|
274
|
+
type FragmentMode = 'base' | 'extended';
|
|
275
|
+
|
|
250
276
|
/**
|
|
251
277
|
* IC3/PDR-based safety verifier for Petri nets using Z3's Spacer engine.
|
|
252
278
|
*
|
|
@@ -279,6 +305,8 @@ declare class SmtVerifier {
|
|
|
279
305
|
private _environmentMode;
|
|
280
306
|
private _timeoutMs;
|
|
281
307
|
private _nuMaxClasses;
|
|
308
|
+
private _fragmentMode;
|
|
309
|
+
private readonly _carrierPlaces;
|
|
282
310
|
private constructor();
|
|
283
311
|
static forNet(net: PetriNet): SmtVerifier;
|
|
284
312
|
initialMarking(marking: MarkingState): this;
|
|
@@ -308,6 +336,27 @@ declare class SmtVerifier {
|
|
|
308
336
|
* structurally bounded). Default 100_000.
|
|
309
337
|
*/
|
|
310
338
|
nuMaxClasses(max: number): this;
|
|
339
|
+
/**
|
|
340
|
+
* Selects the ν-net coloured-place fragment for Route B (NU-051). `base`
|
|
341
|
+
* (default) admits the shipped mint → matched-join fragment only; `extended`
|
|
342
|
+
* additionally admits the opt-in coloured-consumer (drain/relay) role and the
|
|
343
|
+
* declared {@link carrierPlaces}. When `extended` is requested but the net
|
|
344
|
+
* falls outside the coloured-consumer fragment, Route B declines and a short
|
|
345
|
+
* note is appended to the report before falling back to the sound
|
|
346
|
+
* over-approximation.
|
|
347
|
+
*/
|
|
348
|
+
fragmentMode(mode: FragmentMode): this;
|
|
349
|
+
/**
|
|
350
|
+
* Declares ν-net *carrier* places (NU-051, EXTENDED only): intermediate places
|
|
351
|
+
* that carry a fresh name from the minting fork onward to a ν-join input. Under
|
|
352
|
+
* {@link fragmentMode} `extended` they are unioned into the coloured set so the
|
|
353
|
+
* existing mint co-mints one fresh name into all of them; under `base` they are
|
|
354
|
+
* ignored. Accumulating. Throws if a declared place is not in the net — a
|
|
355
|
+
* mistyped carrier name would let two fork branches mint independent names, so
|
|
356
|
+
* the join never becomes name-enabled and the verifier would otherwise report a
|
|
357
|
+
* confident false deadlock; it must surface, never silently proceed.
|
|
358
|
+
*/
|
|
359
|
+
carrierPlaces(...places: Place<any>[]): this;
|
|
311
360
|
/**
|
|
312
361
|
* Runs the verification pipeline.
|
|
313
362
|
*/
|