hermes-agent/skills
Teknium eeb747de25 feat(sessions): opt-in per-session JSON snapshot writer
PR #29182 deleted the per-session JSON snapshot writer outright because
state.db is canonical and the snapshots had no in-tree consumer.  Some
users have external tooling that reads `~/.hermes/sessions/session_{sid}.json`
directly, so reintroduce the writer behind a config flag that defaults
to off.

- Add `sessions.write_json_snapshots` (default False) to DEFAULT_CONFIG
- Restore `AIAgent._save_session_log` + `_clean_session_content` as
  gated methods.  When the flag is off the call is a fast no-op; when
  on, the writer behaves as before (atomic write, truncation guard
  preserved, REASONING_SCRATCHPAD → think tag normalization)
- Re-derive the target path from `agent.session_id` on each call so
  `/branch` and `/compress` re-points happen automatically — no need
  to restore the explicit re-point bookkeeping at call sites
- Wire the single call site in `_persist_session` (the cleanup-on-exit
  hook).  Did NOT restore the 7 intra-turn calls the original PR deleted
  — those were redundant writes within the same turn that doubled disk
  I/O without adding any persistence guarantee `_persist_session` does
  not already provide
- Read the flag once at agent init via `load_config()`, cache as
  `agent._session_json_enabled`
- Update `TestNoSessionJsonSnapshot` → `TestSessionJsonSnapshotOptIn`
  to pin behavior: default off (no file), opt-in true (file written),
  no-op method on default agents, logs_dir retained unconditionally
- Update CONTRIBUTING.md and the bundled `hermes-agent` skill to
  document the flag and its default
2026-05-20 11:44:10 -07:00
..
apple
…
autonomous-ai-agents feat(sessions): opt-in per-session JSON snapshot writer 2026-05-20 11:44:10 -07:00
creative chore(skills/baoyu-article-illustrator): tighten description, add platforms, regen docs 2026-05-18 18:28:56 -07:00
data-science
…
devops feat(kanban): configure worktree paths and branches 2026-05-18 21:33:08 -07:00
diagramming
…
dogfood
…
domain
…
email
…
gaming
…
gifs
…
github
…
index-cache
…
inference-sh
…
mcp
…
media
…
mlops
…
note-taking
…
productivity fix(skills): add timeout to Google OAuth urlopen calls 2026-05-19 00:11:44 -07:00
red-teaming/godmode
…
research
…
smart-home
…
social-media
…
software-development
…
yuanbao
…