@xelth/eck-snapshot 4.3.0 → 4.3.2
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.
Potentially problematic release.
This version of @xelth/eck-snapshot might be problematic. Click here for more details.
- package/README.md +66 -26
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -32,33 +32,9 @@ npm install -g @xelth/eck-snapshot
|
|
|
32
32
|
|
|
33
33
|
Once installed, you can run the tool using the `eck-snapshot` command from any directory.
|
|
34
34
|
|
|
35
|
-
## Workflow
|
|
35
|
+
## Getting Started: Full Snapshot Workflow
|
|
36
36
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
The skeleton workflow is optimized for web-based LLMs (Gemini, ChatGPT) with large context windows. It uses a three-step approach:
|
|
40
|
-
|
|
41
|
-
1. **Initial Context (Maximum Compression):** Create a lightweight map of your entire project where function/method bodies are hidden, showing only signatures and structure.
|
|
42
|
-
```bash
|
|
43
|
-
eck-snapshot --skeleton
|
|
44
|
-
```
|
|
45
|
-
This generates `.eck/snapshots/<name>_sk.md` - a compressed overview that fits even large monoliths into the context window.
|
|
46
|
-
|
|
47
|
-
2. **Lazy Loading (On-Demand Details):** When the AI needs implementation details, use the `show` command to display specific files:
|
|
48
|
-
```bash
|
|
49
|
-
eck-snapshot show src/auth.js src/utils/hash.js
|
|
50
|
-
```
|
|
51
|
-
Copy-paste the output back to your AI chat.
|
|
52
|
-
|
|
53
|
-
3. **Incremental Updates:** As you make changes, send only what changed since the last snapshot instead of the entire repo:
|
|
54
|
-
```bash
|
|
55
|
-
eck-snapshot update
|
|
56
|
-
```
|
|
57
|
-
This generates `.eck/snapshots/update_<timestamp>.md` containing only changed files and git diffs.
|
|
58
|
-
|
|
59
|
-
### Option 2: Full Snapshot Workflow
|
|
60
|
-
|
|
61
|
-
Here's the traditional workflow for creating complete snapshots and focusing on specific features.
|
|
37
|
+
This is the primary workflow for creating complete snapshots of your project.
|
|
62
38
|
|
|
63
39
|
#### Step 1: Create a Full Project Snapshot
|
|
64
40
|
|
|
@@ -130,6 +106,70 @@ A faster, non-AI method to reduce snapshot size. This command keeps only the top
|
|
|
130
106
|
> eck-snapshot --max-lines-per-file 200
|
|
131
107
|
> ```
|
|
132
108
|
|
|
109
|
+
## Skeleton Workflow (Advanced for Large Projects)
|
|
110
|
+
|
|
111
|
+
The skeleton workflow is optimized for web-based LLMs (Gemini, ChatGPT) with large context windows. It uses a three-step approach for maximum compression:
|
|
112
|
+
|
|
113
|
+
### 1. Initial Context (Maximum Compression)
|
|
114
|
+
|
|
115
|
+
Create a lightweight map of your entire project where function/method bodies are hidden, showing only signatures and structure.
|
|
116
|
+
|
|
117
|
+
```bash
|
|
118
|
+
eck-snapshot --skeleton
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
This generates `.eck/snapshots/<name>_sk.md` - a compressed overview that fits even large monoliths into the context window.
|
|
122
|
+
|
|
123
|
+
### 2. Lazy Loading (On-Demand Details)
|
|
124
|
+
|
|
125
|
+
When the AI needs implementation details, use the `show` command to display specific files:
|
|
126
|
+
|
|
127
|
+
```bash
|
|
128
|
+
eck-snapshot show src/auth.js src/utils/hash.js
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
Copy-paste the output back to your AI chat.
|
|
132
|
+
|
|
133
|
+
### 3. Incremental Updates
|
|
134
|
+
|
|
135
|
+
After making changes, use the `update` command (see section below) to send only what changed.
|
|
136
|
+
|
|
137
|
+
## Incremental Updates: The `update` Command
|
|
138
|
+
|
|
139
|
+
The `update` command is a powerful feature that creates **delta snapshots** containing only the files that changed since your last full snapshot. This is essential for maintaining AI context efficiently during active development.
|
|
140
|
+
|
|
141
|
+
### How It Works
|
|
142
|
+
|
|
143
|
+
1. **Anchor Point:** When you create a full snapshot (with `eck-snapshot` or `eck-snapshot --skeleton`), the current git commit hash is saved as an "anchor" in `.eck/.snapshot-anchor`.
|
|
144
|
+
|
|
145
|
+
2. **Change Detection:** The `update` command compares your current working directory against this anchor to identify all modified, added, or deleted files.
|
|
146
|
+
|
|
147
|
+
3. **Delta Generation:** It creates a new snapshot file containing:
|
|
148
|
+
- Only the changed files (with full content)
|
|
149
|
+
- A git diff showing all changes for context
|
|
150
|
+
- Clear instructions for the AI to merge these changes with the base snapshot
|
|
151
|
+
|
|
152
|
+
### Usage
|
|
153
|
+
|
|
154
|
+
```bash
|
|
155
|
+
eck-snapshot update
|
|
156
|
+
```
|
|
157
|
+
|
|
158
|
+
This generates `.eck/snapshots/update_<timestamp>.md`.
|
|
159
|
+
|
|
160
|
+
### When to Use
|
|
161
|
+
|
|
162
|
+
- **During active development:** After making changes based on AI suggestions, send an update instead of the entire codebase
|
|
163
|
+
- **Iterative workflows:** Keep the AI synchronized with your latest code without re-uploading everything
|
|
164
|
+
- **Large projects:** Especially valuable when the full snapshot is large - updates are typically much smaller
|
|
165
|
+
|
|
166
|
+
### Important Notes
|
|
167
|
+
|
|
168
|
+
- You must create a full snapshot first before using `update`
|
|
169
|
+
- Each update is self-contained - send only the latest update to the AI, not all previous updates
|
|
170
|
+
- The AI is instructed to "merge" the update over the base snapshot mentally
|
|
171
|
+
- Works with both regular and skeleton snapshots
|
|
172
|
+
|
|
133
173
|
## Auxiliary Commands
|
|
134
174
|
|
|
135
175
|
* `restore <snapshot_file>`: Recreates a project's file structure from a snapshot.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xelth/eck-snapshot",
|
|
3
|
-
"version": "4.3.
|
|
3
|
+
"version": "4.3.2",
|
|
4
4
|
"description": "A powerful CLI tool to create and restore single-file text snapshots of Git repositories and directories. Optimized for AI context and LLM workflows.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"type": "module",
|