From d364d76bd0fe54783e92e7d696b198f15f2da1f9 Mon Sep 17 00:00:00 2001 From: Ishaan Jaff Date: Fri, 2 Aug 2024 17:24:25 -0700 Subject: [PATCH] add vertex FT spec --- litellm/types/llms/vertex_ai.py | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/litellm/types/llms/vertex_ai.py b/litellm/types/llms/vertex_ai.py index df9696330d4..632b6e519df 100644 --- a/litellm/types/llms/vertex_ai.py +++ b/litellm/types/llms/vertex_ai.py @@ -260,3 +260,26 @@ class GenerateContentResponseBody(TypedDict, total=False): candidates: Required[List[Candidates]] promptFeedback: PromptFeedback usageMetadata: Required[UsageMetadata] + + +class FineTunesupervisedTuningSpec(TypedDict, total=False): + training_dataset_uri: str + validation_dataset: Optional[str] + epoch_count: Optional[int] + learning_rate_multiplier: Optional[float] + tuned_model_display_name: Optional[str] + adapter_size: Optional[ + Literal[ + "ADAPTER_SIZE_UNSPECIFIED", + "ADAPTER_SIZE_ONE", + "ADAPTER_SIZE_FOUR", + "ADAPTER_SIZE_EIGHT", + "ADAPTER_SIZE_SIXTEEN", + ] + ] + + +class FineTuneJobCreate(TypedDict, total=False): + baseModel: str + supervisedTuningSpec: FineTunesupervisedTuningSpec + tunedModelDisplayName: str