Skip to main content

Local LLM Inference Platform with adapter support and evaluation toolkit

Project description

ML-Clara

ML-Clara is a small, config-driven CLI + Python API for:

  • Local LLM inference with streaming (clara run)
  • Lightweight benchmarking (clara eval)
  • LoRA fine-tuning (clara train) and adapter merging (clara export)
  • Device auto-detection (MPS/CUDA/CPU)

This repository also contains Apple’s CLaRa research codebase; ML-Clara lives in the clara/ package.


Install

pip install ml-clara
clara info

If your platform needs a specific PyTorch build, install PyTorch first, then install ML-Clara.


Quickstart

Run

clara run "Explain LoRA in one paragraph" --model gpt2
clara run "Write a haiku about debugging" --model gpt2 --stream

Create a config (recommended)

clara init-config --type default -o config.yaml
clara run "Hello" --config config.yaml

Eval

clara eval --model gpt2 --benchmarks perplexity --samples 50

Fine-tune (LoRA)

clara init-config --type finetune -o finetune.yaml
clara train --config finetune.yaml

Web UI (FastAPI)

pip install "ml-clara[server]"
clara serve --model gpt2

Then open http://127.0.0.1:8000.

Export (merge adapter)

clara export outputs/my-adapter/final --output models/merged

Docs

  • Troubleshooting: docs/TROUBLESHOOTING.md
  • Full repository README (CLaRa research + ML-Clara section): README.md

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

ml_clara-1.3.1.tar.gz (66.1 kB view details)

Uploaded Source

Built Distribution

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

ml_clara-1.3.1-py3-none-any.whl (66.0 kB view details)

Uploaded Python 3

File details

Details for the file ml_clara-1.3.1.tar.gz.

File metadata

  • Download URL: ml_clara-1.3.1.tar.gz
  • Upload date:
  • Size: 66.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.8

File hashes

Hashes for ml_clara-1.3.1.tar.gz
Algorithm Hash digest
SHA256 aa2e9764c6c966d4da873b8b3bce295385f4f03e0159559e8378b86b873f9cd9
MD5 b569e7c2fe0b1a324da857870e403c9d
BLAKE2b-256 b509168c9fdd85178db9150f53e7c82a910724057420c0d6defa530d4771e1bc

See more details on using hashes here.

File details

Details for the file ml_clara-1.3.1-py3-none-any.whl.

File metadata

  • Download URL: ml_clara-1.3.1-py3-none-any.whl
  • Upload date:
  • Size: 66.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.8

File hashes

Hashes for ml_clara-1.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 bbcea40a4c1953a98da1f896a8081d5ba43737d6e95e99c230b3d2a9ae81cb7a
MD5 253ce64b16b8a493f7656034281138aa
BLAKE2b-256 8e188bcb4204e0ad9fc43e762f10a2efa94cbd8b8a86bdf26b62c56bd90e3e40

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