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.1.tar.gz (110.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.1-py3-none-any.whl (95.8 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: gsql_track-0.3.1.tar.gz
  • Upload date:
  • Size: 110.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.1.tar.gz
Algorithm Hash digest
SHA256 2b4a734734f4d18abe9b0b056af620d2937d3199dfe029bc372f46e84a9750e3
MD5 8db6a94513ce200b2f83439a4586b1f2
BLAKE2b-256 aa55e96803e25f47348e8f3b221e9877802aef3aab75d734ee9d6e45c032b890

See more details on using hashes here.

File details

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

File metadata

  • Download URL: gsql_track-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 95.8 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.1-py3-none-any.whl
Algorithm Hash digest
SHA256 c8f840388993b6dabcd16b703850a0916d791d4b92215a10a6424fcae242effb
MD5 11c111b33438245f2a7b0ed452bba5cb
BLAKE2b-256 913ba044fae6782a1b759afc374be35dd57c17ffba3afee568c20d130449fa56

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