Convex-only Slice 1: clients talk to Convex, Flue is a private worker
Normalize the topology so web/desktop/mobile clients communicate only with Convex. Convex admits durable commands, dispatches private Flue turns through FLUE_URL, and stores the product-facing result before clients observe it. - Normalized relational schema: organizations, projects, conversations/turns/ messages/attachments, signals/sources/constraints, works/events/attachments. - Conversation turns queued in Convex; the agent runAction dispatches to Flue and persists assistant response, signals, and proposed work back into Convex. - Browser chat moved off the Flue transport: use-chat-agent now reads reactive Convex rows and sends through conversationMessages.send. - Fixed signed-in blank screen: gate all product queries on useConvexAuth (isAuthenticated && !isRefreshing) plus personal-org bootstrap. - Pinned react/react-dom to 19.2.8 via catalog to fix SSR dual-React crash. - Removed ~16.6k net lines: daemon, AgentOS/Orb, project issues/runs/artifacts, todos, browser Flue transport, mobile execution views, smoke scripts. Verified end-to-end on cheaptricks: connect repo, send actionable message, Flue turn completes, Signal + proposed Work created with exact provenance, persists across refresh.
This commit is contained in:
84
docs/TECH.md
84
docs/TECH.md
@@ -10,62 +10,64 @@
|
||||
## 1. System topology
|
||||
|
||||
```text
|
||||
Web / Buzz / integrations
|
||||
│
|
||||
Web / desktop / mobile
|
||||
│ Convex queries, mutations, storage
|
||||
▼
|
||||
Application API + Convex durable data
|
||||
│
|
||||
Convex application backend
|
||||
├── authentication and tenancy
|
||||
├── normalized product data
|
||||
├── conversation turn queue
|
||||
└── reactive client projections
|
||||
│ service-authenticated dispatch
|
||||
▼
|
||||
Rivet actor system
|
||||
├── ProjectActor
|
||||
├── WorkActor
|
||||
├── AttemptActor
|
||||
├── VerificationActor (later split)
|
||||
├── IntegrationActor (later)
|
||||
└── ResultActor (later)
|
||||
│
|
||||
FLUE orchestration service
|
||||
├── model calls
|
||||
├── typed tools
|
||||
└── canonical Flue persistence in Convex
|
||||
│ later execution commands
|
||||
▼
|
||||
FLUE orchestration/application agents
|
||||
├── Signal/Definition
|
||||
├── Design/Slice planning
|
||||
├── Resolver decisions
|
||||
├── Verification design/evaluation
|
||||
└── Learning synthesis
|
||||
│
|
||||
▼
|
||||
Ports
|
||||
├── HarnessRuntime
|
||||
├── SandboxRuntime
|
||||
├── SourceControl
|
||||
├── ArtifactStore
|
||||
├── PreviewRuntime
|
||||
├── SecretBroker
|
||||
├── EventJournal
|
||||
└── RuntimePolicy
|
||||
│
|
||||
▼
|
||||
Adapters
|
||||
├── OMP/OpenCode/Codex/Pi/custom FLUE
|
||||
├── CubeSandbox/AgentOS/persistent machine/Docker
|
||||
├── Git forge
|
||||
├── object storage
|
||||
└── deployment/preview providers
|
||||
Rivet Engine + AgentOS (post-Slice 1)
|
||||
└── sandboxes, harnesses, and durable execution
|
||||
```
|
||||
|
||||
Clients MUST communicate only with Convex. FLUE and future Rivet/AgentOS
|
||||
services are private workers: Convex admits durable commands, invokes the
|
||||
worker, and stores the product-facing result before clients observe it.
|
||||
|
||||
### Ownership
|
||||
|
||||
| Layer | Owns |
|
||||
|---|---|
|
||||
| Work OS | durable intent, lifecycle, evidence, policy |
|
||||
| Rivet actors | serialized ownership, recovery, timers, leases |
|
||||
| FLUE | programmable orchestration and domain-specific agents |
|
||||
| Convex | authentication, normalized product records, command admission, reactive reads |
|
||||
| FLUE | private programmable orchestration and domain-specific agents |
|
||||
| Rivet actors (later) | serialized execution ownership, recovery, timers, leases |
|
||||
| Harness | bounded coding/tool loop |
|
||||
| Sandbox/runtime | filesystem, processes, network, isolation |
|
||||
| Git | source revision history |
|
||||
| Artifact store | durable outputs/evidence |
|
||||
| External systems | collaboration, delivery, monitoring |
|
||||
|
||||
No harness, sandbox, or chat transcript owns Work state.
|
||||
No client, harness, sandbox, or FLUE process owns product state.
|
||||
|
||||
### Slice 1 relational core
|
||||
|
||||
```text
|
||||
organizations ──< organizationMembers
|
||||
organizations ──< projects ──< projectContextDocuments
|
||||
organizations ──1 conversations ──< conversationTurns
|
||||
conversationTurns ──< conversationMessages ──< conversationAttachments
|
||||
projects ──< signals ──< signalConstraints
|
||||
signals ──< signalSources >── conversationMessages
|
||||
projects ──< works
|
||||
signals ──< signalWorkAttachments >── works
|
||||
works ──< workEvents
|
||||
```
|
||||
|
||||
Convex mutations provide atomic transactions and optimistic serializability.
|
||||
Foreign-key integrity and uniqueness are enforced in the owning mutations;
|
||||
composite indexes back every identity and relation lookup. Flue's adapter
|
||||
tables remain isolated infrastructure persistence and are not product-domain
|
||||
relations.
|
||||
|
||||
## 2. Domain boundaries
|
||||
|
||||
|
||||
Reference in New Issue
Block a user