← 返回
数据分析 中文

Chat History Analyzer

Extracts and analyzes Cursor IDE chat history to identify key discoveries, obstacles, and solutions, saving findings to the journal.
提取并分析 Cursor IDE 聊天记录,识别关键发现、障碍和解决方案,将结果保存到日志。
runeweaverstudios
数据分析 clawhub v1.0.5 2 版本 99884.9 Key: 无需
★ 1
Stars
📥 848
下载
💾 14
安装
2
版本
#latest

概述

Chat History Analyzer | OpenClaw Skill

Description

Extracts and analyzes Cursor IDE chat history to identify key discoveries, obstacles, and solutions, saving findings to the journal.

Chat History Analyzer | OpenClaw Skill

Extracts chat history from Cursor IDE's local SQLite databases, analyzes the last hour of conversations for key discoveries, obstacles, and solutions, and saves structured findings to the OpenClaw journal directory.

Usage

  • As a scheduled cron job to continuously track insights from chat history
  • Manually to analyze recent chat activity
  • To identify recurring patterns, problems, or solutions in your workflow
# Combined log and chat history analysis (for cron jobs)
python3 /Users/ghost/.openclaw/workspace/skills/chat-history-analyzer/scripts/analyze_logs.py

# Analyze last hour of chat history only
python3 /Users/ghost/.openclaw/workspace/skills/chat-history-analyzer/scripts/chat_history_analyzer.py

# Analyze last 2 hours
python3 /Users/ghost/.openclaw/workspace/skills/chat-history-analyzer/scripts/chat_history_analyzer.py --hours 2

# Output JSON format
python3 /Users/ghost/.openclaw/workspace/skills/chat-history-analyzer/scripts/analyze_logs.py --json

What this skill does

  • Extracts chat history from Cursor's SQLite databases (global and workspace-specific)
  • Analyzes the last hour of messages for patterns indicating discoveries, obstacles, and solutions
  • Saves structured findings to /Users/ghost/.openclaw/journal/ as markdown files
  • Runs automatically via cron job every hour

Integration as a Cron Job

This skill is designed to run hourly via OpenClaw cron. The analyze_logs.py script combines both log analysis and chat history analysis.

Example Cron Job Configuration:

{
  "payload": {
    "kind": "agentTurn",
    "message": "Run analyze_logs.py script to analyze the last hour of logs and Cursor chat history, saving findings to journal.",
    "model": "openrouter/google/gemini-2.5-flash",
    "thinking": "low",
    "timeoutSeconds": 180
  },
  "schedule": {
    "kind": "cron",
    "cron": "0 * * * *"
  },
  "delivery": {
    "mode": "announce"
  },
  "sessionTarget": "isolated",
  "name": "Chat History & Log Analysis"
}

Or run directly via shell script:

# Add to crontab (crontab -e)
# Run every hour at minute 0
0 * * * * /Users/ghost/.openclaw/workspace/skills/chat-history-analyzer/scripts/analyze_logs.py --json >> /Users/ghost/.openclaw/logs/analyze_logs.log 2>&1

Output Format

Findings are saved to /Users/ghost/.openclaw/journal/chat_analysis_YYYY-MM-DD_HHMMSS.md with sections for:

  • Key Discoveries: Successful findings, realizations, and implementations
  • Obstacles Encountered: Errors, failures, and blockers
  • Solutions Found: Fixes, workarounds, and resolutions

Requirements

  • Cursor IDE installed with chat history stored locally
  • SQLite3 available (usually pre-installed on macOS)
  • OpenClaw journal directory writable

How it works

  1. Connects to Cursor's SQLite databases at ~/Library/Application Support/Cursor/User/globalStorage/state.vscdb and workspace-specific databases
  2. Extracts messages from the last N hours (default: 1 hour)
  3. Analyzes message content using pattern matching for discoveries, obstacles, and solutions
  4. Saves structured markdown report to the journal directory

版本历史

共 2 个版本

  • v1.0.5 当前
    2026-03-29 07:29 安全 安全
  • v1.0.3
    2026-03-07 01:58

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

ai-intelligence

Agent Swarm

runeweaverstudios
必须使用 OpenRouter。将任务路由至合适模型,并始终通过 sessions_spawn 委派工作。
★ 4 📥 3,615
data-analysis

Data Analysis

ivangdavila
{"answer":"数据分析与可视化。查询数据库、生成报告、自动化电子表格,将原始数据转化为清晰可行的见解。适用于:(1) 您……"}
★ 199 📥 65,248
data-analysis

Excel / XLSX

ivangdavila
创建、检查和编辑 Microsoft Excel 工作簿及 XLSX 文件,支持可靠的公式、日期、类型、格式、重算及模板保留功能。
★ 368 📥 140,804