Skip to content

[OpenVINO] Support nvidia/NVIDIA-Nemotron-3 Models#1789

Open
openvino-agent wants to merge 1 commit into
huggingface:mainfrom
openvino-agent:nemotron_3
Open

[OpenVINO] Support nvidia/NVIDIA-Nemotron-3 Models#1789
openvino-agent wants to merge 1 commit into
huggingface:mainfrom
openvino-agent:nemotron_3

Conversation

@openvino-agent

Copy link
Copy Markdown
Contributor

What does this PR do?

Install transformers==5.10 on top of optimum-intel installations

optimum-cli export openvino -m nvidia/NVIDIA-Nemotron-3-Nano-4B-BF16 NVIDIA-Nemotron-3-Nano-4B-BF16
from transformers import AutoTokenizer, AutoModelForCausalLM
from optimum.intel.openvino import OVModelForCausalLM

#model_path = "nvidia/NVIDIA-Nemotron-3-Nano-4B-BF16"
model_path = "./NVIDIA-Nemotron-3-Nano-4B-BF16"

tokenizer = AutoTokenizer.from_pretrained(model_path)
model = OVModelForCausalLM.from_pretrained(model_path)

# change input text as desired
input_text = "The capital of France is"
# tokenize the text
input_tokens = tokenizer(input_text, return_tensors="pt")
# generate output tokens
output = model.generate(**input_tokens, max_length=10, do_sample=False)
# decode output tokens into text
output = tokenizer.batch_decode(output)
print(output[0])

Fixes # (issue)

Before submitting

  • This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
  • Did you make sure to update the documentation with your changes?
  • Did you write any new necessary tests?

@regisss

regisss commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Install transformers==5.10 on top of optimum-intel installations

@echarlaix @rkazants Should we wait for Transformers v5.10 support to be added first before merging this one?

@IlyasMoutawwakil IlyasMoutawwakil left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants