igortech commited on
Commit
7dc6911
·
verified ·
1 Parent(s): 43705db

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -1,7 +1,7 @@
1
  import gradio as gr
2
  from transformers import pipeline
3
 
4
- generator = pipeline("text-generation", model="microsoft/DialoGPT-small")
5
 
6
  def chat_fn(message, history=None):
7
  try:
@@ -10,4 +10,5 @@ def chat_fn(message, history=None):
10
  return bot_reply, history or []
11
  except Exception as e:
12
  return f"Error: {e}", history or []
 
13
  gr.ChatInterface(fn=chat_fn).launch()
 
1
  import gradio as gr
2
  from transformers import pipeline
3
 
4
+ generator = pipeline("text-generation", model="distilgpt2")
5
 
6
  def chat_fn(message, history=None):
7
  try:
 
10
  return bot_reply, history or []
11
  except Exception as e:
12
  return f"Error: {e}", history or []
13
+
14
  gr.ChatInterface(fn=chat_fn).launch()