# klieo-runlog
Tier 2 observability — RunLog aggregate + replay engine for klieo agents.
Part of the [klieo](https://crates.io/crates/klieo) Rust agent framework.
## Features
- Projects `EpisodicMemory` events into a deterministic `RunLog` per agent run
- Replay engine re-emits a recorded run for debugging or audit
- Deterministic compaction merges partial logs without data loss
## Cargo features
| `sqlite` | off | Activates `SqliteRunLogStore` for persistent run-log storage; pulls `rusqlite`. |
| `compaction-llm` | off | Enables the LLM-assisted compaction pipeline (`LlmAssistedCompactor`). |
| `schemars` | off | Derives `JsonSchema` on the public `Episode` / `RunLog` types so downstream OpenAPI/JSON-schema generators can pick them up. |
| `test-utils` | off | Activates `klieo-core/test-utils`; surfaces test-only helpers. |
## Usage
```toml
[dependencies]
klieo-runlog = "3"
```
```rust
use klieo_runlog::{project, RunLogStore, InMemoryRunLogStore};
// Retrieve episodes from any EpisodicMemory impl, then project:
let episodes = memory.replay(run_id).await?;
let log = project(&episodes, run_id);
// Persist to a store:
let store = InMemoryRunLogStore::default();
store.put(log).await?;
```
## Status
`3.x` — stable.
See [`docs/SEMVER.md`](https://github.com/mohrimic/klieo/blob/main/docs/SEMVER.md).
## License
MIT — see [`LICENSE`](https://github.com/mohrimic/klieo/blob/main/LICENSE).