Unverified Commit 00209e10 authored by Hailey Schoelkopf's avatar Hailey Schoelkopf Committed by GitHub
Browse files

Merge pull request #843 from baberabb/master_bugfix

[bugfix] openai
parents 3326c547 51f4994d
...@@ -198,14 +198,13 @@ class GPT3LM(BaseLM): ...@@ -198,14 +198,13 @@ class GPT3LM(BaseLM):
context_enc = self.tok_encode(context) context_enc = self.tok_encode(context)
inp = context_enc[-(self.max_length - self.max_gen_toks) :] inp = context_enc[-(self.max_length - self.max_gen_toks) :]
inps.append(inp) inps.append(inp)
response = oa_completion( response = oa_completion(
engine=self.engine, engine=self.engine,
prompt=inps, prompt=inps,
max_tokens=self.max_gen_toks, max_tokens=self.max_gen_toks,
temperature=0.0, temperature=0.0,
logprobs=10, logprobs=10,
stop=until, stop=until["until"],
) )
for resp, (context, until_) in zip(response.choices, chunk): for resp, (context, until_) in zip(response.choices, chunk):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment