Phoenix AI
Advanced AI Infrastructure SDK for Autonomous Agents, Chatbots, and Production Backend Services.
Whether you are building with FastAPI, Django, or a custom event-driven service, Phoenix AI eliminates repetitive backend setup and provides a highly-optimized orchestration layer for large language models, computer vision, and physical hardware.
Why Phoenix AI?
- Autonomous Agents: Single-line creation of thinking, planning, and executing AI agents.
- High-Level ChatBot: Turnkey conversational AI with native RAG, Vision, and Memory.
- "Everything as a Service": A unified Dependency Injection container handles Vector DBs, Redis caching, and LLMs seamlessly.
- Fail-Loud & Recover: Auto-fallbacks from Local (Ollama/Transformers) to Cloud (OpenAI) to prevent system crashes.
- Native PyTorch & 4-bit Quantization: Run local models directly on your GPU without external servers, automatically optimized for low-VRAM machines.
- Sensorium (Embodied AI): Plug your AI directly into the physical world via IoT, MQTT, and Arduino plugins.
📦 Installation
Choose the installation tier that matches your project needs:
# Core Backend Framework
# Download Size: ~5.2 MB (Verified)
# Installed Size on Disk: ~15 MB
pip install phx-ashborn
# Core + ChatBot & Conversation Memory
# Download Size: ~35 MB (Estimated)
# Installed Size on Disk: ~90 MB
pip install "phx-ashborn[chatbot]"
# Core + Advanced RAG Frameworks (Qdrant, ChromaDB, Web/API Ingestion)
# Download Size: ~45 MB
# Installed Size on Disk: ~110 MB
pip install "phx-ashborn[rag]"
# Core + Autonomous Agents & Planners
# Download Size: ~107 MB (Verified)
# Installed Size on Disk: ~200 MB
pip install "phx-ashborn[agent]"
# Full Suite (Everything including Local AI Inference)
# ⚠️ Download Size: ~2.2 GB - 2.5 GB (Estimated)
# ⚠️ Installed Size on Disk: ~5.5 GB - 6.0 GB
pip install "phx-ashborn[full]"
Quickstarts & Core Features
1. Autonomous Agents
The Phoenix Agent is a high-speed cognitive engine capable of understanding complex problems, scanning codebases, planning multi-step solutions, and executing parallel tools.
import asyncio
from phoenix import Agent
async def agent_demo():
# Initialize a high-speed Agent with default tools and memory
agent = Agent()
# Or inject custom tools instantly!
from phoenix.framework.agent import tool
@tool(name="custom_math", description="Calculates squares. Input: 'number' (int)")
def math_tool(number: int):
return f"The square is {number ** 2}"
agent.register_tool(math_tool)
# Run a complex engineering task
# The agent will: Think -> Analyze -> Plan -> Execute Tools -> Reflect
result = await agent.run(
"Find the redundant code in the memory module and optimize it.",
mode="plan"
)
print(f"Agent Execution Report: {result}")
asyncio.run(agent_demo())
2. Multi-Modal ChatBot
Need a powerful conversational interface without the complexity of building agent loops? The ChatBot builder abstracts away RAG, Vision (VLM), and Session Memory into a fluent API.
from phoenix import ChatBot
import asyncio
async def chatbot_demo():
# Build a complete AI ChatBot in one line
bot = (ChatBot(local=False, vlm=True)
.with_rag(["./docs", "./src"]) # Ingest folders automatically
.with_memory() # Enable conversation history
.with_security(mode="strict") # Prompt-injection protection
.with_system_prompt("You are a helpful Python expert.")
.build())
# Multi-modal interaction out of the box
response = await bot.chat(
prompt="Explain this architecture diagram.",
image_path="architecture.png"
)
print(response)
asyncio.run(chatbot_demo())
3. Advanced RAG Frameworks
The new object-oriented RAG framework provides scalable RAG, CAG (Cache-Augmented Generation), AgenticRAG, and MultiModalRAG systems out of the box with unified multi-source ingestion.
import asyncio
from phoenix.framework.rag import RAG, AgenticRAG
async def rag_demo():
# Initialize standard RAG (ChromaDB is default)
rag = RAG()
# Unified Multi-Source Ingestion
await rag.ingest_multi([
{"type": "folder", "path": "./my_project"},
{"type": "github", "repo_url": "https://github.com/blackeagle686/phoenix-ai.git"},
{"type": "url", "url": "https://example.com/api-docs"},
{"type": "sql", "connection_string": "sqlite:///data.db", "table": "docs"}
])
# Query with automatic context compression and MMR reranking
answer = await rag.query("How do I extend the caching layer?")
print(answer)
# Or upgrade to AgenticRAG to let the AI verify its own answers and rewrite poor queries!
# agentic = AgenticRAG(max_retries=3, verify_answer=True)
asyncio.run(rag_demo())
🏗️ Advanced Architecture
Multi-Agent Orchestration
Define dynamic teams of specialized agents (e.g., Coder, Reviewer, Security Expert) and coordinate them through parallel broadcasting or sequenced pipelines.
from phoenix.framework import MultiAgentManager, MultiAgentConfig, AgentConfig
config = MultiAgentConfig(
team_name="Engineering Task Force",
agents=[
AgentConfig(name="Giyu_Coder", profile="profiles/coder.json"),
AgentConfig(name="Shinobu_Reviewer", profile="profiles/reviewer.json")
]
)
manager = MultiAgentManager(config)
report = await manager.run_pipeline(
prompt="Implement a thread-safe cache system",
agent_sequence=["Giyu_Coder", "Shinobu_Reviewer"]
)
🦾 Sensorium (Hardware SDK)
Connect your Phoenix Agents to the physical world using an async, zero-latency plugin architecture. Build Smart Home routines, Robotics controllers, or Drone surveillance systems!
from phoenix.framework.sensorium.core.manager import DeviceManager
from phoenix.framework.sensorium.plugins.mock_plugin import MockSensorPlugin
from phoenix.framework.agent import tool
manager = DeviceManager()
await manager.add_device("living_room_temp", MockSensorPlugin())
@tool(name="get_temperature", description="Reads current room temp.")
async def read_temp():
return await manager.get_device("living_room_temp").read()
⚠️ Local Inference Requirements
If you run Phoenix using Local LLMs/VLMs (via Ollama or native Transformers), ensure your machine meets the following specifications to prevent system instability:
- RAM: 8GB Minimum (16GB+ recommended).
- GPU: 4GB+ VRAM required for Vision/VLM models (utilizing built-in 4-bit quantization).
- Disk Space: 10GB+ free space for model weights.
Comprehensive Documentation
Ready to dive deeper? Explore our dedicated guides to master the Phoenix ecosystem:
Core Architecture
Data & Retrieval
- Advanced RAG Frameworks (CAG, Agentic, MultiModal)
- Data Pipelines & Legacy RAG (Arabic Version)
- Model Training & Finetuning (Arabic Version)
Autonomous Agents
Integrations & Extensions
- Django Integration
- FastAPI / Backend Integration
- GUI App Integration
- Sensorium Embodied AI (Hardware)
⚡ BrainMemory Core (Rust Backend)
Phoenix AI ships with an ultra-fast, lock-free memory engine written entirely in Rust, accessible seamlessly from Python. It features a custom-built, embedded Hierarchical Navigable Small World (HNSW) Vector Database for sub-millisecond multi-modal context retrieval.
Performance Benchmarks
Methodology
All benchmarks were executed using cargo bench in release mode. Each benchmark was warmed up before measurement and repeated multiple times by Criterion to reduce statistical noise. Reported values are the benchmark mean.
Hardware Specifications & Parameters:
- CPU: Intel Core i5-1135G7
- RAM: 12 GB
- OS: Ubuntu 24.04 (Linux)
- Rust Version: Stable (1.80+)
- Embedding Size: 384 dimensions
- HNSW Configurations: M = 16, ef_construction = 100, ef_search = 50
Results
- Neural Bus (Event Ingestion):
~4.39 msper event spike.- What we benchmarked: Pushing a memory spike through a lock-free
crossbeamchannel and actively inserting a 384-dimensional embedding directly into the HNSW graph collection.
- What we benchmarked: Pushing a memory spike through a lock-free
- Fractal Compressor:
~2.46 msper 1,000 events.- What we benchmarked: Scanning an array of 1,000 artificially aged memory events, calculating their Exponential Time-Decay coefficients (halflife factor = 0.5), and applying hierarchical compression to prevent memory bloat.
- Retrieval Pipeline Overhead:
~1.01 µs(microseconds).- What we benchmarked: Utilizing a
tokioasync runtime to safely acquire read-locks on the memory core, querying 3 distinct vector collections simultaneously, and compiling the result. (Note: This1.01 µsmetric specifically captures the pipeline's async lock acquisition and traversal overhead on empty/cold collections, proving zero systemic bottleneck before the raw HNSW traversal phase). - The Output (
WorkingMemory): A synthesis of (Top Semantic Events + Recent Episodic Sequences + Relevant Knowledge Nodes) passed directly to the LLM.
- What we benchmarked: Utilizing a
Metadata
Release files for phx-ashborn 1.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| phx_ashborn-1.1.0.tar.gz | 196.7 kB | With provenance | Details for phx_ashborn-1.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| phx_ashborn-1.1.0-py3-none-any.whl | Python 3 | none | any | Details for phx_ashborn-1.1.0-py3-none-any.whl |
Total release size: 455.5 kB
Release files / phx_ashborn-1.1.0.tar.gz
| Download URL | phx_ashborn-1.1.0.tar.gz |
|---|---|
| Size | 196.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0164b7cdb49040e37d76f78ee0c50e96966b65261b80acc59218184f136fa3cc
|
|
BLAKE2b-256 checksum How to use checksums |
88d7936b0326dd8f194e909919e6bbec4d0f0d4235deaed99968453edd0f8ed6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.
Transparency logRelease files / phx_ashborn-1.1.0-py3-none-any.whl
| Download URL | phx_ashborn-1.1.0-py3-none-any.whl |
|---|---|
| Size | 258.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d6d4b0bde59448ec6b522e06262c94ca6e9ad820ee22d84847a26402a5a5bc4b
|
|
BLAKE2b-256 checksum How to use checksums |
c3ab47e552b971a98db0f43a286687b6237e65a539e9cb7a26b358fd903a4ece
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.
Transparency logSecurity for phx-ashborn 1.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for phx_ashborn-1.1.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 18, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.