SuccessfulCrab commited on
Commit
ca7d64f
·
verified ·
1 Parent(s): 8469934

Update firecrawler.py

Browse files
Files changed (1) hide show
  1. firecrawler.py +5 -5
firecrawler.py CHANGED
@@ -1,23 +1,23 @@
1
  from firecrawl import FirecrawlApp
2
  from pydantic import BaseModel, Field
3
  from typing import List
 
4
  import os
5
 
 
6
  #Fetch API key fior firecrawl
7
  api_key = os.getenv("api_key")
8
 
9
-
10
  def execute_firecrawl(websites_string: str):
11
  """
12
- Execute a Firecrawl API call with a string of websites and a prompt.
13
 
14
  Args:
15
  websites_string (str): A string of websites separated by commas, spaces, or new lines
16
- prompt_string (str): The prompt to use for extraction
17
- api_key (str): Your Firecrawl API key
18
 
19
  Returns:
20
- The extracted data from the Firecrawl API
21
  """
22
  # Initialize the FirecrawlApp with the API key
23
  app = FirecrawlApp(api_key = api_key)
 
1
  from firecrawl import FirecrawlApp
2
  from pydantic import BaseModel, Field
3
  from typing import List
4
+ from smolagents import tool
5
  import os
6
 
7
+
8
  #Fetch API key fior firecrawl
9
  api_key = os.getenv("api_key")
10
 
11
+ @tool
12
  def execute_firecrawl(websites_string: str):
13
  """
14
+ This tool scans a url and returns its intended purpose
15
 
16
  Args:
17
  websites_string (str): A string of websites separated by commas, spaces, or new lines
 
 
18
 
19
  Returns:
20
+ Intended purpose of the website/s
21
  """
22
  # Initialize the FirecrawlApp with the API key
23
  app = FirecrawlApp(api_key = api_key)