session-history

Query a local SQLite database to retrieve past conversation sessions and transcripts.

Updated Dec 24, 2024
One-click install
npx skills add https://github.com/BSteffaniak/nix-config --skill session-history-bsteffaniak
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: session-history
Source: https://github.com/BSteffaniak/nix-config/tree/main/configs/opencode/skills/session-history
Command: npx skills add https://github.com/BSteffaniak/nix-config --skill session-history-bsteffaniak

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps you easily find and review past conversations and the code or actions taken within them, preventing the loss of valuable context and accelerating future development.

Core Features & Use Cases

  • Browse Recent Sessions: Quickly see a list of your most recent conversations with timestamps and associated project directories.
  • Read Full Session Details: Retrieve the complete transcript of a past session, including user messages, assistant responses, and tool invocations.
  • Search Across Sessions: Find specific keywords or terms within your entire conversation history to locate relevant past discussions or code snippets.
  • Use Case: You remember discussing a specific bug fix with the AI a few weeks ago but can't recall the exact solution. Use the search function to find the session containing the relevant keywords and review the conversation and code changes.

Quick Start

List the 10 most recent conversation sessions.

Frequently Asked Questions about session-history

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I search past conversation history and code recall in SQLite?

You can search past conversation history by querying a local SQLite database to retrieve session titles, timestamps, and project directories, or search keywords across all session messages to find specific code snippets and discussions.

Can I read full conversation transcripts including tool calls from previous sessions?

Yes, you can read full conversation transcripts from previous sessions. The retrieval process displays complete session details including user messages, assistant responses, and associated tool invocations stored in the SQLite database.

How do I list recent conversation sessions with project directories and timestamps?

To list recent conversation sessions, query the local SQLite database to retrieve and display the most recent records, automatically including their associated project directories and timestamps for quick reference.

Do I need direct file access to the SQLite database to use conversation history search?

Yes, you need direct read access to the SQLite database file located at ~/.local/share/opencode/opencode.db to query and retrieve any past conversation sessions or search across message history.

What is the best way to find a specific bug fix discussed in a past AI session?

The best way to find a specific bug fix is to use the keyword search function across all session messages in the SQLite database to locate the relevant past discussion and review the associated code changes.

Are there limitations when searching conversation logs stored locally in SQLite?

A limitation of searching conversation logs is that retrieval is strictly bound to the local SQLite database file, meaning you cannot access session history if the database file is missing, corrupted, or not synchronized.