Skip to content

Conversation

@agatha197
Copy link
Contributor

@agatha197 agatha197 commented Nov 27, 2025

resolves FR-1726

Enhance Environment Variable Management for Model Services

This PR adds runtime-specific environment variable configurations and improves the environment variable form component with the following features:

  1. Added support for runtime-specific environment variables with predefined configurations for vllm, sglang, and nim runtimes
  2. Implemented autocomplete for environment variable names based on the selected runtime
  3. Added dynamic placeholders for environment variable values based on the selected variable
  4. Created exception for NGC_API_KEY to prevent sanitization despite matching sensitive patterns
  5. Improved form validation and filtering of empty environment variables
  6. Added translations for all new environment variable placeholders across multiple languages

These changes make it easier for users to configure model services with the correct environment variables for each runtime type, providing better guidance through placeholders and autocomplete suggestions.

image.png

image.png

image.png

Checklist:

  • Documentation
  • Minium required manager version
  • Specific setting for review (eg., KB link, endpoint or how to setup)
  • Minimum requirements to check during review
  • Test case(s) to demonstrate the difference of before/after

@github-actions github-actions bot added the size:L 100~500 LoC label Nov 27, 2025
Copy link
Contributor Author


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • flow:merge-queue - adds this PR to the back of the merge queue
  • flow:hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has required the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@github-actions
Copy link
Contributor

github-actions bot commented Nov 27, 2025

Coverage report for ./react

St.
Category Percentage Covered / Total
🔴 Statements
4.4% (-0.02% 🔻)
521/11851
🔴 Branches
3.63% (-0.01% 🔻)
304/8370
🔴 Functions
2.62% (-0.02% 🔻)
95/3632
🔴 Lines
4.37% (-0.02% 🔻)
507/11592
Show new covered files 🐣
St.
File Statements Branches Functions Lines
🔴
... / runtimeVariantConfigs.ts
0% 100% 0% 0%
Show files with reduced coverage 🔻
St.
File Statements Branches Functions Lines
🔴
... / EnvVarFormList.tsx
18% (-9.59% 🔻)
12.77% (-18% 🔻)
14.81% (-10.19% 🔻)
17.02% (-8.9% 🔻)

Test suite run success

146 tests passing in 14 suites.

Report generated by 🧪jest coverage report action from 678781b

@agatha197 agatha197 force-pushed the feat_FR-1726_/auto-populate-env branch from 48b9212 to ad4fcd4 Compare December 1, 2025 04:56
@github-actions github-actions bot added area:ux UI / UX issue. area:i18n Localization size:XL 500~ LoC and removed size:L 100~500 LoC labels Dec 1, 2025
@agatha197 agatha197 marked this pull request as ready for review December 1, 2025 04:56
Copilot AI review requested due to automatic review settings December 1, 2025 04:56
@agatha197 agatha197 review requested due to automatic review settings December 1, 2025 04:58
Copilot AI review requested due to automatic review settings December 1, 2025 05:11
@agatha197 agatha197 force-pushed the feat_FR-1726_/auto-populate-env branch from ad4fcd4 to 1190a02 Compare December 1, 2025 05:11
@agatha197 agatha197 requested review from Copilot and removed request for Copilot December 1, 2025 05:11
Copy link
Contributor

Copilot AI left a comment

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 implements automatic population of environment variables based on the selected inference runtime variant (vLLM, SGLang, NIM). When users select a runtime variant in the service launcher, the system now automatically adds the required environment variables with appropriate placeholders, improving the user experience and reducing configuration errors.

Key changes:

  • Added runtime variant configuration system with predefined environment variables
  • Enhanced EnvVarFormList component with AutoComplete functionality for optional environment variables
  • Added comprehensive i18n translations across 20+ languages for new environment variable placeholders

Reviewed changes

Copilot reviewed 24 out of 24 changed files in this pull request and generated 5 comments.

File Description
react/src/helper/runtimeVariantConfigs.ts New configuration file defining required and optional environment variables for each runtime variant (vllm, sglang, nim)
react/src/components/ServiceLauncherPageContent.tsx Added form value change handler to auto-populate environment variables when runtime variant is selected; improved envvars filtering logic
react/src/components/EnvVarFormList.tsx Enhanced with AutoComplete for variable names, dynamic placeholders based on runtime configs, and improved null safety in filtering
resources/i18n/*.json Added 11 new translation keys for environment variable placeholders (VllmModelName, VllmQuantization, SglangExtraArgs, NimApiKey, etc.) across all supported languages

You can also share your feedback on Copilot code review for a chance to win a $100 gift card. Take the survey.

@agatha197 agatha197 force-pushed the feat_FR-1726_/auto-populate-env branch from 1190a02 to f1a138e Compare December 1, 2025 05:27
Copy link
Contributor

@ironAiken2 ironAiken2 left a comment

Choose a reason for hiding this comment

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

please resolve the confilicts :)

@agatha197 agatha197 force-pushed the feat_FR-1726_/auto-populate-env branch from f1a138e to efb585d Compare December 3, 2025 03:44
@agatha197 agatha197 requested a review from ironAiken2 December 3, 2025 03:45
Copy link
Contributor

@ironAiken2 ironAiken2 left a comment

Choose a reason for hiding this comment

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

Once an environment variable is set, its value does not disappear even if I choose a runtime that does not require variables.

@agatha197 agatha197 marked this pull request as draft December 3, 2025 07:02
@agatha197 agatha197 force-pushed the feat_FR-1726_/auto-populate-env branch from efb585d to 06be6d5 Compare December 3, 2025 07:20
@agatha197 agatha197 marked this pull request as ready for review December 3, 2025 07:21
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 25 out of 25 changed files in this pull request and generated no new comments.

@agatha197 agatha197 force-pushed the feat_FR-1726_/auto-populate-env branch from 06be6d5 to 6008ea8 Compare December 3, 2025 07:59
@agatha197 agatha197 force-pushed the feat_FR-1726_/auto-populate-env branch from 6008ea8 to 678781b Compare December 3, 2025 09:05
@agatha197 agatha197 requested a review from nowgnuesLee December 3, 2025 09:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:i18n Localization area:ux UI / UX issue. size:XL 500~ LoC

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants