pyfcstm.bmc.pipeline

High-level compile-only pipeline for FCSTM BMC queries.

This module provides the convenient public handoff from a state machine and query text or query model to a solve-ready pyfcstm.bmc.properties.BmcPropertyFormula. It composes the existing preparation, core-relation, and property-compilation stages without starting a solver or decoding a witness.

Use compile_bmc_query() when the caller owns a model and query. Use the lower-level pyfcstm.bmc.properties.compile_bmc_property() when the caller already owns a pyfcstm.bmc.relation.BmcCoreFormula and needs to compile only its property objective.

The module contains:

  • compile_bmc_query() - Compile a model and query into a solve-ready property formula without solving it.

Example:

>>> from pyfcstm.bmc.pipeline import compile_bmc_query
>>> from pyfcstm.model import load_state_machine_from_text
>>> model = load_state_machine_from_text('state Root;')
>>> formula = compile_bmc_query(model, 'check reach <= 1: active("Root");')
>>> formula.kind, formula.polarity
('reach', 'witness')

__all__

pyfcstm.bmc.pipeline.__all__ = ['compile_bmc_query']

Built-in mutable sequence.

If no argument is given, the constructor creates a new empty list. The argument must be an iterable if specified.

compile_bmc_query

pyfcstm.bmc.pipeline.compile_bmc_query(model: StateMachine, query: str | BmcQuery, *, options: BmcOptions | None = None) BmcPropertyFormula[source]

Compile a model and BMC query into a solve-ready formula without solving.

The function preserves the existing three-stage BMC truth source: pyfcstm.bmc.engine.prepare_bmc_query(), pyfcstm.bmc.relation.build_bmc_core_formula(), and pyfcstm.bmc.properties.compile_bmc_property(). It does not construct a property solver, call pyfcstm.bmc.witness.solve_bmc_property(), or decode a witness.

Parameters:
Returns:

Compiled property formula ready for an explicit solver call.

Return type:

pyfcstm.bmc.properties.BmcPropertyFormula

Raises:

Example:

>>> from pyfcstm.bmc.pipeline import compile_bmc_query
>>> from pyfcstm.model import load_state_machine_from_text
>>> model = load_state_machine_from_text('state Root;')
>>> formula = compile_bmc_query(model, 'check reach <= 1: active("Root");')
>>> formula.kind, formula.polarity
('reach', 'witness')