@nano-step/nano-brain 2026.6.201 → 2026.6.203
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/README.md +53 -14
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -122,8 +122,8 @@ watcher:
|
|
|
122
122
|
debounce_ms: 2000
|
|
123
123
|
reindex_interval: 300
|
|
124
124
|
# Per-collection exclude_patterns and allowed_extensions are also supported
|
|
125
|
-
# via the workspaces map. See "
|
|
126
|
-
#
|
|
125
|
+
# via the workspaces map. See "Ignore patterns" section below for the
|
|
126
|
+
# global and workspace-local .nano-brainignore files.
|
|
127
127
|
|
|
128
128
|
storage:
|
|
129
129
|
max_file_size: 314572800 # 300MB
|
|
@@ -188,15 +188,17 @@ curl -H "Authorization: Bearer nbt_..." http://host:3100/api/v1/query -d '{"quer
|
|
|
188
188
|
# url: http://admin:mypassword@host:3100/mcp
|
|
189
189
|
```
|
|
190
190
|
|
|
191
|
-
###
|
|
191
|
+
### Ignore patterns
|
|
192
192
|
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
193
|
+
Two layers of `.nano-brainignore` files control what the watcher indexes,
|
|
194
|
+
both using standard `.gitignore` syntax (one pattern per line, supports `**`,
|
|
195
|
+
`!negation`, blank lines, `#` comments).
|
|
196
196
|
|
|
197
|
-
|
|
197
|
+
#### Global — `~/.nano-brain/.nano-brainignore`
|
|
198
198
|
|
|
199
|
-
**
|
|
199
|
+
Loaded once at server startup. Patterns apply to **every** registered
|
|
200
|
+
collection across **every** workspace. Use this for rules that are personal
|
|
201
|
+
to your machine and span all your projects (e.g. always skip `*.png`).
|
|
200
202
|
|
|
201
203
|
```
|
|
202
204
|
# Skip generated files everywhere
|
|
@@ -211,15 +213,52 @@ node_modules/
|
|
|
211
213
|
!icons/important.png
|
|
212
214
|
```
|
|
213
215
|
|
|
214
|
-
|
|
216
|
+
#### Workspace-local — `<workspace_root>/.nano-brainignore`
|
|
217
|
+
|
|
218
|
+
Loaded once per collection when the watcher starts watching it (server
|
|
219
|
+
startup, `POST /api/v1/init`, or `POST /api/v1/collections`). Patterns
|
|
220
|
+
apply **only** to that one workspace. Use this for project-specific rules
|
|
221
|
+
you want to **share with your team via version control** — e.g. skip
|
|
222
|
+
generated code that you commit to git but don't want indexed.
|
|
223
|
+
|
|
224
|
+
```
|
|
225
|
+
# nano-brain-specific rules for this repo (commit me)
|
|
226
|
+
*.generated.go
|
|
227
|
+
fixtures/large/
|
|
228
|
+
*.snap
|
|
229
|
+
```
|
|
230
|
+
|
|
231
|
+
Workspace-local rules layer **additively** on top of global rules and
|
|
232
|
+
per-collection `.gitignore`. There is no cross-file negation: a `!pattern`
|
|
233
|
+
in workspace-local cannot un-exclude a path matched by global.
|
|
234
|
+
|
|
235
|
+
The file at the workspace root is loaded for the `code` collection. The
|
|
236
|
+
sibling `memory` and `sessions` collections are rooted under `~/.nano-brain/`
|
|
237
|
+
and do not normally need their own ignore files.
|
|
238
|
+
|
|
239
|
+
#### Order of evaluation (most aggressive first)
|
|
215
240
|
|
|
216
241
|
1. Hardcoded default exclude dirs (`node_modules`, `.git`, `dist`, `build`, `target`, etc.)
|
|
217
|
-
2.
|
|
218
|
-
3.
|
|
219
|
-
4. Per-collection `
|
|
220
|
-
5. Per-collection `
|
|
242
|
+
2. Global `~/.nano-brain/.nano-brainignore`
|
|
243
|
+
3. Workspace-local `<workspace_root>/.nano-brainignore`
|
|
244
|
+
4. Per-collection `.gitignore` (in collection root)
|
|
245
|
+
5. Per-collection `exclude_patterns` (config-level)
|
|
246
|
+
6. Per-collection `allowed_extensions` (whitelist)
|
|
247
|
+
|
|
248
|
+
#### Reloading
|
|
249
|
+
|
|
250
|
+
Both global and workspace-local files are loaded at collection registration
|
|
251
|
+
time. To pick up edits:
|
|
252
|
+
|
|
253
|
+
- **Global**: restart the server.
|
|
254
|
+
- **Workspace-local**: restart the server, OR re-register the workspace
|
|
255
|
+
with `POST /api/v1/init` (this rebuilds the collection's filter and
|
|
256
|
+
re-reads the file).
|
|
257
|
+
|
|
258
|
+
`POST /api/reload-config` does **not** re-read ignore files — only search
|
|
259
|
+
config and log level are reloaded by that endpoint.
|
|
221
260
|
|
|
222
|
-
|
|
261
|
+
Issues: #263 (global), #317 (workspace-local).
|
|
223
262
|
|
|
224
263
|
### Session Summarization
|
|
225
264
|
|