Bases: BaseModel
One rule waiting to fire, and the facts that put it there.
rule_trace on an :class:EvaluationResult says what already fired.
This says what would fire next, which is the question you have when a
rule you expected did not run. Read it through :meth:Engine.agenda.
Source code in src/fathom/models.py
| class Activation(BaseModel):
"""One rule waiting to fire, and the facts that put it there.
``rule_trace`` on an :class:`EvaluationResult` says what already fired.
This says what *would* fire next, which is the question you have when a
rule you expected did not run. Read it through :meth:`Engine.agenda`.
"""
#: Module-qualified rule name, as CLIPS reports it.
rule: str
#: The module whose agenda holds this activation.
module: str
#: The rule's salience. Within one module, higher fires first.
salience: int
#: Indices of the facts that satisfied the rule's conditions.
facts: list[int] = Field(default_factory=list)
|