返回模型
说明文档
TheBlueObserver/SmolLM2-360M-Instruct-MLX-8777b
该模型 TheBlueObserver/SmolLM2-360M-Instruct-MLX-8777b 是由 HuggingFaceTB/SmolLM2-360M-Instruct 使用 mlx-lm 版本 0.20.2 转换为 MLX 格式的。
使用 mlx
pip install mlx-lm
from mlx_lm import load, generate
model, tokenizer = load("TheBlueObserver/SmolLM2-360M-Instruct-MLX-8777b")
prompt="hello"
if hasattr(tokenizer, "apply_chat_template") and tokenizer.chat_template is not None:
messages = [{"role": "user", "content": prompt}]
prompt = tokenizer.apply_chat_template(
messages, tokenize=False, add_generation_prompt=True
)
response = generate(model, tokenizer, prompt=prompt, verbose=True)
TheBlueObserver/SmolLM2-360M-Instruct-MLX-8777b
作者 TheBlueObserver
text-generation
transformers
↓ 1
♥ 0
创建时间: 2024-12-19 20:34:56+00:00
更新时间: 2024-12-19 20:51:05+00:00
在 Hugging Face 上查看文件 (10)
.gitattributes
README.md
config.json
merges.txt
model.safetensors
model.safetensors.index.json
special_tokens_map.json
tokenizer.json
tokenizer_config.json
vocab.json