mirror of
https://github.com/aljazceru/dev-gpt.git
synced 2025-12-18 14:14:21 +01:00
@@ -2,15 +2,14 @@ from dev_gpt.apis.gpt import ask_gpt
|
||||
from dev_gpt.options.generate.parser import identity_parser
|
||||
|
||||
|
||||
def user_feedback_loop(context, current_description):
|
||||
def user_feedback_loop(current_description):
|
||||
while (user_feedback := get_user_feedback(current_description)):
|
||||
context['user_feedback'] = user_feedback
|
||||
current_description = ask_gpt(
|
||||
add_feedback_prompt,
|
||||
identity_parser,
|
||||
**context
|
||||
microservice_description=current_description,
|
||||
user_feedback=user_feedback,
|
||||
)
|
||||
del context['user_feedback']
|
||||
return current_description
|
||||
|
||||
def get_user_feedback(microservice_description):
|
||||
|
||||
@@ -43,7 +43,7 @@ Description of the microservice:
|
||||
def refine_description(self, microservice_description):
|
||||
context = {'microservice_description': microservice_description}
|
||||
auto_refine_description(context)
|
||||
microservice_description = user_feedback_loop(context, context['microservice_description'])
|
||||
microservice_description = user_feedback_loop(context['microservice_description'])
|
||||
|
||||
test_description = ask_gpt(
|
||||
generate_test_assertion_prompt,
|
||||
|
||||
Reference in New Issue
Block a user