Deadmon's picture
Rename app.py to app2.py
c790cbe verified
raw
history blame contribute delete
675 Bytes
import gradio as gr
import os
# Get the Hugging Face token from the Space's secrets
HF_TOKEN = os.environ.get("HF_TOKEN")
with gr.Blocks(fill_height=True) as demo:
with gr.Sidebar():
gr.Markdown("# Inference Provider")
gr.Markdown("This Space showcases the Orion-zhen/Qwen2.5-7B-Instruct-Uncensored model, served by the featherless-ai API.")
# Use the HF_TOKEN from the environment to authenticate.
# The LoginButton is removed as it's not compatible with a headless React client.
gr.load(
"models/Orion-zhen/Qwen2.5-7B-Instruct-Uncensored",
hf_token=HF_TOKEN,
provider="featherless-ai"
)
demo.launch()