From 5a0b7a6f0e3d78dfec063b430b977601b8c54741 Mon Sep 17 00:00:00 2001 From: Russell Bryant Date: Fri, 12 Jul 2024 14:50:08 -0400 Subject: [PATCH] llm: Set `n` by default in gen_kwargs Prior to converting to yaml format, we were setting `n` to the value of `num_instructions_to_generate`. It was dropped from the yaml since it's a runtime configuration value. We need to set it here so it's set like it was before. Co-authored-by: Mark McLoughlin Signed-off-by: Russell Bryant --- src/instructlab/sdg/llmblock.py | 1 + 1 file changed, 1 insertion(+) diff --git a/src/instructlab/sdg/llmblock.py b/src/instructlab/sdg/llmblock.py index 40304277..e3129684 100644 --- a/src/instructlab/sdg/llmblock.py +++ b/src/instructlab/sdg/llmblock.py @@ -78,6 +78,7 @@ def __init__( "model": self.ctx.model_id, "temperature": 0, "max_tokens": 12000, + "n": self.ctx.num_instructions_to_generate, } # Whether the LLM server supports a list of input prompts