Documentation
This commit is contained in:
parent
85443ee963
commit
fb837ede69
3 changed files with 20 additions and 0 deletions
|
|
@ -31,6 +31,9 @@ haiku-rag search "query"
|
||||||
# Ask questions
|
# Ask questions
|
||||||
haiku-rag ask "Who is the author of haiku.rag?"
|
haiku-rag ask "Who is the author of haiku.rag?"
|
||||||
|
|
||||||
|
# Rebuild database (re-chunk and re-embed all documents)
|
||||||
|
haiku-rag rebuild
|
||||||
|
|
||||||
# Start server with file monitoring
|
# Start server with file monitoring
|
||||||
export MONITOR_DIRECTORIES="/path/to/docs"
|
export MONITOR_DIRECTORIES="/path/to/docs"
|
||||||
haiku-rag serve
|
haiku-rag serve
|
||||||
|
|
|
||||||
10
docs/cli.md
10
docs/cli.md
|
|
@ -35,6 +35,16 @@ haiku-rag get 1
|
||||||
haiku-rag delete 1
|
haiku-rag delete 1
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Rebuild Database
|
||||||
|
|
||||||
|
Rebuild the database by deleting all chunks & embeddings and re-indexing all documents:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
haiku-rag rebuild
|
||||||
|
```
|
||||||
|
|
||||||
|
Use this when you want to change things like the embedding model or chunk size for example.
|
||||||
|
|
||||||
## Search
|
## Search
|
||||||
|
|
||||||
Basic search:
|
Basic search:
|
||||||
|
|
|
||||||
|
|
@ -67,6 +67,13 @@ await client.update_document(doc)
|
||||||
await client.delete_document(doc.id)
|
await client.delete_document(doc.id)
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Rebuilding the Database
|
||||||
|
|
||||||
|
```python
|
||||||
|
async for doc_id in client.rebuild_database():
|
||||||
|
print(f"Processed document {doc_id}")
|
||||||
|
```
|
||||||
|
|
||||||
## Searching Documents
|
## Searching Documents
|
||||||
|
|
||||||
Basic search:
|
Basic search:
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue