下载本地模型(.gguf格式)并在ollama中使用记录
·
前情提要:模型ollama安装在windows系统
1:在模型目录下,创建 Modelfile 文件
可以创建一个myModel文件夹,
在 D:\AI\ollama-models\myModel 目录下新建一个文本文档
重命名为 Modelfile(无扩展名)
用记事本打开写入:
FROM ./你的模型名字.gguf
步骤2:把 GGUF 模型文件放到同一目录
确保目录结构如下:
D:\AI\ollama-models\myModel
├── Modelfile (内容: FROM ./model.gguf)
└── model.gguf (你的 GGUF 模型文件)
步骤3:然后在 PowerShell 中运行
cd D:\AI\ollama-models\myModel
ollama create 你的模型名字-gguf -f Modelfile

步骤4:
运行模型(会自动组装 blobs)
ollama run 模型名-gguf
>>> 你是谁
I am a text-based AI assistant that understands natural language and can generate human-like responses to
questions or statements. My knowledge base is derived from my training on large amounts of internet data up until
2021, but I don't have real-time information or the ability to browse the web. I'm here to help answer questions,
explain concepts, engage in conversation, assist with creative writing and more! Let me know what you need
assistance with.
删除模型可使用
先试试这个
ollama rm self-gguf
如果不行,试试这个
ollama rm self.gguf
更多推荐
所有评论(0)