Vijay Agrawal commited on
Commit
79f4635
·
1 Parent(s): 739e2c9

Update space

Browse files
Files changed (1) hide show
  1. app.py +1 -18
app.py CHANGED
@@ -1,28 +1,11 @@
1
  import gradio as gr
2
- import os
3
  from huggingface_hub import InferenceClient
4
 
5
  """
6
  For more information on `huggingface_hub` Inference API support, please check the docs: https://huggingface.co/docs/huggingface_hub/v0.22.2/en/guides/inference
7
- git commit -am "Update space"
8
- git push
9
- https://huggingface.co/spaces/vijayagrawal/eydemo
10
  """
 
11
 
12
- # Access secrets set in Hugging Face Space Settings
13
- azure_openai_api_key = os.environ.get("AZURE_OPENAI_API_KEY")
14
- azure_openai_endpoint = os.environ.get("AZURE_OPENAI_ENDPOINT")
15
-
16
- # client = InferenceClient("HuggingFaceH4/zephyr-7b-beta")
17
- # Initialize the client with Azure OpenAI endpoint
18
- client = InferenceClient(
19
- model=azure_openai_endpoint,
20
- token=azure_openai_api_key,
21
- headers={
22
- "api-key": azure_openai_api_key,
23
- "Content-Type": "application/json"
24
- }
25
- )
26
 
27
  def respond(
28
  message,
 
1
  import gradio as gr
 
2
  from huggingface_hub import InferenceClient
3
 
4
  """
5
  For more information on `huggingface_hub` Inference API support, please check the docs: https://huggingface.co/docs/huggingface_hub/v0.22.2/en/guides/inference
 
 
 
6
  """
7
+ client = InferenceClient("HuggingFaceH4/zephyr-7b-beta")
8
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9
 
10
  def respond(
11
  message,