Skip to main content

Glassbox LLMs is a GDG open-source project exploring the inner workings of large language models. We combine hands-on experiments with the latest research to decode the “black box” of modern AI

Project description

Glassbox LLMs

Python PyTorch Transformers scikit-learn NumPy 🤗 Datasets Weights & Biases MLflow

Glassbox LLMs is a Python codebase for LLM interpretability experiments (instrumentation, patching, attribution, probes, circuits, and visualization demos).

Install

pip install glassbox

For local development (editable install):

pip install -e .

Usage

Run an experiment via the runner CLI

  • Entry point: python -m glassboxllms.runner.cli --config <path>
  • Example config: src/glassboxllms/runner/example_config.json
python -m glassboxllms.runner.cli --config src/glassboxllms/runner/example_config.json --dry-run
python -m glassboxllms.runner.cli --config src/glassboxllms/runner/example_config.json

Demo notebook: notebooks/glassbox_demo.ipynb

Experiments (in src/glassboxllms/experiments/)

  • cot_faithfulness/: Chain-of-Thought faithfulness evaluation.

    • What it tests: truncation (cut reasoning early and see if the answer changes) + error-injection (inject wrong reasoning and see if the model follows it).
    • Question sets: cot_faithfulness/questions/{arc_challenge,aqua,mmlu}.json
    • Core entrypoint (python API): glassboxllms.experiments.cot_faithfulness.CoTFaithfulnessEvaluator
  • TODO add in the remaining experiments + example usage

👥 Contributors

Meet the team behind Glassbox LLMs! Each contributor has played a key role in shaping the project.

Name Role Top PRs
Rawan Mahdi Project Lead & Architecture
Jordan Rivera ML Research & Interpretability #7 – Sparse autoencoder integration · #21 – Attention map visualizer
Sam Patel Feature Attribution & Analysis #15 – SHAP wrapper implementation · #29 – Gradient-based attribution
Morgan Lee Documentation & Tutorials #9 – Getting started guide · #38 – Notebook tutorial series
Taylor Kim Testing & CI/CD #11 – Test suite setup · #26 – GitHub Actions pipeline

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

glassbox_llms-0.1.2.tar.gz (138.7 kB view details)

Uploaded Source

Built Distribution

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

glassbox_llms-0.1.2-py3-none-any.whl (139.3 kB view details)

Uploaded Python 3

File details

Details for the file glassbox_llms-0.1.2.tar.gz.

File metadata

  • Download URL: glassbox_llms-0.1.2.tar.gz
  • Upload date:
  • Size: 138.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.12

File hashes

Hashes for glassbox_llms-0.1.2.tar.gz
Algorithm Hash digest
SHA256 81a09a45008f7c518a4d71fb3d4b48ddc8c48f663903693b06948fe57a4a19ef
MD5 b71bb664257403d2f1d4a910b643cdb8
BLAKE2b-256 1ac90e65fd02324d1f6848cae54b9ab79b4d5b6fb9b44eec05b985de1a17e5cf

See more details on using hashes here.

File details

Details for the file glassbox_llms-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: glassbox_llms-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 139.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.12

File hashes

Hashes for glassbox_llms-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 ccff78bb065c68f33566986b778702ff95c2a06188e0ad0dab0bc5c5f78cd0d9
MD5 50c01dc0957148b54d78f0ebb84b5b7b
BLAKE2b-256 4be3f455171efa3f02820f157b7f3f1b8acac9c9ac0d224d9828b91c67a7ff6b

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