Class TurWebCrawlerToolService

java.lang.Object
com.viglet.turing.genai.tool.TurWebCrawlerToolService

@Service public class TurWebCrawlerToolService extends Object
  • Constructor Details

    • TurWebCrawlerToolService

      public TurWebCrawlerToolService()
  • Method Details

    • fetchWebpage

      @Tool(name="fetch_webpage", description="Fetches a web page by URL and returns its text content.\nUse this tool when the user asks about a URL, wants to read an article, or needs information from a specific web page.\nArgs:\n url (str): The full URL to fetch (e.g., 'https://example.com/page'). Required.\n includeLinks (str): Set to 'yes' to also include a list of links found on the page. Default is 'no'.\nReturns:\n The page title and main text content, optionally followed by links found on the page.") public String fetchWebpage(String url, String includeLinks)
    • extractLinks

      @Tool(name="extract_links", description="Extracts all links from a web page, optionally filtered by a keyword.\nUse this tool to discover navigation, find sub-pages, or locate specific resources on a site.\nArgs:\n url (str): The full URL to crawl (e.g., 'https://example.com'). Required.\n filterKeyword (str): Optional keyword to filter links by text or URL. Use empty string to return all links.\nReturns:\n A list of links (text and URL) found on the page.") public String extractLinks(String url, String filterKeyword)