feat: hub and skills requirements 032 to 063

Hub: send in the field (032), coherent speak box (033), stream head band (034), Match at full width with its pile (035, 036), Home without the outer box (037), badge to Match (038), rejects that survive a changed or withdrawn card (039), the release card (040), code marks in the review diff (041), why Deny is off (042), the undo window clock (043), widgets without inner boxes (044), the Artifacts head on one line (045), accepting a red gate's risk (046), one code box (047), done rows greyed and folded (048), one control height (049), menus that stay open (050), radio settings in the Device card (051), bubbles beside the modes (052), agent settings on every face and name (053), pin only by menu (054), WASD in Match (055), the flowing card edge (056), Schedules in Controls (057) and the hub poll cost (059).

Skills: the coach leaves for its own repository kevinveenbirkenbach/coach (058; test_install pins its four skills in skills-lock.json and stays red until that repository is published and pinned), hooks and timers start fewer processes (060), council files on hot paths stay bounded and mirror by marker instead of mtime (061), scripts and hooks hand agents less output (062), and block.py builds the commit table and message block in one run (063). Requirement documents 032 to 063 with their implementation amendments.

MEDUSA false positives accepted after kvb-think-criticize (36 lines): MM-SCAN-058 (pla inside replace or plan), JB-SCAN-616/641 (the local clip helper), CODEGEN-SCAN-001 (drop-in paths), CGS-SCAN-029 (systemctl argv from constants), CGS-SCAN-040 (runner poll loop), FLA-SCAN-055 (feedback), WM-SCAN-354, AI-BACKDOOR-006, GENAI-SCAN-1270, B604 (runner shell path for passkey-verified commands), TC004, EXA002, EXA006, EXA010 and WEB-SSRF.

🎯 Fix: 92 %
💥 Break: 8 %
💸 Tokens: 89 %
⏱️ Velocity: –
🛡️ Security: ~100 %
🏆 Score: 95
🚦 Gate: ⛔ break 8 % > 5

Created-with: https://s.veen.world/skills
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Kevin Veen-BirkenbachandClaude Opus 5.5 committed 2026-11-26 08:44:15 +00:00
1 parent e5fd70e183
commit 0fad1bfae3
265 files changed
+10434 -2242

No files matched your search

+24 -1
View File
@@ -5,6 +5,8 @@ Args:
--repo: skills repository root.
--index: count the staged versions in the git index instead of the files.
--top: how many of the longest descriptions to list.
--memory: a MEMORY.md index to hold to MEMORY_WORDS; repeatable, a
missing file counts as empty.
Exit codes:
0 within budget, 1 over budget, 2 usage error.
@@ -20,6 +22,7 @@ from pathlib import Path
LISTING_WORDS = 1500
DESCRIPTION_WORDS = 40
SKILL_WORDS = 600
MEMORY_WORDS = 400
def skill_sizes(repo: Path) -> dict[str, int]:
@@ -59,6 +62,7 @@ def main() -> int:
parser.add_argument("--repo", required=True)
parser.add_argument("--index", action="store_true")
parser.add_argument("--top", type=int, required=True)
parser.add_argument("--memory", action="append", default=[])
args = parser.parse_args()
repo = Path(args.repo)
@@ -76,7 +80,26 @@ def main() -> int:
long = sorted(name for name, n in skill_sizes(repo).items() if n > SKILL_WORDS)
for name in long:
print(f"SKILL.md over {SKILL_WORDS}: {name}")
return 1 if total > LISTING_WORDS or over or long else 0
memory_over = report_memories(args.memory)
return 1 if total > LISTING_WORDS or over or long or memory_over else 0
def report_memories(paths: list[str]) -> bool:
"""Args:
paths: MEMORY.md indexes; a missing file counts as empty.
Returns:
Whether any index holds more than MEMORY_WORDS words.
"""
over = False
for path in paths:
try:
n = len(Path(path).read_text(encoding="utf-8").split())
except FileNotFoundError:
n = 0
over = over or n > MEMORY_WORDS
print(f"{n}/{MEMORY_WORDS} words in {path}" if n <= MEMORY_WORDS else f"MEMORY.md over {MEMORY_WORDS}: {path} ({n})")
return over
if __name__ == "__main__":
+20 -9
View File
@@ -12,8 +12,6 @@ function withCouncilDeny(data) {
return data;
}
module.exports = { COUNCIL_DENY, withCouncilDeny };
function resolved(settingsPath) {
let link;
try {
@@ -27,11 +25,13 @@ function resolved(settingsPath) {
return path.resolve(path.dirname(settingsPath), fs.readlinkSync(settingsPath));
}
function main(settingsPath) {
if (!settingsPath) {
console.error("usage: council-deny.js <settings.json>");
return 2;
}
/**
* Rewrite a settings file atomically through a transform, keeping its mode and following a symlink.
* @param {string} settingsPath the settings file; a missing one starts empty.
* @param {(data: object) => object} transform returns the new content.
* @returns {number} 0 when written, 1 when the file holds no JSON object.
*/
function edit(settingsPath, transform) {
const target = resolved(settingsPath);
let data = {};
let mode = 0o600;
@@ -53,15 +53,26 @@ function main(settingsPath) {
}
const temporary = `${target}.${process.pid}`;
try {
fs.writeFileSync(temporary, JSON.stringify(withCouncilDeny(data), null, 2) + "\n", { mode, flag: "wx" });
fs.writeFileSync(temporary, JSON.stringify(transform(data), null, 2) + "\n", { mode, flag: "wx" });
fs.chmodSync(temporary, mode);
fs.renameSync(temporary, target);
} catch (err) {
fs.rmSync(temporary, { force: true });
throw err;
}
console.log(`skills: Edit and Write on ${COUNCIL_DENY.length} council paths denied in ${settingsPath}`);
return 0;
}
module.exports = { COUNCIL_DENY, withCouncilDeny, edit };
function main(settingsPath) {
if (!settingsPath) {
console.error("usage: council-deny.js <settings.json>");
return 2;
}
const code = edit(settingsPath, withCouncilDeny);
if (code === 0) console.log(`skills: Edit and Write on ${COUNCIL_DENY.length} council paths denied in ${settingsPath}`);
return code;
}
if (require.main === module) process.exit(main(process.argv[2]));
+21 -10
View File
@@ -122,15 +122,25 @@ const SCRIPT_HOOKS = [
["kvb-org-radio/scripts/radio.py", "PostToolBatch", null, "tool", {}],
["kvb-org-radio/scripts/radio.py", "Stop", null, "listen", { asyncRewake: true, timeout: 21600 }],
["kvb-org-radio/scripts/radio.py", "Stop", null, "mailbox", {}],
["kvb-org-radio/scripts/radio.py", "PreToolUse", "Edit|Write|MultiEdit|NotebookEdit|Bash", "block", {}],
["kvb-org-organize/scripts/watch.py", "PostToolUse", "Bash", "watch", {}],
["kvb-org-organize/scripts/watch.py", "PreToolUse", "Bash", "block", {}],
["kvb-org-queue/scripts/queue.py", "PreToolUse", "Bash", "block", {}],
["kvb-org-radio/scripts/radio.py", "PreToolUse", "Edit|Write|MultiEdit|NotebookEdit", "block", {}],
["kvb-org-organize/scripts/hooks.py", "PreToolUse", "Bash", "pre-bash", {}],
["kvb-org-organize/scripts/hooks.py", "PostToolUse", "Bash", "post-bash", {}],
["kvb-org-perform/scripts/log.py", "PreToolUse", "Agent|Task", "spawn", {}],
["kvb-org-perform/scripts/log.py", "PostToolUse", "Bash", "persist", {}],
["kvb-agent-optimize/scripts/graph.py", "PreToolUse", null, "hook", { timeout: 30 }],
["kvb-agent-optimize/scripts/graph.py", "PreToolUse", "Read|Edit|Write|MultiEdit|NotebookEdit|Grep|Glob", "hook", { timeout: 30 }],
["kvb-org-organize/scripts/account.py", "SessionStart", null, "hook", {}],
];
const DISPATCHED = [
["kvb-org-organize/scripts/watch.py", "PostToolUse", "watch"],
["kvb-org-organize/scripts/watch.py", "PreToolUse", "block"],
["kvb-org-queue/scripts/queue.py", "PreToolUse", "block"],
["kvb-org-perform/scripts/log.py", "PostToolUse", "persist"],
];
const ran = (hook, script, sub) => String(hook.command).includes(script) && String(hook.command).endsWith(` ${sub}`);
for (const [script, event, sub] of DISPATCHED) {
data.hooks[event] = (data.hooks[event] || [])
.map((entry) => (Array.isArray(entry.hooks) ? { ...entry, hooks: entry.hooks.filter((hook) => !ran(hook, script, sub)) } : entry))
.filter((entry) => !Array.isArray(entry.hooks) || entry.hooks.length > 0);
}
// Trip-wire: python3 recompiles the script it is started with on every call and caches only imported modules; loading it as __main__ by file path reuses its __pycache__.
const AS_MAIN = `'import importlib.util as u,sys;s=u.spec_from_file_location("__main__",sys.argv[1]);m=u.module_from_spec(s);sys.argv=sys.argv[1:];sys.modules["__main__"]=m;s.loader.exec_module(m)'`;
for (const [script, event, matcher, sub, extra] of SCRIPT_HOOKS) {
@@ -139,10 +149,11 @@ for (const [script, event, matcher, sub, extra] of SCRIPT_HOOKS) {
// Trip-wire: python3 on a missing file exits 2, which blocks every prompt or tool call; the test makes it exit 1.
const command = `[ -f ${file} ] && ${PYTHON} -c ${AS_MAIN} ${file} ${sub}`;
const legacy = [`${PYTHON} ${file} ${sub}`, `[ -f ${file} ] && ${PYTHON} ${file} ${sub}`];
const registered = data.hooks[event].flatMap((entry) => entry.hooks || []).find((hook) =>
String(hook.command).includes(script) && String(hook.command).endsWith(` ${sub}`));
if (registered) {
const owner = data.hooks[event].find((entry) => (entry.hooks || []).some((hook) => ran(hook, script, sub)));
if (owner) {
const registered = owner.hooks.find((hook) => ran(hook, script, sub));
if (legacy.includes(registered.command)) registered.command = command;
if (owner.hooks.length === 1 && matcher) owner.matcher = matcher;
continue;
}
const entry = { hooks: [{ type: "command", command, ...extra }] };
@@ -150,4 +161,4 @@ for (const [script, event, matcher, sub, extra] of SCRIPT_HOOKS) {
}
fs.writeFileSync(settingsPath, JSON.stringify(data, null, 2) + "\n");
console.log(`skills: enabled the caveman and ponytail plugins (plugin skill copies dropped from this .claude), the ${REMINDERS.join(" + ")} reminders, the kvb-org-organize claim gate, resource watch and session account hook, the kvb-org-radio hooks, the kvb-org-queue gate, the kvb-org-perform log, and the kvb-agent-optimize code graph hook in ${settingsPath}`);
console.log(`skills: enabled the caveman and ponytail plugins (plugin skill copies dropped from this .claude), the ${REMINDERS.join(" + ")} reminders, the kvb-org-organize claim gate, resource watch and session account hook, the kvb-org-radio hooks, the kvb-org-perform log, the kvb-agent-optimize code graph hook, and one Bash hook dispatcher (radio, watch, queue, graph, log) per event in ${settingsPath}`);
+49
View File
@@ -0,0 +1,49 @@
#!/usr/bin/env node
"use strict";
const { edit } = require("./council-deny");
const GRAPH = /(^|\/)codebase-memory-mcp$/;
const NARROWED = { PreToolUse: "Grep|Glob" };
const DROPPED = { PostToolUse: "Read" };
const graphOnly = (entry) =>
Array.isArray(entry.hooks) && entry.hooks.length > 0 && entry.hooks.every((hook) => GRAPH.test(String(hook.command || "").trim()));
/**
* Narrow the hooks `codebase-memory-mcp install` registers.
* @param {object} data settings; a PreToolUse entry running only the graph binary matches NARROWED, its PostToolUse
* Read entry goes, and of graph-only entries with one event and matcher the first stays, since every install adds
* its own entry again.
* @returns {object} data, changed in place.
*/
function narrowGraphHooks(data) {
const hooks = data.hooks || {};
for (const [event, entries] of Object.entries(hooks)) {
if (!Array.isArray(entries)) continue;
const seen = new Set();
hooks[event] = entries.filter((entry) => {
if (!graphOnly(entry)) return true;
if (NARROWED[event]) entry.matcher = NARROWED[event];
if (DROPPED[event] === entry.matcher) return false;
const key = String(entry.matcher);
if (seen.has(key)) return false;
seen.add(key);
return true;
});
}
return data;
}
module.exports = { narrowGraphHooks };
if (require.main === module) {
const settingsPath = process.argv[2];
if (!settingsPath) {
console.error("usage: graph-hooks.js <settings.json>");
process.exit(2);
}
const code = edit(settingsPath, narrowGraphHooks);
if (code === 0) console.log(`skills: the codebase-memory-mcp hooks in ${settingsPath} run on ${NARROWED.PreToolUse} only, none after Read`);
process.exit(code);
}
+15 -6
View File
@@ -27,7 +27,7 @@ council_root="${REPO_ROOT}/skills/kvb-org-organize/scripts/councilroot.py"
has_user_systemd() { command -v systemctl &>/dev/null && systemctl --user show-environment &>/dev/null; }
resume_units() {
bash "${REPO_ROOT}/scripts/orchestrator.sh" start || true
if has_user_systemd; then systemctl --user start kvb-org-queue-cleanup.timer kvb-org-queue-cleanup.path || true; fi
if has_user_systemd; then systemctl --user start kvb-org-queue-cleanup.timer kvb-org-queue-cleanup.path kvb-schedules.path kvb-schedules.timer || true; fi
}
# Args: extra councilroot.py migrate arguments. Returns its exit code; on 3
# or 5 every file it left behind or kept beside its namesake is named on stderr.
@@ -73,7 +73,7 @@ fi
if [[ "${TARGET}" == "${HOME}" ]]; then
install -d -m 0700 "$(python3 "${council_root}" durable)"
if has_user_systemd; then
systemctl --user stop kvb-org-queue-cleanup.path kvb-org-queue-cleanup.timer kvb-org-queue-cleanup.service &>/dev/null || true
systemctl --user stop kvb-org-queue-cleanup.path kvb-org-queue-cleanup.timer kvb-org-queue-cleanup.service kvb-schedules.path kvb-schedules.timer kvb-schedules.service &>/dev/null || true
fi
if ! bash "${REPO_ROOT}/scripts/orchestrator.sh" stop; then
resume_units
@@ -149,15 +149,17 @@ fi
if [[ "${TARGET}" == "${HOME}" ]]; then
if has_user_systemd; then
log "skills: enabling the daily kvb-dream notification timer and the kvb-org-queue-cleanup rounds at 00:00, 12:00 and on request"
log "skills: installing the kvb-dream notification timer (off until switched on in the hub's Schedules tab), the kvb-org-queue-cleanup rounds and the kvb-schedules reconciler"
units="${HOME}/.config/systemd/user"
mkdir -p "${units}"
cp -f "${REPO_ROOT}/skills/kvb-dream/systemd/kvb-dream-notify.service" "${REPO_ROOT}/skills/kvb-dream/systemd/kvb-dream-notify.timer" "${units}/"
cp -f "${REPO_ROOT}/skills/kvb-org-queue-cleanup/systemd/kvb-org-queue-cleanup."{service,timer,path} "${units}/"
cp -f "${REPO_ROOT}/skills/kvb-org-organize/systemd/kvb-schedules."{service,timer,path} "${units}/"
systemctl --user daemon-reload
systemctl --user enable --now kvb-dream-notify.timer kvb-org-queue-cleanup.timer kvb-org-queue-cleanup.path
systemctl --user enable --now kvb-org-queue-cleanup.timer kvb-org-queue-cleanup.path kvb-schedules.path kvb-schedules.timer
systemctl --user start kvb-schedules.service || warn "skills: the first kvb-schedules round failed; its timer retries in 5 minutes."
else
warn "skills: no systemd user session; skipped the kvb-dream notification timer and the kvb-org-queue-cleanup rounds."
warn "skills: no systemd user session; skipped the kvb-dream notification timer, the kvb-org-queue-cleanup rounds and the kvb-schedules reconciler."
fi
if command -v docker &>/dev/null; then
if ! bash "${REPO_ROOT}/scripts/orchestrator.sh" install; then
@@ -176,6 +178,9 @@ if [[ "${TARGET}" == "${HOME}" ]]; then
if ! curl -fsSL --proto '=https' https://raw.githubusercontent.com/DeusData/codebase-memory-mcp/main/install.sh | bash; then
warn "skills: the codebase-memory-mcp installer failed; the code graph keeps its previous setup."
fi
if command -v node &>/dev/null; then
node "${REPO_ROOT}/scripts/graph-hooks.js" "${HOME}/.claude/settings.json" || warn "skills: the codebase-memory-mcp hooks keep the installer's matchers."
fi
if (ulimit -c 0; codebase-memory-mcp config set auto_index false); then
log "skills: daemon auto_index off; the kvb-agent-optimize graph.py hook indexes every git root a session touches, the session root included, through its size and memory gates"
else
@@ -189,7 +194,11 @@ if [[ "${TARGET}" == "${HOME}" ]]; then
if [[ "${graph_settings}" != *'"queue_file_threshold"'* || "${graph_settings}" != *'"queue_task"'* ]]; then
warn "skills: kvb-code-graph: no config at ${graph_config} with queue_file_threshold and queue_task; the graph.py hook indexes nothing until the operator sets both (see kvb-agent-optimize)."
fi
if command -v systemctl &>/dev/null && systemctl --user show-environment &>/dev/null && [[ -x "${HOME}/.local/bin/codebase-memory-mcp" ]]; then
graph_row=0
python3 -I "${REPO_ROOT}/skills/kvb-org-organize/scripts/schedules.py" check code-graph >/dev/null || graph_row=$?
if ((graph_row == 3)); then
log "skills: kvb-code-graph.service stays off: its row is switched off in the hub's Schedules tab"
elif command -v systemctl &>/dev/null && systemctl --user show-environment &>/dev/null && [[ -x "${HOME}/.local/bin/codebase-memory-mcp" ]]; then
log "skills: enabling kvb-code-graph.service, which keeps a permanent codebase-memory-mcp daemon so every graph stays watched"
mkdir -p "${HOME}/.config/systemd/user"
cp -f "${REPO_ROOT}/skills/kvb-agent-optimize/systemd/kvb-code-graph.service" "${HOME}/.config/systemd/user/"
+8 -5
View File
@@ -47,6 +47,7 @@ CLEANUP_UNIT="${NAME}-cleanup"
OFFICES_UNIT="${NAME}-offices"
SESSIONS_UNIT="${NAME}-sessions"
RESOURCES_UNIT="${NAME}-resources"
TOKENS_UNIT="${NAME}-tokens"
FIREWALL_UNIT="${NAME}-firewall"
INSTALLED_SKILLS="${HOME}/.claude/skills"
HOST_SCRIPTS=(kvb-org-organize/scripts/council.py kvb-org-organize/scripts/nofollow.py kvb-org-organize/scripts/councilroot.py kvb-org-rasci/scripts/rasci.py kvb-org-operator/scripts/operator.py kvb-org-radio/scripts/radio.py)
@@ -268,7 +269,7 @@ sessions_timer() {
systemctl --user daemon-reload
systemctl --user enable --now "${SESSIONS_UNIT}.timer"
systemctl --user restart "${SESSIONS_UNIT}.timer"
log "skills: ${SESSIONS_UNIT}.timer writes ${STATE}/agent-sessions.json every 15 seconds while the Agent Orchestrator page polls"
log "skills: ${SESSIONS_UNIT}.timer writes ${STATE}/agent-sessions.json every 30 seconds while the Agent Orchestrator page polls and the sessions changed"
}
resources_timer() {
@@ -276,11 +277,13 @@ resources_timer() {
warn "skills: no systemd user session; the Resources view stays empty."
return 0
fi
cp -f "${HUB}/systemd/${RESOURCES_UNIT}.service" "${HUB}/systemd/${RESOURCES_UNIT}.timer" "${UNITS}/"
cp -f "${HUB}/systemd/${RESOURCES_UNIT}.service" "${HUB}/systemd/${RESOURCES_UNIT}.timer" "${HUB}/systemd/${TOKENS_UNIT}.service" "${HUB}/systemd/${TOKENS_UNIT}.timer" "${UNITS}/"
systemctl --user daemon-reload
systemctl --user enable --now "${RESOURCES_UNIT}.timer"
systemctl --user enable --now "${TOKENS_UNIT}.timer"
systemctl --user restart "${RESOURCES_UNIT}.timer"
log "skills: ${RESOURCES_UNIT}.timer samples the host and counts the transcripts' tokens into ${KEPT}/resources every minute"
systemctl --user restart "${TOKENS_UNIT}.timer"
log "skills: ${RESOURCES_UNIT}.timer samples the host into ${KEPT}/resources every minute, ${TOKENS_UNIT}.timer counts the transcripts' tokens every 10 minutes"
}
firewall_unit() {
@@ -340,7 +343,7 @@ stop_all() {
docker compose --file "${HUB}/compose.yml" stop || return 1
fi
if has_systemd; then
systemctl --user stop "${RUNNER}" "${OFFICES_UNIT}.path" "${OFFICES_UNIT}.service" "${RESOURCES_UNIT}.timer" "${RESOURCES_UNIT}.service" &>/dev/null || true
systemctl --user stop "${RUNNER}" "${OFFICES_UNIT}.path" "${OFFICES_UNIT}.service" "${RESOURCES_UNIT}.timer" "${RESOURCES_UNIT}.service" "${TOKENS_UNIT}.timer" "${TOKENS_UNIT}.service" &>/dev/null || true
fi
}
@@ -349,7 +352,7 @@ start_all() {
docker compose --file "${HUB}/compose.yml" start || warn "skills: starting the Agent Orchestrator failed"
fi
if has_systemd; then
for unit in "${OFFICES_UNIT}.path" "${RESOURCES_UNIT}.timer" "${RUNNER}"; do
for unit in "${OFFICES_UNIT}.path" "${RESOURCES_UNIT}.timer" "${TOKENS_UNIT}.timer" "${RUNNER}"; do
if [[ "$(systemctl --user is-enabled "${unit}" 2>/dev/null || true)" == "enabled" ]]; then systemctl --user start "${unit}" || true; fi
done
fi
+1 -1
View File
@@ -10,7 +10,7 @@ STATE="$(python3 "${COUNCIL_ROOT}" root)/watch.json"
KEPT="$(python3 "${COUNCIL_ROOT}" durable)/queue-history.jsonl"
STALE_SECONDS=600
printf 'watch hooks running: %s\n' "$(pgrep -fc 'watch.py watch' || true)"
printf 'watch hooks running: %s\n' "$(pgrep -fc 'watch.py watch|hooks.py post-bash' || true)"
if command -v lsof &>/dev/null; then
printf 'holders of %s:\n' "${KEPT}"
lsof "${KEPT}" 2>/dev/null || printf ' none\n'