llm: full per-agent usage logging with prompts and responses

Log every model call to ~/.claude/memory/llm-logs/YYYY-MM-DD.md with
full prompt, response, agent type, model, duration, and status. One
file per day, markdown formatted for easy reading.

Agent types: fact-mine, experience-mine, consolidate, knowledge,
digest, enrich, audit. This gives visibility into what each agent
is doing and whether to adjust prompts or frequency.
This commit is contained in:
ProofOfConcept 2026-03-05 22:52:08 -05:00
parent e33fd4ffbc
commit 82b33c449c
7 changed files with 51 additions and 17 deletions

View file

@ -227,7 +227,7 @@ fn generate_digest(
println!(" Prompt: {} chars (~{} tokens)", prompt.len(), prompt.len() / 4);
println!(" Calling Sonnet...");
let digest = call_sonnet(&prompt, level.timeout)?;
let digest = call_sonnet("digest", &prompt)?;
let key = digest_node_key(level.name, label);
store.upsert_provenance(&key, &digest, store::Provenance::AgentDigest)?;