PyPI versionCircleCIDocumentation Statuscodecov

yapsap#

yapsap is Yet Another Python SAturation-style Prover. Currently, it can only prove theorems in TPTP library formal language in clausal normal form. yapsap implements the given clause algorithm and was inspired by PyRes.

How to Install#

The best way to install this package is to use pip:

pip install git+https://github.com/inpefess/yapsap.git

How to use#

from random import choice, seed

from yapsap import YapsaProver


class RandomProver(YapsaProver):
    def proof_attempt(self) -> None:
        while not self.proof_found:
            self._step(choice(list(self.state.keys())))


prover = RandomProver(
    "./yapsap/resources/TPTP-mock/Problems/TST/TST001-1.p"
)
seed(0)
prover.proof_attempt()
print(prover.state)

How to Contribute#

Pull requests are welcome. To start:

git clone https://github.com/inpefess/yapsap
cd yapsap
# activate python virtual environment with Python 3.8+
pip install -U pip
pip install -U setuptools wheel poetry
poetry install
# recommended but not necessary
pre-commit install

To check the code quality before creating a pull request, one might run the script local-build.sh. It locally does nearly the same as the CI pipeline after the PR is created.

Reporting issues or problems with the software#

Questions and bug reports are welcome on the tracker.

More documentation#

More documentation can be found here.