Skip to content

[None][doc] AutoDeploy: ad-model-onboard skill updates - #12234

Merged
bmarimuthu-nv merged 2 commits into
NVIDIA:mainfrom
nv-auto-deploy:bala/ad-agent-updates
Mar 16, 2026
Merged

[None][doc] AutoDeploy: ad-model-onboard skill updates#12234
bmarimuthu-nv merged 2 commits into
NVIDIA:mainfrom
nv-auto-deploy:bala/ad-agent-updates

Conversation

@bmarimuthu-nv

@bmarimuthu-nv bmarimuthu-nv commented Mar 16, 2026

Copy link
Copy Markdown
Collaborator

Summary by CodeRabbit

  • Documentation

    • Enhanced debugging and execution workflows for AutoDeploy models with registry-centric approaches
    • Added comprehensive onboarding guide for translating HuggingFace models with phases covering resource gathering, modeling, testing, and deployment
    • Updated review and validation guidelines with expanded multi-modal model support and improved import handling
  • Chores

    • Added multi-agent configuration framework and workflow automation rules

Description

AutoDeploy had a sprint last week where we used the agent to onboard several models. This PR pushes the updated agent skills from the exercise #12209

Test Coverage

PR Checklist

Please review the following before submitting your PR:

  • PR description clearly explains what and why. If using CodeRabbit's summary, please make sure it makes sense.

  • PR Follows TRT-LLM CODING GUIDELINES to the best of your knowledge.

  • Test cases are provided for new code paths (see test instructions)

  • Any new dependencies have been scanned for license and vulnerabilities

  • CODEOWNERS updated if ownership changes

  • Documentation updated as needed

  • Update tava architecture diagram if there is a significant design change in PR.

  • The reviewers assigned automatically/manually are appropriate for the PR.

  • Please check this after reviewing the above items as appropriate for this PR.

GitHub Bot Help

To see a list of available CI bot commands, please comment /bot help.

Signed-off-by: Balamurugan Marimuthu <246387390+bmarimuthu-nv@users.noreply.github.com>
@bmarimuthu-nv
bmarimuthu-nv marked this pull request as ready for review March 16, 2026 04:21
@coderabbitai

coderabbitai Bot commented Mar 16, 2026

Copy link
Copy Markdown
Contributor
📝 Walkthrough

Walkthrough

The changes introduce a comprehensive multi-agent automation framework for AutoDeploy model onboarding workflows. New configuration files enable coordinated debugging, code review, model execution, and progress tracking agents. Documentation is expanded across agent responsibilities, skill phases, and registry-based operational procedures, establishing structured workflows for model deployment with emphasis on canonical operations, registry-centric configuration, and hierarchical validation.

Changes

Cohort / File(s) Summary
Multi-Agent Framework Configuration
.codex/config.toml, .codex/AGENTS.md
Introduces multi-agent system architecture with feature toggles, concurrency settings (max_threads: 6, max_depth: 1), and high-level editing guidelines for agent workflow development.
Agent Configurations
.codex/agents/ad_debug_agent.toml, .codex/agents/ad_onboard_reviewer.toml, .codex/agents/ad_run_agent.toml, .codex/agents/onboard_update_reviewer.toml
Four new TOML agent config files defining metadata, sandbox modes, and detailed developer instructions for debugging, reviewing, running, and tracking model onboarding with registry and worklog management.
Debug Agent Documentation
.claude/agents/ad-debug-agent.md
Revised prerequisites and execution workflow to emphasize registry resolution, CUDA device management, and auto-config resolution from models.yaml instead of manual argument specification.
Onboard Reviewer Documentation
.claude/agents/ad-onboard-reviewer.md
Restructured validation checklist with enhanced config provenance requirements, new multi-modal vision support checks (BB1, BB2), expanded test file import guidance (F4), and refined control flow for conditional validation.
Run Agent Documentation
.claude/agents/ad-run-agent.md
New documentation establishing end-to-end workflow for model execution via gpu-shell, including GPU resource determination, build-and-run invocation, compilation evaluation, log archiving with status tags, and append-only worklog updates.
Model Onboarding Skill
.claude/skills/ad-model-onboard/SKILL.md
Expanded 11-phase comprehensive guide covering GPU memory checks, HF model analysis, prefill-only modeling, canonical ops enforcement, config reuse, position_ids contracts, HF reference strategies, registry management, testing hierarchies, mandatory reviews, and PR workflows.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~30 minutes

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning PR description is incomplete: missing PR title with ticket/type format, lacks detailed explanation of changes, and Test Coverage section is empty. Add a proper PR title following [type] format, provide detailed explanation of what was changed and why, and list relevant test cases or testing approach for the agent skill updates.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title references 'ad-model-onboard skill updates' which aligns with the primary change: comprehensive updates to the onboarding skill documentation and related agent workflows.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
📝 Coding Plan
  • Generate coding plan for human review comments

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 9

🧹 Nitpick comments (3)
.codex/AGENTS.md (1)

6-9: Clarify precedence between concision and exhaustive explanations.

Line 6 and Line 9 currently pull in opposite directions (“be concise” vs “always give complete end-to-end explanations upfront”). Please define an explicit priority rule to avoid inconsistent agent behavior.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.codex/AGENTS.md around lines 6 - 9, Update the guidance to resolve the
conflict between the two rules by making concision the default and full
end-to-end explanations conditional: change the text so "Be concise and act like
a collaborative pair programmer." is the default behavior and add an explicit
sentence after it that says the rule "Give complete end-to-end explanations
upfront, including root cause, mechanism chain, and tradeoff." applies only when
the user explicitly requests detailed analysis or when the situation clearly
requires deep troubleshooting; ensure both phrases remain exactly as written but
add the conditional qualifier so agents use brevity unless the user asks for or
context demands exhaustive explanations.
.codex/agents/onboard_update_reviewer.toml (1)

98-98: Minor: Clarify "generated e2e text" terminology.

The phrase "generated e2e text" is slightly ambiguous. Consider clarifying whether this refers to end-to-end test output logs, generated test summaries, or something else.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.codex/agents/onboard_update_reviewer.toml at line 98, The phrase "generated
e2e text" is ambiguous—replace it with a clearer, explicit term (e.g.,
"generated end-to-end (E2E) test logs" or "generated E2E test summaries") so
readers know whether it refers to test output logs, summaries, or other
artifacts; update the string "generated e2e text" in the
.codex/agents/onboard_update_reviewer.toml entry to the chosen clarified
wording.
.codex/agents/ad_onboard_reviewer.toml (1)

23-23: Hardcoded path may become stale.

The init_file path is hardcoded to a specific repository location. If the directory structure changes, this configuration will require manual updates. Consider whether this path could be parameterized or if the current approach is acceptable given the internal tooling context.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.codex/agents/ad_onboard_reviewer.toml at line 23, The hardcoded init_file
path in .codex/agents/ad_onboard_reviewer.toml (init_file: always
tensorrt_llm/_torch/auto_deploy/models/custom/__init__.py) can break when the
repo layout changes; update this config to use a parameterized or relative path
(e.g., an interpolated variable or env var) instead of the absolute repository
path, or document and centralize the base path in a single config key so code
that reads init_file resolves it relative to that base; modify the code that
consumes init_file to support resolving env vars/placeholders and fallback to a
sensible default.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In @.claude/agents/ad-debug-agent.md:
- Around line 39-42: The doc references running a command "Run via gpu-shell"
but the agent's declared tools do not include gpu-shell; either add "gpu-shell"
to the agent frontmatter tools list or change the instruction to a generic Bash
execution; update the line that currently reads 'Run via gpu-shell:' to instead
declare the tool in the frontmatter tools array (include the tool name
"gpu-shell") or replace that phrase with 'Run in Bash:' (and ensure the example
command remains unchanged) so the command uses an available execution tool.

In @.claude/agents/ad-onboard-reviewer.md:
- Line 36: Update the checklist wording on the BA2 line to use consistent casing
and hyphenation: change the phrase to read "If our modeling code has
expert-list-style MoE experts and the checkpoint has fused MoE experts, add a
load hook to load the safetensors correctly into our expert-list-style weights."
Ensure "MoE" is capitalized and "expert-list-style" is hyphenated consistently
where it appears in the checklist (refer to the BA2 table row content).

In @.claude/skills/ad-model-onboard/SKILL.md:
- Around line 238-240: The README/skill text hardcodes the PR destination and
branch (the literal URL "https://github.com/nv-auto-deploy/TensorRT-LLM", the
remote name `origin` and branch `feat/paperclip_maximizer`) in the "Prepare a
pull request against `origin` ... targeting branch `feat/paperclip_maximizer`"
sentence and again at the later reference (around line 265); change these to
parameterized placeholders (e.g., {pr_remote}, {pr_fork_url}, {pr_branch}) and
describe how to supply defaults or override them when running the onboarding
(update any references that mention `origin` and `feat/paperclip_maximizer`),
ensuring the PR creation/rebase instructions reference the variables instead of
the hardcoded values so other forks/branches can be targeted.
- Around line 245-247: The fenced code block containing the command "python
examples/auto_deploy/build_and_run_ad.py --model <MODEL-ID> --use-registry" is
missing a language tag; update the opening fence from ``` to ```bash so the
block starts with ```bash to satisfy markdownlint MD040 and enable proper syntax
highlighting.

In @.codex/agents/ad_debug_agent.toml:
- Around line 10-24: The debug run instructions still instruct callers to pass a
local config with "--args.yaml-extra" and a model id path; update them to use
the registry-driven flow and to prompt for missing inputs: require/ask for
MODEL_HF_ID and registry config selection instead of a local CONFIG_YAML_FILE,
replace the manual "--args.yaml-extra
examples/auto_deploy/model_registry/configs/<CONFIG_YAML_FILE>" usage with the
registry-driven invocation (use the AutoDeploy registry flag or registry lookup
mechanism used elsewhere in this PR), and ensure the note about reruns
explicitly prompts the user to confirm before rerunning so a fresh log and IR
dump are produced; keep references to AD_DUMP_GRAPHS_DIR and LOG_FILE and ensure
they remain under $PWD.

In @.codex/agents/ad_onboard_reviewer.toml:
- Around line 58-63: The checklist in .codex/agents/ad_onboard_reviewer.toml
skips G5 (it goes G4 then G6); either insert a short explanatory comment stating
G5 is intentionally omitted or renumber G6 to G5 and update any internal
references; locate the block containing "G. Test File Hierarchical Levels" and
change the numbering text (e.g., rename "G6: Export test runs a second
forward..." to "G5..." or add a comment like "# G5 intentionally omitted"
immediately after G4) so the sequence is consistent and any downstream checks
that reference G5/G6 remain correct.

In @.codex/agents/ad_run_agent.toml:
- Around line 10-22: The README/instructions currently force passing a local
config YAML and deriving MODEL_SHORT_NAME from its filename (references:
MODEL_SHORT_NAME, examples/auto_deploy/build_and_run_ad.py, --args.yaml-extra),
which conflicts with the registry-centric --use-registry flow; update the text
and command so that when --use-registry is used the agent does not require a
local args.yaml-extra path, instead derive MODEL_SHORT_NAME from the registry
model identifier (MODEL_HF_ID) or an explicit --model-short-name argument, and
make the example command show both flows (local: --args.yaml-extra
<CONFIG_YAML_FILE> and registry: --use-registry --model <MODEL_HF_ID>
[--model-short-name <SHORT>]). Ensure setup steps that mention creating/using
$PWD/ad_run_logs/<MODEL_SHORT_NAME>_worklog.md clarify which naming source is
used depending on whether --use-registry or --args.yaml-extra is selected.

In @.codex/skills/ad-model-onboard/SKILL.md:
- Around line 238-240: The workflow hardcodes the upstream remote and branch
("origin" and "feat/paperclip_maximizer") in SKILL.md; change it to accept
parameters or user input instead: replace the literal "origin" and
"feat/paperclip_maximizer" occurrences with configurable placeholders (e.g.,
upstream_remote and upstream_branch) and update the skill logic that prepares
the PR to prompt the user or read these values from runtime inputs/env vars;
ensure both occurrences (lines referencing "origin" and
"feat/paperclip_maximizer") are updated and validated before creating the PR so
other remotes/branches are supported.
- Around line 245-247: Update the fenced code block containing "python
examples/auto_deploy/build_and_run_ad.py --model <MODEL-ID> --use-registry" to
include a language identifier (bash) after the opening backticks so the block
becomes ```bash ... ``` to satisfy markdownlint MD040 and match the document's
other examples.

---

Nitpick comments:
In @.codex/AGENTS.md:
- Around line 6-9: Update the guidance to resolve the conflict between the two
rules by making concision the default and full end-to-end explanations
conditional: change the text so "Be concise and act like a collaborative pair
programmer." is the default behavior and add an explicit sentence after it that
says the rule "Give complete end-to-end explanations upfront, including root
cause, mechanism chain, and tradeoff." applies only when the user explicitly
requests detailed analysis or when the situation clearly requires deep
troubleshooting; ensure both phrases remain exactly as written but add the
conditional qualifier so agents use brevity unless the user asks for or context
demands exhaustive explanations.

In @.codex/agents/ad_onboard_reviewer.toml:
- Line 23: The hardcoded init_file path in
.codex/agents/ad_onboard_reviewer.toml (init_file: always
tensorrt_llm/_torch/auto_deploy/models/custom/__init__.py) can break when the
repo layout changes; update this config to use a parameterized or relative path
(e.g., an interpolated variable or env var) instead of the absolute repository
path, or document and centralize the base path in a single config key so code
that reads init_file resolves it relative to that base; modify the code that
consumes init_file to support resolving env vars/placeholders and fallback to a
sensible default.

In @.codex/agents/onboard_update_reviewer.toml:
- Line 98: The phrase "generated e2e text" is ambiguous—replace it with a
clearer, explicit term (e.g., "generated end-to-end (E2E) test logs" or
"generated E2E test summaries") so readers know whether it refers to test output
logs, summaries, or other artifacts; update the string "generated e2e text" in
the .codex/agents/onboard_update_reviewer.toml entry to the chosen clarified
wording.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: c8c1b0b0-238d-4269-8c55-fbdb5b2b544a

📥 Commits

Reviewing files that changed from the base of the PR and between 5a7076c and 1c068fa.

📒 Files selected for processing (11)
  • .claude/agents/ad-debug-agent.md
  • .claude/agents/ad-onboard-reviewer.md
  • .claude/agents/ad-run-agent.md
  • .claude/skills/ad-model-onboard/SKILL.md
  • .codex/AGENTS.md
  • .codex/agents/ad_debug_agent.toml
  • .codex/agents/ad_onboard_reviewer.toml
  • .codex/agents/ad_run_agent.toml
  • .codex/agents/onboard_update_reviewer.toml
  • .codex/config.toml
  • .codex/skills/ad-model-onboard/SKILL.md

Comment thread .claude/agents/ad-debug-agent.md Outdated
Comment thread .claude/agents/ad-onboard-reviewer.md Outdated
Comment thread .claude/skills/ad-model-onboard/SKILL.md Outdated
Comment thread .claude/skills/ad-model-onboard/SKILL.md Outdated
Comment thread .codex/agents/ad_debug_agent.toml Outdated
Comment thread .codex/agents/ad_onboard_reviewer.toml
Comment thread .codex/agents/ad_run_agent.toml Outdated
Comment thread .codex/skills/ad-model-onboard/SKILL.md Outdated
Comment thread .codex/skills/ad-model-onboard/SKILL.md Outdated
Signed-off-by: Balamurugan Marimuthu <246387390+bmarimuthu-nv@users.noreply.github.com>
@bmarimuthu-nv

Copy link
Copy Markdown
Collaborator Author

/bot help

@github-actions

Copy link
Copy Markdown

GitHub Bot Help

/bot [-h] ['run', 'kill', 'skip', 'reuse-pipeline'] ...

Provide a user friendly way for developers to interact with a Jenkins server.

Run /bot [-h|--help] to print this help message.

See details below for each supported subcommand.

Details

run [--reuse-test (optional)pipeline-id --disable-fail-fast --skip-test --stage-list "A10-PyTorch-1, xxx" --gpu-type "A30, H100_PCIe" --test-backend "pytorch, cpp" --add-multi-gpu-test --only-multi-gpu-test --disable-multi-gpu-test --post-merge --extra-stage "H100_PCIe-TensorRT-Post-Merge-1, xxx" --detailed-log --debug(experimental) --high-priority]

Launch build/test pipelines. All previously running jobs will be killed.

--reuse-test (optional)pipeline-id (OPTIONAL) : Allow the new pipeline to reuse build artifacts and skip successful test stages from a specified pipeline or the last pipeline if no pipeline-id is indicated. If the Git commit ID has changed, this option will be always ignored. The DEFAULT behavior of the bot is to reuse build artifacts and successful test results from the last pipeline.

--disable-reuse-test (OPTIONAL) : Explicitly prevent the pipeline from reusing build artifacts and skipping successful test stages from a previous pipeline. Ensure that all builds and tests are run regardless of previous successes.

--disable-fail-fast (OPTIONAL) : Disable fail fast on build/tests/infra failures.

--skip-test (OPTIONAL) : Skip all test stages, but still run build stages, package stages and sanity check stages. Note: Does NOT update GitHub check status.

--stage-list "A10-PyTorch-1, xxx" (OPTIONAL) : Only run the specified test stages. Examples: "A10-PyTorch-1, xxx". Note: Does NOT update GitHub check status.

--gpu-type "A30, H100_PCIe" (OPTIONAL) : Only run the test stages on the specified GPU types. Examples: "A30, H100_PCIe". Note: Does NOT update GitHub check status.

--test-backend "pytorch, cpp" (OPTIONAL) : Skip test stages which don't match the specified backends. Only support [pytorch, cpp, tensorrt, triton]. Examples: "pytorch, cpp" (does not run test stages with tensorrt or triton backend). Note: Does NOT update GitHub pipeline status.

--only-multi-gpu-test (OPTIONAL) : Only run the multi-GPU tests. Note: Does NOT update GitHub check status.

--disable-multi-gpu-test (OPTIONAL) : Disable the multi-GPU tests. Note: Does NOT update GitHub check status.

--add-multi-gpu-test (OPTIONAL) : Force run the multi-GPU tests in addition to running L0 pre-merge pipeline.

--post-merge (OPTIONAL) : Run the L0 post-merge pipeline instead of the ordinary L0 pre-merge pipeline.

--extra-stage "H100_PCIe-TensorRT-Post-Merge-1, xxx" (OPTIONAL) : Run the ordinary L0 pre-merge pipeline and specified test stages. Examples: --extra-stage "H100_PCIe-TensorRT-Post-Merge-1, xxx".

--detailed-log (OPTIONAL) : Enable flushing out all logs to the Jenkins console. This will significantly increase the log volume and may slow down the job.

--debug (OPTIONAL) : Experimental feature. Enable access to the CI container for debugging purpose. Note: Specify exactly one stage in the stage-list parameter to access the appropriate container environment. Note: Does NOT update GitHub check status.

--high-priority (OPTIONAL) : Run the pipeline with high priority. This option is restricted to authorized users only and will route the job to a high-priority queue.

kill

kill

Kill all running builds associated with pull request.

skip

skip --comment COMMENT

Skip testing for latest commit on pull request. --comment "Reason for skipping build/test" is required. IMPORTANT NOTE: This is dangerous since lack of user care and validation can cause top of tree to break.

reuse-pipeline

reuse-pipeline

Reuse a previous pipeline to validate current commit. This action will also kill all currently running builds associated with the pull request. IMPORTANT NOTE: This is dangerous since lack of user care and validation can cause top of tree to break.

@bmarimuthu-nv

Copy link
Copy Markdown
Collaborator Author

/bot skip --comment "doc only"

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #39035 [ skip ] triggered by Bot. Commit: c8be526 Link to invocation

@tensorrt-cicd

Copy link
Copy Markdown
Collaborator

PR_Github #39035 [ skip ] completed with state SUCCESS. Commit: c8be526
Skipping testing for commit c8be526

Link to invocation

@bmarimuthu-nv
bmarimuthu-nv merged commit 503d678 into NVIDIA:main Mar 16, 2026
5 checks passed
reasonsolo pushed a commit to reasonsolo/TensorRT-LLM that referenced this pull request Mar 17, 2026
Signed-off-by: Balamurugan Marimuthu <246387390+bmarimuthu-nv@users.noreply.github.com>
limin2021 pushed a commit to limin2021/TensorRT-LLM that referenced this pull request Mar 19, 2026
Signed-off-by: Balamurugan Marimuthu <246387390+bmarimuthu-nv@users.noreply.github.com>
longcheng-nv pushed a commit to longcheng-nv/TensorRT-LLM that referenced this pull request Mar 31, 2026
Signed-off-by: Balamurugan Marimuthu <246387390+bmarimuthu-nv@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.

3 participants