Spaces:
Sleeping
Sleeping
Add in RAG component
Browse files2 unmodified lines34567870 unmodified lines79808182832 unmodified linesfrom PIL import Imagefrom huggingface_hub import InferenceClientimport os# Hugging Face API keyAPI_KEY = st.secrets["HF_API_KEY"]70 unmodified linesexcept Exception as e:st.error(f"Error generating ingredients: {e}")# Footerst.sidebar.markdown("Developed by Muhammad Hassan Butt.")2 unmodified lines345678970 unmodified lines80818283848586878889902 unmodified linesfrom PIL import Imagefrom huggingface_hub import InferenceClientimport osfrom gradio_client import Client# Hugging Face API keyAPI_KEY = st.secrets["HF_API_KEY"]70 unmodified linesexcept Exception as e:st.error(f"Error generating ingredients: {e}")st.subheader("Healthier alternatives:")try:client = Client("https://4fbc334ff05ec351c8.gradio.live/")result = client.predict(query=f"What's a healthy {top_food} recipe, and why is it healthy?", api_name="/get_response")st.write(result)# Footerst.sidebar.markdown("Developed by Muhammad Hassan Butt.")
app.py+7