Architecture decisions
ADR 0008: Generated code is ordinary Effect
accepted (2026-10-03)
Status: accepted (2026-10-03)
Context
effx must make the explicit Effect program smaller, not hide it. Escape hatches require that generated and handwritten Effect coexist.
Decision
Generators emit plain TypeScript using HttpApi/HttpApiGroup/HttpApiEndpoint,
Rpc/RpcGroup, effect/cli Command, and persistence Context.Service ports with typed adapter conformance suites (spec 0022), importing original schema symbols. Persistence adapters remain application-owned Layers; generated ports have no SQL and no method requirements. Every file starts
with // Generated by effx. Do not edit. plus source and IR ids. Output is deterministic
(sorted by StableId) and readable.
Consequences
- No effx DI container, no runtime registry, no reflection.
- Generator output can be diffed and snapshot-tested; developers can descend to raw Effect at any layer.