@cerefox/memory 0.9.3 → 0.9.5
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.
- package/AGENT_GUIDE.md +30 -0
- package/README.md +4 -4
- package/dist/bin/cerefox.js +28610 -570
- package/dist/frontend/assets/{index-CAp2_lFX.js → index-BHVfMLlE.js} +3 -3
- package/dist/frontend/assets/index-BHVfMLlE.js.map +1 -0
- package/dist/frontend/index.html +1 -1
- package/docs/guides/cli.md +1 -1
- package/docs/guides/connect-agents.md +3 -3
- package/docs/guides/quickstart.md +2 -2
- package/docs/guides/upgrading.md +69 -311
- package/package.json +2 -1
- package/dist/frontend/assets/index-CAp2_lFX.js.map +0 -1
- package/docs/guides/migration-v0.5.md +0 -581
package/AGENT_GUIDE.md
CHANGED
|
@@ -229,6 +229,36 @@ Cheap and idempotent. Call it any time you're uncertain about a convention (link
|
|
|
229
229
|
|
|
230
230
|
---
|
|
231
231
|
|
|
232
|
+
## Choosing a retrieval tool: `cerefox_search` vs `cerefox_metadata_search`
|
|
233
|
+
|
|
234
|
+
These two tools have **different contracts**. Picking the wrong one is the most common retrieval mistake.
|
|
235
|
+
|
|
236
|
+
| Reach for `cerefox_search` when… | Reach for `cerefox_metadata_search` when… |
|
|
237
|
+
|---|---|
|
|
238
|
+
| You want the *most relevant* docs for a topic or question | You want *every* doc matching exact criteria |
|
|
239
|
+
| The query is fuzzy or conceptual (it blends full-text + semantic) | You're filtering by structured metadata (`type`/`status`/tags), project, or date |
|
|
240
|
+
| Top-N ranked hits are enough to answer | You need a complete, exhaustive set (e.g. an inventory or a catch-up) |
|
|
241
|
+
|
|
242
|
+
- **`cerefox_search` is relevance-ranked top-N.** It returns the best `match_count` matches (**default 5** — raise it via `match_count`). It is **not** an enumeration tool: if more docs match than `match_count`, the rest sit silently below the cutoff — and the one you most want (e.g. the *newest*) may be exactly the one dropped.
|
|
243
|
+
- **`cerefox_metadata_search` is exhaustive enumeration by criteria.** No text query. Filters by `metadata_filter` (plus `project_name`, `updated_since` / `created_since`). It returns **metadata only by default** (`include_content=false`) — ids + titles + tags, which is cheap — so raise `limit` (**default 10**) freely to get the whole set. Discover available keys with `cerefox_list_metadata_keys`.
|
|
244
|
+
|
|
245
|
+
### Examples
|
|
246
|
+
|
|
247
|
+
- *"Find our OAuth design notes"* (relevance) → `cerefox_search(query="OAuth design", match_count=5)`
|
|
248
|
+
- *"List every decision-log doc"* (enumeration) → `cerefox_metadata_search(metadata_filter={"type":"decision-log"}, limit=50, include_content=false)`
|
|
249
|
+
- *"What changed since I last looked?"* → `cerefox_metadata_search(metadata_filter={"type":"decision-log"}, updated_since="2026-05-01T00:00:00Z")`
|
|
250
|
+
- *"Just the ids of all active research docs"* → `cerefox_metadata_search(metadata_filter={"type":"research","status":"active"}, limit=100)`
|
|
251
|
+
|
|
252
|
+
### Pattern: finding the newest item in a growing series
|
|
253
|
+
|
|
254
|
+
Don't lean on `cerefox_search` ranking to find "the latest X" — as the series grows, the newest item is the one most likely to fall outside the top-N window. Instead, tag exactly one doc with a pointer (e.g. `latest:"true"`) and fetch it directly:
|
|
255
|
+
```
|
|
256
|
+
cerefox_metadata_search(metadata_filter={"type":"<your-type>", "latest":"true"})
|
|
257
|
+
```
|
|
258
|
+
Metadata is matched as **strings**, so store the flag as the string `"true"` (not a boolean). When the current item is superseded, set the new one's flag first, then clear the old one's — so a reader never sees zero matches.
|
|
259
|
+
|
|
260
|
+
---
|
|
261
|
+
|
|
232
262
|
## Key Workflows
|
|
233
263
|
|
|
234
264
|
### Search then update (ID-based -- preferred)
|
package/README.md
CHANGED
|
@@ -115,9 +115,9 @@ already provisioned (see "Before you install").
|
|
|
115
115
|
> **Upgrading from the Python `cerefox` CLI?** If you have a working
|
|
116
116
|
> `.env` in your repo clone, init detects it and offers to **copy** it to
|
|
117
117
|
> `~/.cerefox/.env` so the TS CLI uses the new home while Python keeps
|
|
118
|
-
> reading the repo file unchanged
|
|
119
|
-
>
|
|
120
|
-
>
|
|
118
|
+
> reading the repo file unchanged (`cerefox init` walks you through the choice).
|
|
119
|
+
> Existing users with no `~/.cerefox/.env` see zero behavior change until they
|
|
120
|
+
> opt in.
|
|
121
121
|
|
|
122
122
|
---
|
|
123
123
|
|
|
@@ -193,7 +193,7 @@ its own. The rest of the `cerefox` CLI is useful for:
|
|
|
193
193
|
- **Project README + roadmap**: <https://github.com/fstamatelopoulos/cerefox>
|
|
194
194
|
- **Architecture overview**: [`CLAUDE.md`](https://github.com/fstamatelopoulos/cerefox/blob/main/CLAUDE.md)
|
|
195
195
|
- **Setup guides**: [`docs/guides/`](https://github.com/fstamatelopoulos/cerefox/tree/main/docs/guides)
|
|
196
|
-
- **
|
|
196
|
+
- **Upgrading**: [`docs/guides/upgrading.md`](https://github.com/fstamatelopoulos/cerefox/blob/main/docs/guides/upgrading.md)
|
|
197
197
|
- **For AI agents using Cerefox**: [`AGENT_GUIDE.md`](https://github.com/fstamatelopoulos/cerefox/blob/main/AGENT_GUIDE.md), [`AGENT_QUICK_REFERENCE.md`](https://github.com/fstamatelopoulos/cerefox/blob/main/AGENT_QUICK_REFERENCE.md), or run `cerefox guides list`.
|
|
198
198
|
- **Changelog**: [`CHANGELOG.md`](https://github.com/fstamatelopoulos/cerefox/blob/main/CHANGELOG.md)
|
|
199
199
|
|