oterm/docs/oracle
Yiorgis Gozadinos 97fd157160
Correct and restructure the docs
- rag_example: rewrite for current haiku.rag. The MCP server is
  `haiku-rag mcp` and opens the database read-only, so documents are
  added with the CLI; the page described `serve`, SQLite storage and
  add/delete tools that no longer exist.
- mcp: stdio servers accept cwd and inherit HOME, LOGNAME, PATH, SHELL,
  TERM and USER.
- app_config: each openaiCompatible endpoint is its own provider;
  XDG_DATA_HOME applies everywhere but Windows; list
  OTERM_OLLAMA_IMAGE_MODEL and everything under OTERM_DATA_DIR.
- commands: add Copy message, an Images section and the command-line
  options; clicking a code block copies the whole message.
- installation: document the speak extra and nix updates; drop the
  0.13.1 tap note.
- development: uv-based setup; docs are built with Zensical.
- One H1 per page; no em dashes.
- README points at the CHANGELOG; drop the stale announcement banner.
2026-09-26 16:42:42 +03:00
..
src/oracle Replace external tool loading with entry points, fix bugs 2026-04-15 12:56:27 +03:00
.python-version Bump pydantic-ai to 2.51.0 and drop Python 3.10 2026-09-26 15:51:22 +03:00
pyproject.toml Bump pydantic-ai to 2.51.0 and drop Python 3.10 2026-09-26 15:51:22 +03:00
README.md Correct and restructure the docs 2026-09-26 16:42:42 +03:00

Oracle: example oterm tool plugin

A minimal example of how to ship a Python package whose function is auto-discovered as an oterm tool.

The tool itself is trivial, oracle(question) always answers "oterm", so you can focus on the packaging:

  • src/oracle/tool.py defines the function. Its name, docstring, and type annotations are what oterm passes to the model.

  • pyproject.toml registers the function under the oterm.tools entry-point group:

    [project.entry-points."oterm.tools"]
    oracle = "oracle.tool:oracle"
    

Install it into the same environment as oterm:

cd docs/oracle
uv pip install .   # or: pip install .

After restart, the oracle tool appears in the new-chat tool selector.

See the tools guide for the full walkthrough.