Authorization notice. Unlazy is dual-use. Only use it on software, sites and systems you own or have explicit permission to test.
Who it is forA Claude Code user running a long task who keeps seeing the agent stop before its own gates pass.
The problemThe agent can end a session while gates are still unmet, and the user only learns this after reviewing the result.
The outcomeA Stop hook in local Claude Code settings that returns a block decision while gates or launch waves are incomplete.
What you need first
- Node.js 16 or newer
- An AI agent that supports skills, such as Claude Code or Codex CLI
- A repository with a task to verify and shell commands the gates can run
Steps
- Run
npx skills add Leonxlnx/unlazyto install the skill, then confirm the ledger exists as GATES.md or under .unlazy/. - Run
node /scripts/install-hooks.mjsto write the hook into .claude/settings.local.json, after you consent to the install. (inferred, check the README) - Add .claude/settings.local.json, .unlazy/, and .unlazy-hook-state.json to the project's ignore rules.
- Run a Claude Code session on the task and confirm the hook blocks exit while a gate is unmet.
- Run
node /scripts/install-hooks.mjs --uninstallwhen the task is done to remove the hook. (inferred, check the README)
Prompt for your agent
Use the unlazy skill in the repo <repo-path> to keep this Claude Code session on <task-name> until its gates pass. Run node /scripts/install-hooks.mjs, then run the session and report whether the Stop hook blocked exit while gates were unmet. Verify that .claude/settings.local.json is listed in the project's ignore rules.
Caveat. The hook's progress guard releases after six consecutive blocks without gate progress, so it will not hold a session open indefinitely.
Use this in your AI agent
Ask your agent
Using the Deduped MCP, get the setup steps for Leonxlnx/unlazy and "Block Claude Code from ending a session with unmet gates"
Add Deduped to Claude Code once
claude mcp add --transport http deduped https://dedupedai.com/mcp
Every Monday: the 5 hottest repos and exactly how to use them. Free, one email a week, unsubscribe anytime.
Get them freeShare: X LinkedIn Hacker News Email Copy link
Third-party repos we don't own. AI-written use cases can be wrong. Disclaimer