Skip to main content

PyPI versionAnaconda versionCircleCIDocumentation StatuscodecovDOI

Python client for Isabelle server

isabelle-client is a TCP client for Isabelle server. For more information about the server see Chapter 4 of the Isabelle system manual.

How to Install

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

pip install isabelle-client

Another option is to use Anaconda:

conda install -c conda-forge isabelle-client

One can also download and run the client together with Isabelle in a Docker container:

docker build -t isabelle-client https://github.com/inpefess/isabelle-client.git
docker run -d --rm -p 8888:8888 --name isabelle-client isabelle-client

And navigate to example page in your browser.

How to use

from isabelle_client import get_isabelle_client, start_isabelle_server

# start Isabelle server
server_info, _ = start_isabelle_server()
# create a client object
isabelle = get_isabelle_client(server_info)
# start a new session
responses = isabelle.session_start()
session_id = responses[-1].response_body.session_id
# send a theory file from the current directory to the server
responses = isabelle.use_theories(
    theories=["Example"], master_dir=".", session_id=session_id
)
# shut the server down
isabelle.shutdown()

For more details, follow the usage example from documentation or a notebook.

High-level connector

You can also pass a theory file body (something you typically put between begin and end keywords) to a high-level connector that will generate a temporary file for you, send it to the Isabelle server and get the result for you. For example, this snippet:

from isabelle_client.isabelle_connector import IsabelleConnector
from isabelle_client.isabelle_connector import IsabelleTheoryError

isabelle_connector = IsabelleConnector()
try:
    isabelle_connector.build_theory(
        r'lemma "\<forall> x. \<forall> y. x = y"' "\nby auto"
    )
    print("Theory is validated!")
except IsabelleTheoryError as error:
    print(error.args[0])

will produce something like:

: Failed to finish proof\<^here>:
: goal (1 subgoal):
:  1. \<And>x y. x = y

More documentation

More documentation can be found here.

Similar Software

There are Python clients to other interactive theorem provers, for example:

Modules helping to interact with Isabelle server from Python are parts of the Proving for Fun project.

There are also clients to Isabelle server in other programming languages, e.g. this one in Rust.

Projects using the client

isabelle-client helped to build some cool LLM stuff (in reversed chronological order):

How to cite

If you’re writing a research paper, you can cite the Isabelle client using the following DOI. You can also cite Isabelle 2021 (and an earlier version of the client) with this DOI. There also is a somewhat more complete (but unpublished) pre-print.

How to Contribute

Please follow the contribution guide while adhering to the code of conduct.

Release files for isabelle-client 1.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for isabelle-client 1.1.2
File Size Uploaded
isabelle_client-1.1.2.tar.gz 20.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for isabelle-client 1.1.2
File Interpreter ABI Platform
isabelle_client-1.1.2-py3-none-any.whl Python 3 none any Details

Total release size: 51.3 kB

Release files / isabelle_client-1.1.2.tar.gz

Download URL isabelle_client-1.1.2.tar.gz
Size 20.7 kB
Tags Source
SHA-256 checksum
How to use checksums
1d8e2694f189eb8df315fb0acae7c41bdf9e9fae8fa02ed14e388babb01896c8
BLAKE2b-256 checksum
How to use checksums
081f13c1396a6ef77110daabe7fcae31948c6bba3bb5e5e4acedbcbbf80bdb97
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.15 {"installer":{"name":"uv","version":"0.11.15","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / isabelle_client-1.1.2-py3-none-any.whl

Download URL isabelle_client-1.1.2-py3-none-any.whl
Size 30.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
4e99604205010a7029b6e0dde4101fd2ca5e972a1492c705669e0efe8f76ecc5
BLAKE2b-256 checksum
How to use checksums
bafd9f5403628f58d39c27e2080af8c66f9ea3561ab72814b8a3f9131b16973d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.15 {"installer":{"name":"uv","version":"0.11.15","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release history Release notifications | RSS feed

This release

1.1.2 This release

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.2

1 release file

1.0.1

2 release files

1.0.0

2 release files

0.6.0

2 release files

0.5.9

2 release files

0.5.7

2 release files

0.5.6

2 release files

0.5.5

2 release files

0.5.4

2 release files

0.5.3

2 release files

0.5.2

2 release files

0.5.1

2 release files

0.5.0

2 release files

0.4.9

2 release files

0.4.7

2 release files

0.4.6

2 release files

0.4.5

2 release files

0.4.3

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.17

2 release files

0.3.16

2 release files

0.3.15

2 release files

0.3.14

2 release files

0.3.13

2 release files

0.3.12

2 release files

0.3.11

2 release files

0.3.10

2 release files

0.3.9

2 release files

0.3.8

2 release files

0.3.7

2 release files

0.3.6

2 release files

0.3.5

2 release files

0.3.4

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.10

2 release files

0.2.9

2 release files

0.2.8

2 release files

0.2.7

2 release files

0.2.5

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

0.0.7

2 release files

0.0.6

2 release files

0.0.5

2 release files

0.0.4

2 release files

0.0.3

2 release files

0.0.2

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page