aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'README.md')
-rw-r--r--README.md28
1 files changed, 28 insertions, 0 deletions
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..534001e
--- /dev/null
+++ b/README.md
@@ -0,0 +1,28 @@
+# cheat
+
+Local command-helper retrieval system using JSONL, SQLite, and sentence-transformers.
+
+## Setup
+
+```sh
+export HF_HOME="$PWD/models/hf"
+export SENTENCE_TRANSFORMERS_HOME="$PWD/models/hf"
+python -m venv venv
+source .venv/bin/activate
+pip install -U pip
+pip install -r requirements.txt
+python scripts/init_db.py
+python scripts/build_index.py
+```
+
+Then run a query like this:
+
+```sh
+python scripts/query_index.py "get free disk space"
+```
+
+To add commands, add to `./cards.jsonl` and rebuild the index:
+
+```sh
+python scripts/build_index.py
+```