mirror of
https://github.com/allaunthefox/Research-Stack.git
synced 2026-07-31 03:05:21 +00:00
chore(devin): UserPromptSubmit hook — programming choice flow reminder
Adds .devin/config.json with a UserPromptSubmit hook that fires on every user message and injects the programming choice flow + post-interaction checklist into the agent's context via add_context. .devin/hooks/programming-choice-reminder.sh: Emits a JSON add_context block with the 7-branch decision tree: 1. Admissibility/gating → Lean only 2. Receipt minting / top-level JSON → AVMIsa.Emit only 3. Alignment classification → Lean (RRC.Emit) 4. Raw input features → Python shim OK with constraints 5. Float in compute path → STOP, use Q16_16 6. Promotion in shim space → STOP, not_promoted until Lean gate passes 7. Pure I/O → Python fine, route receipts through AVMIsa.Emit Plus the 4-step post-interaction checklist (AGENTS.md / build / commit / status) Generated with [Devin](https://cli.devin.ai/docs) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
parent
d3e18e88f0
commit
7585388386
2 changed files with 28 additions and 0 deletions
19
.devin/config.json
Normal file
19
.devin/config.json
Normal file
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
// Project config for Research Stack.
|
||||||
|
// Hooks fire on every user message to remind the agent of the programming
|
||||||
|
// choice flow and post-interaction workflow defined in AGENTS.md.
|
||||||
|
"hooks": {
|
||||||
|
"UserPromptSubmit": [
|
||||||
|
{
|
||||||
|
"matcher": "",
|
||||||
|
"hooks": [
|
||||||
|
{
|
||||||
|
"type": "command",
|
||||||
|
"command": "cat '/home/allaun/Research Stack/.devin/hooks/programming-choice-reminder.sh' | bash",
|
||||||
|
"timeout": 5
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
9
.devin/hooks/programming-choice-reminder.sh
Executable file
9
.devin/hooks/programming-choice-reminder.sh
Executable file
|
|
@ -0,0 +1,9 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
# Programming choice flow reminder — injected before every user message.
|
||||||
|
# Full contract lives in AGENTS.md §Post-Interaction Workflow §5.
|
||||||
|
|
||||||
|
cat <<'EOF'
|
||||||
|
{
|
||||||
|
"add_context": "PROGRAMMING CHOICE FLOW (check before writing any new code):\n\n1. Admissibility / gating / routing / alignment decision? → Lean only. No Python equivalent.\n2. Minting a receipt or emitting top-level JSON? → Semantics.AVMIsa.Emit ONLY (sole output boundary).\n3. Classifying rows / computing alignment scores? → Lean (Semantics.RRC.Emit or new Semantics.RRC.* module).\n4. Supplying raw input features (equation text, IDs, weak_axes)? → Python shim OK, but: (a) no admissibility logic, (b) regenerable from source, (c) TODO(lean-port) if portable.\n5. Float arithmetic in a compute path? → STOP. Use Q16_16.ofNat / Q16_16.ofRatio instead.\n6. Advancing promotion status in shim space? → STOP. Always not_promoted until a Lean gate passes.\n7. Pure I/O (read/write JSON, call subprocess, format output)? → Python shim fine; receipt output must route through AVMIsa.Emit.\n\nSummary rule: Lean owns all decisions. Python owns all I/O.\n\nPOST-INTERACTION CHECKLIST (before claiming session complete):\n1. Update nearest AGENTS.md for every touched subtree\n2. lake build Compiler (+ full lake build if Lean files touched)\n3. Commit with explicit file list — never git add .\n4. git status --branch --short --untracked-files=all"
|
||||||
|
}
|
||||||
|
EOF
|
||||||
Loading…
Add table
Reference in a new issue