# Headless Mode

Load this file when xiaoma-sprint-planning is invoked headless (no interactive user — e.g. by auto-prd-to-stories step-03, auto-full-pipeline step-03, or auto-requirements-pipeline). Follow it for the whole run.

## Detection

Headless mode is in effect when any of the following is true:

- the invoking caller sets a `headless: true` flag (or equivalent argument the harness exposes),
- the invocation is from another skill or a non-interactive runner (no TTY, no user message stream),
- `{workflow.activation_steps_prepend}` includes an entry that explicitly declares headless,
- the first message comes from an automation context that pre-supplies the inputs and asks for the sprint-status path back.

When ambiguous, default to interactive.

## Inputs the caller is expected to provide

- the `epics.md` path (or a workspace containing one / multiple `epic-N.md` files) — the input the sprint plan is built from.

## General

Do not ask, do not greet. Walk every step to completion; auto-proceed through any confirmation or completion-summary prompt — never halt for input.

Produce `sprint-status.yaml` with a `development_status:` section listing every story key (`{epic}-{story}-{slug}`), each epic marker (`epic-N`), and each retrospective (`epic-N-retrospective: optional`), in `epic → its stories → its retrospective` order, all stories defaulting to `backlog`. Apply the **Story ID Conversion Rules** in the SKILL — including the non-ASCII / 中文 → stable ASCII-slug strategy — deterministically, so the same title always yields the same key. Preserve the original title as a trailing `# title: <…>` comment when it was slugged.

## Completion

End by writing `sprint-status.yaml` to the implementation-artifacts location and returning its path.
