richardkovacs commited on
Commit
a07ee33
1 Parent(s): 2a2e637

feat: use inference endpoint

Browse files
Files changed (1) hide show
  1. app.py +6 -1
app.py CHANGED
@@ -1,11 +1,16 @@
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(
8
- model="Orenguteng/Llama-3-8B-Lexi-Uncensored")
 
 
9
 
10
 
11
  def respond(
 
1
  import gradio as gr
2
  from huggingface_hub import InferenceClient
3
+ import os
4
+
5
+ token = os.environ.get("HF_TOKEN")
6
 
7
  """
8
  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
9
  """
10
  client = InferenceClient(
11
+ model="https://mw6ztcar07ths6bp.us-east-1.aws.endpoints.huggingface.cloud",
12
+ token=token
13
+ )
14
 
15
 
16
  def respond(