Expand description
Machine profile (UX §6): hardware facts, detected roles and the adaptations they imply. Built from a
snapshot (pure) plus a bounded scan of the configured model folders (headers are never read), stored in
oomtop-state and refreshed at most daily. Roles are sticky for ROLE_TTL_MS so a model server that
isn’t running right now doesn’t erase the “local LLM” role.
Structs§
Enums§
Constants§
- ROLE_
TTL_ MS - A role not observed for this long is dropped.
- SCAN_
BUDGET - Wall-time budget for the scan (it runs at most once a day, but must not delay the first frame much).
- SCAN_
MAX_ ENTRIES - Bounded model-folder scan: entries visited at most.
Functions§
- build
- Builds (or refreshes) the profile.
prevroles are kept until they expire. - count_
model_ files - Counts
.gguf/.safetensorsfiles under the folders (depth ≤ 3, ≤SCAN_MAX_ENTRIESentries, at mostSCAN_BUDGETof wall time; symlinks not followed; unreadable dirs skipped). Only the count is kept. - hardware
- Hardware facts from a snapshot.
- roles_
in - Roles visible in this snapshot.