stigmergy 1.3.1-beta → 1.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,127 +1,211 @@
1
- ---
2
- name: resumesession
3
- description: Cross-CLI session recovery and history management skill
4
- author: stigmergy
5
- version: 2.0.0
6
- ---
7
-
8
- # ResumeSession Skill
9
-
10
- Cross-CLI session recovery and history management skill for all CLI tools.
11
-
12
- ## Description
13
-
14
- This skill enables session recovery across all supported CLI tools with intelligent project-based filtering.
15
-
16
- ## Usage
17
-
18
- ### Default Behavior - Recover Current Project's Latest Session
19
-
20
- To quickly recover current project's latest session:
21
-
22
- ```bash
23
- # Use stigmergy resume command
24
- stigmergy resume
25
- ```
26
-
27
- This command:
28
- - **Filters by current project** (only shows sessions from current working directory)
29
- - **Finds most recent session** from current project
30
- - **Checks session content** - if latest session is empty, it recovers previous one
31
- - **Displays context** for immediate recovery
32
-
33
- ### Show Multiple Sessions (Current Project Only)
34
-
35
- To show multiple sessions from current project:
36
-
37
- ```bash
38
- # Show 5 most recent sessions
39
- stigmergy resume 5
40
-
41
- # Show 10 most recent sessions
42
- stigmergy resume 10
43
- ```
44
-
45
- ### Show Sessions from Specific CLI
46
-
47
- To show sessions from a specific CLI (current project only):
48
-
49
- ```bash
50
- # Show iFlow sessions
51
- stigmergy resume iflow
52
-
53
- # Show 3 iFlow sessions
54
- stigmergy resume iflow 3
55
- ```
56
-
57
- ### Show All Projects' Sessions
58
-
59
- To show sessions from all projects:
60
-
61
- ```bash
62
- # Show all projects' sessions (default: 10 per CLI)
63
- stigmergy resume --all
64
-
65
- # Show all projects' sessions with limit
66
- stigmergy resume --all 5
67
- ```
68
-
69
- ### Advanced Filters
70
-
71
- ```bash
72
- # Search sessions by keyword
73
- stigmergy resume --search "react"
74
-
75
- # Show today's sessions
76
- stigmergy resume --today
77
-
78
- # Show sessions from last 7 days
79
- stigmergy resume --week
80
-
81
- # Show sessions from last 30 days
82
- stigmergy resume --month
83
-
84
- # Use different view formats
85
- stigmergy resume --format timeline
86
- stigmergy resume --format detailed
87
- ```
88
-
89
- ## Features
90
-
91
- - ✅ **Project-Aware**: Automatically filters sessions by current working directory
92
- - **Smart Content Check**: Skips empty sessions and finds previous one
93
- - **Default Context Recovery**: Shows latest session context by default
94
- - ✅ **Number-Based Control**: Use numbers to show multiple sessions
95
- - **CLI Filtering**: Filter sessions by specific CLI tool
96
- - ✅ **Content Search**: Search sessions by keywords
97
- - **Time Filtering**: Filter by date ranges (today, week, month)
98
- - ✅ **Multiple View Formats**: summary, timeline, detailed, context
99
- - ✅ **Cross-CLI Support**: Works with Claude, Gemini, Qwen, iFlow, CodeBuddy, Codex, QoderCLI, Kode
100
-
101
- ## Command Behavior
102
-
103
- | Command | Behavior |
104
- |---------|----------|
105
- | `stigmergy resume` | Shows **latest session** from **current project** (context format) |
106
- | `stigmergy resume 5` | Shows **5 most recent sessions** from **current project** (summary format) |
107
- | `stigmergy resume iflow` | Shows **latest iFlow session** from **current project** |
108
- | `stigmergy resume iflow 5` | Shows **5 iFlow sessions** from **current project** |
109
- | `stigmergy resume --all` | Shows **all projects' sessions** (10 per CLI) |
110
- | `stigmergy resume --all 5` | Shows **all projects' sessions** (5 per CLI) |
111
-
112
- ## Supported CLIs
113
-
114
- - Claude: `~/.claude/projects/{project-name}/`
115
- - Gemini: `~/.config/gemini/tmp/{hash}/chats/`
116
- - Qwen: `~/.qwen/projects/{project-name}/chats/`
117
- - iFlow: `~/.iflow/projects/{project-name}/`
118
- - CodeBuddy: `~/.codebuddy/projects/{project-name}/`
119
- - Codex: `~/.config/codex/`
120
- - QoderCLI: `~/.qoder/projects/{project-name}/`
121
- - Kode: `~/.kode/projects/{project-name}/`
122
-
123
- ## Notes
124
-
125
- **Best Practice**: Always open your terminal in project directory before using `stigmergy resume`. This ensures you recover sessions relevant to your current project.
126
-
127
- **Important**: By default, only sessions from **current working directory** are shown. Use `--all` to see sessions from all projects.
1
+ ---
2
+ name: resumesession
3
+ description: Cross-CLI session recovery and history management skill
4
+ author: stigmergy
5
+ version: 2.1.0
6
+ ---
7
+
8
+ # ResumeSession Skill
9
+
10
+ Cross-CLI session recovery and history management skill for all CLI tools.
11
+
12
+ ## Description
13
+
14
+ This skill enables Claude CLI and other AI assistants to recover and manage sessions across different CLI tools. When users ask to "恢复上次对话" (recover last conversation) or "查看历史会话" (view session history), this skill provides intelligent project-based filtering and context recovery.
15
+
16
+ **Configuration**: CLI paths and detection are managed by stigmergy. The skill reads configuration from `~/.stigmergy/config.json`.
17
+
18
+ ## When to Use This Skill
19
+
20
+ Use this skill when users request:
21
+ - 恢复上次对话 (recover last conversation)
22
+ - 查看历史会话 (view session history)
23
+ - 继续之前的讨论 (continue previous discussion)
24
+ - 找到之前的某个会话 (find a previous session)
25
+ - 查看某个 CLI 的会话 (view sessions from a specific CLI)
26
+
27
+ ## How It Works
28
+
29
+ ### 1. Identify User Intent
30
+
31
+ Analyze the user's request to determine:
32
+ - Whether they want to recover the latest session or browse multiple sessions
33
+ - Whether they want sessions from a specific CLI or all CLIs
34
+ - Whether they want sessions from current project or all projects
35
+
36
+ ### 2. Execute Recovery Tool
37
+
38
+ Call the `independent-resume.js` script with appropriate parameters:
39
+
40
+ ```javascript
41
+ // Default: recover latest session from current project
42
+ Bash("node independent-resume.js")
43
+
44
+ // Show 5 recent sessions from current project
45
+ Bash("node independent-resume.js 5")
46
+
47
+ // Show iFlow sessions from current project
48
+ Bash("node independent-resume.js iflow")
49
+
50
+ // Show all CLI sessions from current project
51
+ Bash("node independent-resume.js --all")
52
+
53
+ // Show all sessions from all projects
54
+ Bash("node independent-resume.js --complete")
55
+ ```
56
+
57
+ ### 3. Analyze and Present Results
58
+
59
+ The tool returns session data in a structured format. Use LLM intelligence to:
60
+ - Summarize the session content
61
+ - Highlight key information
62
+ - Provide context for continuation
63
+ - Help user select the right session if multiple are shown
64
+
65
+ ### 4. Continue Conversation
66
+
67
+ After displaying the session content, ask the user:
68
+ - "是否要继续这个会话?" (Do you want to continue this session?)
69
+ - "需要查看其他会话吗?" (Do you need to view other sessions?)
70
+ - "需要我帮你做什么?" (What would you like me to do?)
71
+
72
+ ## Configuration
73
+
74
+ **No manual configuration required!** The tool automatically detects installed CLI tools using a two-tier strategy:
75
+
76
+ ### Priority 1: Stigmergy Configuration (if available)
77
+
78
+ If stigmergy is installed and configured, the tool uses its CLI configuration:
79
+ - Reads from `~/.stigmergy/config.json`
80
+ - Uses stigmergy's scan results for CLI paths
81
+ - Supports custom CLI paths and multiple instances
82
+ - Provides the most accurate CLI detection
83
+
84
+ ### Priority 2: Automatic Detection (fallback)
85
+
86
+ If stigmergy is not available or has no configuration, the tool automatically scans common installation locations:
87
+ - Scans multiple common paths for each CLI
88
+ - Supports both Linux/Mac and Windows paths
89
+ - Detects CLI tools without user intervention
90
+ - Works out of the box for most installations
91
+
92
+ **Scanned Locations** (for each CLI):
93
+ - `~/.cli-name/projects/` (Linux/Mac)
94
+ - `~/.config/cli-name/projects/` (Linux/Mac)
95
+ - `~/AppData/Roaming/cli-name/projects/` (Windows)
96
+
97
+ **Supported CLI Tools**:
98
+ - Claude
99
+ - Gemini
100
+ - Qwen
101
+ - iFlow
102
+ - CodeBuddy
103
+ - Codex
104
+ - QoderCLI
105
+ - Kode
106
+
107
+ **Custom Installation Support**:
108
+ If a CLI is installed in a custom location:
109
+ - With stigmergy: Configure in stigmergy for best results
110
+ - Without stigmergy: The tool scans multiple candidate paths automatically
111
+
112
+ ## Usage Examples
113
+
114
+ ### Example 1: Quick Recovery
115
+
116
+ **User**: "恢复上次对话"
117
+
118
+ **AI Response**:
119
+ 1. Execute: `node independent-resume.js`
120
+ 2. Display the latest session content
121
+ 3. Ask: "已恢复上次对话。是否要继续?"
122
+
123
+ ### Example 2: Browse Recent Sessions
124
+
125
+ **User**: "查看最近几次会话"
126
+
127
+ **AI Response**:
128
+ 1. Execute: `node independent-resume.js 5`
129
+ 2. Display the 5 most recent sessions with summaries
130
+ 3. Ask: "找到了 5 个会话。你想继续哪个?"
131
+
132
+ ### Example 3: Filter by CLI
133
+
134
+ **User**: "看看 iFlow 的会话"
135
+
136
+ **AI Response**:
137
+ 1. Execute: `node independent-resume.js iflow`
138
+ 2. Display all iFlow sessions from current project
139
+ 3. Ask: "找到了 X 个 iFlow 会话。你想继续哪个?"
140
+
141
+ ### Example 4: View All Projects
142
+
143
+ **User**: "查看所有项目的会话"
144
+
145
+ **AI Response**:
146
+ 1. Execute: `node independent-resume.js --complete`
147
+ 2. Display sessions grouped by project
148
+ 3. Ask: "你想查看哪个项目的会话?"
149
+
150
+ ## Features
151
+
152
+ - ✅ **Project-Aware**: Automatically filters sessions by current working directory
153
+ - ✅ **Default Context Recovery**: Shows latest session content by default
154
+ - ✅ **Number-Based Control**: Use numbers to show multiple sessions
155
+ - ✅ **CLI Filtering**: Filter sessions by specific CLI tool
156
+ - ✅ **All CLI View**: Show all CLI sessions for current project
157
+ - ✅ **Complete View**: Show all projects' sessions grouped by project
158
+ - ✅ **Cross-CLI Support**: Works with Claude, Gemini, Qwen, iFlow, CodeBuddy, Codex, QoderCLI, Kode
159
+ - ✅ **Smart Project Recognition**: Automatically matches sessions to current project
160
+ - ✅ **Relative Time Display**: Shows relative time (e.g., "5 minutes ago")
161
+
162
+ ## Tool Parameters
163
+
164
+ | Parameter | Description |
165
+ |-----------|-------------|
166
+ | (none) | Recover latest session from current project |
167
+ | `[number]` | Show N most recent sessions from current project |
168
+ | `[cli-name]` | Show sessions from specific CLI (current project) |
169
+ | `[cli-name] [number]` | Show N sessions from specific CLI |
170
+ | `--all` | Show all CLI sessions from current project |
171
+ | `--complete` | Show all sessions from all projects |
172
+
173
+ ## Supported CLIs
174
+
175
+ This skill supports any CLI tool that:
176
+ - Stores sessions in files (typically JSON)
177
+ - Can be configured in stigmergy
178
+ - Has extractable project and session information
179
+
180
+ **Common CLI Tools** (examples, not limited to):
181
+ - Claude
182
+ - Gemini
183
+ - Qwen
184
+ - iFlow
185
+ - CodeBuddy
186
+ - Codex
187
+ - QoderCLI
188
+ - Kode
189
+
190
+ **Custom CLI Support**:
191
+ - Add any CLI to stigmergy configuration
192
+ - Support multiple instances of the same CLI
193
+ - Support custom installation paths
194
+ - Support custom session formats
195
+
196
+ ## Notes
197
+
198
+ **Configuration Strategy**:
199
+ - **Priority 1**: Uses stigmergy configuration if available (most accurate)
200
+ - **Priority 2**: Falls back to automatic detection (works out of the box)
201
+ - No manual configuration required in either case
202
+ - Seamlessly switches between strategies based on environment
203
+
204
+ **Context Loading**: When recovering a session, load the conversation history as context for the LLM to understand the previous discussion.
205
+
206
+ **Project Awareness**: The tool automatically identifies the current project based on the working directory. Ensure users are in the correct project directory.
207
+
208
+ **Error Handling**:
209
+ - If no sessions are found, inform the user and suggest they check if CLI tools have created sessions
210
+ - The tool automatically detects installed CLI tools (with or without stigmergy)
211
+ - If CLI is installed in a custom location, ensure the session directory is accessible
@@ -1,33 +1,33 @@
1
- {
2
- "name": "resumesession",
3
- "displayName": "ResumeSession",
4
- "version": "2.0.0",
5
- "description": "Cross-CLI session recovery and history management with project-aware filtering",
6
- "capabilities": [
7
- "Recover latest session from current project",
8
- "Check session content and skip empty sessions",
9
- "Show multiple sessions from current project",
10
- "Filter sessions by specific CLI",
11
- "Search sessions by content keywords",
12
- "Filter sessions by date range (today, week, month)",
13
- "Show sessions from all projects with --all flag",
14
- "Multiple view formats: summary, timeline, detailed, context",
15
- "Cross-CLI support: Claude, Gemini, Qwen, iFlow, CodeBuddy, Codex, QoderCLI, Kode"
16
- ],
17
- "protocols": ["chinese", "english"],
18
- "hooks": [],
19
- "enabled": true,
20
- "category": "session-management",
21
- "author": "stigmergy",
22
- "dependencies": [],
23
- "implementations": [
24
- {
25
- "name": "stigmergy-resume",
26
- "version": "2.0.0",
27
- "language": "javascript",
28
- "description": "Project-aware session recovery tool",
29
- "runtime": "node",
30
- "entry_point": "src/cli/commands/stigmergy-resume.js"
31
- }
32
- ]
33
- }
1
+ {
2
+ "name": "resumesession",
3
+ "displayName": "ResumeSession",
4
+ "version": "2.0.0",
5
+ "description": "Cross-CLI session recovery and history management with project-aware filtering",
6
+ "capabilities": [
7
+ "Recover latest session from current project",
8
+ "Check session content and skip empty sessions",
9
+ "Show multiple sessions from current project",
10
+ "Filter sessions by specific CLI",
11
+ "Search sessions by content keywords",
12
+ "Filter sessions by date range (today, week, month)",
13
+ "Show sessions from all projects with --all flag",
14
+ "Multiple view formats: summary, timeline, detailed, context",
15
+ "Cross-CLI support: Claude, Gemini, Qwen, iFlow, CodeBuddy, Codex, QoderCLI, Kode"
16
+ ],
17
+ "protocols": ["chinese", "english"],
18
+ "hooks": [],
19
+ "enabled": true,
20
+ "category": "session-management",
21
+ "author": "stigmergy",
22
+ "dependencies": [],
23
+ "implementations": [
24
+ {
25
+ "name": "stigmergy-resume",
26
+ "version": "2.0.0",
27
+ "language": "javascript",
28
+ "description": "Project-aware session recovery tool",
29
+ "runtime": "node",
30
+ "entry_point": "src/cli/commands/stigmergy-resume.js"
31
+ }
32
+ ]
33
+ }
@@ -1,13 +1,13 @@
1
- {
2
- "name": "simple-resume",
3
- "version": "1.0.0",
4
- "description": "Simple cross-CLI session recovery tool",
5
- "language": "javascript",
6
- "runtime": "node",
7
- "entry_point": "src/cli/commands/simple-resume.js",
8
- "metadata": {
9
- "cli_type": "cross-cli",
10
- "session_scope": "all",
11
- "output_format": "full"
12
- }
13
- }
1
+ {
2
+ "name": "simple-resume",
3
+ "version": "1.0.0",
4
+ "description": "Simple cross-CLI session recovery tool",
5
+ "language": "javascript",
6
+ "runtime": "node",
7
+ "entry_point": "src/cli/commands/simple-resume.js",
8
+ "metadata": {
9
+ "cli_type": "cross-cli",
10
+ "session_scope": "all",
11
+ "output_format": "full"
12
+ }
13
+ }