Update app.py
Browse files486 unmodified lines4874884894904914924932 unmodified lines496497498499500501502486 unmodified lineselse:for response in get_response_from_pdf(message, model, selected_docs, num_calls, temperature):yield responseexcept Exception as e:logging.error(f"Error with {model}: {str(e)}")if "microsoft/Phi-3-mini-4k-instruct" in model:2 unmodified linesyield from respond(message, history, fallback_model, temperature, num_calls, use_web_search, selected_docs)else:yield f"An error occurred with the {model} model: {str(e)}. Please try again or select a different model."logging.basicConfig(level=logging.DEBUG)def get_response_from_cloudflare(prompt, context, query, num_calls=3, temperature=0.2, search_type="pdf"):486 unmodified lines4874884894904914922 unmodified lines495496497498499500501486 unmodified lineselse:for response in get_response_from_pdf(message, model, selected_docs, num_calls, temperature):yield responseexcept Exception as e:logging.error(f"Error with {model}: {str(e)}")if "microsoft/Phi-3-mini-4k-instruct" in model:2 unmodified linesyield from respond(message, history, fallback_model, temperature, num_calls, use_web_search, selected_docs)else:yield f"An error occurred with the {model} model: {str(e)}. Please try again or select a different model."logging.basicConfig(level=logging.DEBUG)def get_response_from_cloudflare(prompt, context, query, num_calls=3, temperature=0.2, search_type="pdf"):
app.py+1-2