The Tech Meta

An inside look at tech's evolving playbook

Agent hooks

Code AI observed

Scripts that run by themselves at set points of an agent session, such as after each file edit.

Scripts or commands that an agent tool runs by itself at set moments of a session: before a tool call, after a file edit, when the agent stops. A hook can format the file just written, run the linter or the tests, block a risky command or send a notification. Where an instruction relies on the agent choosing to follow it, a hook runs each time its event fires. The site counts a repo when it holds hook scripts in an agent directory, such as .claude/hooks or .cursor/hooks.json, or a hooks block in committed agent settings.

  • Pro scene today: 9%, 19 of 221 pro repos
  • In three months: −<1 pt (2 pro repos added it, 3 removed it)
  • Kept: 77%, 17 of 22 that had it 3 months ago or before

Pro 9% · Ladder 2%

Insight: 8 of the 19 run a check from a hook, mostly a formatter or a linter, never the tests or a type check; 8 can block an action.

In the pro repos

The 6 most starred of the 19 pro repos that have it today.

By month

MonthPro scene
June 2025<1%
July 2025<1%
August 2025<1%
September 2025<1%
October 20252%
November 20252%
December 20253%
January 20263%
February 20265%
March 20266%
April 20266%
May 20266%
June 20266%
July 20267%
August 20269%
September 20269%
October 20269%
November 20269%
today9%

Inside the practice

Repo profile

SlicePro repos with it
Size: Small3%, 2 of 73
Size: Mid7%, 5 of 74
Size: Large16%, 12 of 74
Layout: Single package6%, 7 of 119
Layout: Monorepo12%, 12 of 102
Main language: TypeScript or JS11%, 11 of 100
Main language: Python12%, 5 of 41
Main language: Go or Rust4%, 2 of 47
Main language: Other3%, 1 of 33

What agent hooks run

Of all repos: those with an agent hook are too few to count over. A check the hook runs after an edit or at the end of a turn.

  • A formatter: 2%, 5 of 221
  • A linter: 1%, 3 of 221
  • Another check script: <1%, 2 of 221

Evidence

Observed in the repos only: no published study is quoted for it yet.

How it is detected

Looks for hook scripts or a hooks block in committed agent settings. Read in repo files. How the method counts

Related practices

More in Code, the most adopted first.

Levels of evidence