Views
No views yet
| Property | Value |
|---|---|
| Parameters | 1.27B |
| Hidden dim | 2048 |
| Layers | 24 (12 Full + 12 MoD) |
| Attention heads | 16 (GQA, 8 KV) |
| Context length | 2048 tokens (YaRN stretchable) |
| Pretraining Tokens | ~4.00B |
| Training Phase | 2 (Supervised Fine-Tuning) |
| Dtype | bfloat16 |
pipeline or AutoModelForCausalLM APIs without any custom generation loops. The generation_config.json handles all the sampler defaults for you.1import torch
2from transformers import pipeline
3
4pipe = pipeline(
5 "text-generation",
6 model="Smilyai-labs/Nova-1-Standard",
7 torch_dtype=torch.bfloat16,
8 device_map="auto",
9 trust_remote_code=True
10)
11
12messages = [
13 {"role": "system", "content": "You are Nova, a helpful, honest AI assistant."},
14 {"role": "user", "content": "Write a Python function to check if a number is prime."}
15]
16
17# The pipeline automatically applies ChatML and uses the correct sampler defaults!
18response = pipe(messages, max_new_tokens=256)
19print(response[0]['generated_text'][-1]['content'])1import torch
2from transformers import AutoModelForCausalLM, AutoTokenizer
3
4model_id = "Smilyai-labs/Nova-1-Standard"
5
6tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
7model = AutoModelForCausalLM.from_pretrained(
8 model_id,
9 trust_remote_code=True,
10 torch_dtype=torch.bfloat16,
11 device_map="auto",
12)
13
14messages = [
15 {"role": "system", "content": "You are Nova, a helpful, honest AI assistant."},
16 {"role": "user", "content": "Explain recursion like I'm five."}
17]
18
19# Apply ChatML template
20inputs = tokenizer.apply_chat_template(
21 messages,
22 add_generation_prompt=True,
23 return_tensors="pt"
24).to(model.device)
25
26# Generate (uses repo generation_config defaults)
27outputs = model.generate(inputs, max_new_tokens=256)
28print(tokenizer.decode(outputs[0][inputs.shape[1]:], skip_special_tokens=True))⚠️ Note on Inference: This model's architecture intentionally disables HuggingFace's KV Cache (use_cache=False) to ensure maximum context retention. Theprepare_inputs_for_generationmethod automatically handles passing the full context window on each step. Just don't manually passuse_cache=Trueor it will throw a warning and force it back toFalse.
<|im_start|>, <|im_end|> — Chat format markers<|code_start|>, <|code_end|> — Code boundaries<|math_start|>, <|math_end|> — Math content<|domain_code|>, <|domain_math|>, <|domain_general|> — Domain context indicators (used in pretraining, though Phase 2 SFT primarily relies on pure ChatML)1@software{nova1,
2 author = {Smilyai Labs},
3 title = {Nova-1: Mixture-of-Depths Language Model},
4 year = {2024},
5 url = {https://huggingface.co/Smilyai-labs/Nova-1-Standard}
6}