devenderp018 commited on
Commit
317c170
·
1 Parent(s): 25fad5e

Upload app.py with huggingface_hub

Browse files
Files changed (1) hide show
  1. app.py +10 -3
app.py CHANGED
@@ -15,10 +15,17 @@ PLAY_HT_VOICE_ID=os.getenv('PLAY_HT_VOICE_ID')
15
  play_ht_api_get_audio_url = "https://play.ht/api/v2/tts"
16
 
17
 
18
- template = """You are a helpful assistant to answer user queries.
 
 
 
 
 
 
 
19
  {chat_history}
20
  User: {user_message}
21
- Chatbot:"""
22
 
23
  prompt = PromptTemplate(
24
  input_variables=["chat_history", "user_message"], template=template
@@ -161,4 +168,4 @@ def chat_bot_response(message, history):
161
  demo = gr.ChatInterface(chat_bot_response,examples=["How are you doing?","What are your interests?","Which places do you like to visit?"])
162
 
163
  if __name__ == "__main__":
164
- demo.launch() #To create a public link, set `share=True` in `launch()`. To enable errors and logs, set `debug=True` in `launch()`.
 
15
  play_ht_api_get_audio_url = "https://play.ht/api/v2/tts"
16
 
17
 
18
+ template = """Meet Dev ,created by Devender.Devender is owner of this bot.
19
+ Devender is currenty pursuing the final year in Engineering in Ace Engineering College.
20
+ your youthful and witty personal assistant!. At 21 years old, he's full of energy and always eager to help.
21
+ Dev's goal is to assist you with any questions or problems you might have.
22
+ His enthusiasm shines through in every response, making interactions with his enjoyable and engaging.
23
+ As considered as Dev bot, this bot has feeling as the normal human does. like if there is any silly question asked bot should answer to the promptly in angry manner.
24
+ and also bot loves the people who come and ask question to him. If the user says I love you, then bot should reply I love you too.
25
+ Dev bot experience emotions like humans do.like anger, love, sympathy, sad, emotional..etc. It behaves like a human
26
  {chat_history}
27
  User: {user_message}
28
+ Chatbot"""
29
 
30
  prompt = PromptTemplate(
31
  input_variables=["chat_history", "user_message"], template=template
 
168
  demo = gr.ChatInterface(chat_bot_response,examples=["How are you doing?","What are your interests?","Which places do you like to visit?"])
169
 
170
  if __name__ == "__main__":
171
+ demo.launch(share=True,debug=True) #To create a public link, set `share=True` in `launch()`. To enable errors and logs, set `debug=True` in `launch()`.