Llama-3.2-3B-Instruct for Kjarni
Built with Llama. This is Meta's Llama-3.2-3B-Instruct, unchanged, hosted so it runs locally with Kjarni without a Hugging Face account or token: one native library, with no Python runtime, server or cloud service. It is a small chat model that follows instructions well for its size, and runs on a CPU or a modest GPU. The model is about 6.4 GB and downloads on first use.
Usage
Kjarni 0.8.3 and later download it from here. In Kjarni the model is called
llama3.2-3b-instruct. The reply below is an example: replies are sampled, so yours will be
worded differently.
Command line
curl -fsSL https://kjarni.ai/install.sh | sh # Windows: irm https://kjarni.ai/install.ps1 | iex
echo "In one sentence, what is a hash table?" | kjarni chat -q -m llama3.2-3b-instruct # or run kjarni chat -m llama3.2-3b-instruct to talk to it
A hash table is a data structure that stores key-value pairs in an array using a hash function to map unique keys to specific indices, allowing for efficient lookup, insertion, and deletion of elements.
Python
# pip install kjarni
from kjarni import Chat
chat = Chat(model="llama3.2-3b-instruct", quiet=True)
print(chat.send("In one sentence, what is a hash table?"))
Rust
// cargo add kjarni anyhow tokio --features tokio/full
#[tokio::main]
async fn main() -> anyhow::Result<()> {
let reply = kjarni::chat::send("llama3.2-3b-instruct", "In one sentence, what is a hash table?").await?;
println!("{reply}");
Ok(())
}
C#
// dotnet add package Kjarni
using Kjarni;
using var chat = new Chat("llama3.2-3b-instruct", quiet: true);
Console.WriteLine(chat.Send("In one sentence, what is a hash table?"));
C++ (C++23)
#include <kjarni.hpp>
#include <iostream>
int main() {
kjarni::ChatOptions options;
options.model = "llama3.2-3b-instruct";
auto chat = kjarni::Chat::create(options);
if (!chat) return 1;
auto reply = chat->send("In one sentence, what is a hash table?");
if (!reply) return 1;
std::cout << *reply << "\n";
}
Go
// go get github.com/kjarni-ai/kjarni-go
package main
import (
"fmt"
"log"
kjarni "github.com/kjarni-ai/kjarni-go"
)
func main() {
chat, err := kjarni.NewChat("llama3.2-3b-instruct", kjarni.WithQuiet(true))
if err != nil {
log.Fatal(err)
}
defer chat.Close()
reply, err := chat.Send("In one sentence, what is a hash table?")
if err != nil {
log.Fatal(err)
}
fmt.Println(reply)
}
To run on a GPU, add --gpu on the command line or pass device="gpu". For 4-bit
weights, which use a fraction of the memory and generate faster on a CPU, add --gguf
or pass quantized=True. The 4-bit
weights come from bartowski/Llama-3.2-3B-Instruct-GGUF.
See the Kjarni documentation for other languages and installation
details.
What changed from the original
Nothing. Every file here is byte for byte the same as in
meta-llama/Llama-3.2-3B-Instruct at revision
0cb88a4f764b7a12671c53f0838cd831a0843b95, except this README, which replaces Meta's model card, and the added
NOTICE. The original/ folder (Meta's PyTorch checkpoint) is left out, since the
safetensors weights hold the same model.
About the model
Llama 3.2 3B Instruct is a 3.21-billion-parameter multilingual model from Meta, tuned for dialogue and released in September 2024. It reads up to 128,000 tokens. Meta officially supports English, German, French, Italian, Portuguese, Hindi, Spanish and Thai.
See Meta's model card for training data, benchmarks, intended use and safety evaluations.
License
Llama 3.2 is licensed under the Llama 3.2 Community License, Copyright © Meta Platforms, Inc. All Rights Reserved. The license is in LICENSE.txt, and use of the
model must follow Meta's Acceptable Use Policy in USE_POLICY.md.
Anyone who downloads the model from here, through Kjarni or directly, receives it under
the same license.
Kjarni and this hosting are not affiliated with or endorsed by Meta.