Skip to main content

Crate agent_reflection

Crate agent_reflection 

Source
Expand description

agent-reflection: self-evaluation loop for LLM agent outputs.

use agent_reflection::{ReflectionResult, ReflectionStore};

let mut store = ReflectionStore::new();
let id = store.record("original output", "my critique", 0.7);
let r = store.get(id).unwrap();
assert!((r.score - 0.7).abs() < 1e-9);

Structsยง

ReflectionResult
A reflection entry.
ReflectionStore
Stores reflection results across turns.