mirror of
https://github.com/MODSetter/SurfSense.git
synced 2026-07-08 22:22:17 +02:00
23 lines
870 B
Python
23 lines
870 B
Python
"""``web.discover`` capability registration (free — see 04-capabilities open item)."""
|
|
|
|
from __future__ import annotations
|
|
|
|
from app.capabilities.core import Capability, register_capability
|
|
from app.capabilities.web.discover.executor import build_discover_executor
|
|
from app.capabilities.web.discover.schemas import DiscoverInput, DiscoverOutput
|
|
|
|
WEB_DISCOVER = Capability(
|
|
name="web.discover",
|
|
description=(
|
|
"Search the web for a query and return ranked results. Use it to find "
|
|
"pages when you don't already have exact URLs. Returns a list of hits "
|
|
"(url, title, snippet, provider); pass the chosen url(s) to web.scrape "
|
|
"to read their full content."
|
|
),
|
|
input_schema=DiscoverInput,
|
|
output_schema=DiscoverOutput,
|
|
executor=build_discover_executor(),
|
|
billing_unit=None,
|
|
)
|
|
|
|
register_capability(WEB_DISCOVER)
|