Skip to main content

Bharat-Tiny-LLM - India's first native edge AI for Hinglish and Hindi, running on-device on ₹8,000 phones.

Project description

🇮🇳 Bharat-Tiny-LLM

India's first native edge AI for Hinglish & Hindi — running fully offline on ₹8,000 phones.

bharat-tiny-llm is the official Python package for Bharat-Tiny-LLM: a 1.5B-parameter, LoRA-fine-tuned language model that speaks fluent Hinglish (Romanized Hindi) and Devanagari Hindi, and runs entirely on-device — no API, no cloud, no internet.

Built by eulogik · 🤗 Model: eulogik/Bharat-Tiny-LLM · 🚀 Live demo: spaces/eulogik/Bharat-Tiny-LLM · 💻 Code: github.com/eulogik/Bharat-Tiny-LLM


Why Bharat-Tiny-LLM?

  • 🌐 Truly bilingual — Hinglish and Devanagari Hindi in one model (most Indic models do only one).
  • 📱 Edge-native — 880 MB 4-bit build runs offline on ₹8,000 Android phones & Apple Silicon.
  • 🆓 Open & free — Apache-2.0 weights, no vendor lock-in, self-hostable.
  • 💸 $0 training cost — fine-tuned on a Mac Mini M4, zero cloud compute.
  • 🪶 Small — 1.5B params, ~57 tok/s on a Mac Mini M4.

Install

# Apple Silicon (recommended — MLX 4-bit, fastest)
pip install bharat-tiny-llm[mlx]

# Other platforms (CPU / CUDA, transformers backend)
pip install bharat-tiny-llm[torch]

Quick start

from bharat_tiny_llm import chat

reply = chat([
    {"role": "user", "content": "Chai peete hain?"},
])
print(reply)

The package ships with a canonical generation config (temperature=0.3, top_p=0.85, repetition_penalty=1.25, no_repeat_ngram_size=3) so output is clean out of the box — no garbled scripts, no degenerate loops. You normally never have to tune these.

Apple Silicon, low-level MLX

from bharat_tiny_llm import load
from mlx_lm import generate

model, tokenizer = load()  # pulls eulogik/Bharat-Tiny-LLM (MLX 4-bit)
prompt = tokenizer.apply_chat_template(
    [{"role": "user", "content": "Biryani kaise banate hain?"}],
    tokenize=False, add_generation_prompt=True,
)
print(generate(model, tokenizer, prompt=prompt, max_tokens=128))

Model variants

Repo Format Size Use
eulogik/Bharat-Tiny-LLM MLX 4-bit ~880 MB Edge / Apple Silicon (default)
eulogik/Bharat-Tiny-LLM-fused PyTorch fp16 ~3.3 GB Server / fine-tuning base

Links

License

Apache-2.0 (base Qwen2.5-1.5B weights Apache-2.0; LoRA adapter Apache-2.0).

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

bharat_tiny_llm-0.1.0.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

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

bharat_tiny_llm-0.1.0-py3-none-any.whl (5.5 kB view details)

Uploaded Python 3

File details

Details for the file bharat_tiny_llm-0.1.0.tar.gz.

File metadata

  • Download URL: bharat_tiny_llm-0.1.0.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for bharat_tiny_llm-0.1.0.tar.gz
Algorithm Hash digest
SHA256 b23d7b828d2f84825b20c943502ff9ffd7927014b8a3aada5cdd4b26e84b1aa4
MD5 1df6badc91961df0a067b4549127fee9
BLAKE2b-256 6a5f6d5f9daff00d640032dd93e342f1abe0c5e583e9d5041ca68de438122809

See more details on using hashes here.

File details

Details for the file bharat_tiny_llm-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for bharat_tiny_llm-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 5d052438f9d51fe735550853b1a96b1e2cc078e5fa9f61649f95b6de522caa70
MD5 8f3c49bc99e818ceca4ce0631cff0a4e
BLAKE2b-256 98305cfa826278686a63107e28de77a2932801ae4cf97ca8b8c3454c20e3edf9

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