OmniNode-ai

close-day

Auto-generates a ModelDayClose YAML from today's GitHub PRs, git activity, and invariant probes

OmniNode-ai 2 3 Updated 3mo ago

Resources

2
GitHub

Install

npx skillscat add omninode-ai/omniclaude/close-day

Install via the SkillsCat registry.

SKILL.md

close-day Skill

CDQA-04 / OMN-2981 — Auto-generates a ModelDayClose YAML from today's GitHub PRs,
git activity, and invariant probes.

Overview

close-day closes out a development day by:

  1. Pulling all merged PRs across the OmniNode-ai GitHub org for today
  2. Fetching the active-sprint Linear plan (OMN-XXXX tickets)
  3. Building actual_by_repo grouped by repo with OMN-XXXX references
  4. Detecting scope drift: PRs with no matching OMN-XXXX ref → drift_detected entry
  5. Running scripts/check_arch_invariants.py (shared with CDQA-07 / OMN-2977) to probe reducers/orchestrators
  6. Detecting golden-path progress by reading emitted_at from ~/.claude/golden-path/TODAY/ artifact JSON files
  7. Setting unknown statuses to "unknown" and adding entries to corrections_for_tomorrow
  8. Validating the assembled dict against ModelDayClose.model_validate() (fails loudly on schema mismatch)
  9. Writing to $ONEX_CC_REPO_PATH/drift/day_close/YYYY-MM-DD.yaml or printing with a warning banner

Quick Start

/close-day

Or with explicit date:

/close-day --date 2026-02-28

ONEX_CC_REPO_PATH Behavior

ONEX_CC_REPO_PATH Behavior
Not set Generates YAML, prints with ⚠️ ONEX_CC_REPO_PATH not set — commit manually banner. File is NOT written.
Set, path exists Writes to $ONEX_CC_REPO_PATH/drift/day_close/YYYY-MM-DD.yaml
Set, path missing Prints error + falls back to print-with-banner

Invariant Probes

Uses scripts/check_arch_invariants.py from CDQA-07 (OMN-2977). Does NOT reimplement the check.

  • Probes reducers_pure and orchestrators_no_io across all repos in omni_home
  • If the script is missing or a repo is not checked out → status: unknown + correction entry
  • effects_do_io_only → always unknown (not checkable via AST scan)

Golden Path Detection

Reads ~/.claude/golden-path/YYYY-MM-DD/*.json for artifacts where:

  • artifact.status == "pass" AND
  • artifact.emitted_at starts with today's ISO date

Does NOT use directory creation time or directory name alone.

Drift Detection

PRs with no OMN-XXXX ref in title or branch name → drift_detected entry with category: scope.

Unknown Handling

Any probe that cannot determine status → status: unknown + actionable entry in corrections_for_tomorrow.

Files

Path Purpose
plugins/onex/skills/close-day/SKILL.md This file (descriptive)
plugins/onex/skills/close-day/prompt.md Authoritative behavior specification
plugins/onex/skills/close-day/close_day.py Core logic module (importable for tests)
tests/unit/skills/test_close_day.py Unit test suite (30 tests)

Dependencies

  • onex_change_control package: ModelDayClose, ModelTicketContract
  • scripts/check_arch_invariants.py (CDQA-07): AST-based invariant scanner
  • gh CLI: for fetching GitHub PRs
  • Linear MCP: for fetching sprint plan (optional)
  • pyyaml: for YAML serialization

Definition of Done

  • All unit tests pass (30 tests)
  • Uses check_arch_invariants.py from CDQA-07 (not a separate implementation)
  • Golden path detection uses emitted_at field in artifact JSON (not dir creation time)
  • Unknown invariants → status: unknown + entry in corrections_for_tomorrow
  • Output validates against ModelDayClose.model_validate() before writing/printing
  • ONEX_CC_REPO_PATH not set → banner printed, file not written