Skip to content

[AutoDeploy] Improved config deepmerge handling - #82

Merged
lucaslie merged 1 commit into
feat/ad-2025-07-07from
ll/config_deepmerging
Jul 15, 2025
Merged

[AutoDeploy] Improved config deepmerge handling#82
lucaslie merged 1 commit into
feat/ad-2025-07-07from
ll/config_deepmerging

Conversation

@lucaslie

Copy link
Copy Markdown

Better handling of deepmerging nested configs/dictionaries from various config sources in the new config system.

Please check out the updated README section for more details on the next iteration of providing AutoDeploy configurability.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR replaces the previous Pydantic-based deep-update approach with an OmegaConf-backed deep merge utility, refactors several settings sources and factory classes to use the new helper, and expands example scripts and documentation to showcase advanced CLI and YAML configuration.

  • Introduces deep_merge_dicts using OmegaConf for recursive merging.
  • Refactors DynamicYamlWithDeepMergeSettingsSource and settings classes to leverage the new merge logic.
  • Updates model factories, example scripts, and README with improved defaults, CLI dot notation, and YAML examples.

Reviewed Changes

Copilot reviewed 9 out of 10 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
tensorrt_llm/_torch/auto_deploy/utils/_config.py Added deep_merge_dicts and refactored YAML source to merge configs via OmegaConf.
tensorrt_llm/_torch/auto_deploy/models/hf.py Reworked tokenizer/model default handling to use deep_merge_dicts.
tensorrt_llm/_torch/auto_deploy/models/factory.py Simplified the register method signature.
tensorrt_llm/_torch/auto_deploy/llm_args.py Migrated to Pydantic v2 settings mixin, added CLI extra-args handling.
tensorrt_llm/_torch/auto_deploy/config/default.yaml Added placeholder default YAML config.
setup.py Included the new YAML config files in package data.
examples/auto_deploy/build_and_run_ad.py Updated example script to use OmegaConf merging and extended CLI features.
examples/auto_deploy/README.md Expanded documentation with detailed CLI/YAML configuration examples.
Comments suppressed due to low confidence (1)

tensorrt_llm/_torch/auto_deploy/config/default.yaml:2

  • [nitpick] The default config file is empty but the docs reference default transform settings. Consider populating this file with the baseline defaults or clarifying that no defaults are needed.
{}

Comment thread tensorrt_llm/_torch/auto_deploy/models/hf.py
Comment thread setup.py
Comment thread tensorrt_llm/_torch/auto_deploy/utils/_config.py Outdated
@lucaslie
lucaslie force-pushed the ll/config_deepmerging branch 2 times, most recently from a6988cc to f0e9c58 Compare July 11, 2025 18:20
Comment thread tensorrt_llm/_torch/auto_deploy/config/default.yaml
Comment thread tensorrt_llm/_torch/auto_deploy/models/hf.py
Comment thread examples/auto_deploy/README.md
@lucaslie
lucaslie requested a review from nvchenghaoz July 11, 2025 18:35
Comment thread examples/auto_deploy/README.md Outdated
Comment thread examples/auto_deploy/README.md
Comment thread examples/auto_deploy/README.md
Comment thread examples/auto_deploy/README.md
@lucaslie
lucaslie force-pushed the ll/config_deepmerging branch from f0e9c58 to 1bb0090 Compare July 14, 2025 18:35
Signed-off-by: Lucas Liebenwein <11156568+lucaslie@users.noreply.github.com>
@lucaslie
lucaslie force-pushed the ll/config_deepmerging branch from 1bb0090 to f4cd863 Compare July 15, 2025 19:16
@lucaslie
lucaslie merged commit 58b8f34 into feat/ad-2025-07-07 Jul 15, 2025
1 check passed
@lucaslie
lucaslie deleted the ll/config_deepmerging branch July 15, 2025 19:25
@lucaslie
lucaslie restored the ll/config_deepmerging branch July 15, 2025 19:25
lucaslie added a commit that referenced this pull request Jul 18, 2025
Signed-off-by: Lucas Liebenwein <11156568+lucaslie@users.noreply.github.com>
lucaslie added a commit that referenced this pull request Jul 21, 2025
Signed-off-by: Lucas Liebenwein <11156568+lucaslie@users.noreply.github.com>
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.

4 participants