Skip to main content

Fagoon AI Agents Workflow

Reason this release was yanked:

Unstable Package

Project description

Fagoon Upgrade

Self-hosted AI platform with workflow automation, agents, chat, and API generation.

Build AI workflows visually, publish them as REST APIs, deploy agents, and chat with LLMs — all running on your own machine.


Quick Start

Prerequisites

Install & Run

# Install the CLI
pipx install fagoon-upgrade

# Start the platform
fagoon up

On first run, you'll see a setup wizard:

  Welcome to Fagoon!
  Let's set up your AI platform.

  How would you like to power your AI?
  1) I have an API key (OpenAI, Gemini, Groq, etc.)
  2) Use local Ollama model (free, runs on your machine)
  3) Skip for now (configure later in the UI)

  Choose [1/2/3]:

Pick your option and Fagoon starts automatically.

Access the Platform

Service URL
Frontend http://localhost:3000
Backend http://localhost:8000

Features

Visual Workflow Builder

Drag-and-drop workflow canvas to build AI automations. Connect LLM nodes, filters, loops, and integrations visually.

Workflow-as-API

Publish any workflow as a REST API endpoint with one click. Get an API key and endpoint URL — call it from any app, any language.

curl -X POST https://your-domain/api/v1/workflow-api/my-workflow/execute \
  -H "X-API-Key: wfapi_xxxxx" \
  -H "Content-Type: application/json" \
  -d '{"input": "Summarize this document"}'

AI Agents

Build and deploy conversational AI agents with memory, tool use, and multi-turn conversations.

Chat Interface

Chat with any LLM provider (OpenAI, Gemini, Groq, Anthropic, Ollama) through a unified interface.

Multi-Provider Support

Use any combination of LLM providers. Switch between them per workflow or per agent.


CLI Commands

fagoon up                    # Start the platform (lite mode)
fagoon up --full             # Start with Redis + Celery (multi-worker)
fagoon up --ollama           # Start with local Ollama LLM
fagoon down                  # Stop the platform
fagoon logs -f               # Follow live logs
fagoon status                # Check if running
fagoon update                # Pull latest version and restart
fagoon config set KEY=VALUE  # Set configuration
fagoon config show           # Show current config
fagoon db set-url URL        # Switch database

Configuration

Configuration is stored in ~/.fagoon/config.json. Set values via CLI or the web UI.

LLM Provider Keys

fagoon config set GEMINI_API_KEY=your-key-here
fagoon config set OPENAI_API_KEY=your-key-here
fagoon config set GROQ_API_KEY=your-key-here

Or configure through the web UI at http://localhost:3000 after login.

Using Local Ollama

Run with the Ollama profile to use free local models:

fagoon up --ollama

This starts an Ollama container alongside Fagoon. The Gemma 2B model is available as a fallback when no API keys are configured.


Deployment Modes

Lite Mode (Default)

Single-user, single-process. No Redis or Celery required. Perfect for personal use and small teams.

fagoon up

Full Mode

Multi-worker with Redis and Celery for background task processing. For production deployments and teams.

fagoon up --full

Using Docker Compose Directly

If you prefer not to use the CLI:

Lite Mode

# docker-compose.yml
services:
  app:
    image: ghcr.io/fagoon-ai/upgrade:2.0.0
    ports:
      - "8000:8000"
      - "3000:3000"
    environment:
      LITE_MODE: "true"
      DATABASE_URL: postgresql+asyncpg://fagoon:fagoon@db:5432/fagoon
      JWT_SECRET: "your-secret-here"
      GEMINI_API_KEY: "your-key-here"
    depends_on:
      db:
        condition: service_healthy

  db:
    image: pgvector/pgvector:pg16
    environment:
      POSTGRES_USER: fagoon
      POSTGRES_PASSWORD: fagoon
      POSTGRES_DB: fagoon
    volumes:
      - fagoon_db:/var/lib/postgresql/data
    healthcheck:
      test: ["CMD-SHELL", "pg_isready -U fagoon"]
      interval: 5s
      timeout: 5s
      retries: 10

volumes:
  fagoon_db:
docker compose up -d

Full Mode

# docker-compose.full.yml
services:
  app:
    image: ghcr.io/fagoon-ai/upgrade:2.0.0
    ports:
      - "8000:8000"
      - "3000:3000"
    environment:
      LITE_MODE: "false"
      DATABASE_URL: postgresql+asyncpg://fagoon:fagoon@db:5432/fagoon
      REDIS_URL: redis://redis:6379/0
      CELERY_BROKER_URL: redis://redis:6379/1
    depends_on:
      db:
        condition: service_healthy
      redis:
        condition: service_started

  worker:
    image: ghcr.io/fagoon-ai/upgrade:2.0.0
    command: uv run celery -A src.core.celery_app worker -P eventlet -c 50
    environment:
      LITE_MODE: "false"
      DATABASE_URL: postgresql+asyncpg://fagoon:fagoon@db:5432/fagoon
      REDIS_URL: redis://redis:6379/0
      CELERY_BROKER_URL: redis://redis:6379/1
    depends_on:
      app:
        condition: service_healthy

  redis:
    image: redis:7-alpine

  db:
    image: pgvector/pgvector:pg16
    environment:
      POSTGRES_USER: fagoon
      POSTGRES_PASSWORD: fagoon
      POSTGRES_DB: fagoon
    volumes:
      - fagoon_db:/var/lib/postgresql/data
    healthcheck:
      test: ["CMD-SHELL", "pg_isready -U fagoon"]
      interval: 5s
      timeout: 5s
      retries: 10

volumes:
  fagoon_db:
docker compose -f docker-compose.full.yml up -d

Workflow API — Turn Any Workflow Into an API

1. Build a Workflow

Open http://localhost:3000, create a workflow in the visual canvas.

2. Publish as API

Click API IntegrationGenerate API Key & Slug. Copy the API key (shown only once).

3. Call It From Anywhere

cURL:

curl -X POST http://localhost:8000/api/v1/workflow-api/your-slug/execute \
  -H "X-API-Key: wfapi_your_key_here" \
  -H "Content-Type: application/json" \
  -d '{"input": "Hello from my app"}'

JavaScript:

const response = await fetch('http://localhost:8000/api/v1/workflow-api/your-slug/execute', {
  method: 'POST',
  headers: {
    'X-API-Key': 'wfapi_your_key_here',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({ input: 'Hello from my app' })
});
const data = await response.json();
console.log(data.output);

Python:

import requests

response = requests.post(
    'http://localhost:8000/api/v1/workflow-api/your-slug/execute',
    headers={'X-API-Key': 'wfapi_your_key_here'},
    json={'input': 'Hello from my app'}
)
print(response.json()['output'])

API Response Format

{
  "success": true,
  "execution_id": "uuid",
  "status": "COMPLETED",
  "output": {
    "output_text": "AI generated response here",
    "model": "gemini-2.5-flash",
    "usage": { "input_tokens": 100, "output_tokens": 50 }
  },
  "usage": { "duration_ms": 2500 }
}

Environment Variables

Variable Default Description
LITE_MODE true true for single-process, false for Redis+Celery
DATABASE_URL auto PostgreSQL connection string
JWT_SECRET auto-generated Secret for JWT tokens
ENCRYPTION_KEY auto-generated Fernet key for encrypting secrets
GEMINI_API_KEY Google Gemini API key
OPENAI_API_KEY OpenAI API key
GROQ_API_KEY Groq API key
ANTHROPIC_API_KEY Anthropic API key
REDIS_URL Redis URL (full mode only)
CELERY_BROKER_URL Celery broker URL (full mode only)
WEB_CONCURRENCY 1 Number of uvicorn workers

Troubleshooting

"Cannot connect to Docker daemon"

Start Docker Desktop and wait for the whale icon to appear in your menu bar.

"Port 3000/8000 already in use"

Stop any other services on those ports, or change ports in the compose file.

Platform won't start

fagoon logs -f     # Check logs for errors
fagoon down        # Stop everything
fagoon up          # Restart

Reset everything

fagoon down
docker volume rm fagoon_db fagoon_data   # Removes all data
fagoon up

Tech Stack

  • Backend: Python, FastAPI, SQLAlchemy, PostgreSQL, pgvector
  • Frontend: Next.js, React, TailwindCSS, React Flow
  • Workflow Engine: Custom DAG executor with 20+ node types
  • Database: PostgreSQL with pgvector for embeddings
  • Task Queue: Celery + Redis (full mode)
  • Container: Docker, Docker Compose

License

MIT


Links

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

fagoon_upgrade-2.0.2.tar.gz (8.1 MB view details)

Uploaded Source

Built Distribution

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

fagoon_upgrade-2.0.2-py3-none-any.whl (672.2 kB view details)

Uploaded Python 3

File details

Details for the file fagoon_upgrade-2.0.2.tar.gz.

File metadata

  • Download URL: fagoon_upgrade-2.0.2.tar.gz
  • Upload date:
  • Size: 8.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for fagoon_upgrade-2.0.2.tar.gz
Algorithm Hash digest
SHA256 9d6ce26fd6390a4d03c6b99f2417af6931d3d202a905c8f0b0b449354d628cbb
MD5 d8ee3164bfdc53e79a051b2b552e483c
BLAKE2b-256 0a83ae2171b642e20b7f0ee88f382955fddb58ad34896e30406e8784fbc75326

See more details on using hashes here.

Provenance

The following attestation bundles were made for fagoon_upgrade-2.0.2.tar.gz:

Publisher: release.yml on Fagoon-AI/upgrade

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fagoon_upgrade-2.0.2-py3-none-any.whl.

File metadata

  • Download URL: fagoon_upgrade-2.0.2-py3-none-any.whl
  • Upload date:
  • Size: 672.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for fagoon_upgrade-2.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 ea497f149c69b2861f4957cc8f7cd711cc404190fc55beb48aa9d2b5f48b2e4a
MD5 c4826251094edca9b299e87a3da8d06e
BLAKE2b-256 48fc3cbe994cd7d1a68e430fadb4a13ea6af53b07011139a5fd59323ab601987

See more details on using hashes here.

Provenance

The following attestation bundles were made for fagoon_upgrade-2.0.2-py3-none-any.whl:

Publisher: release.yml on Fagoon-AI/upgrade

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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