☲ Project Nano-Coder (1.5B Agentic)

Model Description

Project Nano-Coder is a highly compact, agentic AI model fine-tuned exclusively for programming tasks. It is designed to be the smallest, most efficient coding agent possible.

Crucially, this model has been intentionally trained to possess ZERO general knowledge. It does not know history, trivia, or general chat. It only understands programming logic, syntax, and debugging.

🧠 Agentic Architecture

The model is trained on a strict Thought -> Action -> Observation loop. When given a task, it is designed to:

  1. Thought: Analyze the programming problem.
  2. Action: Output the precise code block required.
  3. Observation: Acknowledge the successful generation or prepare to debug based on external feedback.

πŸ› οΈ Intended Use

  • Autonomous coding agents and assistants.
  • Code generation, completion, and refactoring.
  • Debugging and error resolution in Python, JavaScript, HTML, C++, and more.

⚠️ Limitations & Guardrails

  • No General Knowledge: If asked "Who is the president?" or "Tell me a joke", the model will either refuse or output nonsensical code.
  • Requires an External Loop: For true agentic behavior (executing code and reading errors), this model should be paired with an external Python execution sandbox (ReAct loop) that feeds execution results back into the model's prompt.

πŸ’» Training Details

  • Base Model: Qwen2.5-Coder-1.5B
  • Quantization: 4-bit (QLoRA)
  • Dataset: Multi-language coding instructions (Python, JS, HTML, C++) formatted into strict agentic trajectories.
  • Framework: Unsloth + Hugging Face TRL

πŸ“¦ How to Use (Example)

from transformers import AutoModelForCausalLM, AutoTokenizer
import torch

model_id = "TheStrongestOfTomorrow/nano-coder-1.5b-agentic"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(
    model_id, 
    torch_dtype=torch.float16, 
    device_map="auto"
)

prompt = "<|im_start|>system\nYou are Nano-Coder. You possess ZERO general knowledge. You only understand programming logic.<|im_end|>\n<|im_start|>user\nTask: Write a Python function to reverse a string.<|im_end|>\n<|im_start|>assistant\n"

inputs = tokenizer(prompt, return_tensors="pt").to("cuda")
outputs = model.generate(**inputs, max_new_tokens=200)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Model tree for TheStrongestOfTomorrow/nano-coder-1.5b-agentic

Finetuned
(6)
this model