A question solver plugin for OVOS
Project description
ovos-solver-hivemind-plugin
Exposes a HiveMind connection as an OVOS solver plugin.
A solver plugin is a Q&A backend: given a question, return a spoken answer. This
plugin sends the question to a remote HiveMind hub, waits for the hub's speak
responses, and returns them as the answer. Any application that uses OVOS solvers can
use a HiveMind hub as its answering backend.
Use cases:
- Route questions from an app to a remote OVOS/HiveMind hub.
- Expose HiveMind to any OpenAI-compatible UI via ovos-persona-server.
- Integrate HiveMind/OVOS as one solver in a Mixture of Solvers (MoS).
Install
pip install ovos-solver-hivemind-plugin
Quickstart
1. Register a client on the HiveMind hub
On the machine running hivemind-core:
hivemind-core add-client
# note the Access Key and Password
2. Set the identity on the client device
hivemind-client set-identity \
--key <access_key> \
--password <password> \
--host <hub_ip> --port 5678 --siteid solver
Verify:
hivemind-client test-identity
# should print: == Identity successfully connected to HiveMind!
3. Use the solver
from ovos_hivemind_solver import HiveMindSolver
solver = HiveMindSolver(config={"autoconnect": True})
print(solver.spoken_answer("what is the speed of light?"))
Or connect manually:
solver = HiveMindSolver()
solver.connect() # uses the identity file
print(solver.spoken_answer("what is the capital of France?"))
Configuration
| Key | Type | Default | Description |
|---|---|---|---|
autoconnect |
bool | false |
Connect to HiveMind automatically at construction time. |
useragent |
string | "ovos-hivemind-solver" |
User-agent string sent to the hub. |
site_id |
string | value from identity file | Site ID for the HiveMind connection. |
lang |
string | "en-us" |
Default language when none is in context. |
Connection credentials (host, port, key, password) come from the identity file set
with hivemind-client set-identity. They cannot be passed inline.
Using with ovos-persona
Add it as a solver in a persona JSON file:
{
"name": "HiveMind",
"solvers": [
{
"module": "ovos-solver-hivemind-plugin",
"ovos-solver-hivemind-plugin": {
"autoconnect": true
}
}
]
}
Using with ovos-persona-server
Start ovos-persona-server with a persona that includes this solver. Any
OpenAI-compatible client can then query HiveMind via the persona server's REST API.
Documentation
docs/solver_integration.md— how the solver integrates with the OVOS solver framework.docs/configuration.md— full configuration reference.
Credits
This work was sponsored by VisioLab, part of Royal Dutch Visio — the research and education center for assistive technology for blind and visually impaired people.
License
Apache 2.0.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ovos_solver_hivemind_plugin-0.0.4a3.tar.gz.
File metadata
- Download URL: ovos_solver_hivemind_plugin-0.0.4a3.tar.gz
- Upload date:
- Size: 4.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7ae2c1daab8f091e287d68c66c2ed846d46bcb83f153f1c447a9748df7142331
|
|
| MD5 |
55826f2ecc7abeb37dde56217afed54b
|
|
| BLAKE2b-256 |
c5e81a19697e69e7585bb2aced64ef184810d68e5d87cf3549328646aafeeb80
|
File details
Details for the file ovos_solver_hivemind_plugin-0.0.4a3-py3-none-any.whl.
File metadata
- Download URL: ovos_solver_hivemind_plugin-0.0.4a3-py3-none-any.whl
- Upload date:
- Size: 4.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
599002a6010599d3ba54ceb972c7f57fc43b27d702e251f37aa4064f2d11abde
|
|
| MD5 |
0b5df56157ece99cc49b5b8274a0173a
|
|
| BLAKE2b-256 |
cb0d5891946a0ecc958bd80f72e7db7b827b838467a2526b69b49e3f05615748
|