Skip to content
Projects & case studies
App Store deployed · Preparing for commercial launchCase study · System architecture

Phase 3 Benefits

Phase 3 Benefits brings eight health, commuter, and wage-law account types onto one payment card. I built a repository-based second brain—product strategy, specifications, verified facts, and agent memory—to keep AI development aligned.

§01

What was specified and built

Bill of materials

Product strategy and the repository-based second brain established a shared product definition. Within that structure, I directed the specifications and prototype work; a separate development team ported the prototype into production.

DeliverableScopeRole in delivery
Product strategy & second brainShared product definition
  • Strategy documents
  • Product and scope decisions
  • Specifications
  • Verified fact records
  • Dated decisions
  • Persistent agent memory
A shared product definition that keeps assignments aligned with scope, evidence, and owner decisions.
Product experiencesMember · admin · partner
  • Member app · iOS, Android, web
  • Onboarding
  • Virtual card and wallet
  • Balances and decline explanations
  • Receipts and claims
  • Help and household
  • Admin and partner portal
Product scope and prototype experiences that provided the design and copy blueprint for the development team's production work.
Payment rules & safeguardsSpecification · implementation
  • Spend-routing specification · eight account classes
  • Implemented event-intake safeguards
  • Transactional journal
  • Guarded sandbox processor client
A cited routing specification, separate from runtime code; implemented signature checks, validation, de-duplication, and journal audit safeguards.
Delivery & readinessSupporting delivery work
  • Configuration-as-code
  • Backup and restore drill
  • Compliance-readiness evidence
Gated infrastructure changes, recovery exercises, and control-by-control readiness evidence support delivery.
§02

Four layers, one repository

Interactive · trace a change

The architecture that mattered most is the stack around the agents: a context layer they read first, an execution layer bounded by specification, a verification layer with no overrides, and a control layer where a human decides what is true and what ships.

Pick a change and follow it down. Each layer lights the components that touch it and explains what they do with it. Select a layer name to read its role on its own.

Delivery stack · section viewContext, execution, verification, human control
Trace a change
  • Scope decisions, dated
  • Definition of Done · one owner per entry
  • What the registry says
  • Access decisions
  • After-action replanning
  • Local validate chain
  • CI jobs · no continue-on-error
  • Rulebook integrity and citations
  • Drift probes · blocking in check mode
  • Architect review of the wave diff
  • Operations gates · dry run, confirm, destructive
  • Workspace agent
  • Outside coding agent I operated
  • Backlog task · acceptance criteria
  • Dependency-ordered wave
  • Tested write fence between repositories
  • Project instructions
  • Agent memory topics
  • Fact registry · witness and date
  • Decision records · dated overrides
  • Swarm conventions
  • Rules specification, reached by memory topic
OverviewRead from the bottom up

The second brain is the base. Everything above it assumes an agent already knows what is true, what was decided, and who decided it.

L4

Owner decisions. Where money, access, scope, and compliance posture are decided. I owned the Definition of Done and what the fact registry says; each after-action report rewrote the next backlog.

L3

Gates. A local validate chain and CI jobs that stop at the first failure. Rulebook integrity and citation checks. Drift probes that read prose against the registry. An architect review of each wave diff.

L2

Agents and waves. Each assignment had one owner, acceptance criteria, and a place in a dependency graph. Agents worked inside that specification, from the Replit workspace and from a coding agent I operated outside it.

L1

Second brain. Repository files every assignment reads before work and writes back to after it: standing instructions, agent memory by topic, a fact registry with a witness and date on every row, dated decision records, and the conventions parallel agents follow.

Each trace follows one kind of change through the mechanisms recorded in the repository: the files an agent reads, the gates that run, and the decision that stays with me.
§03

Inside the second brain

Context engineering

The second brain is a set of versioned repository files with explicit ownership: what each one governs, who may write it, and which gate reads it. Context engineering here meant deciding those three things for every kind of knowledge the next agent should inherit.

The same files aligned agents in more than one tool. The coding agent I operated outside the Replit workspace, including for cloud console steps, read the same instructions, registry, and decisions as the workspace agent. The repository was the shared context.

ArtifactGovernsWritten byRead by · checked by
Project instructionsStanding directionWhat the product is, what stays fixed, and which repository is writable.Me.Every assignment, first. Enforced by a tested write fence.
Agent memoryPersistent project memoryReusable lessons and verified facts, indexed by topic, so the next agent starts where the last one finished.Agents, after work, inside the assignment's specification.Agents, before work. Reviewed with the wave diff.
Fact registryWhat is trueCurrent business facts. Every row carries a witness and a verification date; when a fact changes, older documents receive a dated override note.Me. The registry governs.Compliance and business prose. Checked by drift probes and citation gates.
Decision recordsSettled scopeMobile-web parity, cloud OCR at launch, manual bank linking in v1, and the other product calls that stay settled across waves.Me, dated.Assignments that touch scope, through the Definition of Done. Checked by its consistency check.
ConventionsHow parallel agents workHow agents share files inside a wave and hand off to the next one.Written after the first wave, from its after-action report.Every wave since. Reviewed by the architect.
§04

How work was sequenced and verified

Specification-driven

Specification-driven development, with the dependency graph deciding order. Each assignment had one owner, acceptance criteria, and a position in a wave; each wave ran through gates with no overrides and an architect review of the whole diff; each after-action report rewrote the next backlog. Feedback changed the plan as well as the code.

  1. 01Specify

    A Definition of Done with one owner per entry; backlogs derived from it; acceptance criteria on every task.

  2. 02Sequence

    Tasks ordered by a dependency graph into waves. The graph decides what can proceed together, whatever the number of agents available.

  3. 03Execute

    Agents work inside the specification, reading the second brain first; cross-repository writes stop at the fence.

  4. 04Verify

    Validate chain, CI jobs with no continue-on-error, rulebook and citation gates, drift probes, architect review of the wave diff.

  5. 05Replan

    An after-action report records what changed and why, writes back to memory, and rewrites the next backlog.

Recorded wave

Ten dependency-ordered tasks, integrated and reviewed in 4 h 46 min from task creation to closeout. Thirty-seven after-action reports captured lessons between May and September 2026.

§05

Evidence, with counting rules

Project workspace · October 2026

Every figure below describes my project workspace. The development team's production repository keeps its own record, attributed to that team.

Delivery record · engineering measures

238Klines of application code in the quality scanner's main scopeNon-blank, non-comment; excludes tests and prototypes. Exact: 238,379.
92.1%test coverage on the shared librariesLibrary scope; quality gate passing.
2.3Kcheck-ins, April to October 2026Mostly automatic agent checkpoints; peak 201 in a rolling 24 hours. Exact: 2,302.
0 → 83of 100 compliance controls in about a monthReadiness evidence on a compliance platform, control by control.

Second brain, as recorded. An agent-memory index with 158 topic files; a fact registry of 15 rows, each with a witness and a verification date; git-age, prose, semantic, agreement, and audit-gap drift probes, advisory by default and blocking in check mode; swarm conventions written after the first wave.

Specification and gates. One Definition of Done with one owner per entry; 626 tasks across 31 backlogs; ten CI jobs, none allowed to continue on error; 37 after-action reports. The rules specification covers eight account classes with 51 cited sources, checked by integrity and citation gates in CI.

Recorded checks on the prototype. 114 of 114 routes passing in the smoke run; 76 of 76 scoped accessibility checks passing in one browser engine; 170 of 170 style-audit captures; 264 test files defining about 2,039 test cases.

Development team's production repository. In that team's codebase, an agent account authored 460 of 536 merged pull requests between late July and late October 2026.

§06

Division of labor

Attribution

Three parties, three records, one product.

MichaelDirection and decisions

Product, architecture, sequencing, compliance posture, and integration. Owner of the Definition of Done and of what the fact registry says. Operated the outside coding agent for cloud console steps.

AI agentsImplementation inside the specification

The member-app prototype, the rules specification, the processor safeguards, and the operations toolkit, built inside the structure above and written back to the second brain after each wave.

Development teamProduction codebase · own record

A separate team ported the prototype into its production codebase, working from it as the end-to-end blueprint and the design and copy source of truth. The functioning member app reached the App Store in under six months from the first product commit and is prepared for commercial launch.

§07

Product knowledge is part of the delivery system.

Portable judgment

I made product decisions and verified lessons available across assignments, then connected acceptance to evidence. That is how the work stayed tied to a shared product definition rather than a series of separate conversations.

01 · Context

Context is infrastructure.

Facts, decisions, and conventions that no agent should rediscover belong in versioned files with a witness, a date, and a gate that reads them. Every agent, in every tool, starts from the same place.

02 · Execution

Specify before you parallelize.

One owner per entry and a dependency graph make parallel agents safe. That structure is what turns more agents into more product.

03 · Control

Supervise at the decision.

Human control belongs where money, access, and compliance posture are decided. Gates with no overrides carry the rest, and after-action reports turn what the gates found into the next plan.

If the build you are weighing touches money, eligibility, or regulated data, the layer that matters most is the one agents read before they write. That is the operating model I bring, whether you are hiring a product leader or scoping a complex build.

Revisit the stack

Need a leader who can
build with AI?

Let's talk about the product challenge, the team, and the outcomes you need—whether you're improving how your business runs or building something new.