A powerful, modern, and educational Python toolkit for automata theory. Visualize DFAs, NFAs, CFGs, PDAs, and Turing machines (single/multi-tape/multi-head); minimize automata; CYK and CFG algorithms; and more with an elegant, type-safe API.
Project description
Automata Diags
A powerful, modern, and educational Python toolkit for automata theory. Visualize DFAs, NFAs, CFGs, minimize automata, and more with an elegant, type-safe API.
For the full, comprehensive documentation including tutorials and the API reference, please visit our Documentation Website.
Installation
pip install automata-diags
Requires Python 3.8+ and Graphviz.
Quick Start
from automata.backend.grammar.dist import State, Symbol
from automata.backend.grammar.regular_languages.dfa.dfa_mod import DFA
from automata.backend.drawings.automata_drawer import AutomataDrawer
# Create a simple DFA
# For more creation methods, see the full documentation.
dfa = DFA.from_string("q0,a,q1;q1,b,q2", start_state="q0", accept_states={"q2"})
# Test it
dfa.accepts([Symbol('a'), Symbol('b')]) # True
# Visualize it
drawer = AutomataDrawer()
drawer.draw_dfa_from_object(dfa, "my_first_dfa")
For more examples and detailed guides, please visit the Full Documentation Site.
Web App
https://ajodo-godson.github.io/automata_diags/
Contributing
Contributions are welcome! Please feel free to open a pull request or submit an issue on our GitHub repository.
License
This project is licensed under the MIT License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file automata_diags-0.3.1.tar.gz.
File metadata
- Download URL: automata_diags-0.3.1.tar.gz
- Upload date:
- Size: 349.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f40336b7d31c149378704370733ddc890ce0e089e22f32689646d9e2fc2cac53
|
|
| MD5 |
915ca02652fc38139ac235588808f498
|
|
| BLAKE2b-256 |
68dde5c453c98c16b670dd47ffc8974d943cdc197bcdf84f09a362623c0d55b2
|
Provenance
The following attestation bundles were made for automata_diags-0.3.1.tar.gz:
Publisher:
python-publish.yml on Ajodo-Godson/automata_diags
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
automata_diags-0.3.1.tar.gz -
Subject digest:
f40336b7d31c149378704370733ddc890ce0e089e22f32689646d9e2fc2cac53 - Sigstore transparency entry: 1001689709
- Sigstore integration time:
-
Permalink:
Ajodo-Godson/automata_diags@6056dc19fd7be03b2861add0756f4326865bbee6 -
Branch / Tag:
refs/tags/V0.3.1 - Owner: https://github.com/Ajodo-Godson
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@6056dc19fd7be03b2861add0756f4326865bbee6 -
Trigger Event:
release
-
Statement type:
File details
Details for the file automata_diags-0.3.1-py3-none-any.whl.
File metadata
- Download URL: automata_diags-0.3.1-py3-none-any.whl
- Upload date:
- Size: 51.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
23b8b7db2ad8a2b1de834abad55d7e0d8b7960d575000d4f55cd648f8a53b93e
|
|
| MD5 |
a3dd0a00964ad9c01a15176a89f8ddfb
|
|
| BLAKE2b-256 |
ed2baa9ce9e397b7d775274e532e8ec5d961bfa153f49c8baed63818be7f02c9
|
Provenance
The following attestation bundles were made for automata_diags-0.3.1-py3-none-any.whl:
Publisher:
python-publish.yml on Ajodo-Godson/automata_diags
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
automata_diags-0.3.1-py3-none-any.whl -
Subject digest:
23b8b7db2ad8a2b1de834abad55d7e0d8b7960d575000d4f55cd648f8a53b93e - Sigstore transparency entry: 1001689714
- Sigstore integration time:
-
Permalink:
Ajodo-Godson/automata_diags@6056dc19fd7be03b2861add0756f4326865bbee6 -
Branch / Tag:
refs/tags/V0.3.1 - Owner: https://github.com/Ajodo-Godson
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@6056dc19fd7be03b2861add0756f4326865bbee6 -
Trigger Event:
release
-
Statement type: