Brutor AI Gateway — Architecture

Brutor AI Control Plane Architecture

Three views — every component that makes up the platform, what each one is responsible for, and how a single request travels through them end to end. Nothing here is aspirational: this is what ships in the deployment bundle.

/components/

What’s in the platform

Detailed component architecture of the Brutor AI Control Plane. Clients call in at the top: the User Portal, external AI clients, your own AI Systems, A2A peers, the Admin Console and the Registry UI. The governed plane holds the Gateway Core (Rust, Axum, port 8100), the Control Plane (Python, FastAPI, port 5050) and the MCP Registry (port 5001). Three Rust workers run alongside: the Skill Runner on port 8210, the KB Uploader, and KB Connector Sync on port 8201. All of them share customer-deployed stores — PostgreSQL, Redis, Qdrant, S3 or MinIO object storage, Vault, Presidio and an observability stack. Outbound, the gateway fronts model providers, MCP servers and A2A peer agents.

Eight Brutor services, seven stores you own, one way out. The Gateway Core is the only component on the request path — everything else either configures it, runs alongside it, or stores what it produces. Ports shown are the bundle defaults.

/component reference/

What each service actually does

Gateway Core Rust · Axum · :8100

The request path, and the only component on it. Proxies LLM, MCP, A2A, Skills and batch traffic; enforces auth, access, quotas, run-level ceilings, guardrails, semantic and argument policy and residency; runs cache lookup and store; writes the proxy log that becomes the run ledger; and serves the end-user Portal API. Read-only with respect to configuration.

Control Plane Python · FastAPI · :5050

Every configuration write, and the backend for the Admin Console. Owns tenants, users, RBAC, providers and models, the MCP catalog, guardrail policy, resource groups and limits, policy-as-code, AI System contracts, assurance reports and the EU AI Act register. It also owns the database schema and runs the Alembic migrations on startup.

Skill Runner Rust · :8210 · JWT-authed

Executes skill scripts in a separate, isolated container — never inside the proxy. No network exposure, read-only rootfs, and a hard timeout (30s sandboxed, 120s trusted). The Core calls it with a signed token; the agent receives script output, never the code.

KB Uploader Rust · internal

Turns documents into retrievable knowledge. Parses PDF, Word, Excel, PowerPoint, markdown, HTML and CSV, chunks the text, calls the Core for embeddings, and writes vectors into Qdrant under the tenant’s own key. Source files land in object storage.

KB Connector Sync Rust · :8201 · 15s poll

Keeps knowledgebases current from the tools you already use: Confluence, Notion, Google Drive, Slack, GitHub, Jira, SharePoint and a web crawler. Scheduled incremental sync, with each document’s source permissions preserved so they still apply at retrieval time.

MCP Registry Python · :5001 · Beta

A standalone registry on the official MCP registry specification (server.json 2025-12-11, /v0.1 REST API). Federate public servers, publish your own, attach governance metadata to every record, and import an entry straight into your MCP catalog.

User Portal React · TypeScript · :3001

The end-user chat client: workspaces, batch processing, knowledgebase-grounded answers with citations, and usage and guardrail alerts. It talks only to the Core’s Portal API — never to the Control Plane.

Admin Console React · TypeScript · :3002

The management surface: configure models, MCP servers, skills and guardrails; build the resource-group tree; set limits and policies; and read Mission Control, proxy logs, the AI Systems fleet board and assurance reports. Backed by the Control Plane.

A ninth surface ships with it: the MCP Registry UI (:3003). Everything else in the diagram — PostgreSQL, Redis, Qdrant, object storage, Vault, Presidio and the observability stack — is standard infrastructure you deploy and own. Brutor stores no customer data outside them.

/request flow/

A single prompt, end to end

Every call — chat completion, MCP tool invocation, skill execution, knowledgebase retrieval or A2A delegation — takes the same governed path through the Rust proxy. Each stage is policy-enforced, observable and tenant-scoped.

1

Client

Portal, agent, backend or A2A peer

2

Identify

JWT & tenant resolved

3

Authorize

Policy & guardrails

4

Cache

Semantic lookup

5

Route

LLM · MCP · Skill · KB · A2A

6

Provider

Stream & record

Step 1
  • OpenAI, MCP or A2A request
  • Bearer token or API key
  • X-Tenant-ID or A2A path
Step 2
  • Verify JWT signature
  • Resolve tenant + agent card
  • Hydrate user / peer context
Step 3
  • Model entitlement check
  • Quota, budget, run ceilings
  • Guardrails & policy
Step 4
  • Embed & search Qdrant
  • Skip when tools attached
  • HIT → return early
Step 5
  • Pick provider & deployment
  • Inject creds from the vault
  • Apply request transforms
Step 6
  • Stream tokens or tool result
  • Store cache entry
  • Emit traces & metrics
Cache hit When the semantic cache resolves at step 4, the proxy answers immediately — skipping steps 5 and 6 — while still emitting an audit record. Requests carrying tools bypass cache entirely (lookup and store), preserving correctness for tool-using flows.

Step 5 routes to one of five targets

Each branch reuses the same auth, policy, cache and audit layers.
LLM completion OpenAI-compatible

Routes to OpenAI, Anthropic, Bedrock, Vertex, Azure OpenAI, Mistral or a self-hosted model — directly, or through a routing group that picks one by weight, load, latency or cost. Streaming preserved end to end.

MCP tool call JSON-RPC

Resolves the configured MCP server for the tenant, attaches user-delegated OAuth tokens held encrypted at the gateway, and streams the result back — after argument policy, guardrails and any approval gate have cleared.

Skill execution Composed

Progressive disclosure over the system MCP server: list → load → act. Scripts run in the external Skill Runner (isolated container, read-only rootfs, JWT-authed); every step is independently governed and audited.

Knowledgebase retrieval RAG

Hybrid search over the group’s Qdrant collection — semantic vectors plus keyword, fused. Content is indexed by the KB Uploader and kept fresh by KB Connector Sync; source permissions still apply at retrieval, and every answer carries citations.

A2A delegation A2A v1.0

Calls a Brutor-hosted Agent Card or a peer A2A agent. Adds signed root, parent and depth headers and enforces the policy-defined max delegation depth.

Return path Response streams back through the same chain, past the output guardrails. The proxy writes audit + usage to PostgreSQL, correlates every hop against the same root task ID so the calls become one run in the ledger, exports OpenTelemetry traces, and updates Prometheus metrics — before the client ever sees the final token.
Pass-through stage
Decision stage (can short-circuit)
All stages run inside the Rust proxy — one process, one trace.
Scroll to Top