SuperAPI AI 工具集

mistral-codestral

智能体与模型

查看项目

更新于 10-16 05:48

技能介绍

用途:在自有硬件上本地运行 Mistral AI 的开源大模型,覆盖前沿推理、通用任务与代码生成,并通过 fleet 路由器把每个 Mistral 请求分配到最合适的设备。

主要模型:Codestral(22B,Ollama 名 codestral,代码专用,支持 80 多种语言与 fill-in-the-middle);Mistral Large(123B,mistral-large,前沿推理与多语言);Mistral-Nemo(12B,mistral-nemo,高效通用);Mistral-Small(22B,mistral-small,快速推理);Mistral 7B(7B,mistral:7b,轻量)。

使用方式: 安装与启动: pip install ollama-herd herd herd-node 在每台设备运行 herd-node,Mistral 请求会自动路由。兼容 OpenAI 风格接口,示例连接: from openai import OpenAI mistral_fleet = OpenAI(base_url="http://localhost:11435/v1", api_key="not-needed") 调用时 model 填 codestral、mistral-large、mistral-nemo 等。也可用 curl 访问 http://localhost:11435 的 /v1/chat/completions 与 /api/chat。

硬件参考:mistral:7b 最低 8GB 内存;mistral-nemo 10GB;codestral 与 mistral-small 16GB;mistral-large 80GB。示例配置跨平台,任何内存相当的 Mac、Linux、Windows 设备均可,路由器支持全平台。

监控:通过 /api/ps 查看已加载模型,/fleet/status 查看集群概览,/dashboard/api/models 查看性能统计,仪表盘位于 http://localhost:11435/dashboard。

同端点还提供其他能力:其他 LLM(Llama 3.3、Qwen 3.5、DeepSeek-V3、Phi 4、Gemma 3)、图像生成 /api/generate-image、语音转写 /api/transcribe、嵌入 /api/embed。

限制:安装时不自动下载任何 Mistral 模型,所有拉取均需用户主动发起;模型体积从 4GB 到 70GB+,下载与删除均需显式确认;不得删除或修改 ~/.fleet-manager/ 中的文件。项目为 MIT 开源。官方文档、Agent Setup Guide 与 API Reference 的具体内容暂未提供。