Geo-MLOps-SDK
Edge SDK and runtime for the Geosoft MLOps Central Platform.
The package ships two things:
geo_mlops_sdk.client— an async HTTP client (httpx) whose methods map 1:1 onto Central's device API. Use it when you only want to call the platform from your own application.geo_mlops_sdk.edge— a standalone edge runtime: local durable queue, connectivity monitor, throttled uploader, collectors, model cache and runners, a FastAPI surface for the on-site web UI, and a service daemon.
An edge PC is assumed to be treated roughly — cables pulled, power cut, offline for days. The runtime accumulates locally under a size/age ceiling, watches for the link to come back, and pushes the backlog without starving the collection that keeps running.
Installation
pip install geo-mlops-sdk # client only
pip install 'geo-mlops-sdk[edge]' # + standalone runtime and daemon
pip install 'geo-mlops-sdk[edge,gpu,modbus,yolo]'
| Extra | Adds |
|---|---|
edge |
runtime, FastAPI surface, daemon (geo-mlops-edge) |
gpu |
NVIDIA utilization in the heartbeat |
modbus |
Modbus TCP collector |
yolo |
local execution of YOLO models |
rfdetr |
local execution of RF-DETR models |
all |
everything above |
PyPI currently holds
0.0.2, a placeholder published before this SDK was rewritten.0.1.0is the first release of the rewritten package; anything below it predates the current API and shares nothing with it but the name.
Usage
from geo_mlops_sdk.client import CentralClient
from geo_mlops_sdk.contracts.edge import HeartbeatBody
async with CentralClient("https://central.example", "device-token") as client:
await client.register(location="yard-1")
await client.send_heartbeat(HeartbeatBody(cpu=12.5, mem=55.0, disk=61.0))
geo-mlops-edge run --config /etc/geo-mlops/edge.yaml # service entry point
geo-mlops-edge status # ask a running agent
geo-mlops-edge queue --state failed # why nothing is arriving
Deployment samples live in deploy/: a systemd unit, a Dockerfile,
and annotated edge.yaml / Modbus register-map examples. The top-level
docker-compose.yml runs the agent on its own from that Dockerfile, reading
/etc/geo-mlops/edge.yaml and edge.env from the host; a push to main of
the geo remote deploys it onto the self-hosted runner labelled edge
(.github/workflows/deploy-edge.yml).
Rotating a device token
A device token is required to talk to Central, and rotating one is a site visit. There is no remote path back:
- Rotate or revoke the token in Central (
POST /edge/devices/{id}/token:rotate). - The agent's next call is refused, the link goes to
AUTH_FAILED, and it stops -- deliberately, rather than hammering Central with rejected requests. - On the machine, put the new token in
/etc/geo-mlops/edge.env(GEO_EDGE_CENTRAL__TOKEN=...) and restart the service:sudo systemctl restart geo-mlops-edge.
Step 3 cannot be done from Central. The command poller stops along with
everything else, so a restart command cannot reach the device either -- which
is why the fleet screen reports how many days a token has left
(token_expires_in_days): tokens last a year, and that is exactly long enough
for the expiry to arrive unplanned.
geo-mlops-edge status says the same thing in words, at the top of its output,
so an engineer already standing at the machine does not have to infer it from a
state name.
The agent never restarts itself. A restart command from the fleet makes it
exit with code 3 and the supervisor starts a clean process.
Development
This project uses uv for dependency management.
uv sync --group dev --all-extras
Quality tooling (wrappers run the tool from the project root):
./check.sh # black --fix, isort --fix, flake8, mypy, pytest
./check.sh --ci # formatters in check mode (what CI runs)
./check.sh --build # the above plus `uv build`
Individual steps remain available: ./black.sh, ./isort.sh, ./flake8.sh,
./mypy.sh, ./pytest.sh.
Tests that need something outside the process are opt-in markers and are
excluded by default: live (a real Central server, see scripts/live/),
weights (real framework packages and checkpoints), gpu (an NVIDIA device).
Plans live in docs/plans/; the current one is
04-edge-sdk-rewrite-plan.md.
Metadata
Release files for geo-mlops-sdk 0.1.0
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 | |
|---|---|---|---|---|
| geo_mlops_sdk-0.1.0.tar.gz | 382.2 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| geo_mlops_sdk-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 484.3 kB
Release files / geo_mlops_sdk-0.1.0.tar.gz
| Download URL | geo_mlops_sdk-0.1.0.tar.gz |
|---|---|
| Size | 382.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
17629369870d1a7a643f494a12bd906c848325af58730a6feb1e875dfcf9afd4
|
|
BLAKE2b-256 checksum How to use checksums |
a54357ae4ff873b812d96632c95dadff437e6680a21372c1293bb408b533b3c6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / geo_mlops_sdk-0.1.0-py3-none-any.whl
| Download URL | geo_mlops_sdk-0.1.0-py3-none-any.whl |
|---|---|
| Size | 102.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
692d9549f10cec5de239628e4ab510720a4c7fbc6b625397d2589bc1b671672b
|
|
BLAKE2b-256 checksum How to use checksums |
8555acc8db57e401b43e6ca228fae45c900cb1122f94d43fdb1f4632bbac7c64
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Security for geo-mlops-sdk 0.1.0
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A 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.