/** * Staging a definition's instructions to a file, because herdr cannot carry them in argv. * * Split out of `src/executors/run-herdr.ts` at the 400-line ceiling. A real seam rather than an arbitrary cut: this is * the one place that works around a **herdr encoding limit**, and it is the only part of the herdr path that * touches the filesystem. `run-herdr.ts` starts and reaps agents; this prepares one argument. */ /** * Move a multi-line `--append-system-prompt` out of argv, because herdr cannot encode it. * * **Measured.** `herdr agent start` types the argv into the pane's shell, so a value containing newlines * is rejected outright: `invalid_agent_argument — agent arguments cannot be encoded safely for the target * shell`. A definition's `SKILL.md` body is always multi-line, so every `delegate({agent})` spawn would * fail on this path. * * pi accepts a **file path** there as readily as literal text (`resolvePromptInput` + `existsSync` in * `dist/core/resource-loader.js`), so the fix is to write the body to a temp file and pass its path — one * short, shell-safe argument. * * The split lives here rather than in `planSpawn` because the constraint is **herdr's**, not pi's: the * direct executor passes the same text inline with no trouble, and a plan builder that pre-emptively wrote * temp files for everybody would be paying one executor's tax on both paths. */ export declare function splitSystemPrompt(args: string[]): { args: string[]; systemPrompts: string[]; }; /** * Move a multi-line system prompt into a temp file and return argv pointing at it. * * Returns the directory so the caller can remove it — and **every** early return on the herdr path must, because * nothing else can: a reviewer measured a permanent `/tmp/grants-herdr-*` per failed `tab create`, unreachable by * either pane sweep because the pane it belonged to never existed. */ export declare function stageSystemPrompt(args: string[]): Promise<{ args: string[]; promptDir?: string; error?: string; }>; //# sourceMappingURL=herdr-stage.d.ts.map