Skip to main content

Lightweight experiment tracking and ML infrastructure with SQLite backend

Project description

gsql-track

Lightweight experiment tracking backed by SQLite. Zero dependencies beyond the Python standard library.

Install

pip install gsql-track

Quick Start

from gsql_track import GsqlTrack

t = GsqlTrack("my-experiment")
run = t.start_run("baseline")
run.log_params({"lr": 0.001, "bs": 64})

for step in range(100):
    run.log(step=step, loss=loss, acc=acc)

run.finish()
t.close()

Log Predictions (for mistake analysis)

run.log_predictions([
    {"id": "e1", "pred": "A", "label": "A", "conf": 0.95, "text": "..."},
    {"id": "e2", "pred": "B", "label": "A", "conf": 0.60, "text": "..."},
])

Web Dashboard

View results in the browser with the companion Go CLI:

gsql track serve

Bulk / Async Loading (tune & bench results)

Load results after all runs finish — useful for distributed or async workflows:

from gsql_track import GsqlTrack

t = GsqlTrack("bench/weak_labels")

# Single-step results (final metrics only)
for result in all_results:
    t.log_completed_run(
        f"{result.model}/{result.task}/seed_{result.seed}",
        params={"lr": result.lr, "bs": result.bs},
        metrics={"acc": result.acc, "f1": result.f1},
    )

# Or multi-step (full training curves)
t.log_completed_run("bert/sst2/seed_0", metrics=[
    {"step": 0, "loss": 2.3, "acc": 0.1},
    {"step": 100, "loss": 0.5, "acc": 0.8},
    {"step": 200, "loss": 0.1, "acc": 0.93},
])

t.close()

Wrapper API

Wrap an existing tracker class to automatically log to gsql:

from gsql_track import tracked
tracker = tracked(MyTracker(config), experiment="mnist")

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

gsql_track-0.3.0.tar.gz (104.1 kB view details)

Uploaded Source

Built Distribution

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

gsql_track-0.3.0-py3-none-any.whl (95.5 kB view details)

Uploaded Python 3

File details

Details for the file gsql_track-0.3.0.tar.gz.

File metadata

  • Download URL: gsql_track-0.3.0.tar.gz
  • Upload date:
  • Size: 104.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.10

File hashes

Hashes for gsql_track-0.3.0.tar.gz
Algorithm Hash digest
SHA256 c2bc2f3020e155e2c4968f9a7f272478fbc73903f4632c8275090c2654aaf98f
MD5 685ec168dece3152a1aa13606f187b83
BLAKE2b-256 8fe3b48441cd9b69fbf8ee68db52c95b9f7ae7346eb9166bb0c9aeb4c9b85087

See more details on using hashes here.

File details

Details for the file gsql_track-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: gsql_track-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 95.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.10

File hashes

Hashes for gsql_track-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 76aa1b248c3d6550285c5c8d429971ebe9a4bd48eee3785e1da30f36a776c18a
MD5 bcc127a66b1460452ce0695a5bc6699c
BLAKE2b-256 37ea00e78f06b633147a3987f3fc97b2944211ee0c940f711f570b9020b7b42c

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