ToConfigLoaderOptions returns a slice of ConfigLoader Option. Some options defined at the application level are going to be passed as defaults for all the configuration for the models. This includes for instance the context size or the number of threads. If a model doesn't set configs directly to th
()
| 1043 | // If a model doesn't set configs directly to the config model file |
| 1044 | // it will use the defaults defined here. |
| 1045 | func (o *ApplicationConfig) ToConfigLoaderOptions() []ConfigLoaderOption { |
| 1046 | return []ConfigLoaderOption{ |
| 1047 | LoadOptionContextSize(o.ContextSize), |
| 1048 | LoadOptionDebug(o.Debug), |
| 1049 | LoadOptionF16(o.F16), |
| 1050 | LoadOptionThreads(o.Threads), |
| 1051 | ModelPath(o.SystemState.Model.ModelsPath), |
| 1052 | } |
| 1053 | } |
| 1054 | |
| 1055 | // ToRuntimeSettings converts ApplicationConfig to RuntimeSettings for API responses and JSON serialization. |
| 1056 | // This provides a single source of truth - ApplicationConfig holds the live values, |