mirror of
https://github.com/lordmathis/llamactl.git
synced 2025-11-06 09:04:27 +00:00
Add idle timeout configuration to instance options and basic fields
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
import { type CreateInstanceOptions, getAllFieldKeys } from '@/schemas/instanceOptions'
|
import { type CreateInstanceOptions, getAllFieldKeys } from '@/schemas/instanceOptions'
|
||||||
|
|
||||||
// Only define the basic fields we want to show by default
|
// Only define the basic fields we want to show by default
|
||||||
export const basicFieldsConfig: Record<string, {
|
export const basicFieldsConfig: Record<string, {
|
||||||
label: string
|
label: string
|
||||||
description?: string
|
description?: string
|
||||||
placeholder?: string
|
placeholder?: string
|
||||||
@@ -21,6 +21,11 @@ export const basicFieldsConfig: Record<string, {
|
|||||||
placeholder: '5',
|
placeholder: '5',
|
||||||
description: 'Delay in seconds before attempting restart'
|
description: 'Delay in seconds before attempting restart'
|
||||||
},
|
},
|
||||||
|
idle_timeout: {
|
||||||
|
label: 'Idle Timeout (minutes)',
|
||||||
|
placeholder: '60',
|
||||||
|
description: 'Time in minutes before instance is considered idle and stopped'
|
||||||
|
},
|
||||||
model: {
|
model: {
|
||||||
label: 'Model Path',
|
label: 'Model Path',
|
||||||
placeholder: '/path/to/model.gguf',
|
placeholder: '/path/to/model.gguf',
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ export const CreateInstanceOptionsSchema = z.object({
|
|||||||
auto_restart: z.boolean().optional(),
|
auto_restart: z.boolean().optional(),
|
||||||
max_restarts: z.number().optional(),
|
max_restarts: z.number().optional(),
|
||||||
restart_delay: z.number().optional(),
|
restart_delay: z.number().optional(),
|
||||||
|
idle_timeout: z.number().optional(),
|
||||||
|
|
||||||
// Common params
|
// Common params
|
||||||
verbose_prompt: z.boolean().optional(),
|
verbose_prompt: z.boolean().optional(),
|
||||||
|
|||||||
Reference in New Issue
Block a user