(agentId?: AgentId)
| 121 | * For subagents (agentId provided), returns {planSlug}-agent-{agentId}.md |
| 122 | */ |
| 123 | export function getPlanFilePath(agentId?: AgentId): string { |
| 124 | const planSlug = getPlanSlug(getSessionId()) |
| 125 | |
| 126 | // Main conversation: simple filename with word slug |
| 127 | if (!agentId) { |
| 128 | return join(getPlansDirectory(), `${planSlug}.md`) |
| 129 | } |
| 130 | |
| 131 | // Subagents: include agent ID |
| 132 | return join(getPlansDirectory(), `${planSlug}-agent-${agentId}.md`) |
| 133 | } |
| 134 | |
| 135 | /** |
| 136 | * Get the plan content for a session |
no test coverage detected