Generate a list of NIM models in pre-commit#1982
Conversation
replace print statements with logging statements Move the dry-run code to it's own method Signed-off-by: David Gardner <dagardner@nvidia.com>
Signed-off-by: David Gardner <dagardner@nvidia.com>
Signed-off-by: David Gardner <dagardner@nvidia.com>
Signed-off-by: David Gardner <dagardner@nvidia.com>
Signed-off-by: David Gardner <dagardner@nvidia.com>
Signed-off-by: David Gardner <dagardner@nvidia.com>
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
Signed-off-by: David Gardner <dagardner@nvidia.com>
Signed-off-by: David Gardner <dagardner@nvidia.com>
mnajafian-nv
left a comment
There was a problem hiding this comment.
This direction makes sense to me. A checked-in generated manifest is a good way to give build.nvidia.com a stable source of truth and help NAT get notified before model removals break examples or docs.
A few things I think we should tighten before this becomes the consumed contract:
- I would keep
ci/.nim_models_used.jsonif build.nvidia.com has already wired to that path. At this point, path stability matters more than renaming. - I like keeping
llmsandembedderssplit. The replacement path and blast radius are different enough that the distinction is useful. - I would align the count field with the downstream contract. The Slack example and Smita’s note mention
num_configs, but the PR currently generatesusage_count. Since the value is counting config files, I think this should benum_configsunless build.nvidia.com explicitly prefersusage_count. - I would add a top-level
schema_versionnow. Once another team is parsing this file, we need a simple way to evolve it without breaking their cron/parser. - I would state the inventory scope explicitly. From the implementation, this appears to cover model references discovered from repo YAML configs, not arbitrary mentions in docs/READMEs. That scope is reasonable, but it should be clear so nobody assumes full documentation coverage.
- The pre-commit hook seems appropriate because it runs in dry-run mode and generates from repo-local files. It should stay deterministic and offline. No build.nvidia.com/NIM service calls in pre-commit.
- I would not require config paths in v1 if build.nvidia.com only needs model/count, but paths would be the next useful field for NAT-side remediation.
Once the file contract is aligned with build.nvidia.com, I’m happy to do a code-level pass.
Description
ci/.nim_models_used.jsonpre-commithookci/scripts/model_health_check.pyto use logging rather than print statementsBy Submitting this PR I confirm: