Spaces:
Build error
Build error
| import gradio as gr | |
| import ollama | |
| def chat_with_spacebot(message): | |
| response = ollama.chat(model="sdsiddharth/SPACEBOT", messages=[{"role": "user", "content": message}]) | |
| return response['message']['content'] | |
| iface = gr.Interface( | |
| fn=chat_with_spacebot, | |
| inputs=gr.Textbox(label="Ask SPACEBOT"), | |
| outputs=gr.Textbox(label="Response"), | |
| title="🚀 Chat with SPACEBOT", | |
| description="Try SPACEBOT instantly without installation!", | |
| ) | |
| iface.launch() | |