Framework for building custom visual no-code workflows for AI and data apps. Also commonly known as: graphical flow based programming framework
Project description
Welcome to Barfi ! 👋
A Python visual Flow Based Programming library to buld workflows that integrates into existing codebases.
Documentation : find it here
Barfi is a Flow-Based Programming framework that offers a graphical programming interface. It is designed to integrate seamlessly into your existing Python applications.
Barfi serves as an abstraction of Graphical Programming, Flow-Based Programming, or Node Programming, where a Block corresponds to a Node, and a Link (or connection) corresponds to an Edge. These concepts go by different names, each reflecting specific needs or philosophies. In Barfi, they form the foundation of a framework for building, saving, and executing workflows as needed. The framework is intentionally kept simple, providing APIs that allow customization for diverse use cases and philosophies.
Many existing visual Flow-Based Programming (FBP) libraries/frameworks operate within their own confined isolated environments, limiting their usability as components in existing applications or scripts. Barfi addresses this by decoupling the graphical programming interface from the computation environment, which eables easy integration into existing apps. The graphical interface is provided through a Streamlit widget: st_flow (with a Jupyter Notebook widget currently in development), while the computation environment is managed independently via the ComputeEngine.
Note: The current version >= 1.0.0 introduces many changes from <= 0.7.0. Check the changelog for more info on this. Versions will no longer be maintained.
Quickstart
A workflow consists of a bunch of Blocks connected to each other, the information of the blocks and connections is stored in a FlowSchema, which is then executed to execute each program/function connected to each Block and to propagate the data from one Block to another.
Installation
Since we will be using the streamlit widget st_flow for the graphical interface here, we will install the package with the streamlit requirements:
pip install barfi[streamlit]
Note: As a best practice, it is recommended to setup a virtual environment to manage the dependencies of the project. If you do not know how to do this, this blog or this section could be of help.
Your First App
Follow this getting started guide on building your first Blocks, creating a FlowSchema and executing it using a ComputeEngine, save it using a SchemaManager.
Getting Started : find it here
Migration from v0
If you were using the versions <= 0.7.0, a migration guide is being written. For using version >= 1.0.0, conceptually all the concepts remain with a minor API changes. v1.0.0 introduces a stronger type checking mechanism, and decouples and SchemaManager and ComputeEngine from the UI by providing separate classes to run those functions. You can check the API docs to get familiarized on how to use them.
Under the hood
The Flow Editor UI is built using ReactFlow.
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 barfi-1.1.0.tar.gz.
File metadata
- Download URL: barfi-1.1.0.tar.gz
- Upload date:
- Size: 894.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.0.1 CPython/3.13.1 Darwin/24.2.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2d5345fc24534738d31fc643687628d55516ef452e77cc2f8ca375326744294b
|
|
| MD5 |
734d7024fa427a48d6a5d86845ae739b
|
|
| BLAKE2b-256 |
4196868ab77bcc75449375026c800891255873414e3fddb63850960c8e981a7d
|
File details
Details for the file barfi-1.1.0-py3-none-any.whl.
File metadata
- Download URL: barfi-1.1.0-py3-none-any.whl
- Upload date:
- Size: 907.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.0.1 CPython/3.13.1 Darwin/24.2.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a5b6ec40aeda6656d901209f7d33db3f1c1ef650665aa752c0f1c555d497e9fe
|
|
| MD5 |
09f8fd031c55f2106c17855f1f14218a
|
|
| BLAKE2b-256 |
e6188fbd3e62e077e9afbb37bb3a97f127449290e19c93257ba20458cd836743
|