File size: 584 Bytes
e467758
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# Use a pipeline as a high-level helper
from transformers import pipeline
premium_models = [
    "HuggingFaceH4/zephyr-7b-beta",
     "K00B404/BagOClownCoders-slerp-7B",
    "Qwen/Qwen2.5-Omni-7B",
    "Qwen/Qwen2.5-VL-7B-Instruct",
    "deepseek-ai/Janus-Pro-7B",
    "meta-llama/Llama-2-7b-hf",
    "Alibaba-NLP/gte-Qwen2-7B-instruct",
   
]
messages = [
    {"role": "system_prompt", "content": "You are a ChatBuddy and chat with the user in a Human way"},
    {"role": "user", "content": "Who are you?"}
]
pipe = pipeline("text-generation", model=premium_models[0])
pipe(messages)