kernelpool/Kimi-K3-2bit-UVMAX
41.4k
kernelpool/Kimi-K3-2bit-UVMAX
Mixed-precision (UVMAX) quantization of moonshotai/Kimi-K3.
What is UVMAX?
UVMAX is a mixed-precision scheme: bit widths are assigned per tensor class from measured round-trip quantization error, rather than uniformly.
Use with mlx
This model requires Kimi K3 support from mlx-lm PR #1626, which has not yet been merged. Until it is included in an mlx-lm release, install mlx-lm from the PR branch:
pip install git+https://github.com/ml-explore/mlx-lm.git@refs/pull/1626/head
pip install tiktokenfrom mlx_lm import load, generate
model, tokenizer = load(
"kernelpool/Kimi-K3-2bit-UVMAX",
tokenizer_config={"trust_remote_code": True},
trust_remote_code=True,
)
prompt = "hello"
messages = [{"role": "user", "content": prompt}]
prompt = tokenizer.apply_chat_template(messages, add_generation_prompt=True)
response = generate(model, tokenizer, prompt=prompt, verbose=True)