Error using in transformers with this code

#2
by sudhir2016 - opened

Code
pipe = pipeline("text-generation", model="01-ai/Yi-6B-Chat-4bits")
Error
ImportError: cannot import name 'MoeModelOutputWithPast' from 'transformers.modeling_outputs' (/usr/local/lib/python3.10/dist-packages/transformers/modeling_outputs.py)

Hi there! Could you please provide more details on perhaps your configuration or steps to reproduce this error? Thanks!

This code in Google Colab free tier

import torch
from transformers import pipeline

pipe = pipeline("text-generation", model="01-ai/Yi-6B-Chat-4bits")

Your need to confirm your account before you can post a new comment.

Sign up or log in to comment