Interactive Architecture Guide
AI Agent Architecturefrom Reasoning to Production
Explore the four layers that power modern AI agent systems — LLM reasoning, orchestration logic, data infrastructure, and tool integration — and learn how Pixeltable eliminates the infrastructure complexity.
The Four Layers of Agent Architecture
Click any layer to explore its role, capabilities, and related resources
Build an Agent in 40 Lines
Define tools as UDFs, wire them to an LLM, and let Pixeltable handle state, caching, and lineage automatically
1import pixeltable as pxt2from pixeltable.functions import openai, invoke_tools34# Define tools as UDFs — Pixeltable tracks everything5@pxt.udf6def get_weather(city: str) -> dict:7 return {"temp": 72, "conditions": "sunny"}89@pxt.query10def search_knowledge(query: str):11 sim = docs.text.similarity(query)12 return docs.order_by(sim, asc=False).limit(5).select(docs.text)1314# Load MCP tools from any server15mcp_tools = pxt.mcp_udfs('http://localhost:8000/mcp')16tools = pxt.tools(get_weather, search_knowledge, *mcp_tools)1718# Create agent workflow — state is automatic19agent = pxt.create_table('my_agent', {'prompt': pxt.String})2021# LLM reasons, selects tools, Pixeltable orchestrates22agent.add_computed_column(23 response=openai.chat_completions(24 model='gpt-4o',25 messages=[{26 'role': 'user',27 'content': agent.prompt28 }],29 tools=tools30 )31)3233# Automatic tool execution with full lineage34agent.add_computed_column(35 tool_output=invoke_tools(tools, agent.response)36)3738# Insert a prompt — everything runs automatically39agent.insert(prompt='What is the weather in Seattle?')4041# Full history, versioning, and reproducibility built in42agent.select(agent.prompt, agent.response, agent.tool_output).collect()
Multimodal Agent Capabilities
Build agents that seamlessly process video, images, audio, and documents with unified infrastructure
Video & Image Agents
Build agents that understand visual content with automatic frame extraction, object detection (YOLOX), and visual similarity search (CLIP).
Document & RAG Agents
Create agents that process PDFs, transcribe audio with Whisper, and answer questions with production-grade RAG — all with automatic embedding sync.
Multi-Agent Workflows
Coordinate specialized agents using Pixelagent's agent-as-tool pattern. Shared infrastructure means shared state, context, and history across agents.
Deep Dive Resources
Explore guides, tutorials, and architecture deep-dives for building production AI agents
Architecture & Foundations
Memory & State
Start Building AI Agents
Stop wrestling with infrastructure. Pixeltable handles state, caching, lineage, and multimodal data — so you can focus on agent logic.
pip install pixeltableOpen SourceApache 2.0