LLM fine-tuning and alignment framework for the Kailash platform
Project description
kailash-align
LLM fine-tuning and alignment framework for the Kailash platform. Part of the Kailash Python SDK by the Terrene Foundation.
Overview
kailash-align provides structured LoRA/QLoRA fine-tuning with full lifecycle tracking:
- AdapterRegistry -- Track adapters from training through evaluation, merge, GGUF export, and deployment
- AlignmentPipeline -- Thin wrappers around TRL SFTTrainer and DPOTrainer with checkpoint management
- AlignmentConfig -- Validated configuration dataclasses with NaN/Inf protection
Installation
pip install kailash-align
Optional Extras
pip install kailash-align[rlhf] # QLoRA via bitsandbytes
pip install kailash-align[eval] # Model evaluation via lm-eval
pip install kailash-align[serve] # GGUF export via llama-cpp-python
pip install kailash-align[all] # All extras
Quick Start
from kailash_align import AlignmentConfig, AlignmentPipeline, AdapterRegistry
# Configure
config = AlignmentConfig(
base_model_id="meta-llama/Llama-3.1-8B",
method="sft",
)
# Track adapters
registry = AdapterRegistry()
# Train
pipeline = AlignmentPipeline(config=config, adapter_registry=registry)
result = await pipeline.train(dataset=my_dataset, adapter_name="my-adapter")
# Result includes adapter path, metrics, and registry version
print(result.adapter_path)
print(result.training_metrics)
License
Apache 2.0 -- see LICENSE.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file kailash_align-0.7.0-py3-none-any.whl.
File metadata
- Download URL: kailash_align-0.7.0-py3-none-any.whl
- Upload date:
- Size: 106.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
201b0b9046b607d984e9c73dc349c2cae9f93781a269d3b460650f0545fa2022
|
|
| MD5 |
b3087a19fef85dc8d793dcb3eea734e5
|
|
| BLAKE2b-256 |
61aecb8204bc2aa122d75004003d5ef6f89435468dbcc6de770e88f900529934
|
Provenance
The following attestation bundles were made for kailash_align-0.7.0-py3-none-any.whl:
Publisher:
publish-pypi.yml on terrene-foundation/kailash-py
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
kailash_align-0.7.0-py3-none-any.whl -
Subject digest:
201b0b9046b607d984e9c73dc349c2cae9f93781a269d3b460650f0545fa2022 - Sigstore transparency entry: 1392692869
- Sigstore integration time:
-
Permalink:
terrene-foundation/kailash-py@7a72a3a5cebf361fa93e27bdc1d964f58b8db3a3 -
Branch / Tag:
refs/tags/align-v0.7.0 - Owner: https://github.com/terrene-foundation
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@7a72a3a5cebf361fa93e27bdc1d964f58b8db3a3 -
Trigger Event:
push
-
Statement type: