文本嵌入推理文档

在本地使用 Metal 运行 TEI

Hugging Face's logo
加入 Hugging Face 社区

并获得增强的文档体验

开始使用

在本地使用 Metal 运行 TEI

您可以本地安装 text-embeddings-inference,以便在您自己的支持 Metal 的 Mac 上运行它。以下是分步安装说明。

步骤 1: 安装 Rust

在您的机器上安装 Rust,在您的终端中运行以下命令,然后按照说明操作

curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

步骤 2: 安装 Metal 支持

cargo install --path router -F metal

步骤 3: 启动文本嵌入推理

安装成功完成后,您可以使用以下命令启动支持 Metal 的文本嵌入推理

model=Qwen/Qwen3-Embedding-0.6B

text-embeddings-router --model-id $model --port 8080

现在您已经准备好在您的机器上本地使用 text-embeddings-inference 了。

< > 在 GitHub 上更新