Architecture guide

Self-hosted AI agent architecture without the mystery layer

A practical architecture separates channel access, credentials, memory, tools, and policy from model execution. This guide explains the boundaries and the operational tradeoffs.

1,346ClawBridge Codex commits at the July 2026 site update
36Repository tags documenting an actively versioned project
86%TypeScript codebase for the public agent platform
12+Supported communication and work channels

Start with trust boundaries

The first architecture question is not which model to use. It is which component may receive messages, hold credentials, read files, call tools, retain memory, and approve high-impact actions.

A five-layer model

  1. Channels: messaging, email, web, voice, CRM, and scheduled triggers.
  2. Host control plane: identity, routing, secrets, policy, sessions, memory, and lifecycle.
  3. Execution environment: the model or agent runtime operating inside a bounded workspace.
  4. Tools and data: APIs, MCP servers, databases, files, and business platforms.
  5. Delivery and observation: output validation, logs, retries, approvals, and monitoring.

Container isolation is not the whole security model

Containers help separate files and processes, but they do not automatically prevent unsafe network access, secret leakage, prompt injection, excessive permissions, or vulnerable dependencies. Production design still needs explicit mounts, network policy, secret handling, tool allowlists, updates, and review.

Memory needs governance

Long-term memory can preserve preferences, prior decisions, and workflow context. It can also preserve inaccurate or sensitive information. Retention rules, user boundaries, deletion paths, and reviewable summaries belong in the design.

Operational readiness

A self-hosted agent should have health checks, restart policies, backups, versioned configuration, audit records, cost visibility, and a human escalation route. If those parts are missing, the system is still a prototype regardless of model quality.

Engineering services

Choose the system, not just the keyword.

Each service page describes a distinct delivery scope with public project evidence, technical boundaries, and a clear handoff path.

Operations

AI Automation Engineer

Workflow automation across CRM, email, calendars, reporting, lead response, and business APIs.

Explore AI automation →
Infrastructure

Self-Hosted AI Agent Developer

Client-owned runtimes with Docker isolation, host-side secrets, storage, and monitoring.

Explore self-hosted AI →
Remote delivery

Remote AI Engineer

Project-based AI agent and automation delivery for distributed teams worldwide.

Explore remote delivery →
Evidence

ClawBridge Codex

Review the architecture and public repository behind Mark’s self-hosted agent work.

Review the case study →

Available for remote builds

Bring me the workflow that keeps falling back to manual work.

I’ll help identify whether it needs an AI agent, deterministic automation, an OpenClaw deployment, a custom integration, or a simpler system.

Email Mark Carmona →