# go_ollama_tiny_rag **Repository Path**: misujiatensorflow_admin/go_ollama_tiny_rag ## Basic Information - **Project Name**: go_ollama_tiny_rag - **Description**: Go + Ollama 构建的 RAG 应用 - **Primary Language**: Go - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2025-08-08 - **Last Updated**: 2025-08-08 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # go_ollama_tiny_rag #### 介绍 Go + Ollama 构建的tinyRAG应用, 如何将本地prompt知识库传送到deepseek #### 软件架构 Go+gin+Ollama+deepseek #### 安装教程 1. 下载Ollama, https://ollama.com/ Ollama是一个用于管理和部署机器学习模型的工具。 2. 下载DeepSeek模型 ```bash ollama run deepseek-r1:1.5b ``` 3. 编译Go语言代码并运行 #### 使用说明 1. 创建知识库目录 mkdir knowledge_base 2. 在知识库目录中添加知识文件(.txt格式) echo "人类眼睛的颜色主要由虹膜中的黑色素含量决定。" > knowledge_base/眼睛知识.txt echo "黑色素越多,眼睛颜色越深。" >> knowledge_base/眼睛知识.txt 2. 编辑.env.local 3. 运行程序 go run main.go 4. 测试 ``` bash curl -X POST http://127.0.0.1/hello \ -H "Content-Type: application/json" \ -d '{"search": "眼睛为什么是黑色的"}' ``` #### 参与贡献 1. Fork 本仓库 2. 新建 Feat_xxx 分支 3. 提交代码 4. 新建 Pull Request #### 特技 1. 使用 Readme\_XXX.md 来支持不同的语言,例如 Readme\_en.md, Readme\_zh.md 2. Gitee 官方博客 [blog.gitee.com](https://blog.gitee.com) 3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解 Gitee 上的优秀开源项目 4. [GVP](https://gitee.com/gvp) 全称是 Gitee 最有价值开源项目,是综合评定出的优秀开源项目 5. Gitee 官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help) 6. Gitee 封面人物是一档用来展示 Gitee 会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)