forge
Explore
Log in

Don't you dare go Hollow

Drop the KB preamble (tooling destroyed)

Browse files at this commit

28ab08d5a3e1beef174036de04515930a9988785Ahmet Kaan GümüşParent: 799b3b5
  • docs
    • drop the KB preamble (tooling destroyed)
    • README section-read guidance
Show full message
🧹 docs: drop the KB preamble (tooling destroyed); README section-read guidance
CLAUDE.mdmodified+4 -28
@@ -3,35 +3,11 @@
3 Rust/axum school-management API (auth, roles, exams, notes, messaging,3 Rust/axum school-management API (auth, roles, exams, notes, messaging,
4 courses, attendance, pomodoro, meals) on PostgreSQL (sqlx). Swagger UI at `/swagger`.4 courses, attendance, pomodoro, meals) on PostgreSQL (sqlx). Swagger UI at `/swagger`.
5 5
6-## Project docs — query the knowledge base, do NOT read README.md6+## Project docs — README.md, read sections not the whole file
7 7
8-README.md is ~355KB (~90k tokens). Its `##` sections live in an embedded8+README.md is ~355KB (~90k tokens). Never read it whole: grep for the `## `
9-SurrealDB knowledge base. Fetch only what you need:9+heading you need, then read that range. Its `## Endpoints` table is GENERATED
10-10+(see Conventions); prose sections are hand-written.
11-```bash
12-KB() { ~/.surrealdb/surreal sql -e "surrealkv://$HOME/.claude/kb/kb.db" \
13- --ns claude --db hezarfen_backend --json --hide-welcome --log error; }
14-# list sections
15-echo 'SELECT id, title FROM doc;' | KB
16-# fetch one section body
17-echo 'SELECT body FROM doc:`time-policy`;' | KB
18-# full-text search, best sections first
19-echo "SELECT id, title, search::score(0) AS s FROM doc WHERE body @0@ 'retake' ORDER BY s DESC LIMIT 3;" | KB
20-# routes for ONE resource (auth, users, notes, messages, events, courses,
21-# subjects, sessions, exams, marks, work, pomodoro, attendance, settings, terms)
22-echo 'SELECT routes FROM endpoint:exams;' | KB
23-```
24-
25-Staleness: if `sha256sum README.md` differs from
26-`echo 'SELECT sha256 FROM meta:readme;' | KB`, re-ingest:
27-
28-```bash
29-python3 ~/.claude/kb/ingest.py README.md | KB
30-python3 ~/.claude/kb/ingest-endpoints.py README.md | KB
31-```
32-
33-The project's own PostgreSQL (container `hezarfen-postgres`) is runtime data —
34-never write knowledge-base rows there (the KB lives in `~/.claude/kb/kb.db`).
35 11
36 ## Code map — orient here, skip discovery greps12 ## Code map — orient here, skip discovery greps
37 13