remove old code
This commit is contained in:
parent
cef88b866a
commit
26b04f364c
|
@ -149,17 +149,14 @@ def generate():
|
||||||
}), 200
|
}), 200
|
||||||
|
|
||||||
else:
|
else:
|
||||||
if opts.mode == 'oobabooga':
|
backend_response = format_sillytavern_err(f'The backend did not return valid JSON.', 'error')
|
||||||
backend_response = format_sillytavern_err(f'The backend did not return valid JSON.', 'error')
|
response_json_body = {
|
||||||
response_json_body = {
|
'results': [
|
||||||
'results': [
|
{
|
||||||
{
|
'text': backend_response,
|
||||||
'text': backend_response,
|
}
|
||||||
}
|
],
|
||||||
],
|
}
|
||||||
}
|
|
||||||
else:
|
|
||||||
raise Exception
|
|
||||||
log_prompt(client_ip, token, request_json_body['prompt'], backend_response, elapsed_time, parameters, dict(request.headers), response.status_code, is_error=True)
|
log_prompt(client_ip, token, request_json_body['prompt'], backend_response, elapsed_time, parameters, dict(request.headers), response.status_code, is_error=True)
|
||||||
return jsonify({
|
return jsonify({
|
||||||
'code': 500,
|
'code': 500,
|
||||||
|
|
Reference in New Issue