Observability
Observability
LevPRO AI runtime exposes structured logs for runtime monitoring.
Structured Logging
Logs are written to logs/app.log and logs/llama.log.
| Environment variable | Values | Default |
|---|---|---|
LOG_LEVEL |
DEBUG, INFO, WARNING, ERROR | DEBUG |
LOG_FORMAT |
text, json | text |
Each log line includes an event tag (LLM_REQUEST, TOOL_CALL, TOOL_RESULT_STORED, WORKING_MEMORY_COMPRESSED, SUPERVISOR_RESTART, etc.).
| Event | When |
|---|---|
WORKING_MEMORY_COMPRESSED |
L1 working memory updated after an agent run |
TOOL_RESULT_STORED |
Large tool output externalized to L3 |
MEMORY_RETRIEVAL_STAGE1 / STAGE2 |
RAG pipeline stages |
MCP_CONNECT / MCP_DISCOVER / MCP_TOOL_CALL / MCP_ERROR |
MCP bridge (local-ai-mcp) |
SKILL_STORED |
Successful run captured as a skill (local-ai-skills) |
SKILL_RETRIEVAL |
Skills context injected into agent prompt (local-ai-skills) |
RESOURCE_PRESSURE / RESOURCE_DEGRADE |
Optional [monitor] polling |
DEGRADATION_TIER |
Crash/OOM graceful degradation |
MODEL_PLAN / MODEL_PLAN_WARNING |
Planner output at startup |
MESSAGE_ARCHIVED / MESSAGE_ARCHIVE_LOAD |
Session message archive |
Removed tool events (built-in net/db/remote/mail/sandbox/workspace packages deleted): HTTP_FETCH / HTTP_REQUEST / HTTP_DOWNLOAD, DB_QUERY / DB_EXECUTE, REMOTE_OP, MAIL_OP, SCRIPT_EXEC_, WORKSPACE_INDEX_. Tags may still exist in EVENT_TAGS for log compatibility but are no longer emitted by Core tools — use MCP servers and MCP_* events instead.
When LOG_FORMAT=json, log records include a request_id field when set via core.logging_config.set_request_id().
Health check
local-ai health [--config config.yaml]
Reports llama-server reachability, LLM circuit breaker state, and optional memory index status when memory.enabled.