Skip to main content
Voodoo

Voodoo

The programmable runtime for adaptive applications and operational systems.

PyPI version Python 3.12+ License: MIT CI PyPI downloads

One runtime for Web, APIs, Agents, Workers, Human workflows, Distributed systems, and Physical systems. Built for the future of adaptive applications and operational systems.

Voodoo favors composition over configuration, Python over DSLs, adapters over lock-in, events over tightly coupled systems, and explicit capabilities over unrestricted AI autonomy.


Table of Contents


Why Voodoo?

Modern application development is fragmented. You assemble a frontend framework, a backend framework, a database, a queue, an event bus, an AI SDK, an auth system, a deployment pipeline — and spend more time gluing them together than building your product.

Voodoo asks: what if all of that was one thing?

Voodoo is not a wrapper around other frameworks. It's a unified runtime where UI, API, agents, workers, events, and data are first-class primitives that share a single execution model.

Quick start

pip install voodoo-framework
voodoo new my_app
cd my_app
voodoo dev

Open http://localhost:8000 — that's it. No npm, no bundler, no config files.

The scaffold produces only app/page.py, voodoo.toml, and pyproject.toml — nothing else. No main.py, no .env, no placeholder directories.

Want AI features? Install with pip install "voodoo-framework[ai]" to add OpenAI, Anthropic, Gemini, and Ollama SDKs.

The AI SaaS app

Here's a complete example exercising the full chain — UI → agent → tool → MCP → mesh → worker → database:

from voodoo import (
    App,
    page,
    state,
    event,
    Agent,
    tool,
    Container,
    Heading,
    Text,
    Button,
    Card,
    Div,
    Table,
)

app = App()

# --- Data model ---
from voodoo import Model


class Lead(Model):
    name: str
    email: str
    status: str = "new"


# --- Tool (one definition, four consumers) ---
@tool
async def create_lead(name: str, email: str) -> str:
    """Create a new lead in the database."""
    lead = await Lead.create(name=name, email=email)
    return f"Created lead #{lead.id}: {name}"


# --- Agent with tool calling ---
agent = Agent(
    model="openai:gpt-4o",
    tools=["create_lead"],
    system_prompt="You are a sales assistant. Use tools to create leads.",
)

# --- Realtime mesh event ---
from voodoo.mesh import mesh


@mesh.on("lead.created")
async def notify_slack(payload):
    # Triggered when a lead is created
    print(f"New lead notification: {payload}")


# --- Reactive UI ---
leads = state([])


@page("/")
def dashboard():
    return Container(
        Heading("AI SaaS Dashboard", level=1),
        Card(
            Text("Ask the AI to create leads"),
            Button("Create Lead", onclick="vd.event('create_lead', 'btn')"),
        ),
        Div(
            Table(*leads.get()),
            id="leads-table",
        ),
    )


@event
async def create_lead(element_id, value):
    run = await agent.run("Create a lead for Ada Lovelace, ada@x.io")
    # Agent calls create_lead tool → DB insert → mesh event fires
    all_leads = await Lead.all()
    leads.set(all_leads)


if __name__ == "__main__":
    app.run()

What makes Voodoo different

Differentiator What it means
AI is one form of Compute AI, agents, tools, and MCP are capabilities within one runtime — not a separate subsystem or a mandatory primitive
Agents as application primitives Agent() sits next to Button() and Card() in your code
Voodoo Mesh Unified event layer connecting UI, workers, agents, and applications
One tool, many consumers A single @tool definition serves Python calls, agents, MCP, and mesh
Observability everywhere Correlation IDs and telemetry built into every subsystem
Unified runtime engine Every operation (HTTP, Agent, Tool, MCP, Worker, Human, Event) produces an Execution record with full traceability
Human-in-the-Loop ask_human() + approve()/deny() — humans as compute participants, not afterthoughts
Adaptive execution Planner resolves capabilities to compute participants; supervisor steers with retry, fallback, budget control
Durable by default Tasks, executions, schedules, and events survive process restarts — backed by SQLite out of the box
Zero-config runtime voodoo newvoodoo dev → working app. No build step. Add voodoo.toml when you need configuration
Local-first, cloud-capable SQLite by default; PostgreSQL, Redis, and S3/R2 are optional adapters behind the same contracts

The Computational Model

The runtime is built on a small set of explicit concepts — not a pile of features:

Entity → State → Intent → Capability → Execution → Effect → State
Intent       — the desired outcome to achieve
Capability   — ability + authorization to produce an effect
Execution    — the central runtime mechanism (every operation is one)
Effect       — the change produced by an execution
State        — the operational truth of an entity or system

Compute, Time, Resource, and Constraint govern how an Execution happens — and AI is one form of Compute, never a fundamental primitive.

from voodoo.primitives import State, Capability, Intent, Effect

See docs/primitives.md for the computational model, docs/execution-model.md for runtime semantics, and ARCHITECTURE.md for the implementation model.

Features

UI & Frontend

  • Reactive UI — Component system in pure Python with WebSocket-driven DOM patches
  • Design System — Built-in theme engine with Tailwind adapter support
  • SEO & GEO — Server-side rendering, sitemaps, OpenGraph, and Generative Engine Optimization

AI & Agents

  • Agents — Provider-driven execution loop with tool calling (OpenAI, Anthropic, Gemini, Ollama)
  • Tools@tool decorator with auto-generated JSON schemas from type hints
  • MCP — Built-in Model Context Protocol server; every tool is automatically exposed
  • Human-in-the-Loopask_human(), approve()/deny(), Task(human=True) — humans as compute participants

Backend & Data

  • Data — Async SQLite ORM with RLS policies and lifecycle hooks
  • Auth — JWT tokens, API keys, session cookies, RBAC route guards
  • Workers@task decorator with retries, timeout, and telemetry spans
  • Voodoo Mesh — Realtime event bus with local + remote boundaries

Runtime & Infrastructure

  • Runtime Engine — Unified ExecutionEngine producing Execution records for every operation
  • Durable Execution — SQLite-backed execution store with checkpointing and voodoo recover CLI
  • Planner — Deterministic capability → compute participant resolution with fallbacks
  • Adaptive Runtime — Supervisor loop with retry, fallback, delegation, budget steering
  • Telemetry — Correlation IDs, request tracking, agent token/cost accounting
  • Security — CORS, CSRF, rate limiting, security headers — all on by default

Adapters (optional extras)

  • PostgreSQL — Database, queue, and event store ([postgres])
  • Redis — Queue and cache ([redis])
  • S3/R2 — Object store with presigned URLs and multipart uploads ([s3])

Installation

Homebrew (macOS/Linux)

brew tap helderperez-dev/voodoo
brew install voodoo

uv

uv tool install voodoo-framework

Magic install script

curl -fsSL https://raw.githubusercontent.com/helderperez-dev/voodoo/main/install.sh | bash

pip / pipx

# Core (lean — no AI SDKs)
pip install voodoo-framework

# With AI providers
pip install "voodoo-framework[ai]"

# With all optional extras
pip install "voodoo-framework[ai,postgres,redis,s3]"

# With dev tools
pip install "voodoo-framework[dev]"

# Isolated environment
pipx install voodoo-framework

Verify

voodoo version

Uninstall

# Homebrew
brew uninstall voodoo && brew untap helderperez-dev/voodoo

# uv
uv tool uninstall voodoo-framework

# pip / pipx
pip uninstall voodoo-framework   # or: pipx uninstall voodoo-framework

# Magic install script
rm -rf ~/.voodoo/venv && rm -f ~/.local/bin/voodoo

Configuration

Voodoo runs zero-config out of the box. When you need to customize, create a voodoo.yaml file:

database:
  provider: sqlite          # sqlite (default) | postgres
queue:
  provider: sqlite          # sqlite (default) | postgres | redis
events:
  provider: sqlite          # sqlite (default) | postgres | memory
objects:
  provider: local           # local (default) | s3
cache:
  provider: memory          # memory (default) | redis
models:
  default: openai:gpt-4o

Environment variables follow the VOODOO_* convention and override defaults. See .env.example for the complete reference.

Key variables:

Variable Default Description
VOODOO_ENV development production disables debug mode
VOODOO_SECRET_KEY dev default JWT signing key — must set in production
VOODOO_DB_PATH .voodoo/state/data.db SQLite database path
VOODOO_DATABASE_PROVIDER sqlite Database backend
VOODOO_QUEUE_PROVIDER sqlite Task queue backend
VOODOO_REDIS_URL Redis URL (queue/cache/events fallback)
OPENAI_API_KEY OpenAI API key for agents

Generate a secure secret key:

voodoo auth secret-key

Documentation

Getting Started

Building Apps

AI & Agents

Realtime & Workers

Runtime & Operations

Engineering

AI Development Workflow

Examples

Example Description Run
hello_world Minimal single-page app voodoo dev examples/hello_world/main.py
dashboard Reactive UI with state and events voodoo dev examples/dashboard/main.py
realtime WebSocket-driven realtime app voodoo dev examples/realtime/main.py
ai_agent Agent with tools and MCP voodoo dev examples/ai_agent/main.py
ai_saas Full SaaS: auth, data, agents, workers voodoo dev examples/ai_saas/main.py

Project Status & Roadmap

Voodoo is in active development (v1.16.0, Beta). The core runtime, UI system, AI agents, MCP, durable execution, and adaptive runtime are production-ready. PostgreSQL, S3/R2, and Redis adapters are shipped behind optional extras; the AI runtime (model-provider protocol, memory, durable agents, and durable human-in-the-loop) is the current focus.

timeline
    title Voodoo Roadmap
    section Shipped (v1.0–v1.15.1)
        Core Runtime & UI : Routing : Components : Reactive state
        AI & Agents : Providers : Tools : MCP : Human-in-the-Loop
        Unified Runtime : ExecutionEngine : Planner : Adaptive supervisor
        Durable Local Runtime : SQLite queue : Executions : Scheduler : Objects : Events
        Production Providers : PostgreSQL : S3/R2 : Redis
    section In Progress (v1.16–v1.19)
        ModelProvider protocol : Model descriptors : Routing aliases
        Memory capability : Layered memory : SQLite + FTS5
        Durable Agents & HITL : Agent registry : Resumable approvals
    section Planned (v2.0+)
        Capability Security & Secrets : v2.0
        Observability & Protocol : v2.1–v2.2
        Local Runtime DX : v2.3
Milestone Version Status
Core framework — runtime, UI, routing, reactive state v1.0–v1.1 ✅ Shipped
AI & unified runtime — agents, tools, MCP, HITL, ExecutionEngine, planner, adaptive runtime v1.2 ✅ Shipped
Durable local runtime (zero-infra) — SQLite storage, queue, executions, scheduler, objects, events v1.3–v1.9 ✅ Shipped
Adapter contracts & runtime configuration v1.10–v1.11 ✅ Shipped
Production providers (optional) — PostgreSQL, S3/R2, Redis v1.12–v1.15 ✅ Shipped
AI runtime — model-provider protocol, memory, durable agents, durable HITL v1.16–v1.19 🚧 In Progress
Capability security & secrets v2.0 📋 Planned
Protocol stability & DX — observability, schemas, local runtime v2.1–v2.3 📋 Planned

See the master roadmap and sprint plan for details.

Contributing

Contributions are welcome! Please read the Contributing Guide before opening a pull request.

AI coding agents: Read AGENTS.md and .github/copilot-instructions.md before making any changes. These define the architectural invariants, code style, testing standards, and sprint protocol that must be followed.

Quick start for contributors:

git clone https://github.com/helderperez-dev/voodoo.git
cd voodoo
just install          # set up dev environment
just format && just lint && just test

By participating, you agree to abide by the Code of Conduct.

Security

Voodoo includes security features on by default: CORS, CSRF protection, rate limiting, and security headers. For production deployments, review the hardening checklist in SECURITY.md.

To report a vulnerability, email contact@helderperez.com — do not open a public issue. See the full Security Policy for response timelines.

Testing

pytest

License

MIT — Copyright (c) 2026 Helder Perez and the Voodoo contributors.

Download files

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

Source Distribution

voodoo_framework-1.17.0.tar.gz (276.0 kB view details)

Uploaded Source

Built Distribution

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

voodoo_framework-1.17.0-py3-none-any.whl (269.4 kB view details)

Uploaded Python 3

File details

Details for the file voodoo_framework-1.17.0.tar.gz.

File metadata

  • Download URL: voodoo_framework-1.17.0.tar.gz
  • Upload date:
  • Size: 276.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.12.5 {"installer":{"name":"uv","version":"0.12.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for voodoo_framework-1.17.0.tar.gz
Algorithm Hash digest
SHA256 8764ae97d2b398edcf2bfa1efda0dfaf985b9379ddac00e885700bc306607e3c
MD5 270f19efcc4358c4444c8b5bef015b2c
BLAKE2b-256 f43b4b76205d5418c0ccb7b87d9c224e92e8afa80f48375517f6b64fd0e3e174

See more details on using hashes here.

File details

Details for the file voodoo_framework-1.17.0-py3-none-any.whl.

File metadata

  • Download URL: voodoo_framework-1.17.0-py3-none-any.whl
  • Upload date:
  • Size: 269.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.12.5 {"installer":{"name":"uv","version":"0.12.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for voodoo_framework-1.17.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b445ddbc5bf91f8a15395db90c40e6c66bc83606ead79738751e0645ee3dec15
MD5 4033bdba7adaa9fda7809d8ef716b37a
BLAKE2b-256 cb763b8638c54848b27dc8fdf90c1db6b99f516b0dde8002003138b5cdf2e608

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 Sentry Error logging StatusPage Status page