CoolFace
Modelpublic

cyberandy/sangue-e-grafi-nemotron-nano-sft-v7

sourceHugging Faceapache-2.0updated 4mo agoView on Hugging Face
0likes13downloads
Model Card

๐Ÿฉธ Sangue e Grafi โ€” Nemotron Mini 4B SFT Adapter (v7)

Supervised Fine-Tuned LoRA adapter on NVIDIA Nemotron Mini 4B โ€” cross-architecture validation of the KG-agent approach.

<p align="center"> <img src="https://huggingface.co/spaces/cyberandy/sangue-e-grafi/resolve/main/banner.png" alt="Sangue e Grafi banner" width="700"/> </p>

Model Description

This is a LoRA (PEFT) adapter trained via Supervised Fine-Tuning (SFT) on top of `nvidia/Nemotron-Mini-4B-Instruct`. It serves as a cross-architecture baseline for the Sangue e Grafi project, demonstrating that the KG-agent approach generalizes beyond a single model family.

The adapter teaches the model the same skills as its Gemma counterpart:

  1. 1.Parse complex kinship narratives in Italian
  2. 2.Emit structured tool calls grounded in the OWL kinship ontology
  3. 3.Reason step-by-step through multi-hop inheritance questions

Training Details

ParameterValue
MethodSFT (Supervised Fine-Tuning)
Base modelnvidia/Nemotron-Mini-4B-Instruct (4B params)
Training data500 adversarial kinship scenarios with teacher traces
TeacherGemini 2.5 Flash โ€” generated gold reasoning traces
FormatSafeTensors LoRA adapter

Benchmark Results ๐Ÿ“Š

Cross-Architecture Comparison

ModelHard Dev-Set Accuracy
Gemma 4B (SFT+GRPO)5/10 (50%)
Nemotron 4B (SFT+GRPO)4/10 (40%)
Gemini 2.5 Flash (no KG)3/10 (30%) โ€” easy set
Both 4B models with KG-agent outperform the frontier model without KG grounding โ€” validating that the approach is architecture-agnostic.

Usage

python
from peft import PeftModel
from transformers import AutoModelForCausalLM, AutoTokenizer

base = AutoModelForCausalLM.from_pretrained("nvidia/Nemotron-Mini-4B-Instruct")
model = PeftModel.from_pretrained(base, "cyberandy/sangue-e-grafi-nemotron-nano-sft-v7")
tokenizer = AutoTokenizer.from_pretrained("nvidia/Nemotron-Mini-4B-Instruct")
Note: This is the SFT-only checkpoint. For the full pipeline, merge this adapter first, then apply the GRPO adapter.

Intended Uses & Limitations

Intended uses:

  • โ€”Cross-architecture validation of KG-grounded reasoning
  • โ€”Research on small-model tool-use agents
  • โ€”Comparison with Gemma-based pipeline

Limitations:

  • โ€”Trained only on Italian kinship / inheritance-law scenarios
  • โ€”Requires the full KG agent framework for reported performance
  • โ€”Slightly lower accuracy than Gemma variant on hard tasks

Project Links

ResourceLink
๐Ÿš€ Live DemoHF Space
๐Ÿ“ฆ GitHubcyberandy/sangue-e-grafi
๐Ÿ“„ PaperRLM-on-KG (arXiv:2604.17056)
๐ŸŽฏ GRPO Adaptersangue-e-grafi-nemotron-nano-grpo
๐Ÿ“Š Agent Traces Datasetsangue-e-grafi-agent-traces

Citation

bibtex
@misc{sangue-e-grafi-2026,
  title   = {Sangue e Grafi: Small Models Beat Frontier LLMs on Adversarial Kinship Reasoning with Knowledge Graph Agents},
  author  = {Andrea Volpini},
  year    = {2026},
  url     = {https://github.com/cyberandy/sangue-e-grafi},
  note    = {Hugging Face Build Small Hackathon 2026}
}