change defaults to 0 temp

This commit is contained in:
rasbt
2024-05-19 09:04:49 -05:00
parent 59f5ed8d68
commit bc5cbbf1bd
4 changed files with 5 additions and 5 deletions

View File

@@ -254,7 +254,7 @@ def token_ids_to_text(token_ids, tokenizer):
return tokenizer.decode(flat.tolist())
def generate(model, idx, max_new_tokens, context_size, temperature=1.0, top_k=None, eos_id=None):
def generate(model, idx, max_new_tokens, context_size, temperature=0.0, top_k=None, eos_id=None):
# For-loop is the same as before: Get logits, and only focus on last time step
for _ in range(max_new_tokens):