Ammah commited on
Commit
26e1075
1 Parent(s): d0e2947

update README.md

Browse files
Files changed (1) hide show
  1. README.md +11 -4
README.md CHANGED
@@ -30,11 +30,16 @@ from llama_cpp import Llama
30
 
31
  # Our stepper takes in a Outlines model to enable guided generation
32
  # This forces the model to follow our output format
33
- model = Llama(
34
- model_path="./path/to/model/npc-llm-7B.gguf",
35
- # n_gpu_layers=-1, # Uncomment to use GPU acceleration
 
 
 
36
  )
37
 
 
 
38
  # Instantiate a stepper: handles prompting + output parsing
39
  stepper = NPCStepper(model=model)
40
  ```
@@ -53,7 +58,9 @@ from gigax.scene import (
53
  ParameterType,
54
  )
55
  # Use sample data
 
56
  current_location = Location(name="Old Town", description="A quiet and peaceful town.")
 
57
  NPCs = [
58
  Character(
59
  name="John the Brave",
@@ -133,7 +140,7 @@ Aldren:
133
 
134
  ```bibtex
135
  @misc{NPC-LLM-7B-GGUF,
136
- url={[https://huggingface.co/Gigax/NPC-LLM-7B](https://huggingface.co/Gigax/NPC-LLM-7B-GGUF)},
137
  title={NPC-LLM-7B-GGUF},
138
  author={Gigax team}
139
  }
 
30
 
31
  # Our stepper takes in a Outlines model to enable guided generation
32
  # This forces the model to follow our output format
33
+ llm = Llama.from_pretrained(
34
+ repo_id="Gigax/NPC-LLM-7B-GGUF",
35
+ filename="npc-llm-7B.gguf"
36
+ # n_gpu_layers=-1, # Uncomment to use GPU acceleration
37
+ # seed=1337, # Uncomment to set a specific seed
38
+ # n_ctx=2048, # Uncomment to increase the context window
39
  )
40
 
41
+ model = models.LlamaCpp(llm)
42
+
43
  # Instantiate a stepper: handles prompting + output parsing
44
  stepper = NPCStepper(model=model)
45
  ```
 
58
  ParameterType,
59
  )
60
  # Use sample data
61
+ context = "Medieval world"
62
  current_location = Location(name="Old Town", description="A quiet and peaceful town.")
63
+ locations = [current_location] # you can add more locations to the scene
64
  NPCs = [
65
  Character(
66
  name="John the Brave",
 
140
 
141
  ```bibtex
142
  @misc{NPC-LLM-7B-GGUF,
143
+ url={[https://huggingface.co/Gigax/NPC-LLM-7B-GGUF](https://huggingface.co/Gigax/NPC-LLM-7B-GGUF)},
144
  title={NPC-LLM-7B-GGUF},
145
  author={Gigax team}
146
  }