mistral

| 选择喜欢的代码风格  

mistral 参数量


tools 7.25b
 

mistral 模型介绍



Mistral AI

Mistral AI 是一家总部位于法国巴黎的人工智能公司,成立于 2023 年,由前 Google DeepMind 和 Meta 的研究人员创立。该公司专注于开发开源和商业大型语言模型(LLMs),致力于提供高效、可定制且可访问的前沿 AI 技术。

Mistral AI 是一个 7B 参数模型,使用 Apache 许可证分发。它可用于指令(指令跟踪)和文本完成。

 

mistral 应用场景


Mistral AI 的模型适用于多种场景,包括但不限于:

  • 虚拟助手:提供快速响应的对话式帮助
  • 多语言翻译:支持多种语言的翻译任务
  • 多模态任务:如图像理解、文档验证、视觉检查等
  • 企业级应用:如代码生成、数据整合等

 

mistral 优势


Mistral AI 的模型适用于多种场景,包括但不限于:

  • 创新技术:Mistral AI 在模型架构和训练策略上进行了多项创新,如多头潜在注意力机制、混合专家架构等。
  • 开源贡献:作为全球开源 AI 和 AI 政策的最强贡献者之一,Mistral AI 推动了 AI 技术的开放合作。
  • 绿色 AI:Mistral AI 被称为世界上最环保的独立 AI 实验室

 

对 Mistral 7B 进行微调以方便聊天


Mistral AI 团队指出,Mistral 7B:

为了展示 Mistral 7B 的泛化能力,我们根据 HuggingFace 上公开的指令数据集对其进行了微调。没有技巧,没有专有数据。最终的模型 Mistral 7B Instruct 优于 MT-Bench 上的所有 7B 模型,并且可与 13B 聊天模型相媲美。

  • 在所有基准测试中均优于 Llama 2 13B
  • 在许多基准测试中均优于 Llama 1 34B
  • 在代码方面接近 CodeLlama 7B 的性能,同时在英语任务中仍然表现出色

 

Mistral AI Function calling


Mistral 0.3 支持使用 Ollama 的原始模式进行函数调用。

Example raw prompt

[AVAILABLE_TOOLS] [{"type": "function", "function": {"name": "get_current_weather", "description": "Get the current weather", "parameters": {"type": "object", "properties": {"location": {"type": "string", "description": "The city and state, e.g. San Francisco, CA"}, "format": {"type": "string", "enum": ["celsius", "fahrenheit"], "description": "The temperature unit to use. Infer this from the users location."}}, "required": ["location", "format"]}}}][/AVAILABLE_TOOLS][INST] What is the weather like today in San Francisco [/INST]

Example response

[TOOL_CALLS] [{"name": "get_current_weather", "arguments": {"location": "San Francisco, CA", "format": "celsius"}}]
 

Mistral AI API - Ollama


curl -X POST http://localhost:11434/api/generate -d '{
  "model": "mistral",
  "prompt":"Here is a story about llamas eating grass"
 }'
 

AI 扩展阅读:




发表评论