Status: Proposed
Version: 1.0
Date: 2025-12-28
Supersedes: N/A
Related ADRs: ADR-030 (VibesPro™ Foundation), ADR-030 (VibesPro™ Integration), ADR-031 (GovernedSpeed™)
Related PRDs: PRD-023
SEA™ originated from VibesPro™, which itself prototyped many governance patterns. GovernedSpeed™ served as an early prototype for SEA™’s runtime governance. As these projects evolved, clear questions emerged:
The alternatives are:
We adopt the “One Kernel, Multiple Shells” architecture:
libs/sea/*) containing stable domain, use-cases, ports| Component | Topology | Integration | Boundary |
|---|---|---|---|
| VibesPro™ | A (internal module) | Dissolved into workspace as own bounded context | libs/vibespro/* + libs/vibespro/public-api |
| GovernedSpeed™ | Donor | Valuable pieces extracted into libs/sea/* |
N/A (merged) |
| Zed IDE | D (blackbox UI) | HTTP/gRPC + LSP | Network contract |
| LibreChat | D (blackbox UI) | OpenAI-compatible API facade | Network contract |
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
libs/
├── sea/ # SEA™ Kernel
│ ├── domain/ # Pure domain: types, invariants, rules
│ ├── app/ # Use-cases, orchestration
│ ├── ports/ # Interfaces: repos, llm, fs, events, auth
│ └── adapters/ # Implementations: http, db, queue, file
│
├── vibespro/ # VibesPro™ Bounded Context
│ ├── domain/ # VibesPro™ entities/value objects
│ ├── app/ # VibesPro™ use-cases
│ ├── ports/ # VibesPro™ interfaces
│ ├── adapters/ # VibesPro™ implementations
│ └── public-api/ # ONLY thing SEA™ can import
│
apps/
├── sea-api/ # SEA™ HTTP API shell
├── sea-worker/ # SEA™ background worker shell
├── sea-cli/ # SEA™ CLI shell
├── vibespro-api/ # VibesPro™ standalone API
├── vibespro-cli/ # VibesPro™ standalone CLI
└── vibespro-worker/ # VibesPro™ worker
GovernedSpeed™ was a prototype for SEA™, so it follows the donor pattern:
libs/sea/*Both are blackbox UI shells that talk to SEA™ over stable APIs:
| UI | Integration Pattern | SEA™ Exposes |
|---|---|---|
| Zed IDE | LSP server + HTTP/gRPC endpoints | Editor-native actions (generate, refactor, validate) |
| LibreChat | OpenAI-compatible /v1/chat/completions |
Chat-first interface via thin adapter |
Rule: UI stays blackbox, SEA™ kernel stays authoritative.
scope:vibespro taglibs/vibespro/public-apilibs/sea/*) runnable without any shelllibs/vibespro/domain/* directly| Spec Concept | Implementation Target | Mapping Rule |
|---|---|---|
| Kernel libs | libs/sea/* structure |
1:1 layer mapping |
| Bounded Context | libs/vibespro/* |
Complete DDD layer structure |
| Public API | Port interface | Method signatures preserved |
| Shell | apps/* |
Composition root only |
| INV-ID | Invariant | Type | Enforcement |
|---|---|---|---|
| INV-030 | Kernel is runnable without shells | System | Unit tests on libs only |
| INV-031 | VibesPro™ remains independently deployable | System | CI builds vibespro-api separately |
| INV-032 | No cross-domain imports except via public-api | Structural | Nx boundary linting |
| INV-033 | UI shells are stateless clients | System | API-only integration |
| Attribute | Target | Rationale |
|---|---|---|
| Modularity | 5+ bounded contexts supported | Platform scalability |
| Testability | 100% domain logic unit testable | No infra in domain layer |
| Flexibility | Swap in-process ↔ HTTP with single adapter change | Deployment options |
| Independence | Each BC can have own release cadence | Team autonomy |
You can:
apps/* and still have fully working kernel in libs/sea/*