File size: 257 Bytes
697cf7a
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
# Use a pipeline as a high-level helper
from transformers import pipeline

pipe = pipeline("text-generation", model="meituan-longcat/LongCat-Flash-Chat", trust_remote_code=True)
messages = [
    {"role": "user", "content": "Who are you?"},
]
pipe(messages)