xyberos-web-search
Web search abstraction plugin — RFC-0019, M5. One WebSearch contract
(search(query, top_k) -> list[Result]), many providers behind it: DuckDuckGo
(free, no API key — the default), plus Tavily, Serper, Brave, Exa,
Firecrawl. Each adapter is a thin, stdlib-only urllib call; the plugin
exposes a single typed web_search tool.
Install
pip install xyberos-web-search # from PyPI
# development (editable, from this repo):
pip install -e ./web-search
Usage
from xyberos import create_app
from xyberos_web_search import WebSearchPlugin
app = create_app()
app.load_plugin(WebSearchPlugin()) # default: duckduckgo - free, no API key
app.tools.execute("web_search", None, query="xyberos", top_k=5)
Provider + key resolution (explicit args, then env):
| Provider | provider |
API key env |
|---|---|---|
| DuckDuckGo (default) | duckduckgo |
— (free, keyless) |
| Tavily | tavily |
TAVILY_API_KEY |
| Serper | serper |
SERPER_API_KEY |
| Brave | brave |
BRAVE_API_KEY |
| Exa | exa |
EXA_API_KEY |
| Firecrawl | firecrawl |
FIRECRAWL_API_KEY |
WEB_SEARCH_PROVIDER selects the default provider (default duckduckgo). Paid
providers raise a clear ProviderError when their key is missing.
Use the contract directly (provider-agnostic)
from xyberos_web_search import get_web_search
search = get_web_search("serper") # reads SERPER_API_KEY
for result in search.search("xyberos", top_k=3):
print(result.title, result.url, result.snippet)
Design
- Contract —
WebSearchprotocol +SearchResult(title, url, snippet, score, extra). - Adapters — thin, dependency-free, with an injectable
requesttransport so tests run without a network. - Tool — the plugin registers
web_search(query: str, top_k: int = 5)through the publicFunctionToolAPI.
Examples
examples/web_search.py— CLI example; needs an API key (see README).
Tests
pip install pytest
pytest tests/
Adapters are tested against canned responses via a fake transport — no network required.
Ship location
Plugin (xyberos.plugins entry point). Depends on M2's HTTP patterns.
Metadata
Release files for xyberos-web-search 0.2.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| xyberos_web_search-0.2.2.tar.gz | 10.3 kB | With provenance | Details for xyberos_web_search-0.2.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| xyberos_web_search-0.2.2-py3-none-any.whl | Python 3 | none | any | Details for xyberos_web_search-0.2.2-py3-none-any.whl |
Total release size: 20.5 kB
Release files / xyberos_web_search-0.2.2.tar.gz
| Download URL | xyberos_web_search-0.2.2.tar.gz |
|---|---|
| Size | 10.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ada7d2201ba08b6e1d704573ff2c7efbe6952caabf78e31c8887fe6712d1fd12
|
|
BLAKE2b-256 checksum How to use checksums |
c2fb9a3906ad629e7b57a6c24f8e31c9f8657a3a185335d37cd4a1905aac8219
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 11, 2026.
Transparency logRelease files / xyberos_web_search-0.2.2-py3-none-any.whl
| Download URL | xyberos_web_search-0.2.2-py3-none-any.whl |
|---|---|
| Size | 10.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a9a507bcbbd8996d95dc825ab6ab919511981cace55eb8252a2f13ed71b659f9
|
|
BLAKE2b-256 checksum How to use checksums |
56b1b7353805ffdaa74b2604f919e001270521ff842b1e39f064d7b06019e84d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 11, 2026.
Transparency logSecurity for xyberos-web-search 0.2.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for xyberos_web_search-0.2.2.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 11, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.