export function renderAgentThreadContext(input) {
    const helpers = input.helpers ?? [];
    const runningHelpers = helpers.filter((helper) => helper.status === "running" || helper.status === "queued");
    const recentHelpers = helpers.slice(-5);
    return `<system-reminder>
[SEED agent-thread context]
Thread: ${input.thread.thread_id}
Agent: ${input.thread.agent_name}
Role: ${input.thread.role_label ?? input.thread.role}
Parent: ${input.thread.parent_thread_id ?? "none"}
Status: ${input.thread.status}
OpenCode session: ${input.thread.opencode_session_id ?? "none"}
Background: ${input.thread.background_id ?? "none"}
Allowed tools: ${input.thread.allowed_tools.join(", ") || "none"}
Denied tools: ${input.thread.denied_tools.join(", ") || "none"}
Allowed skills: ${input.thread.allowed_skills.join(", ") || "none"}
Allowed MCPs: ${input.thread.allowed_mcps.join(", ") || "none"}
Read paths: ${input.thread.read_paths.join(", ") || "none"}
Write paths: ${input.thread.write_paths.join(", ") || "none"}
Helper budget: running ${input.thread.helper_counts.running}/${input.thread.helper_limits.max_parallel_helpers}, completed ${input.thread.helper_counts.completed}, failed ${input.thread.helper_counts.failed}
Unread messages: ${input.unreadMessageCount ?? 0}
Open assigned tasks: ${input.openTaskIds?.join(", ") || "none"}
Latest memory: ${input.latestMemory ?? input.thread.memory_ref ?? "none"}
Recent helpers:
${recentHelpers.length ? recentHelpers.map((helper) => `- ${helper.helper_id} ${helper.status} -> ${helper.target_agent} session:${helper.child_session_id ?? "none"} background:${helper.background_id ?? "none"} prompt:${helper.prompt_ref}`).join("\n") : "- none"}

Act as this durable agent-thread. Use helper child sessions only within your spawn policy and helper budget, and summarize helper results back to your parent thread.
${runningHelpers.length ? `Running helper ids: ${runningHelpers.map((helper) => helper.helper_id).join(", ")}` : ""}
</system-reminder>`;
}
//# sourceMappingURL=render.js.map