Skip to main content

Architecture Decisions — Bowrain Platform

This directory contains the Architecture Decisions for the bowrain platform — the hosted, collaborative, SaaS content platform built on neokapi. All content here is AGPL-3.0 licensed.

Bowrain builds on the neokapi framework. Framework-level decisions (content model, processing pipeline, tools, plugins, AI/MT provider interfaces, the kapi project model) live in the framework's Architecture Decisions. This directory describes bowrain-specific choices: the content store, sync protocol, multi-tenant auth, connectors, event bus, server-side AI operations, agent runtime, apps, and billing.

Tactical implementation details (SQL schemas, algorithm pseudocode, wire protocols specific to bowrain) live in Implementation Notes.

Foundation

ADTitleScope
001Vision and Module ArchitectureBowrain identity, AGPL-3.0 boundary, three-module layout, apps inventory
002Authentication and WorkspacesOIDC federation, PKCE, device flow, workspace multi-tenancy
003Permissions and Access ControlCapability envelope model, token scopes, session grants

Data Layer

ADTitleScope
004Content StorePostgreSQL-backed versioned block store
005StreamsGit-like branching at the content layer
006Graph Concept StoragePlain-SQL (default) / Apache AGE (opt-in) graph backends
007Media and Blob StorageContent-addressed BlobStore, asset metadata

Connectivity

ADTitleScope
008Connector SystemIntegrationConnector, categories, registry
009Sync ProtocolDesired-state reconciliation, content types incl. context, ownership in the payload
010Bowrain CLI.kapi projects with server: block, hooks, MCP
011REST APISlug-based hierarchy, route taxonomy

Events & Automation

ADTitleScope
012Distributed Event BusRedis Streams (ElastiCache in prod)
013Automation EngineRules, quality gates, run visibility, SSE
014Translator WorkflowTasks, activities, notifications, source review
022Convergence as a ServiceServer-side kapi up runs, SSE event stream, server.converge policy, automation collapse

Intelligence

ADTitleScope
015Server-Side AI OperationsTranslation jobs, entity extraction, brand voice governance
016Bravo AgentZeroClaw runtime, scoped tokens, identity delegation, MCP cloud

Applications

ADTitleScope
017Bowrain AppsDesktop, collaborative editor, Pulse, Admin Control Plane
018BillingStripe plans, monthly credits + trial grant, feature matrix, middleware guards

Governance

ADTitleScope
019The correction-learning loopCorrections promoted into versioned regression-test checks
020Governance, audit, and rollbackGroups, deny rules, role overrides, status ABAC, separation of duties, tamper-evident audit log, rollback
021The brand knowledge graphConcepts and typed relations, change-set governance, blast radius, Brand hub