ArkGate
ArkGate 4.6.6 on npm latest

Keep AI-written TypeScript inside an architecture you can trust.

One architecture config. One check. One coach.

When your agent writes TypeScript, ArkGate stops it from breaking the layers — and CI rejects the merge if it still does.

npm install -D arkgate
Four glass architecture layers — Presentation, Application, Domain, Infrastructure — pierced by a vertical contract beam with CONTRACT ACTIVE stamp
  1. 04 Presentation
  2. 03 Application
  3. 02 Domain
  4. 01 Infrastructure — contract active

02 / One minute

Install. Apply. Ask the doctor.

Four lines. That is the product. Stuck? Run doctor. Do #1.

npm install -D arkgate typescript
npx arkgate start
npx arkgate start --apply
npx arkgate-check --doctor

03 / Contract

Domain does not import Infrastructure. As data.

The architecture is ark.config.json. Agents read it. CI enforces it.

ark.config.json
{
  "include": ["src"],
  "layers": [
    {
      "name": "Domain",
      "patterns": ["src/domain/**"],
      "forbiddenGlobals": ["fetch", "Date.now"]
    },
    { "name": "Infrastructure", "patterns": ["src/infrastructure/**"] }
  ],
  "rules": [
    { "from": "Domain", "to": "Infrastructure", "allowed": false }
  ]
}
Denied

src/domain/order.ts

Domain cannot import Infrastructure.

04 / Doctor

One light. One next move.

Suggest

Thin or new tree

Finish start. Run doctor again.

Adapt

Not fully protected

Do action #1 until the light moves.

Enforce

Honest edges

Boundaries hold. Keep required CI.

Enforce · leftover design work

Imports clean. Design not finished.

One small refactor at a time.

One minute

One architecture config. One check. One coach.

When your agent writes TypeScript, ArkGate stops it from breaking the layers.

npx arkgate start