mirror of
https://github.com/ggozad/oterm.git
synced 2026-10-13 18:53:21 +02:00
| .. | ||
| src/oracle | ||
| .python-version | ||
| pyproject.toml | ||
| README.md | ||
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 intentionally trivial — oracle(question) always answers "oterm" — so you can focus on the packaging:
-
src/oracle/tool.pydefines the function. Its name, docstring, and type annotations are what oterm passes to the model. -
pyproject.tomlregisters the function under theoterm.toolsentry-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.