βš›οΈ Vigyan-2B-STEM-Instruct-v1

Sovereign Edge Small Language Model (SLM) for Ultra-Fast STEM Reasoning

Open In Colab  License: CC BY-NC 4.0  GitHub Demo

Developed by Vigyan AI in Varanasi, Uttar Pradesh, India.


🌟 Model Overview

Vigyan-2B-STEM-Instruct-v1 is India's sovereign edge Small Language Model (SLM) engineered specifically for low-latency, edge-deployable STEM reasoning.

At ~2.4 billion parameters, it delivers:

  1. Ultra-Low VRAM Footprint: Requires only ~1.8 GB VRAM in 4-bit NF4 precision, making it deployable on consumer laptops, edge gateways, Raspberry Pi 5, and mobile devices.
  2. Sub-Second Token Generation: Yields 45–60 tokens/second on a single GPU, enabling real-time interactive STEM tutoring and on-device circuit debugging.
  3. Structured Tool Calling: Trained to invoke deterministic Python execution blocks (<tool_call>) for exact arithmetic calculations.

πŸš€ 1-Click Interactive Google Colab Demo

Run the 2B edge model live on free Google Colab hardware with zero local setup:

πŸ‘‰ Open In Colab


πŸ”¬ Core Engineering Domains

  • Circuit Physics & Embedded Hardware: Parallel and series resistor calculations, RC time constants, Kirchhoff's laws, and operational amplifier gains.
  • VLSI EDA & Logic Design: CMOS inverter delays, interconnect resistance, setup and hold time slack, and Boolean logic synthesis.
  • Orbital Mechanics & Physics: Gravitational potential energy, circular orbital speed, kinetic energy, and spring harmonic oscillators.
  • Foundational Mathematics: Definite integration, matrix operations, quadratic vertex solutions, and algebra.

πŸ’» Quickstart (Transformers & PEFT)

import torch
from transformers import AutoTokenizer, AutoModelForCausalLM, BitsAndBytesConfig
from peft import PeftModel

BASE_MODEL = "shreyansh12183/Shreyansh-STEM-AI-2B-v3"
ADAPTER = "shreyansh12183/Vigyan-2B-STEM-Instruct-v1"

# 1. Load Tokenizer
tokenizer = AutoTokenizer.from_pretrained(ADAPTER, trust_remote_code=True)

# 2. 4-bit Quantization Config (Runs on any laptop GPU with < 2GB VRAM)
bnb_config = BitsAndBytesConfig(
    load_in_4bit=True,
    bnb_4bit_quant_type="nf4",
    bnb_4bit_compute_dtype=torch.float16,
    bnb_4bit_use_double_quant=True
)

# 3. Load Model
base_model = AutoModelForCausalLM.from_pretrained(
    BASE_MODEL,
    quantization_config=bnb_config,
    device_map="auto",
    torch_dtype=torch.float16
)
model = PeftModel.from_pretrained(base_model, ADAPTER)
model.eval()

# 4. Prompt
prompt = "<|im_start|>user\nCalculate the equivalent resistance of 150 ohms and 300 ohms in parallel.<|im_end|>\n<|im_start|>assistant\n"
inputs = tokenizer(prompt, return_tensors="pt").to("cuda")

with torch.no_grad():
    outputs = model.generate(**inputs, max_new_tokens=256, do_sample=False)

print(tokenizer.decode(outputs[0], skip_special_tokens=True))

πŸ“œ Non-Commercial License (CC BY-NC 4.0)

This model is released under the Creative Commons Attribution-NonCommercial 4.0 International (CC BY-NC 4.0) license.

  • Permitted Free Use: Academic research, educational exploration, university coursework, and personal non-commercial experiments.
  • Commercial Restrictions: Any commercial deployment, monetization, commercial tutoring platform integration, defense contractor use, or proprietary API hosting requires an explicit enterprise commercial license from Vigyan AI.
  • Commercial Inquiries: Contact Vigyan AI Founder at IIT BHU / Varanasi.
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 shreyansh12183/Vigyan-2B-STEM-Instruct-v1

Finetuned
(2)
this model