Vijayendra
commited on
Commit
•
3981c4f
1
Parent(s):
3b07e01
Update README.md
Browse files
README.md
CHANGED
@@ -25,7 +25,7 @@ if tokenizer.pad_token is None:
|
|
25 |
tokenizer.pad_token = tokenizer.eos_token
|
26 |
|
27 |
# Define the inference function with TextStreamer
|
28 |
-
def generate_answer_with_stream(model, tokenizer, text, max_new_tokens=
|
29 |
prompt = f"Answer the following question\n\n{text}\n\nQuestion:"
|
30 |
|
31 |
# Tokenize the input text
|
|
|
25 |
tokenizer.pad_token = tokenizer.eos_token
|
26 |
|
27 |
# Define the inference function with TextStreamer
|
28 |
+
def generate_answer_with_stream(model, tokenizer, text, max_new_tokens=1024, temperature=0.5, top_k=40, top_p=0.9):
|
29 |
prompt = f"Answer the following question\n\n{text}\n\nQuestion:"
|
30 |
|
31 |
# Tokenize the input text
|