A hook point of Claude Code
TaskCompleted
judged When the assistant marks a task complete, it is claiming the work is done, and jevhooks checks that claim as it checks the end of a turn: for example, files were changed and no test has passed since.
It can refuse the completion once, and the assistant reads the reason; if the assistant marks the task complete again, that goes through. When a completion goes through, jevhooks cannot add a note for the assistant to read: Claude Code takes no added text from a plugin at this point.
Say something
Marking a task complete is the claim that it is done, so Jev is asked nothing: when files were changed and no check has passed since the last change, the completion is refused once, with what to do.
When the assistant marks a task complete, the same rules are checked against the task as it was written down and the turn's tool calls.
Each is an answer Jev could give, and the screen you would see. The rules that decide it are drawn on the page of the jevhook that acts in it.
a task marked complete after four changes and no test send it back
Marking a task complete is the claim that it is done, so that fact is known without asking. With changes and no check since, the completion is refused on what the daemon knows alone: Jev is asked nothing.
β― work through the three tasks for the --json flag β Update(src/flag.rs) βΏ Updated src/flag.rs with 12 additions and 2 removals β Task 2 is complete: the flag is parsed. β» Workingβ¦ task: jevhooks: the task is marked complete, and no check has passed since the last of 4 changes Β· 150 ms Β· $0.0002 [-] this session ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β― ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ βΈ manual mode on Β· esc to interrupt
The completion is refused, and the assistant reads:
jevhooks: The task is marked complete, but this task made 4 changes to files and no test, build, lint or type-check has passed since the last one. Run the check that covers the change, or say plainly that it is unverified. This is said once.
How the rules decided it, on the page of Send back βdoneβ when nothing was checked
a task marked complete with no summary, when your rules ask for one send it back
The assistant marks a task complete with βTask 2 is complete.β and no summary. Jev is 90% sure the rule is broken, and the completion is refused with your rule as the reason.
β― work through the three tasks for the --json flag β Bash(cargo test) βΏ test result: ok. 41 passed; 0 failed; 0 ignored β Task 2 is complete. β» Workingβ¦ task: Jev: this end breaks a rule of yours (90%): "End with a one-line summary of what changed." Β· 150 ms Β· $0.0002 [-] this session ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β― ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ βΈ manual mode on Β· esc to interrupt
The completion is refused, and the assistant reads:
jevhooks: The end of this task looks to break a rule for how one ends: the user's own rule "End with a one-line summary of what changed." (Jev: 90%). Put it right before ending, or say plainly why it does not apply. This is said once for this end.
How the rules decided it, on the page of Send a turn back when it ends against your rules
What this site keeps about a visit, and how to refuse it, is said in one place: what is kept.