diff --git a/Makefile b/Makefile index 0bce7c3e3459b94ec09bdff652e42dac97ef07d2..7d5807ae457eaccc0923ecc5a34d0178e8f1a4f2 100644 --- a/Makefile +++ b/Makefile @@ -62,4 +62,4 @@ maps/%.h: maps/%.txt .assure xxd -i $< > $@ corpus/%.vdb: corpus/%.txt build/context - ./context -i $< -o $@ + ./context -m qwen3 -i $< -o $@ diff --git a/README.md b/README.md index 6619175306b3b382038022fc0d7665e7089727f7..80459429f9cfeda87e93ddf04f363e16d236f9ef 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,26 @@ - To produce a simple C library that can be reused elsewhere. - Test existing small and tiny LLMs and provide some useful results on how they behave. +## Getting started + +1. Build dependencies and binaries: + ```bash + make build/llama.cpp + make run/fetch-models + make build/context + make build/game + ``` + +2. Build a vector context database: + ```bash + build/corpus + ``` + +3. Run the game: + ```bash + ./game -m phi-4-mini-instruct -e qwen3 + ``` + ## Building ### Prerequisites @@ -52,7 +72,7 @@ embedding model (for example, `qwen3`) even if you generate answers with a different model. ```bash -./context -m qwen3 -i corpus/lotr.txt -o corpus/lotr.vdb +./context -m qwen3 -i corpus/map1_keldor.txt -o corpus/map1_keldor.vdb ``` ### Run an NPC query with retrieved context @@ -62,8 +82,8 @@ lines by cosine similarity, and runs the NPC system prompt against that context. You can pass a separate embedding model with `-e`/`--embed-model`. ```bash -./npc -m phi-4-mini-instruct -e qwen3 -p "Who is Gandalf?" -c corpus/lotr.vdb -./npc -m qwen3 -e qwen3 -p "Who is Frodo?" -c corpus/lotr.vdb +./npc -m phi-4-mini-instruct -e qwen3 -p "Who is Keldor?" -c corpus/map1_keldor.vdb +./npc -m qwen3 -e qwen3 -p "What does Keldor believe about the marsh lights?" -c corpus/map1_keldor.vdb ``` ### Run the game