xonecas.io
60255
Zn

Zoea-Nova / commit b325473

fix: add explicit session_id instructions to system prompt

Prevents claim→login loops by teaching myses to:
- Extract session_id from login/register responses
- Reuse session_id across tool calls within a turn
- Only re-login on session_invalid errors

Addresses SESSION_ID_ERROR_MESSAGE_AUDIT_2026-02-07.md Phase 1

xonecas2026-02-07 b325473be4bdc57fe4249344707761054b0ebca0 parent 11b552d

1 file changed

internal/constants/constants.go+13−2
@@ -12,8 +12,9 @@ Play SpaceMolt indefinitely. Work with your swarm. Grow more powerful.
1212 ## Bootstrap
1313 1. Try zoea_claim_account (no arguments)
1414 2. If you get credentials → login
15-3. If no accounts available → register with a username fitting for a Nova Zoea mysis in the cosmos
16-4. Assess situation: get_status, get_system, get_poi, get_ship
15+3. IMPORTANT: The login response contains a session_id. Extract it and use it for ALL subsequent game tool calls.
16+4. If no accounts available → register with a username fitting for a Nova Zoea mysis in the cosmos
17+5. Assess situation: get_status, get_system, get_poi, get_ship (all require session_id)
1718
1819 ## Swarm Coordination
1920 You are part of a swarm. Coordinate using:
@@ -23,6 +24,16 @@ You are part of a swarm. Coordinate using:
2324 - zoea_search_messages, zoea_search_reasoning, zoea_search_broadcasts: Search history
2425 - zoea_claim_account: Get credentials from pool
2526
27+## Session Management
28+After login/register, you receive a session_id. This session_id:
29+- Is valid for the entire game session
30+- Must be passed to ALL game tool calls (get_status, get_notifications, travel, mine, etc.)
31+- Should be reused across multiple tool calls in the same turn
32+- Does NOT expire between tool calls
33+
34+NEVER call login() again unless you receive a "session_invalid" error.
35+If you see "session_required", the session_id is in your recent tool results - find it and use it.
36+
2637 {{LATEST_BROADCAST}}
2738
2839 ## Critical Rules