IMPORTANT: Project AgentNexus is currently in early development and is not ready for production use. APIs are experimental and subject to significant changes. We welcome contributors, testers, and feedback as we work toward a stable release.
A TypeScript-based autonomous agent framework with modular systems for memory, planning, and tool integration. Features vector-based recall, multi-strategy planning, and extensible tools for AI agent development.
Agent Nexus is an advanced cognitive agent architecture framework that enables AI systems to operate with human-like reasoning abilities. By integrating memory management, specialized tools, strategic planning, and action execution into a cohesive system, Agent Nexus creates agents that can solve complex problems, learn from experience, and provide continuous value.
The Agent Nexus architecture consists of four core components:
-
Memory: Divided into short-term (for immediate context) and long-term (for persistent knowledge), allowing the agent to maintain continuity across interactions.
-
Tools: A suite of capabilities including:
- VectorSearch() - Semantic similarity search using vector embeddings
- TextGeneration() - Context-aware content creation
- CodeExecutor() - Secure code execution
- WebBrowser() - Web access and information retrieval
- (Coming soon) ImageAnalysis(), KnowledgeGraph(), DocAnalysis(), RAGRetrieval()
-
Planning: The cognitive center featuring:
- Reflection - Self-assessment of reasoning processes
- Self-critics - Error identification and correction
- Chain of thoughts - Transparent reasoning pathways
- Subgoal decomposition - Breaking complex problems into manageable tasks
-
Action: The execution layer that implements plans and processes feedback to improve future performance.
Source: LinkedIn Post
- Self-Correction: The architecture enables agents to critique their own work before execution, significantly reducing errors.
- Human-Like Reasoning: By mimicking human cognitive processes, these agents can solve problems with greater nuance.
- Continuous Improvement: The feedback loop between action and planning creates a system that learns from every interaction.
- Provider Flexibility: Support for multiple AI model providers allows choosing the best model for each task.
Agent Nexus supports multiple AI model providers, allowing you to choose the best fit for your needs:
- OpenAI - GPT-4o, GPT-3.5 Turbo
- Anthropic - Claude 3.7 Sonnet, Claude 3 Opus
- Google Gemini - Gemini 1.5 Pro
- Local LLMs via Ollama - Llama 3, Mistral, and other local models
Benefits of multi-model support:
- Flexibility: Choose models based on specific task requirements
- Resilience: Fall back to alternative providers if needed
- Cost Optimization: Select models based on budget constraints
- Privacy: Use local models for sensitive information
- Experimentation: Compare outputs across different models
- Agno: Lightweight framework for building agents with memory, knowledge, tools, and reasoning
- claude-task-master: AI-powered task management system
- Next.js: React framework for building the web interface
- TypeScript: For type-safe code
- Weaviate: Vector database for semantic search capabilities
- Multiple AI Providers: OpenAI, Anthropic, Google Gemini, Ollama
- Node.js 18+ and npm/yarn/pnpm
- API keys for the model providers you want to use (OpenAI, Anthropic, Google)
- Ollama (optional, for local models)
-
Clone the repository:
git clone https://github.com/yourusername/AgentNexus.git cd AgentNexus
-
Run the setup script:
npm run setup # or yarn setup # or pnpm setup
-
Configure your model providers:
- Copy
sample.env.local
to.env.local
- Add your API keys for the providers you want to use
- Set your default provider
- Copy
-
Set up Weaviate (for vector search capabilities):
- Start Weaviate using Docker Compose:
docker-compose up -d weaviate
- This will launch Weaviate on
localhost:8080
- Verify it's running with:
curl http://localhost:8080/v1/meta
- Configure Weaviate in your
.env.local
file:WEAVIATE_HOST=localhost:8080 WEAVIATE_SCHEME=http WEAVIATE_API_KEY= # Optional if you're using authentication
- Start Weaviate using Docker Compose:
-
Activate the Agno Python virtual environment:
source ./activate-agno.sh
After you're done working with Agno, you can deactivate the environment:
deactivate
-
Run the development server:
npm run dev # or yarn dev # or pnpm dev
-
Open http://localhost:3000 in your browser to see the result.
Detailed documentation about specific components and functionality is available in the /docs
directory:
- Vector Search Tool - Setting up and using the semantic search capabilities
- Retrieval Augmented Generation - Enhancing LLM responses with relevant context
The web interface provides a simple way to interact with Agent Nexus. You can:
- Chat directly with the agent
- Submit complex tasks for processing
- View the agent's reasoning process
- Switch between different AI model providers
- Explore the cognitive architecture
You can also interact with Agent Nexus through its API:
// Example fetch request
const response = await fetch('/api/agent', {
method: 'POST',
headers: {
'Content-Type': 'application/json'
},
body: JSON.stringify({
message: 'Analyze the performance implications of using vector search in a production environment',
type: 'task', // or 'chat' for simpler interactions
provider: 'anthropic', // optional: specify the provider to use
model: 'claude-3-7-sonnet-20250219' // optional: specify the model to use
})
});
const data = await response.json();
console.log(data.response);
Agent Nexus integrates with claude-task-master for task management:
# View current tasks
npm run task-master list
# Process the next task with Agent Nexus
npm run process-task
You can test individual tools with the test-tool script:
# Test vector search
npm run test-tool -- vectorSearch '{"query":"example search"}'
# Test text generation
npm run test-tool -- textGeneration '{"prompt":"Summarize the benefits of AI","temperature":0.7}'
# Test code execution
npm run test-tool -- codeExecutor '{"code":"console.log(\"Hello, world!\");","language":"javascript"}'
# Test web browser
npm run test-tool -- webBrowser '{"url":"https://example.com","operation":"get"}'
Test different model providers:
# Test all configured providers
npm run test-models
# Test a specific provider
npm run test-models -- openai
npm run test-models -- anthropic
npm run test-models -- ollama
/AgentNexus
│
├── src/
│ ├── app/ # Next.js app
│ │ ├── api/ # API routes
│ │ │ ├── agent/ # Agent API endpoints
│ │ │ └── models/ # Model provider endpoints
│ │ ├── page.tsx # Main page
│ │ └── layout.tsx # App layout
│ │
│ ├── components/ # UI components
│ │ ├── AgentInterface.tsx # Agent chat interface
│ │ ├── ModelSelector.tsx # Model provider selector
│ │ └── ArchitectureVisualizer.tsx # Architecture diagram
│ │
│ ├── core/ # Core Agent Nexus components
│ │ ├── agent.ts # Main Agent class
│ │ ├── memory/ # Memory system components
│ │ ├── models/ # Model provider implementations
│ │ ├── tools/ # Tools integration
│ │ ├── planning/ # Planning system
│ │ └── action/ # Action system
│ │
│
├── scripts/ # Utility scripts
│ ├── setup.sh # Setup script
│ ├── test-tool.ts # Tool testing script
│ ├── test-models.ts # Model provider testing script
│ ├── run-first-task.ts # First task test script
│ └── task-nexus-bridge.ts # Integration with task-master
│
├── tests/ # Test utilities and tests
└── tasks/ # Task definitions for task-master
To add a new model provider:
- Create a new provider class in
src/core/models/
that implements theModelProvider
interface - Update the
ModelProviderType
and factory insrc/core/models/index.ts
- Add the provider to the initialization in
src/core/models/factory.ts
- Add the provider's configuration to
sample.env.local
See CONTRIBUTING.md for detailed development guidelines.
# Run all tests
npm test
# Run specific tests
npm run test-memory
npm run test-models
-
Additional Tools: Complete implementation of remaining tools (ImageAnalysis, KnowledgeGraph, DocAnalysis, RAGRetrieval)
-
Advanced Memory System: Connect to vector databases and implement memory consolidation
-
Enhanced Planning: Improve reasoning with more sophisticated models and strategies
-
Provider Integrations: Add support for more AI model providers and improve existing ones
-
User Interface Improvements: Add visualization for agent's thought processes
-
Multi-Agent Orchestration: Enable multiple agents to work together
This project is licensed under the MIT License - see the LICENSE file for details.
- Agno - For the agent framework
- claude-task-master - For the task management system
- OpenAI, Anthropic, Google, and Ollama - For model provider APIs
- Manthan Patel - For the ignition with this LinkedIn Post