From 05a60660abaf3dd3bcbe44c03aaed4873d44e6fc Mon Sep 17 00:00:00 2001 From: Cameron Pfiffer Date: Thu, 5 Mar 2026 17:43:26 -0800 Subject: [PATCH] feat: enforce strict margin annotation requirement on dispatch --- src/void_tools/cli.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/void_tools/cli.py b/src/void_tools/cli.py index c1e4734..457a5e7 100644 --- a/src/void_tools/cli.py +++ b/src/void_tools/cli.py @@ -290,8 +290,8 @@ def cmd_dispatch(args): if ann and first_post_uri: create_annotation(client, first_post_uri, ann.get("text"), ann.get("motivation", "commenting"), ann.get("quote")) elif first_post_uri: - auto_text = "Automated Index: Autonomous agent output generated." - create_annotation(client, first_post_uri, auto_text, "describing") + print(f"Error: Mandatory annotation block missing for post {first_post_uri}. Aborting dispatch to enforce compliance.", file=sys.stderr) + sys.exit(1) elif action_type == "reply": target_id = act.get("target_id") @@ -324,9 +324,8 @@ def cmd_dispatch(args): if ann and target_uri: create_annotation(client, target_uri, ann.get("text"), ann.get("motivation", "commenting"), ann.get("quote")) elif target_uri: - # Auto-generate an annotation if one isn't explicitly provided, as per admin preference - auto_text = f"Automated Index: Interaction logged with {target_uri.split('/')[2]}." - create_annotation(client, target_uri, auto_text, "describing") + print(f"Error: Mandatory annotation block missing for reply to {target_uri}. Aborting dispatch to enforce compliance.", file=sys.stderr) + sys.exit(1) except Exception as e: print(f"Error replying to {target_uri}: {e}") -- 2.51.2