docs: name bin/brain/search.go; --hop is not a graph walk. (#10)
Published docs and skills still taught bin/kb/search --hop 1. Search lives at bin/brain/search.go; --hop errors until File edges exist. A unittest gates the SoT so the lie cannot return.
This commit is contained in:
@@ -30,12 +30,11 @@ related:
|
||||
---
|
||||
```
|
||||
|
||||
`bin/kb/index` reads this. `type` becomes a searchable column and `related`
|
||||
becomes a graph edge:
|
||||
`bin/kb/index` reads this. `type` becomes a searchable column. `related:` is
|
||||
frontmatter for humans; graph hops from it are not implemented yet.
|
||||
|
||||
```bash
|
||||
bin/kb/search "deploy" --type howto
|
||||
bin/kb/search "Stecktafel" --hop 1 # follow links and related
|
||||
bin/brain/search.go "deploy"
|
||||
```
|
||||
|
||||
## Audit checklist
|
||||
@@ -46,8 +45,7 @@ bin/kb/search "Stecktafel" --hop 1 # follow links and related
|
||||
The indexer chunks on H2, so split files also search better.
|
||||
3. Is `status: archive` set on anything superseded? Archived files stay indexed
|
||||
but stop competing with current ones for a reader's attention.
|
||||
4. Does every explanation link the reference it explains, and vice versa? That
|
||||
link is what `--hop 1` walks.
|
||||
4. Does every explanation link the reference it explains, and vice versa?
|
||||
|
||||
## Rule
|
||||
|
||||
|
||||
+13
-12
@@ -2,9 +2,10 @@
|
||||
name: kb-search
|
||||
description: >-
|
||||
Deduction search over the 2dph brain (Ladybug graph: ops corpus, portfolio,
|
||||
ssh hosts) with bin/kb/search instead of reading files or grepping repos.
|
||||
Use whenever a question starts with "where is", "what runs on", "which file
|
||||
describes", "who is", "how is X done", before opening any documentation.
|
||||
ssh hosts) with bin/brain/search.go instead of reading files or grepping
|
||||
repos. Use whenever a question starts with "where is", "what runs on",
|
||||
"which file describes", "who is", "how is X done", before opening any
|
||||
documentation.
|
||||
---
|
||||
|
||||
# kb-search — deduction over facts and info
|
||||
@@ -22,15 +23,17 @@ second independent source when local roots cannot confirm. An answer is
|
||||
`(not confirmed)`.
|
||||
|
||||
```bash
|
||||
bin/kb/search "Matrix federation" # pointers + snippets, YAML
|
||||
bin/kb/search "what runs on arc-2" --hop 1 # follow graph edges
|
||||
bin/kb/search "onlyoffice postgres" --root facts # restrict to confirmed
|
||||
bin/kb/search "where is cs-lexicon" --json | yq '.[].ref'
|
||||
bin/kb/get <id> --body # full chunk only when needed
|
||||
bin/kb/stats # index health
|
||||
bin/kb/eval # recall@5 >= 0.95 gate
|
||||
bin/brain/search.go "Matrix federation" # pointers + snippets, YAML
|
||||
bin/brain/search.go "onlyoffice postgres" --root facts # restrict to confirmed
|
||||
bin/brain/search.go "where is cs-lexicon" --json | yq '.[].ref'
|
||||
bin/kb/get <id> --body # full chunk only when needed
|
||||
bin/kb/stats # index health
|
||||
bin/kb/eval # recall@5 >= 0.95 gate
|
||||
```
|
||||
|
||||
`bin/kb/search` is a deprecated wrapper. `--hop` errors (File/FROM_FILE edges
|
||||
are not wired yet); do not treat it as a graph walk.
|
||||
|
||||
## Rules
|
||||
|
||||
- Search before you read. Never grep a repo for a concept the graph covers.
|
||||
@@ -38,8 +41,6 @@ bin/kb/eval # recall@5 >= 0.95 gate
|
||||
facts first, then info leafs clearly marked `(not confirmed)`.
|
||||
- If recall looks wrong, run `bin/kb/eval`; it gates control questions and
|
||||
should stay at or above 95% recall@5.
|
||||
- `--hop N` follows sibling leaves, owning files, `related:` links and
|
||||
vector-neighbours — that is the deduction walk, not random expansion.
|
||||
- Escalate to `web-search` (the `web-search` skill) as the independent second
|
||||
source when both local roots cannot confirm; never report an unconfirmed
|
||||
single-source local answer as fact.
|
||||
@@ -18,9 +18,10 @@ bin/web/search "postgres partial index" --lang en --fresh year
|
||||
|
||||
## Web or knowledge base
|
||||
|
||||
`bin/kb/search` holds our own facts: the ops stack, portfolio, ssh hosts, the
|
||||
lexicon. Go there first. Reach for `bin/web/search` when the answer is outside
|
||||
our repos: upstream library behaviour, vendor documentation, public standards.
|
||||
`bin/brain/search.go` holds our own facts: the ops stack, portfolio, ssh hosts,
|
||||
the lexicon. Go there first. Reach for `bin/web/search` when the answer is
|
||||
outside our repos: upstream library behaviour, vendor documentation, public
|
||||
standards.
|
||||
|
||||
Keep the two apart. A finding is stronger when the reader can see that one
|
||||
source was ours and one was not.
|
||||
|
||||
Reference in New Issue
Block a user