Repository navigation
air: add a hidden air serve command - #7954
Draft
erarpitagarwal wants to merge 1 commit into
Draft
erarpitagarwal wants to merge 1 commit into
erarpitagarwal wants to merge 1 commit into
Conversation
air serve serves a registered Unity Catalog model version on a serving endpoint, from a YAML file (-f) or flags. It reads the version's MLmodel to pick the compute: dedicated inference for a dedicated checkpoint, GPU replicas for a command, CPU for any other model. It returns once the endpoint accepts the update, or with --watch once it's ready. Co-authored-by: Isaac <no-reply@databricks.com>
This was referenced Nov 25, 2026
Collaborator
✅ Integration test reportCommit: 7ba5795
Top 6 slowest tests (at least 2 minutes):
|
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stack (review in order; each PR is based on the one before):
air registercommand #7952:air registerair servecommand #7954:air serve(this PR)Changes
Adds a hidden
databricks air servecommand. It serves a registered Unity Catalog model version on a serving endpoint, using the clients from the previous PR. It takes a YAML file (-f) or its required fields as flags (--uc-model,--endpoint-name); flags override the file.Which version: the newest READY version, or
model_version(--model-version).Compute follows from the version (read from its MLmodel). When the file leaves compute out:
latency_sensitive, 600 model units;GPU_1xA10replica;A compute block of the wrong kind is refused before the endpoint changes.
Replicas are sent as a provisioned concurrency range, 4 per replica. Endpoints on H100 need
min_replicasequal tomax_replicas, because they aren't scaled.Dedicated compute:
modeselects a low-latency or throughput profile. Replicas have no mode yet, so it's refused for any other version rather than ignored.min_unitsmust equalmax_units, andreservation_termis refused.Waiting: it returns once the endpoint accepts the create or update;
--watchwaits until it's ready. It prints the URL to query, which is the audio route for an audio task. Ctrl-C or--timeoutbefore the endpoint changes says nothing was changed; after, it prints the command that continues.The endpoint config is replaced, not merged. Environment variables aren't set yet (TODO), so an update clears any the endpoint has.
Also:
--dry-run,--override,-h config.<field>,--timeoutand-o json, as forair register.Why
Last of four PRs. Registering and serving are separate commands, so a version can be registered once and served on several endpoints, or re-served with new compute without registering again. The command stays hidden, with no changelog entry, until the server APIs are on everywhere.
Tests
go test ./cmd/air/,go vetandgolangci-lint(0 issues) pass. New tests cover the schema (defaults, partial blocks, refused fields, flags over the file), each kind's defaults, compute of the wrong kind, version selection, serving with and without--watch, JSON output and field help.air servewith only the model and endpoint picked the newest READY version, read its MLmodel, created an endpoint with oneGPU_1xA10replica, and returned while it updated; the endpoint was then deleted. A dedicated checkpoint hasn't been served from this revision yet.This pull request and its description were written by Isaac.