reset(['editingId', 'name', 'config_yaml']); $this->engine = 'llama.cpp'; $this->modal('config-form')->show(); } public function edit(int $id): void { $config = ServerConfig::where('user_id', auth()->id())->findOrFail($id); $this->editingId = $config->id; $this->name = $config->name; $this->engine = $config->engine; $this->config_yaml = $config->config_yaml; $this->modal('config-form')->show(); } public function save(): void { $validated = $this->validate([ 'name' => ['required', 'string', 'max:128', Rule::unique('server_configs', 'name')->where('user_id', auth()->id())->ignore($this->editingId)], 'engine' => ['required', 'string', 'max:64'], 'config_yaml' => ['nullable', 'string', 'max:65535'], ]); ServerConfig::updateOrCreate( ['id' => $this->editingId, 'user_id' => auth()->id()], $validated ); $this->modal('config-form')->close(); Flux::toast(variant: 'success', text: __('Inference args saved.')); // Config identity is part of the session grouping key — re-summarize // so linked runs regroup immediately. Illuminate\Support\Facades\Artisan::call('festbench:summary'); } public function delete(int $id): void { ServerConfig::where('user_id', auth()->id())->whereKey($id)->firstOrFail()->delete(); Flux::toast(variant: 'success', text: __('Inference args deleted.')); Illuminate\Support\Facades\Artisan::call('festbench:summary'); } public function with(): array { return [ 'configs' => ServerConfig::where('user_id', auth()->id())->orderBy('name')->get(), ]; } }; ?>
{{ __('Inference Args') }} {{ __('Named inference server invocations. Runs link to them; the identity keeps differently-tuned sessions in their own groups.') }}
{{ __('New inference args') }}
@if ($configs->isNotEmpty()) {{ __('Name') }} {{ __('Engine') }} {{ __('Linked runs') }} @foreach ($configs as $config) {{ $config->name }} {{ $config->engine }} {{ $config->runs()->count() }}
{{ __('Edit') }} {{ __('Delete') }}
@endforeach
@else {{ __('No inference args yet') }} {{ __('Save your llama.cpp / vllm / hosted-provider invocation as a named entry so runs group by their tuning.') }} @endif
{{ $editingId ? __('Edit config') : __('New inference args') }} {{ __('Paste the full inference server invocation (YAML or argv list), or how a hosted model was addressed.') }}
@foreach (['llama.cpp', 'vllm', 'unknown', 'other'] as $engine) {{ $engine }} @endforeach
{{ __('Cancel') }} {{ __('Save config') }}