Skip to main content

Project Structure

/home/agent/
├── docker-compose.yml # All 7 services
├── .env # Environment variables
├── .env.example # Template
├── config/ # Mounted as /data/config in agent-core
│ └── prime.md # Operator override (top of system prompt)
├── data/ # Persistent data volumes
│ ├── postgres/ # PostgreSQL data files
│ ├── redis/ # Redis AOF persistence
│ ├── memory/ # Memory snapshots, self_model.json
│ ├── logs/ # Log files
│ ├── screenshots/ # Browser screenshots
│ ├── shared/ # Shared files between containers
│ ├── chat-uploads/ # User-uploaded files
│ ├── browser-sessions/ # Chromium profile directories
│ ├── skills/ # Custom Python skills
│ │ └── <skill_name>/
│ │ └── skill.py
│ ├── backups/ # Database backups
│ └── ollama/ # Ollama model weights
├── containers/
│ ├── agent-core/ # Main agent container
│ │ ├── Dockerfile
│ │ ├── requirements.txt
│ │ └── src/
│ │ ├── main.py # Entry point, wires all components
│ │ ├── config.py # Pydantic Settings
│ │ ├── agent/ # Core agent cognitive systems
│ │ │ ├── context.py # build_context() - prompt assembly
│ │ │ ├── epistemic.py # Domain confidence tracking
│ │ │ ├── self_model.py # Agent self-knowledge
│ │ │ └── cpi.py # Cognitive Pressure Index
│ │ ├── agent_manager/ # Multi-agent orchestration
│ │ │ ├── __init__.py # AgentOrchestrator
│ │ │ ├── runtime.py # AgentRuntime
│ │ │ ├── meta_agent.py # MetaSupervisor (optional)
│ │ │ └── tick_job.py # AgentTickJob
│ │ ├── dashboard/ # Web dashboard
│ │ │ ├── app.py # FastAPI app setup
│ │ │ ├── auth.py # Session auth, CSRF
│ │ │ ├── routes/ # Route handlers
│ │ │ │ ├── chat.py
│ │ │ │ ├── goals.py
│ │ │ │ ├── agents.py
│ │ │ │ ├── memory.py
│ │ │ │ ├── scheduler.py
│ │ │ │ ├── integrations.py
│ │ │ │ └── cognitive.py
│ │ │ └── templates/ # Jinja2 HTML templates
│ │ ├── db/ # Database layer
│ │ │ ├── models.py # SQLAlchemy models (18 tables)
│ │ │ └── session.py # Async session factory
│ │ ├── events/ # Event bus and handlers
│ │ │ ├── bus.py # Redis Streams EventBus
│ │ │ ├── handlers.py # Main request handler (2000+ lines)
│ │ │ └── types.py # EventType enum
│ │ ├── goal_orchestrator/ # Goal engine
│ │ │ ├── __init__.py # GoalOrchestrator
│ │ │ ├── planner.py # PlanGenerator
│ │ │ ├── plan_validator.py # PlanCritic
│ │ │ ├── executor.py # Task executor
│ │ │ ├── reflection_job.py # GoalMetaReflectionJob
│ │ │ └── types.py # Goal, Task, TaskGraph, AutonomyMode
│ │ ├── health/ # Health monitoring
│ │ │ ├── monitor.py # HealthMonitor
│ │ │ ├── repair.py # SelfHealer
│ │ │ ├── introspection.py # Introspector
│ │ │ └── broker_client.py # BrokerClient
│ │ ├── identity/ # Identity management
│ │ │ └── __init__.py # IdentityManager
│ │ ├── integrations/ # Integration platform
│ │ │ ├── __init__.py # IntegrationRegistry, SecretVault, PolicyEngine
│ │ │ ├── circuit_breaker.py
│ │ │ ├── registry.py
│ │ │ └── connectors/ # 33 connectors
│ │ │ ├── slack.py
│ │ │ ├── discord.py
│ │ │ ├── github.py
│ │ │ └── ...
│ │ ├── memory/ # Memory systems
│ │ │ ├── manager.py # MemoryManager
│ │ │ ├── types.py # MemoryType, MemoryQuery
│ │ │ ├── knowledge_graph.py
│ │ │ ├── temporal.py # Temporal extraction and reasoning
│ │ │ ├── procedural.py # Procedure abstraction
│ │ │ ├── learning.py # Learning loop
│ │ │ ├── behavioral.py # Behavioral rules
│ │ │ └── visual.py # Visual memory
│ │ ├── models/ # AI model management
│ │ │ ├── manager.py # ModelManager
│ │ │ ├── router.py # Task-based model routing
│ │ │ └── types.py # Message, ModelRequest
│ │ ├── observability/ # Metrics and economics
│ │ │ ├── metrics.py
│ │ │ └── economics.py
│ │ ├── runtime/ # Service registry
│ │ │ └── registry.py
│ │ ├── scheduler/ # Background jobs (23 total)
│ │ │ ├── scheduler.py # Job runner
│ │ │ ├── jobs.py # Core jobs
│ │ │ ├── dream.py # DreamJob
│ │ │ ├── autonomous.py # AutonomousGoalGeneratorJob
│ │ │ ├── perception.py # BackgroundPerceptionJob
│ │ │ ├── behavioral_learner.py
│ │ │ ├── integrity.py # SelfIntegrityMonitorJob
│ │ │ ├── cpi_monitor.py # CognitiveLoadMonitorJob
│ │ │ ├── subscriptions.py
│ │ │ ├── world_model_job.py
│ │ │ ├── skill_evolution_job.py
│ │ │ └── digest.py
│ │ ├── skills/ # Skill system
│ │ │ ├── base.py # SkillBase, SkillDefinition, SkillResult
│ │ │ ├── capability.py # CapabilityLevel, policies
│ │ │ ├── executor.py # SkillExecutor
│ │ │ ├── registry.py # SkillRegistry
│ │ │ ├── parser.py # parse_skill_calls()
│ │ │ ├── auto_detect.py # Auto-detect skill needs
│ │ │ ├── anticipatory.py # Anticipatory simulation
│ │ │ ├── skill_evolution.py # Code generation + validation
│ │ │ ├── builtin/ # Built-in skill implementations
│ │ │ │ ├── __init__.py # register_builtin_skills()
│ │ │ │ ├── web_search.py
│ │ │ │ ├── browser.py
│ │ │ │ ├── python_exec.py
│ │ │ │ ├── shell.py
│ │ │ │ ├── gmail.py
│ │ │ │ ├── self_improve.py
│ │ │ │ ├── skill_manager.py
│ │ │ │ ├── agent_manager_skill.py
│ │ │ │ └── ...
│ │ │ └── openclaw/ # OpenClaw skill marketplace
│ │ │ ├── loader.py # load_all_python_skills()
│ │ │ └── clawhub_client.py
│ │ └── utils/ # Utilities
│ │ └── redaction.py # Secret redaction
│ ├── agent-telegram/ # Telegram bridge
│ │ ├── Dockerfile
│ │ └── src/
│ │ ├── main.py
│ │ └── bridge.py # Telegram ↔ Redis bridge
│ ├── agent-nginx/ # Reverse proxy
│ │ ├── Dockerfile
│ │ ├── nginx.conf
│ │ └── html/ # Landing page
│ └── agent-broker/ # Docker socket sidecar
│ ├── Dockerfile
│ └── src/
│ └── main.py # Command allowlist + Redis listener
├── docs/ # Documentation
│ ├── reports/ # Audit and validation reports
│ └── MEMORY.md # Auto-memory for Claude Code
└── scripts/
├── backup.sh
├── restore.sh
└── migrate.sh