Adding Agent Capabilities to ai-backends with Pi
Melvin Vivas · X video post · 2026-08-15 · Open on X
Topics: AI Agents, Tool Use & MCP, LLMOps, Deployment & Monitoring, Portfolio Projects · Level: intermediate
Summary
Melvin added agent capabilities to his open-source ai-backends project using Pi. ai-backends is an API server for common AI use cases. It supports many models and providers, running locally with Ollama or LM Studio or in the cloud via OpenRouter, OpenAI, Anthropic and others.
Key points
- ai-backends is an API server runtime for common AI use cases.
- It supports multiple models and providers.
- It runs locally with Ollama or LM Studio, or in the cloud via OpenRouter, OpenAI, Anthropic, etc.
- Agent capabilities were added using Pi (@pidotdev).
- It's open source on GitHub, so you can read the code to see how agents are built in.
Resources mentioned
- AIBackends · repo · aibackends.com · free
Open-source API server runtime for common AI use cases that supports many models and providers (Ollama, LM Studio, OpenRouter, OpenAI, Anthropic).
Also in: Redacting PII Locally with GLiNER-PII Before AI Processing (Melvin Vivas on X · notes), Building a production website with Opus 5.5 and TanStack (Melvin Vivas on X · notes), CamelFlow: open-source visual viewer for Apache Camel routes (Melvin Vivas on X · notes), AI Backends: A Production AI Workflow Engineering Site (Link Share) (Melvin Vivas on X · notes) and 17 more - Pi · tool · x.com · free
A customizable coding agent that can be extended through its Extensions API and connected to several model providers.
Also in: 100-Iteration Autonomous Coding Loop with Local Qwen on an RTX 3090 (Melvin Vivas on X · notes), Pi Agent: A Highly Customizable Agent with Durable Sessions (Melvin Vivas on X · notes), Prompting an Autonomous Agent Loop: Be Specific, Show Visible Progress (Melvin Vivas on X · notes), Running an Overnight 100-Iteration Agent Loop with a Local Qwen Model (Melvin Vivas on X · notes) and 54 more - Ollama · tool · x.com · free · recommended by both Bashiri Smith & Melvin Vivas
Open-source tool for downloading and running LLMs locally from a simple command line or API.
Also in: GitHub Copilot Adds Intelligent Local Model Routing (Project HydraFusion) (Melvin Vivas on X · notes), Run Local LLMs on the Computer You Already Have: A Beginner's Path (Melvin Vivas on X · notes), Running LLMs Locally Without an Expensive Rig (Melvin Vivas on X · notes), Adding Vercel AI Gateway as a provider in AIBackends with Devin (Melvin Vivas on X · notes) and 14 more - LM Studio · tool · x.com · free
Desktop app for downloading and running LLMs locally, with a developer mode that serves models through an API.
Also in: Run Local LLMs on the Computer You Already Have: A Beginner's Path (Melvin Vivas on X · notes), Running LLMs Locally Without an Expensive Rig (Melvin Vivas on X · notes), Adding Vercel AI Gateway as a provider in AIBackends with Devin (Melvin Vivas on X · notes), LoRA Fine-Tune Qwen3.5-2B on Your Tweets with Unsloth Studio (Melvin Vivas on X · notes) and 32 more - OpenRouter · tool · openrouter.ai · free
A single OpenAI-compatible API that routes requests to hundreds of models from many providers, with one bill and model fallbacks.
Also in: Stealth Model 'Space Bunny' Revealed as MiniMax M3.1 Flash (Melvin Vivas on X · notes), NVIDIA Nemotron 3.5 Super VL now on OpenRouter (Melvin Vivas on X · notes), OpenRouter serves image models, including FLUX 3 Image Klein (Melvin Vivas on X · notes), Comparing Opus 5.5, GPT-6 Astra and Grok 4.7 on OpenRouter (Melvin Vivas on X · notes) and 53 more
Try this
- Clone ai-backends and run it locally with Ollama or LM Studio.
- Build a multi-provider AI API server that has agent endpoints.
More in AI Agents, Tool Use & MCP
- Running a Hermes agent locally on Qwen 3.8 27B (Q4_K_M) on an RTX 3090
- DonvitoCodes Colab notebooks for running local models (LFM2.5-2.6B)
- Multi-agent delegation to lower-cost models to save Codex limits
- Create scheduled jobs in Hermes by asking in chat
- Hermes (Grok 4.6) vs ChatGPT Work on a text-to-PDF task
- Turning the X 'For You' Algorithm Code into an Agent Skill