deepseek-harness/docs
Tianyi Cui c658f4d155 fix(hooks): address Codex review — tighten codec to the reference schemas, preserve stdout
Codex's PR-E review found three protocol-fidelity blockers + two doc gaps, all
verified against ~/repos/refs:

- (A) Top-level `decision` accepted allow/deny/ask, but both reference schemas
  reserve those for hookSpecificOutput.permissionDecision — the legacy top-level
  decision is approve/block ONLY. Split topLevelDecisionOf (approve/block) from
  permissionDecisionOf (allow/deny/ask), so an out-of-band {"decision":"deny"} is
  now invalid and ignored instead of becoming a real blocking decision.
- (A) hookSpecificOutput was parsed without its hookEventName discriminator.
  HookOutput now surfaces hookEventName so a bridge can discard a block whose
  claimed event doesn't match the firing one (the schemas key the block by event).
- (A) runHook discarded raw stdout. HookOutput now carries `stdout` (trimmed,
  verbatim) so a bridge can reproduce CC's plain-stdout rendering / Codex's
  plain-stdout-as-additionalContext behavior.
- (B) hook/* SessionEventMap variants were only named in prose; added a payload/role
  table to core-data-structures/session.md (a maintained catalog surface).
- (B) Removed PR-stack-position references (PR-F / "future bridge packages") from a
  test comment and the RFC, per the current-state-wording rule.

New codec tests: top-level allow/deny/ask invalid+ignored, hookEventName capture,
raw stdout preserved on plain + JSON + empty stdout. 51 tests, per-file 100%.
2026-07-01 01:12:04 +08:00
..
cookbook fix(events): address Codex review — protect post-execute result, purge stale tools/execute refs 2026-06-30 20:25:30 +08:00
cordis-catalog feat(subagent): enrich subagent/start + subagent/end lifecycle events (observe-only) 2026-06-30 21:29:08 +08:00
core-data-structures fix(hooks): address Codex review — tighten codec to the reference schemas, preserve stdout 2026-07-01 01:12:04 +08:00
postmortem Fix doc cross-links for the hierarchy; add package-path + shape gates 2026-06-20 23:12:14 +08:00
rfc fix(hooks): address Codex review — tighten codec to the reference schemas, preserve stdout 2026-07-01 01:12:04 +08:00
AGENTS.md docs(rfc): classify RFCs by kind via path-encoded subdirectories 2026-06-20 22:29:45 +08:00
architecture.md feat(events): interception seams — the typed-Decision surface for hooks 2026-06-30 17:11:18 +08:00
development.md docs: sync development CI gate docs 2026-06-22 12:54:11 +08:00
module-graph.md feat(hooks): dsh-hook-protocol — shared Claude Code / Codex hook wire-protocol core 2026-07-01 00:41:53 +08:00