NeuronDB: AI Database Extension for PostgreSQL

REST API and WebSocket agent runtime system with long-term memory, tool execution, and streaming responses. Integrates seamlessly with NeuronDB.

NeuronDB A PostgreSQL AI-Extension Demo

NeuronAgent API Demo
NeuronAgent API Demo Terminal
Interactive demonstration of NeuronAgent REST API endpoints for agent management, session handling, and message processing.
REST APIAgent ManagementSession HandlingVector Search
Click "Run Demo" to see NeuronAgent API in action

Architecture

AI agent runtime architecture with state management, memory store, and tool execution

NeuronAgent Architecture

API Layer

REST API | WebSocket | Health Check

Agent State Machine

  • • State Persistence
  • • Task Execution
  • • Recovery & Retry
  • • State Transitions

Session Management

  • • Session Lifecycle
  • • Context Management
  • • Message History
  • • Multi-tenancy

Tool Registry

  • • SQL Tools
  • • HTTP Tools
  • • Code Execution
  • • Shell Commands

Memory Store

  • • HNSW Vector Search
  • • Context Retrieval
  • • Long-term Memory
  • • Semantic Search

Job Queue

  • • Background Jobs
  • • Retry Logic
  • • Poison Handling
  • • SKIP LOCKED

NeuronDB Integration

Vector Search | Embeddings | LLM Operations | PostgreSQL

Agent Runtime Features

Why NeuronDB

Agent State Machine

Complete state machine for autonomous task execution with state persistence, recovery, and transition management. Supports complex workflows with conditional branching and state validation.

Long-term Memory

HNSW-based vector search for context retrieval from historical conversations and knowledge base. Semantic search across agent interactions. Memory persistence across sessions with temporal relevance weighting.

Tool System

Extensible tool registry supporting SQL, HTTP, Code, and Shell operations. Tool execution with timeout, validation, and error handling. Streaming responses for long-running operations. Custom tool registration API.

REST API & WebSocket

Full CRUD API for agents, sessions, and messages. WebSocket support for real-time streaming responses. RESTful endpoints with OpenAPI documentation. Rate limiting and authentication middleware.

Background Jobs

PostgreSQL-based job queue with worker pool, retries, and poison message handling. SKIP LOCKED for concurrent processing. Crash recovery and job state persistence. Tenant-aware job isolation.

Authentication & Security

API key-based authentication with rate limiting and role-based access control. Request validation and sanitization. Audit logging for security compliance. Multi-tenant isolation at the database level.

Session Management

Session lifecycle management with context preservation. Message history tracking and pagination. Multi-agent session support. Session timeout and cleanup policies.

NeuronDB Integration

Deep integration with NeuronDB for embeddings generation, vector search, and LLM operations. Direct SQL tool access to NeuronDB functions. Efficient context retrieval using HNSW indexes.

Capabilities

Agent runtime features

CapabilityDescriptionPerformanceProduction Ready
Agent State MachineState persistence, recovery, transitionsSub-second state changes
Long-term MemoryHNSW vector search, semantic retrievalMillisecond context lookup
Tool RegistrySQL, HTTP, Code, Shell toolsConcurrent execution
REST APIFull CRUD operations for agents, sessionsHigh-throughput requests
WebSocketReal-time streaming responsesLow-latency streaming
Background JobsJob queue with retries, SKIP LOCKEDNon-blocking async ops
AuthenticationAPI keys, rate limiting, RBACOAuth-ready
Get Started

Build AI Agents with NeuronAgent

Deploy NeuronAgent. Create autonomous agent systems with persistent memory, tool execution, and streaming responses.