lcbwhite commited on
Commit
1d48616
·
verified ·
1 Parent(s): c3e6035

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -6
app.py CHANGED
@@ -1,10 +1,11 @@
1
  import random
2
  import gradio as gr
 
3
 
4
- def alternatingly_agree(message, history):
5
- if len(history) % 2 == 0:
6
- return f"Yes, I do think that '{message}'"
7
- else:
8
- return "I don't think so"
9
 
10
- gr.ChatInterface(alternatingly_agree).launch()
 
1
  import random
2
  import gradio as gr
3
+ from transformers import AutoModelForCausalLM
4
 
5
+ def LMmodel(message, history):
6
+ base_model_id="LeoLM/leo-mistral-hessianai-7b-chat"
7
+ base_model = "AutoModelForCausalLM.from_pretrained(base_model_id, device_map="auto",trust_remote_code=True)
8
+ return works
9
+
10
 
11
+ gr.ChatInterface(LMmodel).launch()