mirror of
https://github.com/khoaliber/khoj.git
synced 2026-03-02 13:18:18 +00:00
Use url fragment schema for deep link URIs, borrowing from URL/PDF schemas. E.g file:///path/to/file.txt#line=<line_no>&#page=<page_no> Compute line number during (recursive) markdown entry chunking. Test line number in URI maps to line number of chunk in actual md file. This deeplink URI with line number is passed to llm as context to better combine with line range based view file tool. Grep tool already passed matching line number. This change passes line number in URIs of markdown entries matched by the semantic search tool.
1.3 KiB
Vendored
1.3 KiB
Vendored
Main Readme
Allow natural language search, chat with your documents using transformer based models
This is a test markdown file with multiple, nested child entries.
Dependencies
- Python3
- Miniconda
Installation
pip install khoj
Run
Load ML model, generate embeddings and expose API to query specified org-mode files
python3 main.py --input-files ~/Notes/Schedule.org ~/Notes/Incoming.org --verbose
Use
Khoj via API
- Query:
GEThttp://localhost:42110/api/search?q="What is the meaning of life" - Update Index:
GEThttp://localhost:42110/api/update - Khoj API Docs
Khoj via Web
- Open browser to http://localhost:42110
- Enter query in search box
Acknowledgments
- MiniLM Model for Asymmetric Text Search. See (SBert Documentation)[https://www.sbert.net/examples/applications/retrieve_rerank/README.html]
- OpenAI CLIP Model for Image Search. See SBert Documentation