Design the system.
Agents write the code.

Half an Architect is an architecture board whose output is code. Lay out your backend from typed, configured blocks, and agents build it into your repository, one pull request at a time.

Access is by invitation for now.

presentation

driverapifastify · bearer
operatorwswebsocket
sensorintakefastify · certs

logic

reservationshold · expire
paymentshttp · mock
pricingzone rules
occupancydebounce

data

baystorepostgres
ratecacheredis · ttl 60s

pricing hits postgres on every quote. Cache the rules in redis?

livemapredis · geo
parkingdbpostgres
mapcacheredis
env22 vars
  • DATABASE_URL
  • REDIS_URL
  • SENSOR_CA_CERT
  • PAYMENTS_KEY
  • PAYMENTS_MOCKtest
baywatch is a made-up smart parking network: 40,000 bay sensors, live maps, reservations.

From board to repository.

Follow one system from its first block to a pull request. Scroll, or pick a step.

  1. Compose the system from typed blocks.

    APIs, objects, data access, databases, integrations and environments. Each block carries real settings, and its connections say what it may call. Together they are the spec.

  2. Think in three layers.

    Presentation takes requests, logic holds the business, data reads and writes. Use the patterns you already trust; the agents follow them and bring good practice of their own.

  3. Review the design with Assist.

    Assist reads the whole board and answers at system level. It can propose blocks, and nothing lands on the board until you approve it.

  4. Agents build it layer by layer.

    Foundation, API, data, logic, then the entry point. Each agent writes the files for its own blocks.

  5. Every file where you would look for it.

    The repository mirrors the board, so you know where the code is before you open it. Point at a block to see its files.

  6. Change the board, and only that code changes.

    Edit one block and the next build touches the files that belong to it. No change on the board means no change in the code.

Compose the system from typed blocks. APIs, objects, data access, databases, integrations and environments. Each block carries real settings, and its connections say what it may call. Together they are the spec.

presentation

driverapifastify · bearer
operatorwswebsocket
sensorintakefastify · certs

logic

reservationshold · expire
paymentshttp · mock
pricingzone rules
occupancydebounce

data

baystorepostgres
ratecacheredis · ttl 60s
livemapredis · geo
parkingdbpostgres
mapcacheredis
env22 vars
  • DATABASE_URL
  • REDIS_URL
  • SENSOR_CA_CERT
  • PAYMENTS_KEY
  • PAYMENTS_MOCKtest

Blocksbaywatch

  • API
  • Object
  • Data access
  • Database
  • Stream
  • Integration
  • Environment
Block
driverapi API on presentation
Settings
fastifybearer
Calls
reservations
Becomes
src/modules/driverapi/routes.tssrc/modules/driverapi/ports.tssrc/modules/driverapi/middlewares/authenticate.ts

Drag a block onto its layer, connect it, set its options. That is the whole spec.

Assistreads the whole board

Review the system. Anything that breaks at scale?

pricing reads every zone's rules from postgres on each quote. On event days that's thousands of queries a second against the same rows. Cache the rules in the redis you already run for the live map?

ratecacheData access · redis · ttl 60s · on data

baywatch/24 files

Board changepricing gets a second strategy: event-day rates

  1. parkingdb
  2. init
  3. 01_schema.sql
  4. src
  5. app
  6. app.ts
  7. config
  8. config.ts
  9. modules
  10. baystore
  11. bayStore.ts
  12. pool.ts
  13. driverapi
  14. middlewares
  15. authenticate.ts
  16. ports.ts
  17. routes.ts
  18. livemap
  19. liveMap.ts
  20. occupancy
  21. occupancyService.test.ts
  22. occupancyService.ts
  23. operatorws
  24. handlers.ts
  25. ports.ts
  26. payments
  27. paymentsClient.mock.ts
  28. paymentsClient.ts
  29. pricing
  30. eventDayStrategy.ts+
  31. pricingStrategy.test.ts+
  32. pricingStrategy.ts~
  33. ratecache
  34. rateCache.ts
  35. reservations
  36. reservationService.ts
  37. sensorintake
  38. middlewares
  39. verifyDevice.ts
  40. ports.ts
  41. routes.ts
  42. main.ts
  43. .env.example
  44. docker-compose.yaml

Outgrown one system? Draw a boundary.

Systems start small and grow fast. When one stops making sense, zoom out and draw a boundary around each API and what it needs. Every boundary becomes a system of its own.

One system, one deploy. Fine up to a point.

systems/lobbytypescript

systems/realtimego

systems/backofficetypescript

lobbyapifastify · bearer
gameclientwebsocket
adminapiadminrpcfastify · ssogrpc
matchmakingskill buckets
sessions30 Hz tick
anticheathttp · mock
progressionxp · unlocks
leaderboardsrankings
playerstorepostgres
sessionviewredis · read
sessionstateredis
matcheventskafka publisher
resultsfeedkafka consumer
rankingsredis
gamedbpostgres
sessioncacheredis
matchbuskafka
rankcacheredis
envglobal
  • LOG_LEVEL
  • OTEL_ENDPOINT
  • JWT_ISSUER
  • REGION

systems/lobby/typescript

  • Dockerfile
  • docker-compose.yaml
  • .env.example
  • gamedb/init/01_schema.sql
  • src/modules/lobbyapi/
  • src/modules/matchmaking/
  • src/modules/playerstore/
  • src/modules/sessionview/
  • src/main.ts

systems/realtime/go

  • Dockerfile
  • docker-compose.yaml
  • .env.example
  • matchbus/init/01_topics.sh
  • src/modules/gameclient/
  • src/modules/sessions/
  • src/modules/anticheat/
  • src/modules/sessionstate/
  • src/modules/matchevents/
  • src/main.go

systems/backoffice/typescript

  • Dockerfile
  • docker-compose.yaml
  • .env.example
  • src/modules/adminrpc/
  • src/modules/progression/
  • src/modules/leaderboards/
  • src/modules/resultsfeed/
  • src/modules/rankings/
  • src/main.ts
  • systems/lobby typescript

    • lobbyapi
    • matchmaking
    • playerstore
    • sessionview
    • gamedb
  • systems/realtime go

    • gameclient
    • sessions
    • anticheat
    • sessionstate
    • matchevents
    • sessioncache
    • matchbus
  • systems/backoffice typescript

    • adminrpc
    • progression
    • leaderboards
    • resultsfeed
    • rankings
    • rankcache

lastlight is made up for this page.

Six people, six readings of the same code.

Teams get reshuffled and directions change. The people who knew why leave, and the reasons leave with them. After that everyone reads the code their own way and nobody owns it. A board is one picture of the whole system, and everyone reads the same one. Change it and the code follows.

The coderead by six people

6 directions

The boardread by six people

1 direction

It's still your code.

Read it, change it, push to it. Every build lands as a pull request for you to merge or turn down. Disagree with something? Open a pull request of your own and say why. Half an Architect picks up the reasoning and builds with it from then on.

  1. build-3f1c08a2board: expire reservation holds
  2. your PR #4“Debounce the transition. Sensors flap at dusk.”
  3. build-91be44d0board: add cache for pricing
  4. build-c27a5e19Your debounce change is already part of the system

An example history for baywatch.

You bring the intent.
Agents bring the code.

You decide what gets built and how. Agents write it the way you would have, where you would look for it, so the code is never a mystery.

Sign in

Access is by invitation for now.