Types for the Tunings API (fine-tuning/model tuning).
This module provides structs for tuning job configuration, status, and response parsing for Google's model tuning API.
Summary
Functions
Parses a tuning job from API response.
Checks if a tuning job has completed (terminal state).
Checks if a tuning job failed.
Checks if a tuning job is still running (non-terminal state).
Checks if a tuning job succeeded.
Parses job state string to atom.
Converts job state atom to API string.
Converts CreateTuningJobConfig to API request map.
Types
Functions
@spec from_api_response(map()) :: Gemini.Types.Tuning.TuningJob.t()
Parses a tuning job from API response.
@spec job_complete?(Gemini.Types.Tuning.TuningJob.t()) :: boolean()
Checks if a tuning job has completed (terminal state).
@spec job_failed?(Gemini.Types.Tuning.TuningJob.t()) :: boolean()
Checks if a tuning job failed.
@spec job_running?(Gemini.Types.Tuning.TuningJob.t()) :: boolean()
Checks if a tuning job is still running (non-terminal state).
@spec job_succeeded?(Gemini.Types.Tuning.TuningJob.t()) :: boolean()
Checks if a tuning job succeeded.
Parses job state string to atom.
Converts job state atom to API string.
@spec to_api_map(Gemini.Types.Tuning.CreateTuningJobConfig.t()) :: map()
Converts CreateTuningJobConfig to API request map.