agent-history

Search Claude Code conversation history across local, WSL, Windows, and SSH remotes.

10|4|Updated Nov 20, 2025
One-click install
npx skills add https://github.com/kvsankar/agent-history --skill agent-history
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: agent-history
Source: https://github.com/kvsankar/agent-history/tree/main/.
Command: npx skills add https://github.com/kvsankar/agent-history --skill agent-history

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

This Skill helps you quickly locate, analyze, and extract insights from Claude Code conversations, enabling you to answer questions about past discussions, find solutions, gauge usage, and export history for audits.

Core Features & Use Cases

  • Search past conversations across workspaces and sources (local, WSL, Windows, remotes) using patterns or aliases.
  • Export to Markdown for sharing, backups, or audits.
  • Usage analytics: time spent, token counts, and tool usage across days and projects.
  • Use Case: Summarize last quarter’s bug fixes by exporting relevant sessions and computing metrics.

Quick Start

Start by listing sessions in your current workspace with agent-history lss, then export them with agent-history export to Markdown for easy sharing.

Frequently Asked Questions about agent-history

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

FAQPage Schema
How do I search Claude Code conversation history?

Search past Claude Code conversations using pattern matching across local, WSL, Windows, and SSH remotes. The Skill reads JSONL/JSON session data from ~/.claude/projects, applies date filtering and workspace encoding, then returns matching sessions with metadata for easy location and analysis.

Can I export Claude Code sessions to Markdown?

Export conversations to Markdown format for sharing, backups, or audits. The Skill converts session data into readable Markdown output, preserving conversation structure and metadata across all supported workspace sources.

How do I analyze token usage and time spent across Claude Code projects?

Generate usage analytics including token counts, time spent, and tool usage metrics across days and projects. The Skill processes session history to compute statistics and produce analytics outputs for measuring productivity and resource consumption.

What's the quickest way to list and view my Claude Code sessions?

List all sessions in your current workspace with `agent-history lss`, then export them to Markdown with `agent-history export`. This two-step workflow surfaces all available conversations and enables instant sharing or archival.

Does this work with remote workspaces and SSH connections?

Yes. The Skill supports session search and export across local, WSL, Windows, and SSH remote workspaces. It reads history from ~/.claude/projects on each environment with proper workspace encoding and pattern matching.

Can I filter Claude Code history by date or project?

Filter conversations using date ranges and pattern matching to isolate sessions by timeframe or project. Combined with export, this lets you summarize specific periods like last quarter's bug fixes or extract solutions from targeted projects.

Related Skills