style(no-slop): remove every em-dash + banned words across all modules + capstone
Apply the no-ai-slop standard (now binding in AGENTS.md): the em-dash character is banned outright (restructured, not blind-replaced), plus the banned word/phrase list (delve, leverage, robust, seamless, truly, unlock, etc.). 0 em-dashes remain in modules + capstone; the only "robust" left is the planted M10 ai-change.patch trap. Module H1 titles use a colon separator. All deliberate teaching devices preserved; labs compile/parse (py/sh/yaml/json); no junk. AGENTS.md updated with the hard no-slop rules. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TfzV5QvtPDz8LJS3Pu5VLT
This commit is contained in:
@@ -1,14 +1,14 @@
|
||||
"""Assistive issue-triage agent — local simulation of a triage bot.
|
||||
"""Assistive issue-triage agent: local simulation of a triage bot.
|
||||
|
||||
Stands in for a forge-native triage agent (triggered when an issue opens) without a hosted account.
|
||||
It assembles the prompt, then validates and renders the AI's suggestion — and stops at a human
|
||||
It assembles the prompt, then validates and renders the AI's suggestion, and stops at a human
|
||||
confirm. The agent proposes labels and a route; it does not apply them.
|
||||
|
||||
python triage.py prompt # taxonomy + issue -> prompt for the agent
|
||||
python triage.py apply ai-triage.sample.json # validate + render + confirm gate
|
||||
|
||||
The validation step matters: the agent may only use labels that exist in label-taxonomy.md. A
|
||||
hallucinated label is rejected. Stdlib only — no pip install.
|
||||
hallucinated label is rejected. Stdlib only, no pip install.
|
||||
"""
|
||||
|
||||
import argparse
|
||||
@@ -31,7 +31,7 @@ and a rationale for the issue that follows. Return ONLY the JSON object the taxo
|
||||
"""
|
||||
|
||||
# Allowed labels are the backticked `prefix:value` tokens in the taxonomy file. Keeping the source
|
||||
# of truth in the committed markdown — not hardcoded here — is the point.
|
||||
# of truth in the committed markdown (not hardcoded here) is the point.
|
||||
LABEL_RE = re.compile(r"`([a-z]+:[a-z0-9-]+)`")
|
||||
|
||||
|
||||
@@ -75,7 +75,7 @@ def cmd_apply(args: argparse.Namespace) -> int:
|
||||
bogus = [l for l in labels if l not in allowed]
|
||||
if bogus:
|
||||
print("=" * 70)
|
||||
print("REJECTED — the agent suggested labels that aren't in the taxonomy:")
|
||||
print("REJECTED: the agent suggested labels that aren't in the taxonomy:")
|
||||
for l in bogus:
|
||||
print(f" - {l}")
|
||||
print(
|
||||
@@ -85,7 +85,7 @@ def cmd_apply(args: argparse.Namespace) -> int:
|
||||
return 1
|
||||
|
||||
print("=" * 70)
|
||||
print("TRIAGE AGENT — suggestion (advisory only)")
|
||||
print("TRIAGE AGENT: suggestion (advisory only)")
|
||||
print("=" * 70)
|
||||
print(f"\n Labels: {', '.join(labels) or '(none)'}")
|
||||
print(f" Route to: {sug.get('assignee_type', '?')}")
|
||||
@@ -99,7 +99,7 @@ def cmd_apply(args: argparse.Namespace) -> int:
|
||||
" - confirm apply the labels and route as proposed\n"
|
||||
" - edit change a label or the route, then apply\n"
|
||||
" - reject the triage is wrong; do it yourself\n"
|
||||
"\nA wrong label here costs one glance and one click to fix — which is exactly why\n"
|
||||
"\nA wrong label here costs one glance and one click to fix, which is exactly why\n"
|
||||
"triage is the safe place to let an agent in first.\n"
|
||||
)
|
||||
return 0
|
||||
|
||||
Reference in New Issue
Block a user