# Configuration Reference Every setting belongs to one of four scopes. The scope decides when the value is fixed and what it applies to: | Scope | Fixed when | Applies to | Native API | | --- | --- | --- | --- | | [Runtime](#runtime) | The runtime is opened | The whole process: devices, threads, memory budget | `RuntimeOptions` in `edge0/engine.h` | | [Load](#load) | The model is loaded | One loaded model; the same settings exist for every model | `LoadOverrides` in `edge0/generation.h` | | [Model options](#model-options) | The model is loaded | One loaded model; each model declares its own | `LoadOverrides::model_options` | | [Generation](#generation) | Each request | One generation call | `GenerationOverrides` in `edge0/generation.h` | The reference CLI (`edge0-infer`) and the local server use the same settings and defaults as the native API; the CLI flag names are given below. Settings that only exist in the CLI or the server are listed under [Command options](#command-options). ## How a value is chosen Load and generation settings take the first value given by: 1. the request (a CLI flag, an HTTP request field, or the override passed to `generate` or `resolve_load_configuration`); 2. the application's prepared configuration (`resolve_generation_configuration`; for the server, its command-line sampling options); 3. the model's recommendation, stored in the model assets or declared by the model; 4. the platform default. An invalid value is rejected with `invalid_argument` (or `unsupported` when the platform cannot do it); the engine never falls back to a lower level to hide the error. Settings that change memory use are admitted against the memory budget when the model is loaded, and a load that does not fit fails instead of shrinking anything. Every effective value can be checked together with its source (`request`, `application`, `model` or `platform`): `edge0-infer describe --model
` | `top_p` | above 0, at most 1 | Nucleus sampling after top-k |
| `--repetition-penalty `, `--frequency-penalty ` | `presence_penalty`, `frequency_penalty` | -2 to 2 | OpenAI-style penalties, applied separately from the repetition penalty |
| `--seed