I do not follow you. Are you exporting yours sessions manually? How are you performing insertions and queries? How does your agent know the session schema? How does OpenCode 'understand' anything when it is just a dumb app? Are you using some OpenCode memory skill? Do you have a write up of your workflow?

opencode export -h

you can also work with the opencode sqlite database directly

I am not sure we are talking about the same thing. I am talking about a way to automatically create memories, for agentic use. This involves knowing when to create, amend, and delete memories. Are you handling these tasks? This is the core of agentic memory management. Your responses seem to indicate a different use case, like making backups.