# pi-autocontext-sports boundaries

This Pi package wraps `sports-impact-core` with a consolidated `sports_impact` tool. It includes package-local boundary guidance so npm/Pi users can see the contract without cloning the full repository. The canonical repository contract is `docs/BOUNDARIES.md` at <https://github.com/greyhaven-ai/sports-impact-core/blob/main/docs/BOUNDARIES.md>.

The machine-readable external handoff contract is shipped in this package at `schemas/game-footage-external-handoff.schema.json` and mirrored from `sports-impact-core`.

## Included scope

- Pi-assisted setup and reporting for deterministic NBA injury, trade, trade-feasibility, backtest, calibration, fixture-quality, and game-footage artifact analysis.
- Tool actions that validate, analyze, normalize, visualize, audit, gate, and generate downstream CI adoption plans for precomputed court-coordinate tracking/detection outputs and related JSON/CSV artifacts.
- Prompt and skill guidance that keeps numeric projections, salary/apron feasibility checks, and required financial source/license provenance gates in deterministic package code rather than hidden LLM arithmetic.

## Not included

- No raw video inference.
- No object detection.
- No segmentation.
- No homography estimation.
- No jersey OCR.
- No betting/gambling recommendations.
- No medical advice, diagnosis, or guaranteed-performance claims.
- No legal advice or authoritative CBA rulings; feasibility checks are deterministic preflights controlled by explicit rule-profile inputs.
- No hidden LLM arithmetic for numeric projections.

## External handoff

Use `sports_impact` game-footage actions only after external systems have produced precomputed court-coordinate tracking/detection outputs or pixel-coordinate exports with explicit scale metadata and source-system provenance. The `validate_game_footage_external_handoff` action reports schema/version, required metadata, source-system provenance, pixel-scale, raw-video boundary, bbox format, coordinate completeness, detection completeness, and confidence checks without running raw CV; `normalize_external_handoff_game_footage` then converts valid handoffs into `game-footage-analysis-input/v1` for existing analysis workflows; fixture-pack manifests can use `files.externalHandoffInput` and `normalization.adapter: "external_handoff"` so `audit_game_footage_fixture_pack` records validation evidence, input hashes, normalized-output comparisons, and rerun drift checks, while `gate_game_footage_external_handoff_fixture_pack` adds a hard CI gate for validation pass, source-system provenance, raw-video boundary pass, bbox format alignment, and normalized-input matching. Use `gate_game_footage_external_handoff_invalid_fixtures` for manifest-backed negative coverage, `generate_game_footage_external_handoff_gate_ci` to emit downstream GitHub Actions YAML that runs both gates together, `verify_game_footage_external_handoff_gate_ci` to verify adopted YAML still matches the deterministic generator, `verify_game_footage_external_handoff_gate_ci_registry` to verify registries of downstream adopted workflows across projects, and `gate_game_footage_external_handoff_gate_ci_registry` to enforce required-project, package-version, command-coverage, YAML-match, valid+invalid fixture-gate, boundary, and optional drift policy over registry reports. Use `generate_game_footage_external_handoff_gate_ci_registry_gate` to emit registry-gate CI YAML, `verify_game_footage_external_handoff_gate_ci_registry_gate` to verify adopted registry-gate CI YAML still matches the deterministic generator, `verify_game_footage_external_handoff_gate_ci_registry_gate_registry` to verify registries of downstream registry-gate CI adoptions, and `gate_game_footage_external_handoff_gate_ci_registry_gate_registry` to enforce required-project, minimum-package-version, command-coverage, YAML-match, previous-registry, and optional drift policy over those registry reports. Use `generate_game_footage_external_handoff_gate_ci_registry_gate_registry_gate` / `verify_game_footage_external_handoff_gate_ci_registry_gate_registry_gate` to emit and verify downstream CI YAML for that verifier+gate pair, and `verify_game_footage_external_handoff_gate_ci_registry_gate_registry_gate_registry` to verify registries of downstream adoption for that generated workflow. The Pi prompt may explain assumptions and caveats, but it must not claim raw CV, betting/gambling, medical, or guaranteed-performance capabilities.
