keep-skill 0.2.0__tar.gz → 0.4.1__tar.gz
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.
- {keep_skill-0.2.0 → keep_skill-0.4.1}/.gitignore +2 -0
- keep_skill-0.4.1/PKG-INFO +219 -0
- keep_skill-0.4.1/README.md +168 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/SKILL.md +67 -17
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/__init__.py +1 -1
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/api.py +325 -11
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/cli.py +453 -83
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/config.py +2 -2
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/document_store.py +351 -12
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/pending_summaries.py +6 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/providers/embedding_cache.py +6 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/store.py +128 -11
- {keep_skill-0.2.0 → keep_skill-0.4.1}/pyproject.toml +1 -1
- keep_skill-0.2.0/PKG-INFO +0 -304
- keep_skill-0.2.0/README.md +0 -253
- {keep_skill-0.2.0 → keep_skill-0.4.1}/LICENSE +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/docs/system/conversations.md +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/docs/system/domains.md +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/docs/system/now.md +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/__main__.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/chunking.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/context.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/errors.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/indexing.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/logging_config.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/paths.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/providers/__init__.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/providers/base.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/providers/documents.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/providers/embeddings.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/providers/llm.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/providers/mlx.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/providers/summarization.py +0 -0
- {keep_skill-0.2.0 → keep_skill-0.4.1}/keep/types.py +0 -0
|
@@ -0,0 +1,219 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: keep-skill
|
|
3
|
+
Version: 0.4.1
|
|
4
|
+
Summary: Semantic memory - remember and search documents by meaning
|
|
5
|
+
Project-URL: Homepage, https://github.com/hughpyle/keep
|
|
6
|
+
Project-URL: Repository, https://github.com/hughpyle/keep
|
|
7
|
+
Author: Hugh Pyle
|
|
8
|
+
License: MIT
|
|
9
|
+
License-File: LICENSE
|
|
10
|
+
Keywords: agents,chromadb,embeddings,semantic-memory,vector-search
|
|
11
|
+
Classifier: Development Status :: 3 - Alpha
|
|
12
|
+
Classifier: Intended Audience :: Developers
|
|
13
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
14
|
+
Classifier: Programming Language :: Python :: 3
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
18
|
+
Classifier: Topic :: Software Development :: Libraries
|
|
19
|
+
Classifier: Topic :: Text Processing
|
|
20
|
+
Requires-Python: <3.14,>=3.11
|
|
21
|
+
Requires-Dist: chromadb>=0.4
|
|
22
|
+
Requires-Dist: tomli-w>=1.0
|
|
23
|
+
Requires-Dist: typer>=0.9
|
|
24
|
+
Provides-Extra: anthropic
|
|
25
|
+
Requires-Dist: anthropic>=0.40.0; extra == 'anthropic'
|
|
26
|
+
Provides-Extra: dev
|
|
27
|
+
Requires-Dist: pytest-cov>=4.0; extra == 'dev'
|
|
28
|
+
Requires-Dist: pytest>=7.0; extra == 'dev'
|
|
29
|
+
Provides-Extra: documents
|
|
30
|
+
Requires-Dist: beautifulsoup4>=4.9; extra == 'documents'
|
|
31
|
+
Requires-Dist: pypdf>=5.0; extra == 'documents'
|
|
32
|
+
Provides-Extra: gemini
|
|
33
|
+
Requires-Dist: google-genai>=1.0.0; extra == 'gemini'
|
|
34
|
+
Provides-Extra: local
|
|
35
|
+
Requires-Dist: beautifulsoup4>=4.9; extra == 'local'
|
|
36
|
+
Requires-Dist: mlx-lm>=0.10; (platform_system == 'Darwin' and platform_machine == 'arm64') and extra == 'local'
|
|
37
|
+
Requires-Dist: mlx>=0.10; (platform_system == 'Darwin' and platform_machine == 'arm64') and extra == 'local'
|
|
38
|
+
Requires-Dist: pypdf>=5.0; extra == 'local'
|
|
39
|
+
Requires-Dist: sentence-transformers>=2.2; extra == 'local'
|
|
40
|
+
Provides-Extra: mlx
|
|
41
|
+
Requires-Dist: mlx-lm>=0.10; extra == 'mlx'
|
|
42
|
+
Requires-Dist: mlx>=0.10; extra == 'mlx'
|
|
43
|
+
Provides-Extra: openai
|
|
44
|
+
Requires-Dist: openai>=1.0; extra == 'openai'
|
|
45
|
+
Provides-Extra: openclaw
|
|
46
|
+
Requires-Dist: anthropic>=0.18.0; extra == 'openclaw'
|
|
47
|
+
Requires-Dist: google-genai>=1.0.0; extra == 'openclaw'
|
|
48
|
+
Provides-Extra: sentence-transformers
|
|
49
|
+
Requires-Dist: sentence-transformers>=2.2; extra == 'sentence-transformers'
|
|
50
|
+
Description-Content-Type: text/markdown
|
|
51
|
+
|
|
52
|
+
# keep
|
|
53
|
+
|
|
54
|
+
**Semantic memory with version history.**
|
|
55
|
+
|
|
56
|
+
Index documents and notes. Search by meaning. Track changes over time.
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
pip install 'keep-skill[local]'
|
|
60
|
+
keep init
|
|
61
|
+
|
|
62
|
+
# Index content
|
|
63
|
+
keep update path/to/document.md -t project=myapp
|
|
64
|
+
keep update "Rate limit is 100 req/min" -t topic=api
|
|
65
|
+
|
|
66
|
+
# Search by meaning
|
|
67
|
+
keep find "what's the rate limit?"
|
|
68
|
+
|
|
69
|
+
# Track what you're working on
|
|
70
|
+
keep now "Debugging auth flow"
|
|
71
|
+
keep now -V 1 # Previous context
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
---
|
|
75
|
+
|
|
76
|
+
## What It Does
|
|
77
|
+
|
|
78
|
+
- **Semantic search** — Find by meaning, not just keywords
|
|
79
|
+
- **Version history** — All documents retain history on update
|
|
80
|
+
- **Tag organization** — Filter and navigate with key=value tags
|
|
81
|
+
- **Recency decay** — Recent items rank higher in search
|
|
82
|
+
- **Works offline** — Local embedding models by default
|
|
83
|
+
|
|
84
|
+
Backed by ChromaDB for vectors, SQLite for metadata and versions.
|
|
85
|
+
|
|
86
|
+
---
|
|
87
|
+
|
|
88
|
+
## Installation
|
|
89
|
+
|
|
90
|
+
**Python 3.11–3.13 required.**
|
|
91
|
+
|
|
92
|
+
```bash
|
|
93
|
+
# Recommended: local models (works offline)
|
|
94
|
+
pip install 'keep-skill[local]'
|
|
95
|
+
|
|
96
|
+
# Or with uv (faster):
|
|
97
|
+
uv tool install 'keep-skill[local]'
|
|
98
|
+
|
|
99
|
+
# API-based alternative (requires OPENAI_API_KEY)
|
|
100
|
+
pip install 'keep-skill[openai]'
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
First run downloads embedding models (~3-5 minutes).
|
|
104
|
+
|
|
105
|
+
---
|
|
106
|
+
|
|
107
|
+
## Quick Start
|
|
108
|
+
|
|
109
|
+
```bash
|
|
110
|
+
keep init # Creates .keep/ at repo root
|
|
111
|
+
|
|
112
|
+
# Index files and notes
|
|
113
|
+
keep update file:///path/to/doc.md -t project=myapp
|
|
114
|
+
keep update "Important insight" -t type=note
|
|
115
|
+
|
|
116
|
+
# Search
|
|
117
|
+
keep find "authentication flow" --limit 5
|
|
118
|
+
keep find "auth" --since P7D # Last 7 days
|
|
119
|
+
|
|
120
|
+
# Retrieve
|
|
121
|
+
keep get file:///path/to/doc.md
|
|
122
|
+
keep get ID -V 1 # Previous version
|
|
123
|
+
keep get "ID@V{1}" # Same as -V 1 (version identifier)
|
|
124
|
+
keep get ID --history # All versions
|
|
125
|
+
|
|
126
|
+
# Tags
|
|
127
|
+
keep tag project=myapp # Find by tag
|
|
128
|
+
keep tag --list # List all tags
|
|
129
|
+
|
|
130
|
+
# Current context
|
|
131
|
+
keep now # Show what you're working on
|
|
132
|
+
keep now "Fixing login bug" # Update context
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
### Python API
|
|
136
|
+
|
|
137
|
+
```python
|
|
138
|
+
from keep import Keeper
|
|
139
|
+
|
|
140
|
+
kp = Keeper()
|
|
141
|
+
|
|
142
|
+
# Index
|
|
143
|
+
kp.update("file:///path/to/doc.md", tags={"project": "myapp"})
|
|
144
|
+
kp.remember("Rate limit is 100 req/min", tags={"topic": "api"})
|
|
145
|
+
|
|
146
|
+
# Search
|
|
147
|
+
results = kp.find("rate limit", limit=5)
|
|
148
|
+
for r in results:
|
|
149
|
+
print(f"[{r.score:.2f}] {r.summary}")
|
|
150
|
+
|
|
151
|
+
# Version history
|
|
152
|
+
prev = kp.get_version("doc:1", offset=1)
|
|
153
|
+
versions = kp.list_versions("doc:1")
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
See [docs/QUICKSTART.md](docs/QUICKSTART.md) for configuration and more examples.
|
|
157
|
+
|
|
158
|
+
---
|
|
159
|
+
|
|
160
|
+
## Documentation
|
|
161
|
+
|
|
162
|
+
- **[docs/QUICKSTART.md](docs/QUICKSTART.md)** — Setup, configuration, lazy summarization
|
|
163
|
+
- **[docs/REFERENCE.md](docs/REFERENCE.md)** — Complete CLI and API reference
|
|
164
|
+
- **[docs/AGENT-GUIDE.md](docs/AGENT-GUIDE.md)** — Working session patterns
|
|
165
|
+
- **[docs/ARCHITECTURE.md](docs/ARCHITECTURE.md)** — How it works under the hood
|
|
166
|
+
- **[SKILL.md](SKILL.md)** — The reflective practice (for AI agents)
|
|
167
|
+
|
|
168
|
+
---
|
|
169
|
+
|
|
170
|
+
## For AI Agents
|
|
171
|
+
|
|
172
|
+
This library was designed as an agent skill — persistent memory that helps agents reflect before acting and learn from experience.
|
|
173
|
+
|
|
174
|
+
**The practice:**
|
|
175
|
+
- Pause before acting — `keep find` what you already know
|
|
176
|
+
- Notice breakdowns — when assumptions surface, index them
|
|
177
|
+
- Reflect after — `keep update` learnings for future sessions
|
|
178
|
+
|
|
179
|
+
See **[SKILL.md](SKILL.md)** for the full practice guide.
|
|
180
|
+
|
|
181
|
+
---
|
|
182
|
+
|
|
183
|
+
## Status
|
|
184
|
+
|
|
185
|
+
**Current:** v0.3.0
|
|
186
|
+
|
|
187
|
+
**Working:**
|
|
188
|
+
- ✅ Semantic search with embeddings
|
|
189
|
+
- ✅ Document versioning (all updates retain history)
|
|
190
|
+
- ✅ Content-addressed IDs for text (same content = same ID)
|
|
191
|
+
- ✅ Tag queries and full-text search
|
|
192
|
+
- ✅ Current context tracking (`keep now`)
|
|
193
|
+
- ✅ Recency decay (recent items rank higher)
|
|
194
|
+
- ✅ Lazy summarization (background processing)
|
|
195
|
+
- ✅ Provider abstraction (local or API-based)
|
|
196
|
+
|
|
197
|
+
**Planned** (see [later/](later/)):
|
|
198
|
+
- ⏳ Private/shared routing
|
|
199
|
+
- ⏳ Relationship graphs between items
|
|
200
|
+
- ⏳ LLM-based auto-tagging
|
|
201
|
+
|
|
202
|
+
---
|
|
203
|
+
|
|
204
|
+
## License
|
|
205
|
+
|
|
206
|
+
MIT
|
|
207
|
+
|
|
208
|
+
---
|
|
209
|
+
|
|
210
|
+
## Contributing
|
|
211
|
+
|
|
212
|
+
Published on [PyPI as `keep-skill`](https://pypi.org/project/keep-skill/).
|
|
213
|
+
|
|
214
|
+
Issues and PRs welcome:
|
|
215
|
+
- Provider implementations
|
|
216
|
+
- Performance improvements
|
|
217
|
+
- Documentation clarity
|
|
218
|
+
|
|
219
|
+
See [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines.
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
# keep
|
|
2
|
+
|
|
3
|
+
**Semantic memory with version history.**
|
|
4
|
+
|
|
5
|
+
Index documents and notes. Search by meaning. Track changes over time.
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
pip install 'keep-skill[local]'
|
|
9
|
+
keep init
|
|
10
|
+
|
|
11
|
+
# Index content
|
|
12
|
+
keep update path/to/document.md -t project=myapp
|
|
13
|
+
keep update "Rate limit is 100 req/min" -t topic=api
|
|
14
|
+
|
|
15
|
+
# Search by meaning
|
|
16
|
+
keep find "what's the rate limit?"
|
|
17
|
+
|
|
18
|
+
# Track what you're working on
|
|
19
|
+
keep now "Debugging auth flow"
|
|
20
|
+
keep now -V 1 # Previous context
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
## What It Does
|
|
26
|
+
|
|
27
|
+
- **Semantic search** — Find by meaning, not just keywords
|
|
28
|
+
- **Version history** — All documents retain history on update
|
|
29
|
+
- **Tag organization** — Filter and navigate with key=value tags
|
|
30
|
+
- **Recency decay** — Recent items rank higher in search
|
|
31
|
+
- **Works offline** — Local embedding models by default
|
|
32
|
+
|
|
33
|
+
Backed by ChromaDB for vectors, SQLite for metadata and versions.
|
|
34
|
+
|
|
35
|
+
---
|
|
36
|
+
|
|
37
|
+
## Installation
|
|
38
|
+
|
|
39
|
+
**Python 3.11–3.13 required.**
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
# Recommended: local models (works offline)
|
|
43
|
+
pip install 'keep-skill[local]'
|
|
44
|
+
|
|
45
|
+
# Or with uv (faster):
|
|
46
|
+
uv tool install 'keep-skill[local]'
|
|
47
|
+
|
|
48
|
+
# API-based alternative (requires OPENAI_API_KEY)
|
|
49
|
+
pip install 'keep-skill[openai]'
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
First run downloads embedding models (~3-5 minutes).
|
|
53
|
+
|
|
54
|
+
---
|
|
55
|
+
|
|
56
|
+
## Quick Start
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
keep init # Creates .keep/ at repo root
|
|
60
|
+
|
|
61
|
+
# Index files and notes
|
|
62
|
+
keep update file:///path/to/doc.md -t project=myapp
|
|
63
|
+
keep update "Important insight" -t type=note
|
|
64
|
+
|
|
65
|
+
# Search
|
|
66
|
+
keep find "authentication flow" --limit 5
|
|
67
|
+
keep find "auth" --since P7D # Last 7 days
|
|
68
|
+
|
|
69
|
+
# Retrieve
|
|
70
|
+
keep get file:///path/to/doc.md
|
|
71
|
+
keep get ID -V 1 # Previous version
|
|
72
|
+
keep get "ID@V{1}" # Same as -V 1 (version identifier)
|
|
73
|
+
keep get ID --history # All versions
|
|
74
|
+
|
|
75
|
+
# Tags
|
|
76
|
+
keep tag project=myapp # Find by tag
|
|
77
|
+
keep tag --list # List all tags
|
|
78
|
+
|
|
79
|
+
# Current context
|
|
80
|
+
keep now # Show what you're working on
|
|
81
|
+
keep now "Fixing login bug" # Update context
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
### Python API
|
|
85
|
+
|
|
86
|
+
```python
|
|
87
|
+
from keep import Keeper
|
|
88
|
+
|
|
89
|
+
kp = Keeper()
|
|
90
|
+
|
|
91
|
+
# Index
|
|
92
|
+
kp.update("file:///path/to/doc.md", tags={"project": "myapp"})
|
|
93
|
+
kp.remember("Rate limit is 100 req/min", tags={"topic": "api"})
|
|
94
|
+
|
|
95
|
+
# Search
|
|
96
|
+
results = kp.find("rate limit", limit=5)
|
|
97
|
+
for r in results:
|
|
98
|
+
print(f"[{r.score:.2f}] {r.summary}")
|
|
99
|
+
|
|
100
|
+
# Version history
|
|
101
|
+
prev = kp.get_version("doc:1", offset=1)
|
|
102
|
+
versions = kp.list_versions("doc:1")
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
See [docs/QUICKSTART.md](docs/QUICKSTART.md) for configuration and more examples.
|
|
106
|
+
|
|
107
|
+
---
|
|
108
|
+
|
|
109
|
+
## Documentation
|
|
110
|
+
|
|
111
|
+
- **[docs/QUICKSTART.md](docs/QUICKSTART.md)** — Setup, configuration, lazy summarization
|
|
112
|
+
- **[docs/REFERENCE.md](docs/REFERENCE.md)** — Complete CLI and API reference
|
|
113
|
+
- **[docs/AGENT-GUIDE.md](docs/AGENT-GUIDE.md)** — Working session patterns
|
|
114
|
+
- **[docs/ARCHITECTURE.md](docs/ARCHITECTURE.md)** — How it works under the hood
|
|
115
|
+
- **[SKILL.md](SKILL.md)** — The reflective practice (for AI agents)
|
|
116
|
+
|
|
117
|
+
---
|
|
118
|
+
|
|
119
|
+
## For AI Agents
|
|
120
|
+
|
|
121
|
+
This library was designed as an agent skill — persistent memory that helps agents reflect before acting and learn from experience.
|
|
122
|
+
|
|
123
|
+
**The practice:**
|
|
124
|
+
- Pause before acting — `keep find` what you already know
|
|
125
|
+
- Notice breakdowns — when assumptions surface, index them
|
|
126
|
+
- Reflect after — `keep update` learnings for future sessions
|
|
127
|
+
|
|
128
|
+
See **[SKILL.md](SKILL.md)** for the full practice guide.
|
|
129
|
+
|
|
130
|
+
---
|
|
131
|
+
|
|
132
|
+
## Status
|
|
133
|
+
|
|
134
|
+
**Current:** v0.3.0
|
|
135
|
+
|
|
136
|
+
**Working:**
|
|
137
|
+
- ✅ Semantic search with embeddings
|
|
138
|
+
- ✅ Document versioning (all updates retain history)
|
|
139
|
+
- ✅ Content-addressed IDs for text (same content = same ID)
|
|
140
|
+
- ✅ Tag queries and full-text search
|
|
141
|
+
- ✅ Current context tracking (`keep now`)
|
|
142
|
+
- ✅ Recency decay (recent items rank higher)
|
|
143
|
+
- ✅ Lazy summarization (background processing)
|
|
144
|
+
- ✅ Provider abstraction (local or API-based)
|
|
145
|
+
|
|
146
|
+
**Planned** (see [later/](later/)):
|
|
147
|
+
- ⏳ Private/shared routing
|
|
148
|
+
- ⏳ Relationship graphs between items
|
|
149
|
+
- ⏳ LLM-based auto-tagging
|
|
150
|
+
|
|
151
|
+
---
|
|
152
|
+
|
|
153
|
+
## License
|
|
154
|
+
|
|
155
|
+
MIT
|
|
156
|
+
|
|
157
|
+
---
|
|
158
|
+
|
|
159
|
+
## Contributing
|
|
160
|
+
|
|
161
|
+
Published on [PyPI as `keep-skill`](https://pypi.org/project/keep-skill/).
|
|
162
|
+
|
|
163
|
+
Issues and PRs welcome:
|
|
164
|
+
- Provider implementations
|
|
165
|
+
- Performance improvements
|
|
166
|
+
- Documentation clarity
|
|
167
|
+
|
|
168
|
+
See [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: keep
|
|
3
|
-
version: 0.1
|
|
3
|
+
version: 0.4.1
|
|
4
4
|
description: Associative memory for reflection and skillful action
|
|
5
5
|
homepage: https://github.com/hughpyle/keep
|
|
6
6
|
runtime: python:3.12-slim
|
|
@@ -26,12 +26,16 @@ You have a memory. Use it — not sometimes, but as practice.
|
|
|
26
26
|
|
|
27
27
|
Ground yourself:
|
|
28
28
|
1. What kind of conversation is this? (Action? Possibility? Clarification?)
|
|
29
|
-
2.
|
|
29
|
+
2. Where am I? What's the current context?
|
|
30
|
+
```bash
|
|
31
|
+
keep now
|
|
32
|
+
```
|
|
33
|
+
3. What do I already know about this?
|
|
30
34
|
```bash
|
|
31
35
|
keep find "what I'm about to work on"
|
|
32
36
|
```
|
|
33
|
-
|
|
34
|
-
|
|
37
|
+
4. Be here, now, "aquí donde los papas queman", and reflect.
|
|
38
|
+
5. Only then: act.
|
|
35
39
|
|
|
36
40
|
**After acting, reflect:**
|
|
37
41
|
- What happened? What did I learn?
|
|
@@ -106,7 +110,7 @@ Then retrieve and read it:
|
|
|
106
110
|
keep get "file://$PWD/docs/library/mn61.html"
|
|
107
111
|
```
|
|
108
112
|
|
|
109
|
-
This teaching (MN 61) uses the mirror metaphor: "What is a mirror for?" "For reflection." Actions — bodily, verbal, mental — are to be done with repeated reflection. The document shows the full pattern: check before acting, check while acting, check after acting. If unskillful, confess and adjust. If skillful, stay refreshed and continue training.
|
|
113
|
+
This teaching ([MN 61](docs/library/mn61.html)) uses the mirror metaphor: "What is a mirror for?" "For reflection." Actions — bodily, verbal, mental — are to be done with repeated reflection. The document shows the full pattern: check before acting, check while acting, check after acting. If unskillful, confess and adjust. If skillful, stay refreshed and continue training.
|
|
110
114
|
|
|
111
115
|
### Breakdowns Are Valuable
|
|
112
116
|
|
|
@@ -140,7 +144,7 @@ These aren't test fixtures. They're seed wisdom:
|
|
|
140
144
|
|
|
141
145
|
- **[true_person_no_rank.md](docs/library/true_person_no_rank.md)** — A Zen teaching with layers of commentary. Notice how each commentator re-enacts the pointing from a different angle — not explaining, not accumulating facts, but each responding to what students in that era needed. This is how knowledge in your memory should relate: organic, not hierarchical.
|
|
142
146
|
|
|
143
|
-
|
|
147
|
+
The [docs/library/](docs/library/) directory contains additional seed material.
|
|
144
148
|
|
|
145
149
|
---
|
|
146
150
|
|
|
@@ -158,8 +162,41 @@ Update it as your focus changes:
|
|
|
158
162
|
keep now "Working on authentication bug in login flow"
|
|
159
163
|
```
|
|
160
164
|
|
|
165
|
+
Check previous context if needed:
|
|
166
|
+
```bash
|
|
167
|
+
keep now -V 1 # Previous context
|
|
168
|
+
keep now --history # All versions
|
|
169
|
+
```
|
|
170
|
+
|
|
161
171
|
This helps future you (and other agents) pick up where you left off.
|
|
162
172
|
|
|
173
|
+
### Similar Items for Discovery
|
|
174
|
+
|
|
175
|
+
When you retrieve an item, you automatically see related items:
|
|
176
|
+
|
|
177
|
+
```bash
|
|
178
|
+
keep get ID # Shows up to 3 similar items
|
|
179
|
+
keep get ID --similar # List more similar items
|
|
180
|
+
keep get ID --no-similar # Just the document
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
This enables serendipitous discovery — you may find relevant context you didn't know to search for.
|
|
184
|
+
|
|
185
|
+
### Version History
|
|
186
|
+
|
|
187
|
+
All documents retain history on update. Use this to see how understanding evolved:
|
|
188
|
+
|
|
189
|
+
```bash
|
|
190
|
+
keep get ID -V 1 # Previous version
|
|
191
|
+
keep get ID --history # List all versions (default 10, -n to override)
|
|
192
|
+
```
|
|
193
|
+
|
|
194
|
+
Text updates use content-addressed IDs — same content = same ID. This enables versioning through tag changes:
|
|
195
|
+
```bash
|
|
196
|
+
keep update "auth decision" -t status=draft # Creates ID from content
|
|
197
|
+
keep update "auth decision" -t status=final # Same ID, new version
|
|
198
|
+
```
|
|
199
|
+
|
|
163
200
|
### Summaries Are Your Recall Mechanism
|
|
164
201
|
|
|
165
202
|
Memory stores **summaries**, not full content. This is intentional:
|
|
@@ -180,8 +217,8 @@ keep update "Token refresh fails if clock skew > 30s" -t domain=auth -t type=fin
|
|
|
180
217
|
|
|
181
218
|
Later:
|
|
182
219
|
```bash
|
|
183
|
-
keep tag domain
|
|
184
|
-
keep tag type
|
|
220
|
+
keep tag domain=auth # Everything about auth
|
|
221
|
+
keep tag type=decision # All decisions made
|
|
185
222
|
```
|
|
186
223
|
|
|
187
224
|
**Suggested tag dimensions:**
|
|
@@ -219,13 +256,20 @@ Don't dump everything into context. Navigate the tree:
|
|
|
219
256
|
| Command | Purpose | Example |
|
|
220
257
|
|---------|---------|---------|
|
|
221
258
|
| `now` | Get/set current context | `keep now` or `keep now "status"` |
|
|
222
|
-
| `
|
|
259
|
+
| `now -V N` | Previous context versions | `keep now -V 1` or `keep now --history` |
|
|
260
|
+
| `find` | Semantic similarity search | `keep find "authentication flow" --limit 5` |
|
|
261
|
+
| `find --id` | Find similar to existing item | `keep find --id "docid" --limit 3` |
|
|
262
|
+
| `search` | Full-text search in summaries | `keep search "OAuth"` |
|
|
263
|
+
| `list` | List recent item IDs | `keep list` or `keep --full list` |
|
|
223
264
|
| `update` | Index content (URI, text, or stdin) | `keep update "note" -t key=value` |
|
|
224
|
-
| `get` | Retrieve
|
|
225
|
-
| `
|
|
226
|
-
| `
|
|
227
|
-
| `tag
|
|
228
|
-
| `
|
|
265
|
+
| `get` | Retrieve item (shows similar items) | `keep get "file:///path/to/doc.md"` |
|
|
266
|
+
| `get --similar` | List similar items | `keep get ID --similar` or `-n 20` for more |
|
|
267
|
+
| `get -V N` | Previous versions | `keep get ID -V 1` or `keep get ID --history` |
|
|
268
|
+
| `tag` | List tag values or find by tag | `keep tag domain=auth` or `keep tag --list` |
|
|
269
|
+
| `tag-update` | Modify tags on existing item | `keep tag-update "id" --tag key=value` |
|
|
270
|
+
| `collections` | List all collections | `keep collections` |
|
|
271
|
+
| `init` | Initialize or verify store | `keep init` |
|
|
272
|
+
| `config` | Show configuration and store path | `keep config` |
|
|
229
273
|
| `process-pending` | Process lazy summaries | `keep process-pending --all` |
|
|
230
274
|
|
|
231
275
|
### Fast Indexing with `--lazy`
|
|
@@ -251,17 +295,22 @@ Default output uses YAML frontmatter format:
|
|
|
251
295
|
```yaml
|
|
252
296
|
---
|
|
253
297
|
id: file:///path/to/doc.md
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
298
|
+
tags: {project: myapp, domain: auth}
|
|
299
|
+
similar:
|
|
300
|
+
- doc:related-auth (0.89)
|
|
301
|
+
- doc:token-notes (0.85)
|
|
257
302
|
score: 0.823
|
|
303
|
+
prev:
|
|
304
|
+
- v1: 2026-01-15 Previous summary...
|
|
258
305
|
---
|
|
306
|
+
Document summary here...
|
|
259
307
|
```
|
|
260
308
|
|
|
261
309
|
Global flags (before the command):
|
|
262
310
|
```bash
|
|
263
311
|
keep --json find "auth" # JSON output
|
|
264
312
|
keep --ids find "auth" # IDs only (for piping)
|
|
313
|
+
keep --full list # Full items (overrides IDs-only default)
|
|
265
314
|
keep -v find "auth" # Debug logging
|
|
266
315
|
```
|
|
267
316
|
|
|
@@ -310,6 +359,7 @@ This is the practice. Not once, but every time.
|
|
|
310
359
|
## See Also
|
|
311
360
|
|
|
312
361
|
- [docs/AGENT-GUIDE.md](docs/AGENT-GUIDE.md) — Detailed patterns for working sessions
|
|
362
|
+
- [docs/REFERENCE.md](docs/REFERENCE.md) — Complete CLI and API reference
|
|
313
363
|
- [docs/QUICKSTART.md](docs/QUICKSTART.md) — Installation and setup
|
|
314
364
|
- [docs/system/conversations.md](docs/system/conversations.md) — Full conversation framework
|
|
315
365
|
- [docs/system/domains.md](docs/system/domains.md) — Domain-specific organization
|