Agent Brain - Home
Intelligent Agent Orchestration & Decision Engine with Sequential Thinking + Knowledge Graph Integration
Overview
Agent Brain is the cognitive orchestration layer of the Agent Buildkit platform, providing intelligent decision-making, task planning, and knowledge management for autonomous AI agents. It combines sequential thinking workflows, distributed knowledge graphs (Neo4j + Qdrant), and multi-agent coordination to enable self-optimizing agent systems.
Core Function: Orchestrates autonomous agents through structured thinking stages, routes tasks to optimal agents based on capabilities, and maintains distributed knowledge graphs for contextual decision-making across the entire agent mesh.
Quick Start
# Install dependencies
cd /Users/flux423/Sites/LLM/agent-buildkit
npm install && npm run thinking:setup
# Configure environment
cp .env.example .env
# Edit: GITLAB_TOKEN, NEO4J_PASSWORD, QDRANT_API_KEY
# Start autonomous orchestration
buildkit thinking start --project llm/agent-buildkit
# Configure IDE integration (Cursor, Windsurf, Zed, Claude Desktop)
buildkit thinking configure-ide all
# Access dashboard
# http://localhost:3000/orchestration
Key Features
- Sequential Thinking: 8-stage cognitive workflow (Problem Definition → Research → Analysis → Synthesis → Implementation → Validation → Reflection → Conclusion)
- Autonomous Orchestration: Zero-human-interaction agent spawning, task claiming, and execution
- Knowledge Graph: Neo4j + Qdrant distributed knowledge with vector search and relationship mapping
- Intelligent Routing: Capability-based task distribution with multiple load balancing strategies
- GitLab Integration: Complete issue lifecycle management, milestone tracking, and roadmap automation
- Distributed Security: Tailscale mesh networking with zero-trust authentication
- Real-time Monitoring: Live dashboard with WebSocket updates, performance analytics, and anomaly detection
- MCP Integration: Model Context Protocol support for 6 IDEs (Cursor, Windsurf, Zed, Claude Desktop, Continue, Cline)
Wiki Navigation
Core Documentation
- Architecture - Decision engine, task planning, and orchestration design
- Knowledge Graph Guide - Neo4j + Qdrant integration and distributed knowledge architecture
- Development Guide - Local setup, testing, and contribution workflow
Advanced Topics
- Sequential Thinking: 8-stage cognitive workflow with GitLab sync
- Agent Mesh: Distributed coordination with Tailscale networking
- Task Planning: Intelligent routing with capability matching
- Knowledge Discovery: Semantic search and relationship mapping
- Decision Engine: Multi-criteria agent selection and optimization
Operations
- Deployment: Kubernetes + Docker + OrbStack production setup
- Monitoring: Phoenix Arize + Prometheus + Grafana observability
- Troubleshooting: Common issues and emergency procedures
- CI/CD: GitLab components for pipeline automation
Current Focus (Agent Brain Capabilities)
Cognitive Processing
- 8-Stage Sequential Thinking: Structured problem-solving workflow with axioms and assumptions
- Thought Tracking: Complete metadata, GitLab issue sync, and knowledge graph integration
- Session Management: Multi-session coordination with context preservation
Orchestration
- Fault-Tolerant Agent System: Self-healing with circuit breakers and automatic recovery
- Distributed Locking: Redis + GitLab atomic operations prevent duplicate work
- Intelligent Assignment: ML-driven work distribution based on agent capabilities
- Dynamic Scaling: Auto-scaling based on workload and performance metrics
Knowledge Management
- Neo4j Knowledge Graph: Relationship mapping for issues, agents, milestones, and tasks
- Qdrant Vector Search: Semantic search with 384-dimension embeddings
- Distributed Discovery: Multi-region knowledge sources with automatic failover
- Provenance Tracking: Complete audit trail of decisions and actions
Integration
- GitLab CE: OAuth, webhooks, issue lifecycle, milestone sync, roadmap automation
- Phoenix Arize: Learning loop with quality metrics and cost prediction
- MCP Protocol: 6 IDE integrations with context server support
- Tailscale Mesh: Secure agent-to-agent communication with MagicDNS discovery
Agent Types
Worker Agents
- Process individual tasks through sequential thinking stages
- Execute implementations with validation
- Report results and sync to GitLab
Orchestrator Agents
- Coordinate multiple workers across milestones
- Manage dependencies and workflow optimization
- Dynamic task rebalancing
Critic Agents
- Review work quality and provide feedback
- Ensure coding standards and best practices
- Validation stage enforcement
Integrator Agents
- Combine outputs from multiple workers
- Resolve conflicts and ensure coherence
- Final synthesis and documentation
Performance Metrics
- Throughput: 1,000+ issues/day processing capacity
- Agent Concurrency: 50+ agents with linear scaling
- Response Time: <100ms lock acquisition, <5s issue claiming
- Knowledge Graph: Sub-second Cypher queries, <200ms vector search
- Availability: 99.9% uptime with automatic failover
- Success Rate: <1% agent failure rate with self-healing
Technology Stack
- Runtime: Node.js 20+, TypeScript 5.0+, Python 3.9+
- Knowledge Storage: Neo4j 5.0+ (graph), Qdrant 1.0+ (vectors), Redis 6.2+ (cache/locks)
- Orchestration: Docker, Kubernetes, OrbStack
- Observability: Phoenix Arize, Prometheus, Grafana, OpenTelemetry
- Networking: Tailscale mesh with MagicDNS
- MCP Framework: @modelcontextprotocol/sdk 1.19+
- GitLab Integration: @gitbeaker/rest 43.7+
CLI Commands
Sequential Thinking
buildkit thinking create-session --name "Feature Planning" --project <id>
buildkit thinking process-thought --session <id> --thought "..." --stage Research
buildkit thinking summary --session <id>
buildkit thinking sync-gitlab --session <id> --milestone <id>
Agent Orchestration
buildkit thinking start --project <id> --max-agents 5
buildkit thinking spawn-agent --name "Worker" --type worker --project <id>
buildkit thinking list-agents
buildkit thinking enable-roadmap --project <id> --interval 30000
Knowledge Graph
buildkit gitlab-kg build --project <id>
buildkit gitlab-kg sync --incremental
buildkit gitlab-kg query "MATCH (a:Agent)-[:WORKS_ON]->(p:Project) RETURN a, p"
buildkit gitlab-kg related --issue-id <id>
buildkit gitlab-kg assign-opportunities --agent-id <id>
Orchestration Control
buildkit orchestration start --replicas 5 --redis-url redis://localhost:6379
buildkit orchestration status --detailed
buildkit orchestration scale --agents 10 --strategy gradual
buildkit orchestration issue claim --issue-id <id> --agent-id <id>
buildkit orchestration locks inspect --verbose
IDE Configuration
buildkit thinking configure-ide cursor # Configure Cursor
buildkit thinking configure-ide windsurf # Configure Windsurf
buildkit thinking configure-ide zed # Configure Zed
buildkit thinking configure-ide all # Configure all IDEs
Related Projects
- @bluefly/agent-router - Multi-provider LLM routing
- @bluefly/agent-mesh - Distributed agent coordination
- @bluefly/agent-protocol - MCP protocol implementation
- @bluefly/agent-tracer - Distributed tracing
Quick Links
- Repository: https://gitlab.bluefly.io/llm/npm/agent-buildkit
- Issues: https://gitlab.bluefly.io/llm/npm/agent-buildkit/-/issues
- CI/CD: https://gitlab.bluefly.io/llm/npm/agent-buildkit/-/pipelines
- Package Registry: https://gitlab.bluefly.io/llm/npm/agent-buildkit/-/packages
- Documentation: Full Docs
Support
- Issues: https://gitlab.bluefly.io/llm/npm/agent-buildkit/-/issues
- Documentation: This wiki +
/docsdirectory (146 files) - Team: LLM Platform Team llm-platform@bluefly.io
- Dashboard: http://localhost:3000/orchestration
Last Updated: 2025-11-02 Maintainer: LLM Platform Team License: MIT