Skip to main content

Bitswan is a framework for building automations and pipelines in Jupyter

Project description

Bitswan: A tool for building Pipelines & Automations in Jupyter

You can find example pipelines in the examples directory.

Installation

This library is part of the bitswan suite which is managed by the bitswan workspace cli. You must first install the bitswan workspaces cli before installing and using the bitswan notebooks cli.

$ git clone git@github.com:bitswan-space/BitSwan.git
$ cd BitSwan
$ curl -LsSf https://astral.sh/uv/install.sh | sh
$ uv venv
$ source .venv/bin/activate
$ uv pip install -e ".[dev]"

Running pipelines

You can run a pipeline with a simple command:

$ bitswan notebook examples/WebForms/main.ipynb

When developing web endpoints it can be helpful to instruct the pipeline to automatically restart if the source code changes.

$ bitswan notebook examples/WebForms/main.ipynb --watch

Running Tests

You can find examples for automatically testing pipelines in the testing examples directory.

Run tests with the --test flag.

$ bitswan notebook examples/Testing/InspectError/main.ipynb --test

Running tests for pipeline Kafka2KafkaPipeline.

    ┌ Testing event:        b'foo'
    └ Outputs:              [b'FOO'] ✔

All tests passed for Kafka2KafkaPipeline.


Running tests for pipeline auto_pipeline_1.

    ┌ Testing event:        b'{"foo":"aaa"}'
    └ Outputs:              [b'{"foo": "A   A   A"}'] ✔

    ┌ Testing event:        b'{"foo":"aab"}'
    │ Probing after-upper.
    └ Outputs:              [b'{"foo": "B   A   A"}'] ✔

    ┌ Testing event:        b'{"foo":"cab"}'
    └ Outputs:              [b'{"foo": "B   A   C"}'] ✘

You can combine --test with --watch to automatically rerun tests whenever the source files change.

Licence

Bitswan is open-source software, available under BSD 3-Clause License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bitswan-2025.7.24.9.tar.gz (583.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

bitswan-2025.7.24.9-py2.py3-none-any.whl (446.5 kB view details)

Uploaded Python 2Python 3

File details

Details for the file bitswan-2025.7.24.9.tar.gz.

File metadata

  • Download URL: bitswan-2025.7.24.9.tar.gz
  • Upload date:
  • Size: 583.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for bitswan-2025.7.24.9.tar.gz
Algorithm Hash digest
SHA256 b40e93fb4f6458e22e9e2aaa852976fd103209aa2d80a7a3686eceb927cccbef
MD5 77ec8b79a384540b22be4d8ba19e9051
BLAKE2b-256 680c372d113c2cc20f1197685bc5915cf2487def756a44a0b55fa52d4f26cea7

See more details on using hashes here.

File details

Details for the file bitswan-2025.7.24.9-py2.py3-none-any.whl.

File metadata

  • Download URL: bitswan-2025.7.24.9-py2.py3-none-any.whl
  • Upload date:
  • Size: 446.5 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for bitswan-2025.7.24.9-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 0afc13e36ca24fc267a671b8f1742e6f3b73a3f291f46a2fb0c44c7ccaa68ab7
MD5 23272820dbdbed221553b1072937d7c5
BLAKE2b-256 753ff9da90fc8c73df2c64c13d403c426572caba5172b4c507115ee7a6828445

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page