Topics ▾
Workflows ·

Turn each agent correction into a lint rule

Advanced, 30 minutes

Lauren Tan from the Grok Bot team turns each correction she gives a coding agent into a deterministic check, like a lint rule with an error message that names the real fix, instead of adding another line to the agent's rules.

Published

How this helps you

You fix each recurring mistake once, in code, so you stop repeating yourself and have less to check in every review.

✦ Try it
I just corrected you on [pattern, e.g. using setTimeout to patch a rendering bug]. Don't add this to your rules, a skill or a code comment. In [repo], turn it into a deterministic check instead: a [lint rule / dependency rule / type / test] that fails when [pattern] appears in [folders]. Make the error message tell the next agent the root-cause fix: [what to do instead]. Show me how many existing cases it finds. Make it block new cases first, then propose a separate change that cleans up the old ones. Include a failing and a passing example and the check's output.

Fill in: [pattern]: the exact mistake you corrected. [folders]: where the rule applies (she allows some patterns only inside framework code). [what to do instead]: the fix you'd have explained. The prompt is ours, built from the method in her talk.

What they did

In her AI Engineer talk 'All Code Is Slop (Except Mine)', Lauren Tan (poteto), an engineer on the Grok Bot team, explains how the team keeps agent-written code trustworthy at high volume. She says she shipped 3,000 pull requests last month, the team shipped 11,000, and the share that gets reverted is steady at about 0.5%. Her rule: whenever you correct an agent, ask how to make that correction a deterministic check in code instead of another line in your rules or AGENTS.md, because code is reproducible and enforceable and prose isn't. The team banned React's useEffect in product code, made imports between the electron main and renderer folders fail a dependency check, and banned about 99% of code comments after agents used comments to justify quick fixes like stray timers. Their lint errors tell the agent to fix the root cause rather than patch around it.

Who it's for: Developers who use Grok Bot to run coding agents (Cursor cloud agents, CLIs) on a codebase they own.

Before you start

How to try it

  1. Next time you correct the agent, stop before you add a line to its rules, a skill or a code comment.
  2. Ask whether the mistake can be made impossible or loud: a lint rule, a banned API, a type, a test, or a folder layout where the wrong import fails a dependency check.
  3. Have the agent write the check with an error message that says what to do instead, so the next agent fixes the root cause.
  4. Turn it on for new code first so no new cases slip in, then clean up the existing ones in a separate change. This is the order she recommends.
  5. Delete the prose rule or comment the check replaces.
  6. Add verification on top: ask for screenshots, videos or diagrams of the running app with each change, and review those instead of every line. Only automate the loop once this works.

What to expect

Her timers example: agents kept reaching for setTimeout and requestAnimationFrame as quick fixes for a clash between VS Code's imperative style and React's declarative style, and wrote comments explaining why each fix was justified. The timers spread, garbage collection rose and the app lagged. In Grok Bot the team now bans most comments and uses lint rules whose errors point at the root cause. A successful check is one the agent hits, reads, and then fixes properly without you saying anything.

Common mistakes

Related tips

Worth knowingFor runtime verification the team gives agents a 'feature map', a site map of the app's features from the user's point of view, plus reusable command line tools inside skills to save tokens. She says most of her tokens now go on verification. Once the foundations were there, Grok Bot became the outer loop: on each release it starts a Cursor project that tests the build like a real user, opens a fix pull request for each bug and merges it.
Next in Workflows →Turn an SOP you already wrote into a working Bot

Learn more: Grok Bot Use Cases: Real Workflows From Real Users · All Grok Bot workflows tips

Related Grok Bot tips

More Workflows →
Workflows

Numbered sales page rewrites, then ask what's broken

Matt Clark had Grok Bot improve a sales page 50 times, each at its own numbered URL. The best finds came at the end, when he asked for the five things that were broken or inconsistent.

How this helps you You get a list of concrete page fixes and a check for contradictions (guarantees, claims, prices) that could cost you sales or trust.
Spotted by Matt Clark (YouTube) · 29 Nov 2026
Read more
Workflows

Hand huge reads to Gemini 4 Neon, let Grok Bot do the rest

Give Grok Bot a skill that sends whole folders, long documents or codebases to Google's Gemini 4 Neon API in one call, saves the findings next to the files, and shows the cost before every call.

How this helps you Your Bot can work through material far bigger than one conversation, see the cost before it spends, and doesn't pay twice to read the same files.
Spotted by @kkite_aiarc · 28 Nov 2026
Read more
Workflows

Give an SEO Bot one goal and Search Console to check it

Ras Mic's Grok Bots run SEO for a fan wiki: an hourly pass, a daily report, and Google Search Console as the way the Bot checks whether its changes worked.

How this helps you Your Bot does the repetitive SEO checks and fixes, and every change is judged against real search numbers you can open yourself.
Spotted by Ras Mic (YouTube) · 26 Nov 2026
Read more