JabrilJacobs commited on
Commit
bfac4ac
·
verified ·
1 Parent(s): 39d66fb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +10 -4
app.py CHANGED
@@ -6,7 +6,7 @@ import pandas as pd
6
  from typing import TypedDict, Annotated, Union, Dict, Any
7
  from smolagents import DuckDuckGoSearchTool
8
  from langchain_community.tools import DuckDuckGoSearchRun
9
- from tools import get_hub_stats, analyze_image
10
  from langchain.tools import Tool
11
  from langchain_huggingface import HuggingFaceEndpoint, ChatHuggingFace
12
  from langchain_openai import ChatOpenAI
@@ -46,10 +46,16 @@ class NewAgent:
46
  )
47
  # Initialize the Image Analysis tool
48
  image_analysis_tool = Tool(
49
- name="analyze_image",
50
- func=analyze_image,
51
- description="Analyzes images and answers questions about their content. Input should be the path to an image file."
52
  )
 
 
 
 
 
 
53
  # Generate the chat interface, including the tools
54
  tools = [
55
  search_tool,
 
6
  from typing import TypedDict, Annotated, Union, Dict, Any
7
  from smolagents import DuckDuckGoSearchTool
8
  from langchain_community.tools import DuckDuckGoSearchRun
9
+ from tools import get_hub_stats, analyze_image, read_excel_file
10
  from langchain.tools import Tool
11
  from langchain_huggingface import HuggingFaceEndpoint, ChatHuggingFace
12
  from langchain_openai import ChatOpenAI
 
46
  )
47
  # Initialize the Image Analysis tool
48
  image_analysis_tool = Tool(
49
+ name="analyze_image",
50
+ func=analyze_image,
51
+ description="Analyzes images and answers questions about their content. Input should be the path to an image file."
52
  )
53
+ # Initialize the Read Excel tool
54
+ read_excel_tool = Tool(
55
+ name="read_excel_file",
56
+ func=read_excel_file,
57
+ description="Reads an Excel file and returns structured information about its contents."
58
+ )
59
  # Generate the chat interface, including the tools
60
  tools = [
61
  search_tool,