rename: tts model type to audio for broader category support

This commit is contained in:
imagineer99 2026-03-10 13:28:49 +00:00
commit 3de197ac31
6 changed files with 13 additions and 13 deletions

View file

@ -53,9 +53,9 @@ export const MODEL_TYPES: ReadonlyArray<{
description: "Image understanding models",
},
{
value: "tts",
label: "TTS",
description: "Text-to-speech models",
value: "audio",
label: "Audio",
description: "Audio and speech models",
},
{
value: "embeddings",
@ -128,6 +128,6 @@ export const DEFAULT_HYPERPARAMS = {
export const MODEL_TYPE_TO_HF_TASK: Record<ModelType, PipelineType> = {
text: "text-generation",
vision: "image-text-to-text",
tts: "text-to-speech",
audio: "text-to-speech",
embeddings: "feature-extraction",
};

View file

@ -26,19 +26,19 @@ import { useShallow } from "zustand/react/shallow";
const TYPE_ICONS: Record<ModelType, typeof ImageIcon> = {
vision: ImageIcon,
tts: VoiceIcon,
audio: VoiceIcon,
embeddings: Database02Icon,
text: TextIcon,
};
const TYPE_TOOLTIPS: Record<ModelType, string> = {
vision: "Fine-tune models that understand images and text together",
tts: "Fine-tune text-to-speech models for voice generation",
audio: "Fine-tune text-to-speech and audio models",
embeddings: "Fine-tune models for semantic search and similarity",
text: "Fine-tune large language models for text generation",
};
const COMING_SOON: ModelType[] = ["tts", "embeddings"];
const COMING_SOON: ModelType[] = ["audio", "embeddings"];
export function ModelTypeStep(): ReactElement {
const { modelType, setModelType } = useTrainingConfigStore(

View file

@ -64,7 +64,7 @@ export interface ModelConfigResponse {
is_lora: boolean;
is_audio?: boolean;
base_model?: string | null;
model_type?: "text" | "vision" | "tts" | "embeddings" | null;
model_type?: "text" | "vision" | "audio" | "embeddings" | null;
}
export interface LocalModelInfo {

View file

@ -130,7 +130,7 @@ export const useTrainingConfigStore = create<TrainingConfigStore>()(
// Use backend-provided model_type when available, otherwise
// infer from is_vision (temporary until backend ships model_type).
const inferredModelType: ModelType = modelDetails.model_type
?? (modelDetails.is_vision ? "vision" : modelDetails.is_audio ? "tts" : "text");
?? (modelDetails.is_vision ? "vision" : modelDetails.is_audio ? "audio" : "text");
set({
...patch,

View file

@ -118,7 +118,7 @@ const BOOSTED_TASK_CATEGORIES: Record<ModelType, Set<string>> = {
"image-to-text",
"image-captioning",
]),
tts: new Set([
audio: new Set([
"text-to-speech",
"text-to-audio",
"automatic-speech-recognition",
@ -195,7 +195,7 @@ const CURATED_EMPTY_QUERY_DATASET_IDS: Partial<Record<ModelType, string[]>> = {
"lmms-lab/VQAv2",
"hezarai/parsynth-ocr-200k",
],
tts: [
audio: [
"MrDragonFox/Elise",
"keithito/lj_speech",
"parler-tts/mls_eng_10k",
@ -242,7 +242,7 @@ const INCOMPATIBLE_TASKS_BY_MODEL: Record<ModelType, Set<string>> = {
"audio-to-audio",
"automatic-speech-recognition",
]),
tts: new Set([
audio: new Set([
"text-to-image",
"image-to-image",
"image-to-video",

View file

@ -1,7 +1,7 @@
// SPDX-License-Identifier: AGPL-3.0-only - See /studio/LICENSE.AGPL-3.0
// Copyright © 2025 Unsloth AI
export type ModelType = "vision" | "tts" | "embeddings" | "text";
export type ModelType = "vision" | "audio" | "embeddings" | "text";
export type TrainingMethod = "qlora" | "lora" | "full";
export function isAdapterMethod(method: TrainingMethod): boolean {