Repository navigation
v0.7.0 — agent/ and hooks
Two directories' worth of new surface, and a row that was lying about itself.
agent/ — one directory for everything this project authors
Instructions, skills, commands and hooks each landed somewhere different, by a
rule of their own. agent/ is the floor of one rule instead — the slot a file
lands in decides how it loads — with instructions, skills, commands,
hooks, subagents and tools as the slots.
Layered, not moved. AGENTS.md, .claude/skills and .bkht-coder/commands all
still load, and agent/ goes last, where the most specific source belongs. A
workspace root needs an agent.json marker and the global root does not:
agent/ is exactly what an eve project calls its own agent, and adopting one
unasked would make its system prompt ours.
Skills gain the flat form, where the file is the skill and its path is its name.
A flat skill ships no resources — its neighbours are other skills, not its files
— so skill(resource=...) refuses one by name rather than reaching sideways
into somebody else's directory.
coder info prints the surface before anything reads from it, and doctor
reports it.
Hooks — your own commands, fired on tool events
permissions.json remembers what you allowed but cannot do anything. A
hooks block in config.json can: run the formatter after a write, refuse a
call whose shape this project never wants, kick off a build when the turn ends.
{
"hooks": {
"post_tool": ["[ -n \"$CODER_PATH\" ] && ruff format \"$CODER_PATH\""],
"pre_tool": ["scripts/gate.sh"]
}
}Three events, and only pre_tool can say no. A non-zero exit blocks the call
and what the hook printed becomes the tool result, so the model reads the
refusal and works around it — the same correction path a malformed call takes:
● write_file(vendor/lib.py)
! blocked by a hook: vendor/ is not ours to edit
post_tool fires once the call has run, including when it failed: "the write
did not happen" is exactly what a hook watching writes needs to hear. turn_end
fires once, however the turn stopped.
Context reaches a hook through the environment rather than the command line,
because a command line means quoting and quoting means a hook that silently does
the wrong thing on a path with a space in it. CODER_PATH is lifted out of the
arguments JSON on its own, because every hook anybody actually writes wants that
one value.
Bounded, and asymmetrically. Everything is timed out at 30s. A pre_tool hook
that times out blocks — it is the one place failing open is worse than
failing loudly, because a gate nobody heard from is not a gate. So does one
whose script has gone missing, since the shell answered 127. Only a machine
with no shell at all fails open, where nothing was spawned to hear from.
The sub-agent behind task gets the parent's hooks. A gate is not a gate if
delegating the read is the way around it.
Hooks are arbitrary commands out of a config file that fire without anyone
asking, so they are never invisible: doctor names every one, /context counts
them, SECURITY.md says what they are, and --no-hooks runs a session with
none.
Fixed
A fresh session's context bar read a fifth full before anything was sent.
usage_ratio falls back to estimating from the payload when the backend has not
reported a token count, and the payload includes the system prompt — so with no
messages at all it answered with the size of a prompt the model had not been
given, and /clear could not put the bar back to zero. On this repository that
was 19% before a word had been typed. It now reads 0% until there is something
in the history.
Full notes in CHANGELOG.md.
Full Changelog: v0.6.0...v0.7.0