fix: add turn check debug logs + one-time prompt injection #6

Merged
zhi merged 1 commits from fix/turn-check-debug-and-onetime-inject into feat/turn-based-speaking 2026-02-28 19:27:59 +00:00

1 Commits

Author SHA1 Message Date
zhi
f03d32e15f fix: add turn check debug logs + one-time prompt injection
1. Turn check improvements:
   - Add debug logs for ctx.agentId, resolved accountId, turnOrder length
   - Fallback to ctx.accountId if resolveAccountId fails
   - Add resolveDiscordUserId debug logs for handoff troubleshooting

2. One-time prompt injection:
   - Add sessionInjected Set to track injected sessions
   - Use prependContext (not systemPrompt) but only inject once per session
   - Skip subsequent injections with debug log
2026-02-28 19:27:39 +00:00