ChainOS-python is a python client for the ChainOS engine
Project description
ChainOS
An extremely fast, language-agnostic, graph workflow engine for building, testing, and deploying complex workflows.
Story
Chainos : the Forger of Sequential Bonds
Chainos focuses on the power of chained processes, from AI to algorithmic sequences where each step is linked to the next. As the forger of sequences, Chainos ensures that every link in the chain holds, promoting security, efficiency, and integrity in systems that rely on unbroken processes.
Help
Installing
Setup environment
# Choose a python version
pyenv install 3.10
pyenv install 3.11
# Create a virtualenv
# Can replace 3.11 with your version
pyenv virtualenv 3.11 chainos
# See all installed python versions and available virtualenvs
pyenv versions
# activate virtualenv
pyenv activate chainos
# leave virtualenv
pyenv deactivate
pip install poetry
Setup project
git clone git@github.com:chainos-io/chainos-python.git
cd chainos-python
poetry install --with test,dev --no-root
Running ChainOS
Example chainos project
from chainos import ChainOS as cos
container = cos.Container()
chain = cos.Chain(container=container)
@cos.task
def step1() -> int:
print("Hello, World!")
return 1
@cos.task
def step2(input1: int):
print(f"step2: {input1}")
return input1 * 2
chain.add(step1)
chain.add(step2)
container.add(chain)
chain.run()
Contributing
For guidance on setting up a development environment and how to make a contribution to Chainos, see Contributing to Pydantic.
Or see Contribution guidelines for this project
Reporting a Security Vulnerability
See our security policy.
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.