Local UI to run and train LLMs and diffusion models. Supports GGUF, MLX, Qwen3.8, DeepSeek-V4.1, MiniMax-H3, Gemma 4, FLUX and more.
Python agentaichatgptdeepseekfine-tuninggemmaimage-generationllamallmllmsopenaipythonqwenreinforcement-learningself-hostedstable-diffusiontext-to-speechttsuiunsloth
// SPDX-License-Identifier: AGPL-3.0-only
// Copyright 2026-present the Unsloth AI Inc. team. All rights reserved. See /studio/LICENSE.AGPL-3.0
import { create } from "zustand";
export type PromptQueueUIEntry = {
runId: string;
current: number;
total: number;
local: boolean;
temporary: boolean;
dispatched: boolean;
paused: boolean;
};
export type PromptQueueUIItemStatus =
| "queued"
| "next"
| "waiting"
| "running"
| "paused";
export type PromptQueueUIItem = {
id: string;
runId: string;
prompt: string;
attachmentNames?: string[];
position: number;
total: number;
status: PromptQueueUIItemStatus;
threadIds: string[];
canEdit: boolean;
canRemove: boolean;
};
export interface PromptQueueUIState {
byThreadId: Record<string, PromptQueueUIEntry>;
current: number;
total: number;
items: PromptQueueUIItem[];
isRunning: boolean;
}
export const usePromptQueueUI = create<PromptQueueUIState>(() => ({
byThreadId: {},
current: 0,
total: 0,
items: [],
isRunning: false,
}));