Skip to content

feat(api): add GPU compute fraction parsing and validation - #33

Open
gaoyk19 wants to merge 1 commit into
kai-scheduler:mainfrom
gaoyk19:feat/gpu-compute-fractions-api
Open

gaoyk19 wants to merge 1 commit into
kai-scheduler:mainfrom
gaoyk19:feat/gpu-compute-fractions-api

Conversation

@gaoyk19

@gaoyk19 gaoyk19 commented Nov 9, 2026

Copy link
Copy Markdown

Description

Add GPU compute fraction support to the shared API utilities:

  • Add per-container compute share annotation keys and node Ready reason constants (MemoryOnly and Full).
  • Parse compute shares as fixed-point integers in units of 1e-5.
  • Validate value range and precision, mutually exclusive policies, required memory fractions, supported compute modes, and container consistency.
  • Reject conflicting compute policies during extraction and ignore runtime .gpu-compute.applied annotations when resolving the request container.
  • Add unit and regression tests for parsing and validation.

Related Issues

Fixes kai-scheduler/KAI-Scheduler#2584

Checklist

  • Self-reviewed
  • Added/updated tests (if needed)
  • Updated documentation (if needed)
  • Added a changelog fragment via make changelog (or applied the skip-changelog label). Do not edit CHANGELOG.md directly — pending fragments are folded into it at release time.

Breaking Changes

None.

Additional Notes

Validation passed:

  • go test ./utilities/resources
  • make validate
  • git diff --check

A new API tag must be published after merging so KAI Scheduler can consume these changes.

Add compute share annotations, fixed-point parsing, shared validation, and node Ready reason constants.

Reject conflicting compute policies during extraction and exclude applied shares from request container resolution. Cover parsing and validation with regression tests.
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.

Compute fractions: API keys, parsing, validation and Ready reasons

1 participant