// Agent API reads: layered search (memory_search), full-row reads with
// hierarchy expansion / conversation-history paging (memory_get), and the
// deterministic timeline (Phase 4). The write surface (agent_update /
// agent_review) lives in agent_write.cpp; helpers shared by both surfaces
// (agent_snippet / parse_agent_handle / fetch_agent_row) live in
// agent_common.cpp.
//
// Design contract lives in StorageBackend's docs and PHASE2-STEPS.md; the
// hybrid scoring itself is reused untouched (Impl::search); everything here
// is post-filtering, handle formatting, and row fetches.
#include "sqlite/backend_impl.h"
#include "sqlite/agent_common.h"
#include "embedder.h"
#include "config.h"
#include "util/time.h"
#include "util/sqlite.h"
#include "sqlite/text_index.h"
#include
#include "nlohmann_json.hpp"
#include
#include
#include
#include
#include
#include