(state: SidecarState, model: string)
| 105 | |
| 106 | /** Der Wert des Statusleisten-Chips zu einer Lage. Der Beweislauf liest ihn woertlich. */ |
| 107 | export function llmChipValue(state: SidecarState, model: string): string { |
| 108 | switch (state) { |
| 109 | case 'off': |
| 110 | return 'off'; |
| 111 | case 'disabled-by-policy': |
| 112 | return 'off by policy'; |
| 113 | case 'not-running': |
| 114 | return 'not running'; |
| 115 | case 'starting': |
| 116 | return 'starting'; |
| 117 | case 'ready': |
| 118 | return model.length > 0 ? `ready: ${model}` : 'ready'; |
| 119 | default: |
| 120 | return 'off'; |
| 121 | } |
| 122 | } |
| 123 | |
| 124 | /** Der `title` des Menuepunktes, je nach Lage. */ |
| 125 | export function llmMenuTitle(state: SidecarState): string { |
no outgoing calls
no test coverage detected