fix: source error in installed app

This commit is contained in:
John Wang 2023-05-19 10:56:28 +08:00
parent 7f1ed21e61
commit 9319cf54bf
2 changed files with 3 additions and 3 deletions

View File

@ -42,7 +42,7 @@ class CompletionApi(InstalledAppResource):
app_model=app_model,
user=current_user,
args=args,
from_source='api',
from_source='console',
streaming=streaming
)
@ -101,7 +101,7 @@ class ChatApi(InstalledAppResource):
app_model=app_model,
user=current_user,
args=args,
from_source='api',
from_source='console',
streaming=streaming
)

View File

@ -127,7 +127,7 @@ class MessageService:
message_id=message_id
)
feedback = message.user_feedback
feedback = message.user_feedback if isinstance(user, EndUser) else message.admin_feedback
if not rating and feedback:
db.session.delete(feedback)