Instructions to use nvidia-umd/avf-instruct-615-hf with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use nvidia-umd/avf-instruct-615-hf with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="nvidia-umd/avf-instruct-615-hf") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoModelForSeq2SeqLM model = AutoModelForSeq2SeqLM.from_pretrained("nvidia-umd/avf-instruct-615-hf", dtype="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use nvidia-umd/avf-instruct-615-hf with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "nvidia-umd/avf-instruct-615-hf" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "nvidia-umd/avf-instruct-615-hf", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/nvidia-umd/avf-instruct-615-hf
- SGLang
How to use nvidia-umd/avf-instruct-615-hf with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "nvidia-umd/avf-instruct-615-hf" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "nvidia-umd/avf-instruct-615-hf", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "nvidia-umd/avf-instruct-615-hf" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "nvidia-umd/avf-instruct-615-hf", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use nvidia-umd/avf-instruct-615-hf with Docker Model Runner:
docker model run hf.co/nvidia-umd/avf-instruct-615-hf
| { | |
| "audio_chunk_length": 600, | |
| "audio_hop_length": 160, | |
| "audio_sampling_rate": 16000, | |
| "feature_extractor": { | |
| "chunk_length": 600, | |
| "dither": 0.0, | |
| "feature_extractor_type": "WhisperFeatureExtractor", | |
| "feature_size": 128, | |
| "hop_length": 160, | |
| "n_fft": 400, | |
| "n_samples": 9600000, | |
| "nb_max_frames": 60000, | |
| "padding_side": "right", | |
| "padding_value": 0.0, | |
| "return_attention_mask": true, | |
| "sampling_rate": 16000 | |
| }, | |
| "image_aspect_ratio": "dynamic_s2", | |
| "image_processor": { | |
| "do_convert_rgb": null, | |
| "do_normalize": true, | |
| "do_rescale": true, | |
| "do_resize": true, | |
| "image_mean": [ | |
| 0.5, | |
| 0.5, | |
| 0.5 | |
| ], | |
| "image_processor_type": "SiglipImageProcessor", | |
| "image_std": [ | |
| 0.5, | |
| 0.5, | |
| 0.5 | |
| ], | |
| "resample": 3, | |
| "rescale_factor": 0.00392156862745098, | |
| "size": { | |
| "height": 448, | |
| "width": 448 | |
| } | |
| }, | |
| "interleaved_video_segment_duration": 30, | |
| "interleaved_vis_aud_in_video": true, | |
| "load_audio_in_video": true, | |
| "max_tiles": 12, | |
| "mm_use_bos_eos_tokens": true, | |
| "num_video_frames": 128, | |
| "padding_side": "left", | |
| "processor_class": "AudioVisualFlamingoProcessor", | |
| "s2_scales": [ | |
| 448, | |
| 896, | |
| 1344 | |
| ] | |
| } | |