mirror of
https://github.com/abetlen/llama-cpp-python.git
synced 2023-09-07 17:34:22 +03:00
Fix example documentation
This commit is contained in:
@@ -127,7 +127,8 @@ class Llama:
|
||||
]:
|
||||
"""Generate tokens.
|
||||
|
||||
>>> llama = Llama("models/117M")
|
||||
Examples:
|
||||
>>> llama = Llama("models/ggml-7b.bin")
|
||||
>>> tokens = llama.tokenize(b"Hello, world!")
|
||||
>>> for token in llama.generate(tokens, top_k=40, top_p=0.95, temp=1.0, repeat_penalty=1.1):
|
||||
... print(llama.detokenize([token]))
|
||||
|
||||
Reference in New Issue
Block a user