Skip to main content

A Neuro-San powered Smart Agent Network Framework

Project description

NSFlow - A FastAPI based client for NeuroSan

NSFlow is a framework that enables users to explore, visualize, and interact with smart agent networks. It integrates NeuroSan for intelligent agent-based interactions.

Project Logo


Installation & Running NSFlow

NSFlow can be installed and run in three different ways:

1️⃣ Run NSFlow using git repo

To simplify execution, NSFlow provides a CLI command to start both the backend and frontend simultaneously.

Step 1: Clone the repository

git clone https://github.com/leaf-ai/nsflow.git

Step 2: Install NSFlow dependencies

python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
pip install -r requirements-private.txt

Step 3: Run Everything with a Single Command

python -m nsflow.run

By default, this will start:

  • backend (FastAPI + NeuroSan) here: http://127.0.0.1:4173/docs or http://127.0.0.1:4173/redoc
  • frontend (React) here: http://127.0.0.1:4173

2️⃣ Run NSFlow with a Wheel

You can run NSFlow inside a Docker container, which includes both the backend and frontend.

Step 1: Build the Frontend

sh build_scripts/build_frontend.sh

Step 2: Build the Wheel

sh build_scripts/build_wheel.sh

Note: The above script output should show that the wheel contains a module prebuilt_frontend


3️⃣ Development & Contribution (Manually Start Frontend & Backend)

If you want to contribute, ensure you have the necessary dependencies installed: To start the frontend and backend separately, follow these steps:

Step 1: Clone the Repository

git clone https://github.com/your-org/nsflow.git
cd nsflow

Step 2: Install Dependencies

Make sure you have Python 3.12 and Node.js (with Yarn) installed.

python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
pip install -r requirements-private.txt
cd frontend; yarn install

Step 3: Start the Backend & Frontend on separately

Backend:

cd .. # Back to project root
python -m nsflow.run --dev

Frontend: On another terminal window

cd frontend
yarn dev

By default:

  • backend will be available at: http://127.0.0.1:8005
  • frontend will be available at: http://127.0.0.1:5173

OR

Step 3: Start the prebuilt Frontend served with Backend

Note:

  • Ensure that ./nsflow/prebuilt_frontend/dist dir exists in your project
  • run sh build_scripts/build_frontend.sh to create the above dist if it is not present
cd .. # Back to project root
python -m nsflow.run
  • frontend will be available at: http://127.0.0.1:4173
  • backend will be available at: http://127.0.0.1:4173/docs

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

nsflow-0.5.9.tar.gz (212.9 kB view details)

Uploaded Source

Built Distribution

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

nsflow-0.5.9-py3-none-any.whl (218.4 kB view details)

Uploaded Python 3

File details

Details for the file nsflow-0.5.9.tar.gz.

File metadata

  • Download URL: nsflow-0.5.9.tar.gz
  • Upload date:
  • Size: 212.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for nsflow-0.5.9.tar.gz
Algorithm Hash digest
SHA256 ef7f0bd34f7f264b4596c6e44debb6f2d52deb14d180b7833f8f8b16e5c53c2d
MD5 2ef8b20af3e182dc9f39fea307243c6e
BLAKE2b-256 cb91cb4d85c2ddefddd7d0e639c0866e0b790382b9ee5b2256fbd87813f9cc74

See more details on using hashes here.

File details

Details for the file nsflow-0.5.9-py3-none-any.whl.

File metadata

  • Download URL: nsflow-0.5.9-py3-none-any.whl
  • Upload date:
  • Size: 218.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for nsflow-0.5.9-py3-none-any.whl
Algorithm Hash digest
SHA256 dd3082d2a6a0223dbbf7d63e52f25b1f82c8a1fbe446657c483a9922a09083f7
MD5 6e670e89ad384010cb97787ce46e430e
BLAKE2b-256 090c5ef3b4753b2bc068bda23c4646bec0e20878aa85416dfea195fd3176b751

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