{
  "name": "alfabaykal/by-the-book — 9 hooks",
  "slug": "source-hooks-57922f713ef142b703e48462",
  "type": "hooks",
  "category": "developer-tools",
  "example": false,
  "evidence_state": "pinned_source_listing",
  "stamp": "Pinned source listing — machine-checked",
  "summary": "Pinned source declarations and file hashes were listed.",
  "outcome": "Listed 9 hook declarations. Ran 22 git commands; each one's exit status and output hash is in commands.json. Scope: acquisition and static inspection.",
  "rule_results": [
    "The retained source tree matches its acquisition manifest.",
    "Declared hook names (listing.json): SessionStart; SubagentStart; PreToolUse; PostToolUse; PostToolUse; PostToolUse; Stop; SubagentStop; SessionEnd"
  ],
  "task": "What declarations and files are present in this pinned source?",
  "setup": "Git blob acquisition followed by static source inspection.",
  "limitations": "Scope: acquisition and static inspection. Command results: commands.json.",
  "source_url": "https://github.com/alfabaykal/by-the-book",
  "documentation_url": "https://github.com/alfabaykal/by-the-book",
  "commit": "d3f8a985f39b8e9a84fff1f724fd742764ce60c0",
  "tree_sha256": "9457d5de547cd86e442caf6f6daced1a37a51b5ad1288fd7c0f859638d9a3712",
  "file_sha256": {
    ".claude-plugin/marketplace.json": "e0bc03eff7a98b87e491402a244d691705a17a65f7ebab6861fac383cc545af2",
    ".claude-plugin/plugin.json": "2608c6f509df634f2ae161ec69f8804b4417a27c9fedf3f1ac54b28bb6c7fb95",
    ".gitignore": "4d916b4a129babe59042e9b1405e0cbcc7aae57ca6309f0107ea4334a47e78d0",
    "LICENSE": "3126ca0813d1e3759372f905555d054b28006decf45854b26747fc6202587662",
    "README.md": "d9ae5a990bbf6b4de82cf19f35980275d309682c126cbfa4dfb18d90051e6067",
    "assets/logo.svg": "580b7b5c56fbf3eb097d7de744b6cc1925b47af4c39385cd86c9ac28209b2aee",
    "hooks/core.md": "abf27cb80789ed50e966a0fe17419ced3dfc7feb525e03a866d42122f4a82a57",
    "hooks/core.sh": "d08040ab1fcd412e7da2b4e43939a1f29ee8c106e9c852378f9227ac1056da8a",
    "hooks/hooks.json": "69ec8ab6ffdf1a0f124e9690cb39d2100e313363aaa4f190322f9095dac47c0e",
    "hooks/law-gate.sh": "17258147aabdba9df1a03eb4c4b6c55710afe0493364b1b23bcfcad3c146573e",
    "hooks/practice.sh": "6c3029f9485f773972e35c834d858f944e187f2e1eb9c9d7883970ec7bc992e3",
    "skills/how-should-it-work/SKILL.md": "bf0f0d46482a507ad869c7e77204e227dcf1546c6fe430684e2b36c5dc6f1ba6",
    "skills/is-it-by-the-book/SKILL.md": "a3bddee1aec6f524e160d1b09dc5e1969b1ae386904ea90be652a867e34b9a2b",
    "skills/will-it-pass-tomorrow/SKILL.md": "57305f0823b856289bf992f752ee8b2f91874e4d8a650f0317a5ca0d851022af",
    "tests/core.test.sh": "484727e842d60ed9695e33610147c05e8a7f8c9861979b6d5fe137b62837d99e",
    "tests/law-gate.test.sh": "b4abc507cba18ddd0eacfe23d6bead5de2254ff945da6d69db20785d77eed9fd",
    "tests/practice.test.sh": "0e7731fc76cc27deea9f8ef65bf8ac9482ad147ca870616587c8d7812bb65937"
  },
  "lockfiles": [
    "LOCK.json"
  ],
  "utc_date": "2026-11-27T21:27:05Z",
  "source_date": "2026-11-24",
  "discovered_date": "2026-11-24",
  "retested_date": "2026-11-27",
  "reviewed_date": "2026-11-27",
  "published_date": "2026-11-27",
  "modified_date": "2026-11-27",
  "reviewer": "machine pipeline",
  "harness_version": "toolwitness harness at commit 2af5e8f14b9fc723e51bbf977c7e85e324078d6a",
  "claude_code_version": "Not applicable: static source inspection (commands.json).",
  "model_id": "Not applicable: static source inspection (commands.json).",
  "scanner_version": "Not applicable: static source inspection.",
  "rulepack_version": "Not applicable: static source inspection.",
  "agents": [],
  "disclaimer": "This record lists declarations and file hashes from a pinned source tree. Git command results from acquisition and static inspection are retained in commands.json. Scope: acquisition and static inspection. It is not a security or quality verdict. Changed bytes are outside this record.",
  "commands": [
    "Ran 22 git commands; each one's exit status and output hash is in commands.json. Scope: acquisition and static inspection."
  ],
  "prompt_list": [
    "Not applicable: static source inspection (commands.json)."
  ],
  "history": [
    "2026-11-27T21:27:05Z: pinned source inspection"
  ],
  "application": {
    "name": "alfabaykal/by-the-book — 9 hooks",
    "softwareVersion": "d3f8a985f39b8e9a84fff1f724fd742764ce60c0",
    "applicationCategory": "DeveloperApplication",
    "operatingSystem": "Not exercised"
  },
  "artifacts": {
    "transcript": "Ran 22 git commands; each one's exit status and output hash is in commands.json. Scope: acquisition and static inspection.",
    "sinkhole_log": "Not applicable: static source inspection (commands.json).",
    "canary_log": "Not applicable: static source inspection (commands.json).",
    "scanner_output": "Not applicable: static source inspection (commands.json).",
    "normalized_text": "{\n  \"listing\": {\n    \"skills\": [\n      {\n        \"path\": \"skills/how-should-it-work/SKILL.md\",\n        \"name\": \"how-should-it-work\",\n        \"description\": \"Use before choosing how something works - a mechanism, an API, a pattern, a library or its version, a build file, a config, the fix for a bug - and when the user asks for best practices. Use when a shortcut with a known limit looks tempting (\\\"good enough for now\\\", \\\"redo it if a profile shows it\\\", polling, a sleep loop, a hand-rolled version of what the platform provides).\",\n        \"files\": {\n          \"skills/how-should-it-work/SKILL.md\": \"bf0f0d46482a507ad869c7e77204e227dcf1546c6fe430684e2b36c5dc6f1ba6\"\n        }\n      },\n      {\n        \"path\": \"skills/is-it-by-the-book/SKILL.md\",\n        \"name\": \"is-it-by-the-book\",\n        \"description\": \"Use when reviewing a diff or auditing code, your own diff included, for whether each mechanism follows the platform's guidance (the Practice axis of a review). Test code is in scope. Starts by asking whether the diff decides how anything works, skips mechanical changes, and reports where the platform's advice differs from a project rule.\",\n        \"files\": {\n          \"skills/is-it-by-the-book/SKILL.md\": \"a3bddee1aec6f524e160d1b09dc5e1969b1ae386904ea90be652a867e34b9a2b\"\n        }\n      },\n      {\n        \"path\": \"skills/will-it-pass-tomorrow/SKILL.md\",\n        \"name\": \"will-it-pass-tomorrow\",\n        \"description\": \"Use before writing or fixing a test, before re-recording a stored reference (a snapshot, a golden file), when a test fails only sometimes, only in CI, only under load or takes seconds, and when reviewing test code. The test controls the clock, network, disk, timers and system components its code depends on, and waits for a state, never for time.\",\n        \"files\": {\n          \"skills/will-it-pass-tomorrow/SKILL.md\": \"57305f0823b856289bf992f752ee8b2f91874e4d8a650f0317a5ca0d851022af\"\n        }\n      }\n    ],\n    \"hooks\": [\n      {\n        \"path\": \"hooks/hooks.json\",\n        \"sha256\": \"69ec8ab6ffdf1a0f124e9690cb39d2100e313363aaa4f190322f9095dac47c0e\",\n        \"event\": \"SessionStart\",\n        \"matcher\": \"startup|resume|clear|compact\",\n        \"declaration\": {\n          \"type\": \"command\",\n          \"command\": \"sh \\\"${CLAUDE_PLUGIN_ROOT}/hooks/core.sh\\\" SessionStart\",\n          \"timeout\": 10\n        },\n        \"executed\": false\n      },\n      {\n        \"path\": \"hooks/hooks.json\",\n        \"sha256\": \"69ec8ab6ffdf1a0f124e9690cb39d2100e313363aaa4f190322f9095dac47c0e\",\n        \"event\": \"SubagentStart\",\n        \"matcher\": null,\n        \"declaration\": {\n          \"type\": \"command\",\n          \"command\": \"sh \\\"${CLAUDE_PLUGIN_ROOT}/hooks/core.sh\\\" SubagentStart\",\n          \"timeout\": 10\n        },\n        \"executed\": false\n      },\n      {\n        \"path\": \"hooks/hooks.json\",\n        \"sha256\": \"69ec8ab6ffdf1a0f124e9690cb39d2100e313363aaa4f190322f9095dac47c0e\",\n        \"event\": \"PreToolUse\",\n        \"matcher\": \"Edit|Write|MultiEdit|NotebookEdit\",\n        \"declaration\": {\n          \"type\": \"command\",\n          \"command\": \"sh \\\"${CLAUDE_PLUGIN_ROOT}/hooks/practice.sh\\\" pre-edit\",\n          \"timeout\": 10\n        },\n        \"executed\": false\n      },\n      {\n        \"path\": \"hooks/hooks.json\",\n        \"sha256\": \"69ec8ab6ffdf1a0f124e9690cb39d2100e313363aaa4f190322f9095dac47c0e\",\n        \"event\": \"PostToolUse\",\n        \"matcher\": \"Bash\",\n        \"declaration\": {\n          \"type\": \"command\",\n          \"command\": \"sh \\\"${CLAUDE_PLUGIN_ROOT}/hooks/law-gate.sh\\\"\",\n          \"timeout\": 10\n        },\n        \"executed\": false\n      },\n      {\n        \"path\": \"hooks/hooks.json\",\n        \"sha256\": \"69ec8ab6ffdf1a0f124e9690cb39d2100e313363aaa4f190322f9095dac47c0e\",\n        \"event\": \"PostToolUse\",\n        \"matcher\": \"Edit|Write|MultiEdit|NotebookEdit\",\n        \"declaration\": {\n          \"type\": \"command\",\n          \"command\": \"sh \\\"${CLAUDE_PLUGIN_ROOT}/hooks/practice.sh\\\" post-edit\",\n          \"timeout\": 10\n        },\n        \"executed\": false\n      },\n      {\n        \"path\": \"hooks/hooks.json\",\n        \"sha256\": \"69ec8ab6ffdf1a0f124e9690cb39d2100e313363aaa4f190322f9095dac47c0e\",\n        \"event\": \"PostToolUse\",\n        \"matcher\": \"Skill\",\n        \"declaration\": {\n          \"type\": \"command\",\n          \"command\": \"sh \\\"${CLAUDE_PLUGIN_ROOT}/hooks/practice.sh\\\" skill\",\n          \"timeout\": 10\n        },\n        \"executed\": false\n      },\n      {\n        \"path\": \"hooks/hooks.json\",\n        \"sha256\": \"69ec8ab6ffdf1a0f124e9690cb39d2100e313363aaa4f190322f9095dac47c0e\",\n        \"event\": \"Stop\",\n        \"matcher\": null,\n        \"declaration\": {\n          \"type\": \"command\",\n          \"command\": \"sh \\\"${CLAUDE_PLUGIN_ROOT}/hooks/practice.sh\\\" stop\",\n          \"timeout\": 10\n        },\n        \"executed\": false\n      },\n      {\n        \"path\": \"hooks/hooks.json\",\n        \"sha256\": \"69ec8ab6ffdf1a0f124e9690cb39d2100e313363aaa4f190322f9095dac47c0e\",\n        \"event\": \"SubagentStop\",\n        \"matcher\": null,\n        \"declaration\": {\n          \"type\": \"command\",\n          \"command\": \"sh \\\"${CLAUDE_PLUGIN_ROOT}/hooks/practice.sh\\\" stop\",\n          \"timeout\": 10\n        },\n        \"executed\": false\n      },\n      {\n        \"path\": \"hooks/hooks.json\",\n        \"sha256\": \"69ec8ab6ffdf1a0f124e9690cb39d2100e313363aaa4f190322f9095dac47c0e\",\n        \"event\": \"SessionEnd\",\n        \"matcher\": null,\n        \"declaration\": {\n          \"type\": \"command\",\n          \"command\": \"sh \\\"${CLAUDE_PLUGIN_ROOT}/hooks/practice.sh\\\" end\",\n          \"timeout\": 10\n        },\n        \"executed\": false\n      }\n    ],\n    \"executions\": []\n  }\n}"
  },
  "review_input": {
    "identity_artifact": "identity.json",
    "evidence_sha256": {
      "LOCK.json": "a1df33e9561d7d110df873aa6d8acb4a19e43d02dcb473a5127041b7d37161e8",
      "commands.json": "b9353eb9e0ec77267bf1012067c2249007e6b0f8e9570bef34422560d278152f",
      "complete.json": "91b504b43905fdc009504d516c45eea831f39a1995b9e7d69987c9756c936d6f",
      "identity.json": "80465e3137c8ffaba691772ccdb29e5733bcc65d664366fcd525fe83e561af06",
      "listing.json": "4803d31fb14450c1415dd9f216d898388b403c2897aed9bafdcf460f47e1c627",
      "selection.json": "d27ac253aedd1803dae1555399aa23625a5a94335f2e97602c4d2c5f3b162dd3"
    },
    "claims": [
      {
        "id": "acquired",
        "field": "summary",
        "text": "Pinned source declarations and file hashes were listed.",
        "sources": [
          "LOCK.json",
          "listing.json",
          "commands.json"
        ]
      },
      {
        "id": "listed",
        "field": "outcome",
        "text": "Listed 9 hook declarations. Ran 22 git commands; each one's exit status and output hash is in commands.json. Scope: acquisition and static inspection.",
        "sources": [
          "LOCK.json",
          "listing.json",
          "commands.json"
        ]
      },
      {
        "id": "tree",
        "field": "rule_results.0",
        "text": "The retained source tree matches its acquisition manifest.",
        "sources": [
          "LOCK.json",
          "listing.json",
          "commands.json"
        ]
      },
      {
        "id": "declared",
        "field": "rule_results.1",
        "text": "Declared hook names (listing.json): SessionStart; SubagentStart; PreToolUse; PostToolUse; PostToolUse; PostToolUse; Stop; SubagentStop; SessionEnd",
        "sources": [
          "LOCK.json",
          "listing.json",
          "commands.json"
        ]
      }
    ]
  },
  "review": {
    "kind": "machine-checked",
    "date": "2026-11-27",
    "reviewed_sha256": "c0c273cdf5599f5d0627126cf6fec4a2da0aae0a516a754032d15c158aeed001",
    "gates": "97194a62857cba6eed5bc97e7e257d88932f670f0cc07023304683a61081c2d4",
    "codex": "dbaf1ec9cf6887d0b271a097849221d8ecb02b4be44f94130fec36569466a7ee",
    "grok": "eb94e9e58f11a5edb04c0793cf15759683d27ce6c7c462396e5d0e9f3d83d3dd",
    "summary": "Deterministic gates passed; every claim rebuilt from evidence with a reviewed template; Grok reported no standing refutation."
  }
}
