Skip to main content

Web search tools for Bub

Project description

bub-web-search

Provider-selectable web search tools for bub.

Providers

Set BUB_SEARCH_PROVIDER to enable exactly one search provider:

  • ollama registers web.search
  • searxng registers searxng.search

If the provider is unset or its required configuration is missing, neither tool is registered.

Installation

bub install bub-web-search

Ollama

Required:

  • BUB_SEARCH_PROVIDER=ollama
  • BUB_SEARCH_OLLAMA_API_KEY

Optional:

  • BUB_SEARCH_OLLAMA_API_BASE
    • Default: https://ollama.com/api

The web.search tool accepts query and max_results.

SearXNG

Required:

  • BUB_SEARCH_PROVIDER=searxng
  • BUB_SEARCH_SEARXNG_BASE_URL

Optional:

  • BUB_SEARCH_SEARXNG_TIMEOUT_SECONDS
    • Default: 10
  • BUB_SEARCH_SEARXNG_DEFAULT_LANGUAGE
  • BUB_SEARCH_SEARXNG_DEFAULT_SAFE_SEARCH
    • 0 off, 1 moderate, 2 strict
    • Default: 1
  • BUB_SEARCH_SEARXNG_USER_AGENT
    • Default: bub-web-search/1.0
  • BUB_SEARCH_SEARXNG_AUTH_HEADER
  • BUB_SEARCH_SEARXNG_AUTH_VALUE

The searxng.search tool accepts:

  • query
  • max_results
  • categories
  • engines
  • language
  • time_range
  • safe_search

The SearXNG instance must allow JSON responses from its /search endpoint.

Migration From bub-searxng-search

Replace the package with bub-web-search, set BUB_SEARCH_PROVIDER=searxng, and rename the environment variables:

  • BUB_SEARXNG_SEARCH_BASE_URL to BUB_SEARCH_SEARXNG_BASE_URL
  • other BUB_SEARXNG_SEARCH_* variables to BUB_SEARCH_SEARXNG_*

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bub_web_search-0.0.1.tar.gz (5.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

bub_web_search-0.0.1-py3-none-any.whl (7.7 kB view details)

Uploaded Python 3

File details

Details for the file bub_web_search-0.0.1.tar.gz.

File metadata

  • Download URL: bub_web_search-0.0.1.tar.gz
  • Upload date:
  • Size: 5.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.20 {"installer":{"name":"uv","version":"0.11.20","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for bub_web_search-0.0.1.tar.gz
Algorithm Hash digest
SHA256 7aa3bfdfd53bea9c75b21f654a71f9e3bc1b34b5d892f8983e24ef5d7e1639c3
MD5 c118a6eb44b503bd1ce2a84e8c824b50
BLAKE2b-256 51998b98af026c6159a0a88d5ce0923684df384130bc02582c0f3ff70373c7d2

See more details on using hashes here.

File details

Details for the file bub_web_search-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: bub_web_search-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 7.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.20 {"installer":{"name":"uv","version":"0.11.20","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for bub_web_search-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 ab6f8d71e75a05fdd6be8355cf11ca2676734f77445c352182c0cc24d45458b0
MD5 87f4e60976e3e20ed50f8946bedcc584
BLAKE2b-256 ee490a0b705a7db9846431201117bbed2b331bac40c8db81f98617e7b1d41ad0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page