Class: Ask::Tools::WebSearch

Inherits:
Ask::Tool
  • Object
show all
Defined in:
lib/ask/web_search/tool.rb

Constant Summary collapse

SEARXNG_URL =
ENV.fetch("SEARXNG_URL", "http://localhost:8888")

Instance Method Summary collapse

Instance Method Details

#execute(query:) ⇒ Object



21
22
23
24
# File 'lib/ask/web_search/tool.rb', line 21

def execute(query:)
  results = search(query)
  format_results(results)
end