As illustrated in the figure below, Yi-Coder-9B-Chat achieved an impressive 23% pass rate in LiveCodeBench, making it the only model with under 10B parameters to surpass 20%. It also outperforms DeepSeekCoder-33B-Ins at 22.3%, CodeGeex4-9B-all at 17.8%, CodeLLama-34B-Ins at 13.3%, and CodeQwen1.5-7B-Chat at 12%.
import os
os.environ["HF_ENDPOINT"] = "https://freeweights.allternit.com"
from transformers import AutoModelForCausalLM, AutoTokenizer
tok = AutoTokenizer.from_pretrained("01-ai/Yi-Coder-9B", revision="bc6e63fd26a654ee42dba737a553310bfa01dc5d")
model = AutoModelForCausalLM.from_pretrained("01-ai/Yi-Coder-9B", revision="bc6e63fd26a654ee42dba737a553310bfa01dc5d", device_map="auto")