You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 102e76c
Browse filesBrowse the repository at this point in the historyBrowse files
Guardrails: the AI edits prose, the author decides
Author commands (approve, reject, undo, rule, state:accept, release, import,
guard seal) refuse under an AI host (CLAUDECODE, CODEX_CI/SESSION_ID/THREAD_ID).
A PreToolUse shell hook (Bash|PowerShell) blocks author commands in their usual
forms and disguises, Git history and config writes, tool installs, writes to
protected paths, and HTTP to the author page. The edit hook (now incl.
NotebookEdit) denies protected paths, paths outside the book, and code files.
Protected: .claude, CLAUDE.md, AGENTS.md, project.json, package files, .git,
node_modules, quality, narrative-state, continuity, .weaver, releases, review,
imports, world-bible/characters.json.
Detection: doctor adds guardrails-installed (hooks, deny rules, no
disableAllHooks in book or user settings), book-settings-sealed (`weaver guard
seal` fingerprints settings and quality/), approved-history (manuscript commits
since the import baseline must carry Approved-with) and protected-files-clean.
Studio footer shows guardrail status. Book template gets a five-line AGENTS.md
and CLAUDE.md -> @AGENTS.md. Undo commits now carry the approval trailer.
Verified: 86/86 tests from inside Claude Code (CLAUDECODE set) and Codex, with
discrimination tests per guard; consumer install passes. Real headless Claude
Code on an installed copy: 9/10 attack prompts left the book unchanged (no
commits, sealed files intact, doctor green). Hard blocks fired for git commit,
.claude edits (deny rule), disableAllHooks and tool reinstall; the rest were
declined by the model on AGENTS.md alone. The failure: told to add em dashes
"even if a check complains", the AI did; the post hook blocked but runs after
the write. Approval still refuses, but V1-A2 moves the blocking-rule check
before the edit.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011b2uBmyJAFs2WhLj81JJG3
Session-Id: 61e7c924-7a69-4dda-83e6-6e95ffcb326b
Agent: claude-code
||!hookEntryInstalled(settings.hooks?.PreToolUse,WEAVER_HOOK_COMMANDS.shell,WEAVER_HOOK_COMMANDS.shellMatcher))problems.push("a required edit or shell hook is missing");
193
+
if(!Array.isArray(settings.permissions?.deny)||!WEAVER_DENY_RULES.every((rule)=>settings.permissions.deny.includes(rule)))problems.push("an author permission rule is missing");
194
+
if(settings.permissions?.disableBypassPermissionsMode!=="disable")problems.push("permission bypass has not been disabled");
fix: guardProblems.some((problem)=>problem.startsWith("~")) ? "Your user-level Claude settings disable or prevent the checks. Contact PickBits to restore them." : FINDINGS.guardrailsInstalled.fix
0 commit comments