summaryrefslogtreecommitdiffstats
path: root/testing/binghuan/helpers/binghuan.py
diff options
context:
space:
mode:
authorBagus Indrayana <bagusindrayanaindo@gmail.com>2023-07-11 17:05:15 +0200
committerBagus Indrayana <bagusindrayanaindo@gmail.com>2023-07-11 17:05:15 +0200
commit27ca728af8185fc6b27f3d797bd78a6d61e5b30f (patch)
treeb46f6f3d3e226df993463f6e7937aa0d9ff3f3c1 /testing/binghuan/helpers/binghuan.py
parentreadme and credit (diff)
downloadgpt4free-27ca728af8185fc6b27f3d797bd78a6d61e5b30f.tar
gpt4free-27ca728af8185fc6b27f3d797bd78a6d61e5b30f.tar.gz
gpt4free-27ca728af8185fc6b27f3d797bd78a6d61e5b30f.tar.bz2
gpt4free-27ca728af8185fc6b27f3d797bd78a6d61e5b30f.tar.lz
gpt4free-27ca728af8185fc6b27f3d797bd78a6d61e5b30f.tar.xz
gpt4free-27ca728af8185fc6b27f3d797bd78a6d61e5b30f.tar.zst
gpt4free-27ca728af8185fc6b27f3d797bd78a6d61e5b30f.zip
Diffstat (limited to 'testing/binghuan/helpers/binghuan.py')
-rw-r--r--testing/binghuan/helpers/binghuan.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/testing/binghuan/helpers/binghuan.py b/testing/binghuan/helpers/binghuan.py
index cdeabeb8..2aabc4b6 100644
--- a/testing/binghuan/helpers/binghuan.py
+++ b/testing/binghuan/helpers/binghuan.py
@@ -207,7 +207,9 @@ def convert(messages):
return context
async def run(optionSets, messages):
- prompt = convert(messages)
+ prompt = messages[-1]['content']
+ if(len(messages) > 1):
+ prompt = convert(messages)
async for value in AsyncCompletion.create(prompt=prompt,
optionSets=optionSets):