Skip to content

[Ready For Review][AQUA][Multi-Model] Enhance AQUA CLI to Accept Fine-Tuned Weights Under Base Model in Multi-Model Deployment #1209

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

mrDzurb
Copy link
Member

@mrDzurb mrDzurb commented Jun 18, 2025

Description

Currently, the CLI and UI handler for multi-model deployment accept a flat list of models, where model_id can refer to either a base model or a fine-tuned weight. Under the hood, the handler detects fine-tuned models and transforms the input into a nested structure grouping fine-tuned weights under their respective base models. This logic should be improved by explicitly allowing users to provide a base model and its associated fine-tuned weights directly in the input structure. This enhancement simplifies user intent, reduces ambiguity, and enables direct validation of base-to-weight relationships.

Current CLI command

ads aqua deployment create \
  --container_image_uri "dsmc://odsc-vllm-serving:0.8.5.post1.6" \
  --models '[
    {
      "model_id": "ocid1.log.oc1.iad.<ocid>",
      "gpu_count": 1,
      "model_name": "meta-llama/Meta-Llama-3.1-8B",
      "model_task": "text_generation",
    },
    {
      "model_task": "text_generation",
      "model_id": "ocid1.log.oc1.iad.<ocid>",
      "gpu_count": 1
    }
  ]' \
  --instance_shape "VM.GPU.A10.2" \
  --display_name "modelDeployment_multimodel"

New CLI command

ads aqua deployment create \
  --container_image_uri "dsmc://odsc-vllm-serving:0.8.5.post1.6" \
  --models '[
    {
      "model_id": "ocid1.log.oc1.iad.<ocid>",
      "gpu_count": 1,
      "model_name": "meta-llama/Meta-Llama-3.1-8B",
      "model_task": "text_generation",
      "fine_tune_weights": [
        {
          "model_id": "ocid1.datasciencemodel.oc1.iad.<>",
          "model_name": "meta-llama/Meta-Llama-3.1-8B-FT1"
        },
        {
          "model_id": "ocid1.datasciencemodel.oc1.iad.<>",
          "model_name": "meta-llama/Meta-Llama-3.1-8B-FT2"
        }
      ]
    },
    {
      "model_task": "text_generation",
      "model_id": "ocid1.log.oc1.iad.<ocid>",
      "gpu_count": 1
    }
  ]' \
  --instance_shape "VM.GPU.A10.2" \
  --display_name "modelDeployment_multimodel"

@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label Jun 18, 2025
@mrDzurb mrDzurb changed the title [AQUA][Multi-Model] Enhance CLI & UI Handler to Accept Fine-Tuned Weights Under Base Model in Multi-Model Deployment [AQUA][Multi-Model] Enhance AQUA CLI to Accept Fine-Tuned Weights Under Base Model in Multi-Model Deployment Jun 18, 2025
@mrDzurb mrDzurb requested review from elizjo and lu-ohai June 18, 2025 04:20
Copy link

📌 Cov diff with main:

Coverage-41%

📌 Overall coverage:

Coverage-58.22%

@mrDzurb mrDzurb changed the title [AQUA][Multi-Model] Enhance AQUA CLI to Accept Fine-Tuned Weights Under Base Model in Multi-Model Deployment [Ready For Review][AQUA][Multi-Model] Enhance AQUA CLI to Accept Fine-Tuned Weights Under Base Model in Multi-Model Deployment Jun 18, 2025
Copy link

📌 Cov diff with main:

Coverage-41%

📌 Overall coverage:

Coverage-58.22%

List[str]
A list of all model OCIDs associated with this multi-model reference.
"""
ids = {self.model_id}
Copy link
Member

Choose a reason for hiding this comment

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

Check if self.model_id exists before inserting/ creating set?

# Use fallback name if needed
ft_model.model_name = (
ft_model.model_name or fine_tune_source_model.display_name
)
Copy link
Member

Choose a reason for hiding this comment

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

are we allowing users to name their own FT modules?

Copy link
Member

@VipulMascarenhas VipulMascarenhas left a comment

Choose a reason for hiding this comment

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

changes lgtm 👍

elizjo
elizjo previously approved these changes Jun 18, 2025
Copy link
Member

@elizjo elizjo left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link

📌 Cov diff with main:

Coverage-36%

📌 Overall coverage:

Coverage-58.19%

Copy link

📌 Cov diff with main:

Coverage-36%

📌 Overall coverage:

Coverage-58.21%

Copy link

📌 Cov diff with main:

Coverage-35%

📌 Overall coverage:

Coverage-58.21%

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCA Verified All contributors have signed the Oracle Contributor Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants