This article answers a straightforward practical question: how do you get a coding agent to write code for modern AdonisJS without hallucinating deprecated APIs or forcing you to line-edit every generated file? To solve this, framework creator Harminder Virk released Flow — an official context engineering harness included in the AdonisJS Plus platform, which the team launched on November 16, 2026 in a public announcement.
Instead of yet another 200-line system prompt, the harness closes two loops at once: it gives the agent up-to-date stack rules before code generation and filters out typical mistakes at the pull-request stage, working inside Claude Code, Cursor, and other local environments. I dug into how the tool works on an AdonisJS 6 scenario to see how this loop plays out in practice and where its boundaries lie.
Why agents get framework versions mixed up and where context breaks down
When you work through Claude Code, Cursor, Codex, GitHub Copilot, or OpenCode, the bottleneck is no longer typing speed — it's reading time. In Virk's experience, when context is imprecise, the model fills in the blanks from older training data, and any time saved on generation evaporates during line-by-line review.
The author calls his approach a "software factory," though he is quick to clarify that it isn't an unattended assembly line. Humans still file issues and have the final say before merging a branch, while agents handle implementation and open pull requests. That's how Virk built the AdonisJS Plus website, package registry, and dashboard.
To keep this workflow from stalling on recurring mistakes, context has to be split into two halves:
- Product context — business logic, domain trade-offs, and your team's architectural taste, which is unique to each project.
- Tech stack context — directory layout, validation rules, ORM usage, and testing standards, which are shared across all AdonisJS applications.
Maintaining that second half manually in every repository is wasted effort, even though many teams already keep shared rules in a root CLAUDE.md — something we explored in our piece on building AI-native workflows in a repository. Flow takes over the stack context: the framework authors write it and keep it in sync with package releases.
Take a real-world task: in an AdonisJS 6 app with Lucid ORM, you ask an agent to build an authentication and user profile controller. Without a harness, the model can easily mix v4, v5, and v6 calls, throw together files manually with an arbitrary structure, read unvalidated fields via request.all(), or forget to scope queries to the current user. With Flow, the path changes at every stage.
The four quadrants of context engineering: how Flow closes the loop
The sharpest insight in Flow's architecture is separating prevention from verification. Instructions without follow-up checks can't tell if they worked, while checks without upfront rules catch the same mistake in every commit. That's why the harness builds on a 2×2 matrix from Joël Quenneville's talk "Harness Engineering on Rails" and Birgitta Böckeler's article on harness engineering: intervention before writing code (feed forward) or after (feedback), executed by a deterministic tool (computational) or by a model (inferential).
The first quadrant is generators (feed forward + computational). Agents tend to create files from scratch by hand, causing controller structure to drift across a project. Flow's skills require the model to run node ace make:controller AuthController or node ace make:model first, getting a predictable scaffold following AdonisJS 6 conventions before writing any logic.
The second quadrant is versioned documentation and eight skills (feed forward + inferential). Flow installs local guides matched strictly to the major versions of Lucid ORM, VineJS, and Bouncer in your project, stripping out descriptions obvious to an LLM and leaving hard rules where models usually guess. Alongside them sit eight built-in /flow- skills — a modular pattern similar to what we covered in our breakdown of the evolution of agent skills. They enforce layer boundaries and access control: in our AuthController, the agent immediately uses VineJS schemas for incoming payloads and Bouncer for authorization checks, while scoping list queries and bulk operations to the current user.
The third quadrant is linter rules (feedback + computational). Deterministic requirements for project structure and test coverage are packaged as ast-grep rules inside ESLint. They run in your editor, via npm run lint, and in CI regardless of who wrote the code, without burning tokens in the model's context window.
The fourth quadrant is pull request review (feedback + inferential). The reviewer checks the diff against the same rules baked into the skills, catching four classic AdonisJS bugs:
- IDOR — a controller action loads someone else's record without checking ownership.
- N+1 — a list query hits the database for every row because
preloadwas missed. - Blocking migration — a schema change could lock writes in production during deploy.
- Validation bypass — raw request data like
request.all()slips into inner layers without passing through VineJS.
If the agent still sneaks in a direct request.all() call while building the user profile, the review catches and stops that pull request before merge.
Local agent integration, limits, and your first step
Flow runs on top of your existing local agent in a Node.js v20+ and AdonisJS 6+ project with an active subscription granting access to the private @adonisplus registry. To wire the harness into a repo, add the package through Ace CLI and run the setup wizard:
node ace add @adonisplus/flow
node ace flow:install
The first command installs @adonisplus/flow, and the second binds the versioned docs, ESLint ast-grep rules, and skills to your chosen environment — Claude Code, Cursor, Codex, GitHub Copilot, or OpenCode. Once that's done, typing /flow- in your agent chat brings up the full list of built-in architectural workflows.
To review uncommitted changes or an open pull request locally before pushing, run a single command:
npx @adonisplus/flow review
The check runs locally or inside your own GitHub Actions pipeline using your own API keys or LLM subscription: no code is sent to AdonisJS servers, and the platform doesn't resell tokens or credits. Flow also coexists cleanly with general-purpose reviewers like CodeRabbit or Pullfrog.
Beyond the harness itself, an AdonisJS Plus subscription at $19/month billed annually ($228/year, with a 30-day refund window) includes Feature packs — recipes for end-to-end features like passkeys, 2FA, and secure password reset that the agent weaves directly into your existing codebase instead of a rigid template — plus Persona and Permissions modules for accounts and roles, and a private Discord. For Virk, who went full-time on the framework in July 2025 and crossed a hundred early subscribers since March 2026, this funds the ongoing development of free, open-source AdonisJS.
Still, don't adopt it blindly — there are three clear limitations to keep in mind:
- Stack requirements: the harness targets the current AdonisJS 6+ branch and a modern runtime; it won't support older v4 or v5 projects.
- Closed paid model: only a personal subscription is available right now (team plans are on the roadmap), and the source code for the
ast-greprules and skills isn't published on GitHub. - Boundary of responsibility: Flow knows the framework, but it doesn't replace product-specific rules or your final sign-off on a merge.
You can test whether your team actually needs this loop today without buying a subscription: open the last pull request generated by a coding agent and check it for the exact mistakes Flow targets — validation bypasses, missing preload calls, absent ownership checks, and risky migrations. If you spot even a couple of those, a structured harness or strict repo rules will pay for themselves on the very next review.

