# @v2/sophia-release-candidate-ingestion

`@v2/sophia-release-candidate-ingestion` is the V2 cook-time bridge that sends
the frame-data spreadsheet and release-candidate patch-notes corpus through
`@sophia/ingestion` before a release-candidate cook starts.

The bridge is intentionally off rollback authority. It produces a manifest that
records the Sophia source package, cook hook, release-candidate id, cook
platform, content hashes, stage summaries, and quality-floor status for the two
required documents:

- `V2/balance/data/frame-data.csv`
- `V2/balance/patch-notes/*.md`

## Cook Hook

`V2/ue/Tools/run-sophia-release-candidate-ingest.py` is called by BuildGraph and
the `cook-all` wrappers before `Cook` or `BuildCookRun` executes. The cook fails
if the spreadsheet or patch notes do not parse, a patch note references an
unknown `move_id`, or the underlying `@sophia/ingestion` quality floor is not
met.

The generated manifest defaults to the cook archive under
`Sophia/<platform>/release-candidate-ingestion.json` for the wrappers and
`Sophia/release-candidate-ingestion.json` for BuildGraph.

## Local Use

```bash
pnpm exec tsx apps/v2/sophia-release-candidate-ingestion/src/cli.ts \
  --release-candidate-id rc-2026.05.13 \
  --platform Win64 \
  --frame-data V2/balance/data/frame-data.csv \
  --patch-notes V2/balance/patch-notes \
  --out /tmp/v2-sophia-release-candidate-ingestion.json
```

## Contract

- Source of truth: `@sophia/ingestion`
- V2 bridge package: `@v2/sophia-release-candidate-ingestion`
- Cook hook: `SophiaReleaseCandidateIngestion`
- Inputs: frame-data CSV plus patch-note Markdown corpus
- Required cadence: every release-candidate cook
- Rollback authority: `mayInfluenceRollback: false`
