Sev-X commited on
Commit
a7e512b
·
verified ·
1 Parent(s): be19f9b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +12 -0
app.py CHANGED
@@ -58,6 +58,18 @@ demo = gr.ChatInterface(
58
  ],
59
  )
60
 
 
 
 
 
 
 
 
 
 
 
 
 
61
 
62
  if __name__ == "__main__":
63
  demo.launch()
 
58
  ],
59
  )
60
 
61
+ from gradio_client import Client
62
+
63
+ client = Client("Sev-X/Test-AI")
64
+ result = client.predict(
65
+ message="Hello!!",
66
+ system_message="You are a friendly Chatbot.",
67
+ max_tokens=512,
68
+ temperature=0.7,
69
+ top_p=0.95,
70
+ api_name="/chat"
71
+ )
72
+ print(result)
73
 
74
  if __name__ == "__main__":
75
  demo.launch()