Samuel Thomas commited on
Commit
7979b63
·
1 Parent(s): 9420d94

tweak text

Browse files
Files changed (2) hide show
  1. app.py +1 -1
  2. tools.py +13 -11
app.py CHANGED
@@ -173,7 +173,7 @@ def run_and_submit_all( profile: gr.OAuthProfile | None):
173
 
174
  # --- Build Gradio Interface using Blocks ---
175
  with gr.Blocks() as demo:
176
- gr.Markdown("# Basic Agent Evaluation Runner")
177
  gr.Markdown(
178
  """
179
  **Instructions:**
 
173
 
174
  # --- Build Gradio Interface using Blocks ---
175
  with gr.Blocks() as demo:
176
+ gr.Markdown("# HF Course Agent Evaluation Runner")
177
  gr.Markdown(
178
  """
179
  **Instructions:**
tools.py CHANGED
@@ -23,6 +23,19 @@ from transformers import BlipProcessor, BlipForQuestionAnswering, pipeline
23
  from io import BytesIO
24
  from sentence_transformers import SentenceTransformer
25
 
 
 
 
 
 
 
 
 
 
 
 
 
 
26
  nlp = spacy.load("en_core_web_sm")
27
 
28
  # Define file extension sets for each category
@@ -66,17 +79,6 @@ def write_bytes_to_temp_dir(file_bytes: bytes, file_name: str) -> str:
66
  print(f"File written to: {file_path}")
67
  return file_path
68
 
69
- import os
70
- import re
71
- from PIL import Image # This is correctly imported, but was being used incorrectly
72
- import numpy as np
73
- from collections import Counter
74
- import torch
75
- from transformers import BlipProcessor, BlipForQuestionAnswering, pipeline
76
- from typing import TypedDict, List, Optional, Dict, Any, Literal, Tuple
77
- from langgraph.graph import StateGraph, START, END
78
- from langchain.docstore.document import Document
79
-
80
  # 1. Define the State type
81
  class State(TypedDict, total=False):
82
  question: str
 
23
  from io import BytesIO
24
  from sentence_transformers import SentenceTransformer
25
 
26
+
27
+ import os
28
+ import re
29
+ from PIL import Image # This is correctly imported, but was being used incorrectly
30
+ import numpy as np
31
+ from collections import Counter
32
+ import torch
33
+ from transformers import BlipProcessor, BlipForQuestionAnswering, pipeline
34
+ from typing import TypedDict, List, Optional, Dict, Any, Literal, Tuple
35
+ from langgraph.graph import StateGraph, START, END
36
+ from langchain.docstore.document import Document
37
+
38
+
39
  nlp = spacy.load("en_core_web_sm")
40
 
41
  # Define file extension sets for each category
 
79
  print(f"File written to: {file_path}")
80
  return file_path
81
 
 
 
 
 
 
 
 
 
 
 
 
82
  # 1. Define the State type
83
  class State(TypedDict, total=False):
84
  question: str