Skip to content

feat(v2d_challenge): add 5/week quota guard, agent dry-run lock, and participant CI/CD workflow - #214

Open
m0at wants to merge 1 commit into
nvidia-isaac:mainfrom
m0at:feat/v2d-challenge-compliance-cicd
Open

m0at wants to merge 1 commit into
nvidia-isaac:mainfrom
m0at:feat/v2d-challenge-compliance-cicd

Conversation

@m0at

@m0at m0at commented Oct 25, 2026

Copy link
Copy Markdown

Summary

The V2D Challenge submission kit includes skills/v2d-submit/SKILL.md so participants can use coding agents to validate, pack, and submit entries across the 23 metric leaderboards. In practice, teams using autonomous or iterative coding models (Claude Code, Codex, Cursor, etc.) can hit an unintended failure mode due to a mismatch between Kaggle's API limits and the written challenge rules:

  1. Kaggle's 5/day API limit vs. V2D's 5/week rule: Kaggle's competition settings only support a daily cap (5/day), and submit/v2d_submit.py previously queried competition_get_submission_limits(slug).num_allowed_now as a non-blocking warning. Autonomous agents that rely on Kaggle's API response see quota available every day and can submit up to 35 times/week per track before realizing the written rule is 5 submissions per rolling 7-day week (outside the final 3-day unlimited window).
  2. Agent live-upload probing: Coding agents often test whether a CLI command succeeds end-to-end. Without an explicit agent-environment lock in v2d_submit.py, an agent following SKILL.md can trigger live Kaggle uploads during debugging instead of stopping at --dry-run.
  3. Cross-track fan-out & partial-leaderboard retries: Without a declarative track-scope file or receipt check on --only, automated scripts can accidentally submit to tracks a team did not intend to enter (or standalone track_3_mesh), or use --only without a matching prior receipt.

This PR hardens the submission kit and adds a drop-in GitHub Actions CI/CD workflow so participants using coding agents or automated pipelines can validate locally and in CI without risking accidental rule violations.

What This PR Adds

  • Rolling 7-Day (5/Week) Quota Enforcement (tools/compliance_gate.py, submit/v2d_submit.py, tools/preflight.py):
    • Queries both live Kaggle submission history (competition_submissions(slug, page_size=20)) and local *.kaggle-receipt.json / .v2d_submission_ledger.json records over a rolling 7-day window.
    • Hard-blocks uploads when >= 5 submissions have been used in the past 7 days (while automatically permitting the official final 3-day unlimited window 2026-11-01T22:00:00Z to 2026-11-04T22:00:00Z and blocking post-deadline uploads).
    • Blocks duplicate SHA-256 re-uploads so teams do not burn weekly quota on an identical file, and detects cross-leaderboard count divergence across a track's metric competitions.
  • Declared Track Scope (.v2d_policy.json) & Atomic Track Bundles:
    • Lets teams lock their entered tracks via python3 tools/compliance_gate.py init-policy --tracks <track...> (.v2d_policy.json) so scripts/CI cannot upload to unauthorized tracks.
    • Blocks standalone --track track_3_mesh uploads (since Track 3 requires one combined Parquet with automatic .cd-o.parquet extraction).
    • Requires --retry-receipt <receipt.json> when using --only <METRIC>, verifying that the retried file has the exact same SHA-256 as the sibling metrics that succeeded and that the retried metric is in UPLOAD_FAILED state.
  • Autonomous Agent Live-Upload Lock & PreToolUse Hook (tools/agent_submission_guard.py, skills/v2d-submit/SKILL.md):
    • Detects common coding-agent environment markers (CLAUDECODE, CODEX_SANDBOX, CURSOR_TRACE_ID, ANTIGRAVITY_AGENT, AIDER, SWE_AGENT, DEVIN_SESSION, OPENHANDS, V2D_AGENT_MODE) and restricts agent invocations of v2d_submit.py to --dry-run, --check-entry, or --poll-receipt.
    • Requires --confirm-human-upload for interactive human uploads (or manual workflow_dispatch in CI).
    • Includes a standalone PreToolUse hook (tools/agent_submission_guard.py) that participants can attach to their coding agent to block direct kaggle competitions submit or Python SDK upload calls.
  • Offline Provenance & Integrity Audit (tools/compliance_gate.py audit):
    • Verifies non-placeholder code_commit_url provenance (rejecting upstream nvidia-isaac/video_to_data or template commit SHAs), non-synthetic checkpoint_sha256 digests, Track 1 kinematic non-degeneracy, and < 0.1 mm (1e-4 m) mesh noise / near-duplicate geometry checks in v2dlb/mesh_quality.py.
  • Drop-In Participant CI/CD Workflow (tools/v2d_compliance/participant_ci_template.yml / .github/workflows/v2d_submission_ci.yml in kit):
    • Runs offline schema, provenance, and quota checks on every push and pull_request without Kaggle credentials, and isolates live Kaggle uploads behind a manual workflow_dispatch job gated by a protected GitHub Environment.

Compatibility

  • 100% compatible with live Kaggle host scorers: Does not alter any submission column schemas, sample row IDs, or the released eval_script_sha256 / eval_code_sha256 digests.
  • Synchronized kit archive: Updates docs/v2d_challenge/assets/v2d_submission_kit.zip and KIT_MANIFEST.json, verified byte-for-byte against tools/v2d_compliance/ in test_compliance_gate.py.

Testing

python3 -m unittest -v tools.v2d_compliance.tests.test_compliance_gate
python3 .github/scripts/check_root_files.py
python3 .github/scripts/agent_context_check.py

All 15 unit tests and repository hygiene checks pass.

…participant CI/CD workflow

Signed-off-by: m0at <47344131+m0at@users.noreply.github.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant