Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions s05_todo_write/code.py
Original file line number Diff line number Diff line change
Expand Up @@ -232,10 +232,8 @@ def summary_hook(messages: list):
# agent_loop — same as s04 + nag reminder counter
# ═══════════════════════════════════════════════════════════

rounds_since_todo = 0

def agent_loop(messages: list):
global rounds_since_todo
rounds_since_todo = 0
while True:
# s05: nag reminder — inject if model hasn't updated todos for 3 rounds
if rounds_since_todo >= 3 and messages:
Expand Down
4 changes: 1 addition & 3 deletions s06_subagent/code.py
Original file line number Diff line number Diff line change
Expand Up @@ -312,10 +312,8 @@ def summary_hook(messages: list):
# agent_loop — same as s05 + nag reminder, task auto-dispatches
# ═══════════════════════════════════════════════════════════

rounds_since_todo = 0

def agent_loop(messages: list):
global rounds_since_todo
rounds_since_todo = 0
while True:
# s05: nag reminder
if rounds_since_todo >= 3 and messages:
Expand Down
4 changes: 1 addition & 3 deletions s07_skill_loading/code.py
Original file line number Diff line number Diff line change
Expand Up @@ -356,10 +356,8 @@ def summary_hook(messages: list):
# agent_loop — same as s05-s06 + nag reminder
# ═══════════════════════════════════════════════════════════

rounds_since_todo = 0

def agent_loop(messages: list):
global rounds_since_todo
rounds_since_todo = 0
while True:
if rounds_since_todo >= 3 and messages:
messages.append({"role": "user",
Expand Down