How to use from
Pi
Start the llama.cpp server
# Install llama.cpp:
brew install llama.cpp
# Start a local OpenAI-compatible server:
llama serve -hf smshahbaj/Rifa-Nano-0.5B:
Configure the model in Pi
# Install Pi:
npm install -g @earendil-works/pi-coding-agent
# Add to ~/.pi/agent/models.json:
{
  "providers": {
    "llama-cpp": {
      "baseUrl": "http://localhost:8080/v1",
      "api": "openai-completions",
      "apiKey": "none",
      "models": [
        {
          "id": "smshahbaj/Rifa-Nano-0.5B:"
        }
      ]
    }
  }
}
Run Pi
# Start Pi in your project directory:
pi
Quick Links

RIFA-Nano

Created / maintained by SM Shahbaj


About

RIFA-Nano is a lightweight fine-tuned model maintained by SM Shahbaj.

Property Value
Model RIFA-Nano
Parameters 0.5B
Creator SM Shahbaj

Part of the RIFA model family by SM Shahbaj.


Downloads

File Link
Safetensors Browse
Rifa-Nano-0.5B.F16.gguf Download
Rifa-Nano-0.5B.Q3_K_M.gguf Download
Rifa-Nano-0.5B.Q4_K_M.gguf Download
Rifa-Nano-0.5B.Q5_K_M.gguf Download
Rifa-Nano-0.5B.Q6_K.gguf Download
Rifa-Nano-0.5B.Q8_0.gguf Download

Recommended: Q5_K_M when available.


Quick start

from transformers import AutoModelForCausalLM, AutoTokenizer
repo = "smshahbaj/Rifa-Nano-0.5B"
tok = AutoTokenizer.from_pretrained(repo)
model = AutoModelForCausalLM.from_pretrained(repo, device_map="auto")
messages = [{"role": "user", "content": "Hello"}]
text = tok.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
inputs = tok(text, return_tensors="pt").to(model.device)
print(tok.decode(model.generate(**inputs, max_new_tokens=64)[0], skip_special_tokens=True))

Creator

SM Shahbajhuggingface.co/smshahbaj

License: Apache 2.0

RIFA Model Family — SM Shahbaj

Downloads last month
1,646
Safetensors
Model size
0.5B params
Tensor type
BF16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for smshahbaj/Rifa-Nano-0.5B

Quantizations
3 models