Repository navigation
feat(cli): add command 'llm svc model-configs' to list builtin/custom… - #318
Merged
Merged
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces the kubectl rbg llm svc model-configs command to list available model configurations and refactors the model loading logic to support mode-level merging between built-in and user-defined configurations. Feedback identifies a bug in the mode merging logic where duplicates within the same file are not correctly handled, suggests validating the --output flag, recommends sorting modes for deterministic output, and points out a shallow copy issue with the Resources map in the configuration loader.
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.
Motivation
Previously, users had no way to discover which model IDs and run modes were available before running
kubectl rbg llm svc run. When a user-defined model config overlapped with a built-in one, the entire built-in model was silently replaced (model-level merge), causing loss of non-overridden modes. This PR addresses both issues by:Modifications
New Command:
llm svc model-configsMODEL ID,MODE,DESCRIPTION.-o wideshows additional columns:ENGINE,SOURCE.Documentation
cmd/cli/README.mdanddoc/cli/kubectl-rbg-llm-svc.mdwith:llm svc model-configscommand description, flags, and examples.model-configshelps discover deployable models beforellm svc run.Tests
model_config_test.goassertions to reflect the new mode-level merge behavior:go test ./cmd/cli/...passes.Files Changed
cmd/cli/cmd/llm/svc/model_configs.go(new)cmd/cli/cmd/llm/svc/run/model_config.gocmd/cli/cmd/llm/svc/run/model_config_test.gocmd/cli/cmd/llm/svc/svc.gocmd/cli/README.mddoc/cli/kubectl-rbg-llm-svc.md