Prompt-driven backend framework — add AI-powered natural language tool execution to any Python project
Project description
VibeServer
Prompt-driven backend framework. Replace REST endpoints with natural language.
pip install vibeserver
from vibeserver import VibeServer
vs = VibeServer()
@vs.tool("greet", description="Greet a user by name")
def greet(name: str) -> dict:
return {"message": f"Hello, {name}!"}
vs.run() # starts at http://localhost:8000
Then call it:
from vibeserver import VibeClient
async with VibeClient("http://localhost:8000") as client:
result = await client.vibe("greet Alice")
print(result.data) # {"message": "Hello, Alice!"}
How It Works
Instead of POST /api/greet {"name": "Alice"}:
- Send natural language:
POST /with{"input": "greet Alice"} - LLM plans execution:
{steps: [{action: "greet", params: {name: "Alice"}}]} - Tool executes and returns structured JSON
- Repeat calls match the Intent Graph — no LLM needed
Quick Start
# Scaffold a new project
vibeserver init my-app
cd my-app
# Edit app.py to add your tools, then:
vibeserver serve
# Open http://localhost:8000 for the Web UI
SDK: Embedded Mode
from fastapi import FastAPI
from vibeserver import VibeServer
app = FastAPI()
vs = VibeServer()
@vs.tool("search_users", description="Search users by name")
def search_users(query: str, limit: int = 10) -> dict:
results = db.query(f"SELECT * FROM users WHERE name LIKE '%{query}%' LIMIT {limit}")
return {"users": results}
# Mount under existing FastAPI app
app.mount("/vibe", vs.asgi("my-app"))
Client: Remote Access
from vibeserver import VibeClient
async with VibeClient("http://vibe:8000", api_key="vs_xxx") as client:
# Natural language execution
result = await client.vibe("search users named Alice")
# Streaming (SSE)
async for event in client.stream("create a report for Q3"):
print(event["type"], event)
# Direct API
tools = await client.list_tools()
metrics = await client.metrics()
Built-in Tools (9 included)
| Tool | Description |
|---|---|
compute |
Transform data (uppercase, lowercase, json_parse, sum, length) |
create_record |
Create a database record |
search |
Search records by type |
update_record |
Update a record |
delete_record |
Delete a record |
get_user |
Look up user by ID |
auth |
Verify API keys |
list_users |
List all users (admin) |
stats |
System statistics |
Configuration
VIBESERVER_MODEL=openai/cmd/deepseek/deepseek-v4-pro
VIBESERVER_API_BASE=http://localhost:20128/v1
VIBESERVER_API_KEY=sk-xxx
VIBESERVER_DB_PATH=vibeserver.db
VIBESERVER_LOG_LEVEL=INFO
Or pass directly:
vs = VibeServer(
model="openai/cmd/deepseek/deepseek-v4-pro",
api_base="http://localhost:20128/v1",
api_key="sk-xxx",
)
Docker
docker compose up
Architecture
POST / {"input": "create a note saying hello"}
→ Guardrails (prompt injection check)
→ Intent Graph: match cached plan?
YES → ParamExtractor fills slots → execute
NO → LLM Planner → validate → new node → execute
→ Responder → {"status": "success", "data": {...}}
Full architecture docs: docs/ARCHITECTURE.md
License
MIT
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
vibeserver-0.3.0.tar.gz
(35.4 kB
view details)
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 vibeserver-0.3.0.tar.gz.
File metadata
- Download URL: vibeserver-0.3.0.tar.gz
- Upload date:
- Size: 35.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/7.0.0 CPython/3.12.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3e91225de7d7d3aade880723418a8b99cbd1944cf058d53888c90cb49738e95c
|
|
| MD5 |
62f03363ab7c337957dbe7de85059dde
|
|
| BLAKE2b-256 |
59a971c346b8764add66e686e250dcb4e411b64046233b1dbf0d7a72c5d79027
|
File details
Details for the file vibeserver-0.3.0-py3-none-any.whl.
File metadata
- Download URL: vibeserver-0.3.0-py3-none-any.whl
- Upload date:
- Size: 40.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/7.0.0 CPython/3.12.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
95ea9f49fe38f1d2466273bbfe50f87c7cfc3811835d1fadf1387ba64e504c07
|
|
| MD5 |
21129fddf71e6b00f6f6502041027d10
|
|
| BLAKE2b-256 |
65aae77d0a5c32b8ad4af7452465773a929aaf75e0d1cb0787e5893fc818d30a
|