acecalisto3 commited on
Commit
f059638
·
verified ·
1 Parent(s): 7128a54

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +15 -3
app.py CHANGED
@@ -6,7 +6,16 @@ import subprocess
6
  import threading
7
  import time
8
  import shutil
9
- from typing import Dict, Tuple
 
 
 
 
 
 
 
 
 
10
 
11
  # --- Constants ---
12
 
@@ -312,8 +321,8 @@ with gr.Blocks(theme='ParityError/Interstellar') as demo:
312
  submit_button.click(
313
  chat_interface,
314
  inputs=[
315
- chat_interface_input._id,
316
- chatbot._id,
317
  get_agent_cluster,
318
  temperature_slider,
319
  max_new_tokens_slider,
@@ -370,5 +379,8 @@ with gr.Blocks(theme='ParityError/Interstellar') as demo:
370
  outputs=[code_output],
371
  )
372
 
 
 
 
373
  # --- Launch Gradio ---
374
  demo.queue().launch(debug=True)
 
6
  import threading
7
  import time
8
  import shutil
9
+ from typing import Dict, Tuple, List
10
+ import json
11
+ from rich import print as rprint
12
+ from rich.panel import Panel
13
+ from rich.progress import track
14
+ from rich.table import Table
15
+ from rich.prompt import Prompt, Confirm
16
+ from rich.markdown import Markdown
17
+ from rich.traceback import install
18
+ install() # Enable rich tracebacks for easier debugging
19
 
20
  # --- Constants ---
21
 
 
321
  submit_button.click(
322
  chat_interface,
323
  inputs=[
324
+ chat_interface_input,
325
+ chatbot,
326
  get_agent_cluster,
327
  temperature_slider,
328
  max_new_tokens_slider,
 
379
  outputs=[code_output],
380
  )
381
 
382
+ # --- Initialize Hugging Face Client ---
383
+ client = InferenceClient(repo_id=MODEL_NAME, token=os.environ.get("HF_TOKEN"))
384
+
385
  # --- Launch Gradio ---
386
  demo.queue().launch(debug=True)