refactor: summarize error message without line number

This commit is contained in:
Florian Hönicke
2023-06-05 17:05:58 +02:00
parent 304777837d
commit 938d615edc
4 changed files with 31 additions and 5 deletions

View File

@@ -0,0 +1,14 @@
import os
from dev_gpt.apis.gpt import GPTSession
from dev_gpt.options.generate.chains.auto_refine_description import enhance_description
def test_better_description(tmpdir):
os.environ['VERBOSE'] = 'true'
GPTSession(os.path.join(str(tmpdir), 'log.json'), model='gpt-3.5-turbo')
better_description = enhance_description({
'microservice_description': 'Input is a tweet that contains passive aggressive language. The output is the positive version of that tweet.'
})
assert 'gpt_3_5_turbo' in better_description