Compare commits

...

6 Commits

Author SHA1 Message Date
祀梦
396d78fb73 docs: 添加 MCP 与 Skills 详解文章,调整模型分类侧边栏结构 2026-03-29 16:08:20 +08:00
祀梦
145f5b8971 chore(scripts): 移除不必要的站点脚本
删除以下未使用的脚本:
- clear-vuepress-cache.mjs
- place-ragflow-guide.mjs
- verify-site.mjs
2026-03-29 13:22:45 +08:00
祀梦
5578a63c1d docs(ai): 添加 RAGFlow MCP 部署文档与 AI 栏目整理
- 新增 Windows 11 RAGFlow + MCP 完整部署记录
- 添加 AI 栏目首页与免费模型 API 文档
- 更新 VuePress 配置与 collections 结构
- 添加缓存清理和文档同步脚本
2026-03-29 13:21:46 +08:00
祀梦
de14950045 feat(blog): 新增 AI 分类目录与中文展示名
- collections 中 BLOG_CATEGORY_LABEL_ZH 增加 ai ->「AI」

- 新增 docs/blog/ai/(.gitkeep 占位,文章以 .md 放入此目录)

已通过 npm run docs:verify

Made-with: Cursor
2026-03-29 10:16:00 +08:00
祀梦
2d5b8c35b8 chore: 移除 LeetCode 笔记并加入站点验证与 Agent 工作流规则
- 从 collections、导航移除 LeetCode,删除 docs/notes/programming/leetcode 下页面

- devDependencies 显式加入 @vuepress/helper@rc.123,配合 overrides 降低 Vite 预构建白屏风险

- 新增 npm run docs:verify 与 scripts/verify-site.mjs(构建后检查首页 hero)

- .cursor/rules/agent-workflow-verify-and-git.mdc:每次修改须验证;用户未明确说不要提交时默认 commit

Made-with: Cursor
2026-03-29 10:05:49 +08:00
祀梦
f50d8ef8c2 chore: 升级 VuePress/Plume 并迁移至 collections 配置
- 将 vuepress 升至 2.0.0-rc.26、vuepress-theme-plume 升至 1.0.0-rc.192

- 用 defineCollections 替代已废弃的 blog + notes,新增 collections.ts 并删除 notes.ts

- 通过 package overrides 将 @vuepress/helper 固定为 rc.123,避免 dev 下 encodeSVG 缺失导致首页白屏

- 新增 .npmrc(legacy-peer-deps)以兼容当前 peer 依赖解析

未包含 docs/.vuepress/dist 等构建产物。

Made-with: Cursor
2026-03-29 10:01:40 +08:00
18 changed files with 5203 additions and 2509 deletions

View File

@@ -0,0 +1,31 @@
---
description: 每次站点相关修改后须本地构建/启动并验证Git 仅在被用户明确要求时提交
alwaysApply: true
---
# Agent 工作流:验证站点与 Git 提交
## 修改后必须自行验证(硬性要求)
凡改动 **VuePress / Plume 配置、`docs/` 下内容与主题相关代码** 等会影响站点展示或 dev/build 的行为时,**在本轮任务结束前必须**完成下列至少一项,并确认 **首页等主要页面非白屏**、**无控制台致命报错**(开发模式下可 F12 查看):
1. **推荐(与线上最接近)**:在项目根执行
`npm run docs:build`
然后执行
`npm run docs:verify`
(会检查 `docs/.vuepress/dist/index.html` 是否包含首页 hero 结构。)
2. **若重点验证热更新 / 开发体验**:执行
`npm run docs:dev-clean`
`--clean-cache --clean-temp` 可避免 **Vite 预构建缓存** 仍指向旧版 `@vuepress/helper`,从而触发 **`encodeSVG` 导出缺失、整站白屏**。)
在浏览器打开本地地址,确认首页 hero 与导航正常。
**白屏常见原因速记**`@vuepress/plugin-markdown-chart` 等依赖需要 `@vuepress/helper/client` 导出 `encodeSVG`;若 `docs/.vuepress/.cache` 里预打包了过旧的 helper会出现 **仅 dev 白屏、build 正常**。处理:执行 **`npm run docs:clear-cache`** 后重启 dev或 **`npm run docs:dev-clean`** / **`npm run docs:build`**(后两者会 clean。项目已在 `config.ts` 的 Vite `optimizeDeps.include` 中强制包含 `@vuepress/helper/client`,以降低复发概率。
## Git 提交策略
- **禁止自作主张提交****仅当用户在本轮对话中明确说出要提交**(例如「提交一下」「帮我 commit」「推到 git」等才执行 `git add` / `git commit` / `git push`。
- **未要求提交时**:改完代码、做完验证即可结束;**不要**替用户 commit。
- **用户若说不要提交**:同样不执行任何 git 写入操作。
**注意**:构建产物目录 **`docs/.vuepress/dist`**、缓存 **`.cache` / `.temp`** 已在 `.gitignore` 中,**不要**将编译输出提交进源码仓。

1
.npmrc Normal file
View File

@@ -0,0 +1 @@
legacy-peer-deps=true

1
Untitled Normal file
View File

@@ -0,0 +1 @@
WINDOWS11_RAGFLOW_DEPLOYMENT_AND_MCP_GUIDE.md

View File

@@ -0,0 +1,272 @@
import { defineCollection, defineCollections } from 'vuepress-theme-plume'
/** 博客目录名 → 中文分类展示 */
const BLOG_CATEGORY_LABEL_ZH: Record<string, string> = {
blog: '博客',
competition: '竞赛',
technology: '技术',
website: '网站',
elysia: '爱莉希雅',
collect: '合集',
ai: 'AI',
}
export default defineCollections([
defineCollection({
type: 'post',
dir: 'blog',
title: '博客',
link: '/blog/',
linkPrefix: '/article/',
postCover: {
layout: 'left',
compact: true,
},
categoriesTransform: (categories) =>
categories.map((c) => ({
...c,
name: BLOG_CATEGORY_LABEL_ZH[c.name] ?? c.name,
})),
}),
defineCollection({
type: 'doc',
dir: 'notes/ai',
title: '模型',
linkPrefix: '/ai/',
sidebar: [
{ text: '模型', link: '/ai/' },
{
text: '基础概念',
collapsed: false,
items: [
{ text: 'MCP 与 Skills 详解', link: '/article/mcp-and-skills/' },
],
},
{
text: '部署与工具链',
collapsed: false,
items: [
{ text: 'RAGFlow 与 MCP', link: '/article/windows11-ragflow-deployment-mcp/' },
],
},
{
text: '模型与 API',
collapsed: false,
items: [{ text: '大模型 API 整合', link: '/article/free_model_api/' }],
},
],
}),
defineCollection({
type: 'doc',
dir: 'notes/subject/english',
title: '英语学习',
linkPrefix: '/subject/english/',
sidebar: [
{ text: '英语学习笔记', link: '/subject/english/' },
{
text: '学习环境与工具',
prefix: '/basis',
items: [{ text: '英语环境配置', link: '/subject/english/basis/' }],
},
{
text: '词汇与记忆',
prefix: '/vocabulary',
items: [{ text: '词汇学习与记忆法', link: '/subject/english/vocabulary/' }],
},
{
text: '语法与句法',
prefix: '/grammar',
items: [{ text: '核心语法与句型', link: '/subject/english/grammar/' }],
},
{
text: '听力与口语',
prefix: '/listening-speaking',
items: [{ text: '听力口语训练', link: '/subject/english/listening-speaking/' }],
},
{
text: '阅读与写作',
prefix: '/reading-writing',
items: [{ text: '阅读提升', link: '/subject/english/reading-writing/' }],
},
{
text: '写译',
prefix: '/writing-translation',
items: [{ text: '写作与翻译指南', link: '/subject/english/writing-translation/' }],
},
{
text: '考试与备考',
prefix: '/exam',
items: [{ text: '英语四级 (CET-4) 备考指南', link: '/subject/english/exam/cet-4/' }],
},
{
text: '资源与工具',
prefix: '/resources',
items: [{ text: '学习资源与工具', link: '/subject/english/resources/' }],
},
],
}),
defineCollection({
type: 'doc',
dir: 'notes/subject/certification',
title: '系统分析师',
linkPrefix: '/subject/certification/',
sidebar: [
{ text: '系统分析师简介', link: '/subject/certification/' },
{
text: '第一篇 基础知识',
prefix: '/certification/sys-analyst',
items: [
{ text: '第一章 绪论', link: '/subject/certification/sys-analyst/' },
{ text: '第二章 数学与工程基础', link: '/subject/certification/sys-analyst/math/' },
],
},
{
text: '第二篇 关键技术',
prefix: '/certification/sys-analyst',
items: [
{ text: '第十章 系统规划与分析', link: '/subject/certification/sys-analyst/planning/' },
],
},
],
}),
defineCollection({
type: 'doc',
dir: 'notes/programming/solidity',
title: 'Solidity',
linkPrefix: '/programming/solidity/',
sidebar: [
{ text: 'Solidity 学习笔记', link: '/programming/solidity/' },
{
text: '基础语法',
prefix: '/basic-syntax',
items: [
{ text: 'Solidity 基础语法与数据类型', link: '/programming/solidity/basic-syntax/' },
],
},
{
text: '项目实例',
prefix: '/basic-syntax',
items: [{ text: 'Solidity 代码实例', link: '/programming/solidity/analysis/case-analysis/' }],
},
{
text: '杂项',
prefix: '/other',
items: [
{ text: 'Hardhat 相关知识', link: '/programming/solidity/other/hardhat/' },
{ text: '一些没分类的小知识', link: '/programming/solidity/other/miscellaneous/' },
],
},
],
}),
defineCollection({
type: 'doc',
dir: 'notes/theory/cryptography',
title: '密码学基础',
linkPrefix: '/theory/cryptography/',
sidebar: [
{ text: '密码学基础', link: '/theory/cryptography/' },
{
text: '古典加密算法',
prefix: '/theory',
items: [
{ text: '替换密码', link: '/theory/cryptography/substitution-ciphers/' },
{ text: '置换密码', link: '/theory/cryptography/permutation-encryption/' },
],
},
],
}),
defineCollection({
type: 'doc',
dir: 'notes/ops/blockchain',
title: '区块链运维',
linkPrefix: '/ops/blockchain/',
sidebar: [
{ text: '区块链运维指南', link: '/ops/blockchain/' },
{
text: '区块链理论基础',
prefix: '/theory',
items: [
{ text: '区块链的基本原理', link: '/ops/blockchain/theory/basic-principles/' },
{ text: 'FISCO-BCOS 节点类型', link: '/ops/blockchain/theory/fisco-bcos-node-type/' },
],
},
{
text: '区块链运维',
items: [
{ text: '区块链产品设计和基本部署', link: '/ops/blockchain/practice/basic-deployment/' },
{ text: '区块链网络部署与管理', link: '/ops/blockchain/practice/node-deployment/' },
{ text: 'Console 控制台操作', link: '/ops/blockchain/practice/console-operator/' },
],
},
],
}),
defineCollection({
type: 'doc',
dir: 'notes/ops/linux',
title: 'Linux 运维',
linkPrefix: '/ops/linux/',
sidebar: [
{ text: 'Linux 运维笔记', link: '/ops/linux/' },
{
text: 'Linux 基础',
prefix: '/linux',
items: [{ text: 'Linux 基础命令详解', link: '/ops/linux/basic-commands/' }],
},
{
text: '其他',
prefix: '/linux',
items: [{ text: '一些零散的命令', link: '/ops/linux/other/' }],
},
],
}),
defineCollection({
type: 'doc',
dir: 'notes/ops/docker',
title: 'Docker',
linkPrefix: '/ops/docker/',
sidebar: [
{ text: 'Docker 运维笔记', link: '/ops/docker/' },
{
text: '数据库相关',
prefix: '/ops/docker/db/',
items: [
{ text: 'MongoDB 部署', link: '/ops/docker/db/mongodb/' },
{ text: 'Postgres 部署', link: '/ops/docker/db/postgres/' },
],
},
{
text: '其他服务',
prefix: '/ops/docker/other/',
items: [{ text: 'ETLCloud 部署', link: '/ops/docker/other/ETLCloud/' }],
},
],
}),
defineCollection({
type: 'doc',
dir: 'notes/programming/web',
title: 'Web 开发',
linkPrefix: '/programming/web/',
sidebar: [
{ text: 'Web 开发学习笔记', link: '/programming/web/' },
{
text: '基础知识',
prefix: '/basic-syntax',
items: [
{ text: 'Web 前端基础讲解', link: '/programming/web/basic-syntax/html-css-js/' },
{ text: 'HTML 常用标签与属性', link: '/programming/web/basic-syntax/html-tags-attributes/' },
{ text: 'HTML 列表与语义布局', link: '/programming/web/basic-syntax/html-lists-and-semantic-layout/' },
{ text: 'JavaScript 基础知识', link: '/programming/web/basic-syntax/javascript-basics/' },
],
},
],
}),
])

View File

@@ -10,16 +10,6 @@ import { fileURLToPath } from 'node:url'
const __filename = fileURLToPath(import.meta.url) const __filename = fileURLToPath(import.meta.url)
const __dirname = path.dirname(__filename) const __dirname = path.dirname(__filename)
/** 博客目录名 → 中文分类展示Plume 从路径自动生成分类,此处仅改展示名) */
const BLOG_CATEGORY_LABEL_ZH: Record<string, string> = {
blog: '博客',
competition: '竞赛',
technology: '技术',
website: '网站',
elysia: '爱莉希雅',
collect: '合集',
}
export default defineUserConfig({ export default defineUserConfig({
base: '/', base: '/',
lang: 'zh-CN', lang: 'zh-CN',
@@ -37,6 +27,13 @@ export default defineUserConfig({
'@theme/Blog/VPPostItem.vue': path.resolve(__dirname, './theme/Blog/VPPostItem.vue'), '@theme/Blog/VPPostItem.vue': path.resolve(__dirname, './theme/Blog/VPPostItem.vue'),
}, },
}, },
/**
* 强制预构建含 encodeSVG 的 client 入口,避免 docs/.vuepress/.cache/deps 里残留旧版
* @vuepress/helper 导致 dev 下「does not provide an export named encodeSVG」整页白屏。
*/
optimizeDeps: {
include: ['@vuepress/helper/client'],
},
}, },
}), }),
shouldPrefetch: false, shouldPrefetch: false,
@@ -44,8 +41,6 @@ export default defineUserConfig({
theme: plumeTheme({ theme: plumeTheme({
/* 站点域名,启动 SEO 优化 */ /* 站点域名,启动 SEO 优化 */
hostname: 'https://www.simengweb.com', hostname: 'https://www.simengweb.com',
/* 博客文章页面链接前缀 */
article: '/article/',
/* 启用数学公式支持和Mermaid图表 */ /* 启用数学公式支持和Mermaid图表 */
markdown: { markdown: {
@@ -66,21 +61,6 @@ export default defineUserConfig({
message: '愿每一份温柔都被世界珍藏 ✨', message: '愿每一份温柔都被世界珍藏 ✨',
copyright: '<a href="https://beian.miit.gov.cn/" target="_blank" aria-label="gongan filing address">沪ICP备2023010022号-1</a>©2025祀梦的个人博客' copyright: '<a href="https://beian.miit.gov.cn/" target="_blank" aria-label="gongan filing address">沪ICP备2023010022号-1</a>©2025祀梦的个人博客'
}, },
/**
* 博客相关配置
*/
blog: {
postCover: {
layout: 'left',
// width: 300,
compact: true
},
categoriesTransform: (categories) =>
categories.map((c) => ({
...c,
name: BLOG_CATEGORY_LABEL_ZH[c.name] ?? c.name,
})),
},
/** /**
* 文章贡献者配置 * 文章贡献者配置

View File

@@ -9,6 +9,10 @@ export default defineNavbarConfig([
text: '博客', text: '博客',
link: '/blog/', link: '/blog/',
}, },
{
text: '模型',
link: '/ai/',
},
{ {
text: '学科知识', text: '学科知识',
items: [ items: [
@@ -25,10 +29,6 @@ export default defineNavbarConfig([
{ {
text: '编程笔记', text: '编程笔记',
items: [ items: [
{
text: 'LeetCode',
link: '/programming/leetcode/',
},
{ {
text: 'Solidity', text: 'Solidity',
link: '/programming/solidity/', link: '/programming/solidity/',

View File

@@ -1,200 +0,0 @@
import { defineNoteConfig, defineNotesConfig } from 'vuepress-theme-plume'
/**
* 配置编程笔记
*/
const LeetCode = defineNoteConfig({
dir: 'programming',
link: '/programming/leetcode/',
sidebar: [
{ text: "LeetCode 指南", link: "/programming/leetcode/" },
{
text: "刷题题单", prefix: "/question_sheet", items: [
{ text: "LeetCode 入门题单~(≧∇≦)ノ", link: "/programming/leetcode/question_sheet/beginner/" }
]
}
]
})
const english = defineNoteConfig({
dir: 'subject',
link: '/subject/english/',
sidebar: [
{ text: "英语学习笔记", link: "/subject/english/" },
{
text: "学习环境与工具", prefix: "/basis", items: [
{ text: "英语环境配置", link: "/subject/english/basis/" }
]
},
{
text: "词汇与记忆", prefix: "/vocabulary", items: [
{ text: "词汇学习与记忆法", link: "/subject/english/vocabulary/" }
]
},
{
text: "语法与句法", prefix: "/grammar", items: [
{ text: "核心语法与句型", link: "/subject/english/grammar/" }
]
},
{
text: "听力与口语", prefix: "/listening-speaking", items: [
{ text: "听力口语训练", link: "/subject/english/listening-speaking/" }
]
},
{
text: "阅读与写作", prefix: "/reading-writing", items: [
{ text: "阅读提升", link: "/subject/english/reading-writing/" }
]
},
{
text: "写译", prefix: "/writing-translation", items: [
{ text: "写作与翻译指南", link: "/subject/english/writing-translation/" }
]
},
{
text: "考试与备考", prefix: "/exam", items: [
{ text: "英语四级 (CET-4) 备考指南", link: "/subject/english/exam/cet-4/" }
]
},
{
text: "资源与工具", prefix: "/resources", items: [
{ text: "学习资源与工具", link: "/subject/english/resources/" }
]
}
]
})
const certification = defineNoteConfig({
dir: 'subject',
link: '/subject/certification/',
sidebar: [
{ text: "系统分析师简介", link: "/subject/certification/" },
{
text: "第一篇 基础知识", prefix: "/certification/sys-analyst", items: [
{ text: "第一章 绪论", link: "/subject/certification/sys-analyst/" },
{ text: "第二章 数学与工程基础", link: "/subject/certification/sys-analyst/math/" }
],
},
{
text: "第二篇 关键技术", prefix: "/certification/sys-analyst", items: [
{ text: "第十章 系统规划与分析", link: "/subject/certification/sys-analyst/planning/" }
],
}
]
})
const solidity = defineNoteConfig({
dir: 'programming',
link: '/programming/solidity/',
sidebar: [
{ text: "Solidity 学习笔记", link: "/programming/solidity/" },
{
text: "基础语法", prefix: "/basic-syntax", items: [
{ text: "Solidity 基础语法与数据类型", link: "/programming/solidity/basic-syntax/" }
],
},
{
text: "项目实例", prefix: "/basic-syntax", items: [
{ text: "Solidity 代码实例", link: "/programming/solidity/analysis/case-analysis/" }
],
},
{
text: "杂项", prefix: "/other", items: [
{ text: "Hardhat 相关知识", link: "/programming/solidity/other/hardhat/" },
{ text: "一些没分类的小知识", link: "/programming/solidity/other/miscellaneous/" }
],
}
]
})
const cryptography = defineNoteConfig({
dir: 'theory',
link: '/theory/cryptography/',
sidebar: [
{ text: "密码学基础", link: "/theory/cryptography/" },
{
text: "古典加密算法", prefix: "/theory", items: [
{ text: "替换密码", link: "/theory/cryptography/substitution-ciphers/" },
{ text: "置换密码", link: "/theory/cryptography/permutation-encryption/" },
]
},
]
})
const blockchain = defineNoteConfig({
dir: 'ops',
link: '/ops/blockchain',
sidebar: [
{ text: "区块链运维指南", link: "/ops/blockchain/" },
{
text: "区块链理论基础", prefix: "/theory", items: [
{ text: "区块链的基本原理", link: "/ops/blockchain/theory/basic-principles/" },
{ text: "FISCO-BCOS 节点类型", link: "/ops/blockchain/theory/fisco-bcos-node-type/" }
]
},
{
text: "区块链运维", items: [
{ text: "区块链产品设计和基本部署", link: "/ops/blockchain/practice/basic-deployment/" },
{ text: "区块链网络部署与管理", link: "/ops/blockchain/practice/node-deployment/" },
{ text: "Console 控制台操作", link: "/ops/blockchain/practice/console-operator/" }
]
}
]
})
const linux = defineNoteConfig({
dir: 'ops',
link: '/ops/',
sidebar: [
{ text: "Linux 运维笔记", link: "/ops/linux/" },
{
text: "Linux 基础", prefix: "/linux", items: [
{ text: "Linux 基础命令详解", link: "/ops/linux/basic-commands/" }
]
},
{
text: "其他", prefix: "/linux", items: [
{ text: "一些零散的命令", link: "/ops/linux/other/" }
]
}
]
})
const docker = defineNoteConfig({
dir: 'ops',
link: '/ops/docker/',
sidebar: [
{ text: "Docker 运维笔记", link: "/ops/docker/" },
{
text: "数据库相关",
prefix: "/ops/docker/db/",
items: [
{ text: "MongoDB 部署", link: "/ops/docker/db/mongodb/" },
{ text: "Postgres 部署", link: "/ops/docker/db/postgres/" },
]
},
{
text: "其他服务",
prefix: "/ops/docker/other/",
items: [
{ text: "ETLCloud 部署", link: "/ops/docker/other/ETLCloud/" },
]
},
]
})
const web = defineNoteConfig({
dir: 'programming',
link: '/programming/web/',
sidebar: [
{ text: "Web 开发学习笔记", link: "/programming/web/" },
{
text: "基础知识", prefix: "/basic-syntax", items: [
{ text: "Web 前端基础讲解", link: "/programming/web/basic-syntax/html-css-js/" },
{ text: "HTML 常用标签与属性", link: "/programming/web/basic-syntax/html-tags-attributes/" },
{ text: "HTML 列表与语义布局", link: "/programming/web/basic-syntax/html-lists-and-semantic-layout/" },
{ text: "JavaScript 基础知识", link: "/programming/web/basic-syntax/javascript-basics/" },
],
},
]
})
/**
* 导出所有的 note
*/
export default defineNotesConfig({
dir: 'notes',
link: '/',
notes: [LeetCode, english, certification, solidity, blockchain, linux, docker, cryptography, web],
})

View File

@@ -1,6 +1,6 @@
import { defineThemeConfig } from 'vuepress-theme-plume' import { defineThemeConfig } from 'vuepress-theme-plume'
import collections from './collections'
import navbar from './navbar' import navbar from './navbar'
import notes from './notes'
export default defineThemeConfig({ export default defineThemeConfig({
logo: '/plume.svg', logo: '/plume.svg',
@@ -21,5 +21,5 @@ export default defineThemeConfig({
}, },
navbar, navbar,
notes, collections,
}) })

0
docs/blog/ai/.gitkeep Normal file
View File

View File

13
docs/notes/ai/README.md Normal file
View File

@@ -0,0 +1,13 @@
---
title: 模型
createTime: 2026/03/29 20:00:00
permalink: /ai/
---
# 模型
这里是我和大模型、RAG、本地部署还有各种工具链打交道的地方
和博客里的随想不同这些笔记会更系统化一些方便以后自己回来查的时候能一把抓到重点。左侧的目录会随着我记的东西越来越多而慢慢展开就像「英语学习」「Web 开发」那些栏目一样,可以按专题慢慢逛。
当然啦,如果只是突然想到什么、想随手记几句碎碎念,还是会丢进 [博客](/blog/) 里,那里更适合发点动态更新的小东西~

View File

@@ -2,13 +2,11 @@
title: 便宜免费的大模型 API 整合 2025年11月11日 title: 便宜免费的大模型 API 整合 2025年11月11日
createTime: 2025/11/11 13:54:02 createTime: 2025/11/11 13:54:02
permalink: /article/free_model_api/ permalink: /article/free_model_api/
tags: sidebar: '/ai/'
- llm
--- ---
百度千帆、讯飞星火、腾讯混元均有免费在线额度SCNet 提供 0.1 元/百万 tokens 的超低价大模型,轻量任务先薅免费,量大了再掏 0.1 元,稳! 百度千帆、讯飞星火、腾讯混元均有免费在线额度SCNet 提供 0.1 元/百万 tokens 的超低价大模型,轻量任务先薅免费,量大了再掏 0.1 元,稳!
<!-- more -->
## 免费的大模型 API 整合 ## 免费的大模型 API 整合
嗨~如果你在找既温柔又省荷包的小模型,就把它们悄悄收进这里吧!它们也许不是夜空最亮的那颗星,却能在摘要、划重点、轻声问答的小角落里,给你软软又稳稳的陪伴哦~ 嗨~如果你在找既温柔又省荷包的小模型,就把它们悄悄收进这里吧!它们也许不是夜空最亮的那颗星,却能在摘要、划重点、轻声问答的小角落里,给你软软又稳稳的陪伴哦~

View File

@@ -0,0 +1,188 @@
---
title: MCP 与 Skills让 AI 助手更懂你的利器
createTime: 2026/03/29 14:00:00
permalink: /article/mcp-and-skills/
sidebar: '/ai/'
---
嗨~今天来聊聊两个让 AI 助手变得更聪明、更贴心的小魔法:**MCP** 和 **Skills** 🪄
它们就像是给 AI 装上了「外挂」和「说明书」,让它不仅能聊天,还能真正帮你干活、调用工具、甚至访问你的本地知识库~
## 一、MCP 是什么?
**MCP** 全称是 **Model Context Protocol**(模型上下文协议),是由 [Anthropic](https://www.anthropic.com/) 提出的一种开放协议。
简单来说,它就像是 AI 和外部世界之间的「通用翻译官」🌐
### 为什么需要 MCP
想象一下:
- 你想让 AI 查一下你的本地数据库
- 你想让 AI 调用某个特定工具
- 你想让 AI 访问你的笔记知识库
以前,每个工具都要写一套单独的对接代码,很麻烦对吧?
MCP 的出现,就是为了让这些「对接」变得标准化——**一次配置,到处可用**。
### MCP 的工作原理
```
┌─────────────┐ ┌─────────────┐ ┌─────────────┐
│ AI 助手 │ ◄──► │ MCP 协议 │ ◄──► │ 外部工具 │
│ (Cursor等) │ │ (标准化) │ │ (数据库/API) │
└─────────────┘ └─────────────┘ └─────────────┘
```
AI 助手通过 MCP 协议,可以:
- 🔍 **检索**Retrieval查询知识库、数据库
- 🛠️ **调用工具**Tools执行特定功能
- 💾 **访问资源**Resources读取文件、配置等
## 二、Skills 是什么?
如果说 MCP 是「通信协议」,那 **Skills** 就是「技能说明书」📖
### Skills 的概念
Skills技能是封装好的、可复用的功能模块。每个 Skill 通常包含:
- **功能描述**:这个技能是干嘛的
- **调用方式**:需要哪些参数、返回什么结果
- **使用示例**:实际怎么调用
### MCP vs Skills 的关系
| 概念 | 比喻 | 作用 |
|------|------|------|
| **MCP** | 电话线/网络协议 📡 | 负责「能连上」 |
| **Skills** | 电话簿/功能菜单 📋 | 负责「知道能做什么」 |
MCP 让 AI 和工具**连得通**Skills 让 AI**知道怎么用**。
## 三、实际应用场景
### 场景 1本地知识库检索 🗃️
就像我在 [RAGFlow 部署文章](../windows11-ragflow-deployment-mcp/) 里写的,通过 MCP 把 RAGFlow 接到 Cursor 里:
```json
// Cursor 的 MCP 配置
{
"mcpServers": {
"RAGFlow": {
"url": "http://127.0.0.1:39382/mcp/"
}
}
}
```
然后 AI 就能:
- 自动检索你的笔记
- 基于本地知识回答问题
- 不用把敏感文件上传到云端
### 场景 2数据库查询 🗄️
配置一个数据库 MCP ServerAI 就能直接帮你:
```
用户:查一下上个月销售额最高的产品
AI【通过 MCP 调用数据库查询工具】
SELECT product_name, SUM(sales)
FROM sales
WHERE date >= '2025-02-01'
GROUP BY product_name
ORDER BY SUM(sales) DESC
LIMIT 1;
结果是:产品 A销售额 ¥123,456
```
### 场景 3文件操作 📁
通过文件系统 MCPAI 可以:
- 读取项目配置文件
- 批量重命名文件
- 生成代码并保存到指定目录
## 四、在 Cursor 中使用
### 配置 MCP Server
以 Cursor 为例,在 `~/.cursor/mcp.json` 中添加:
```json
{
"mcpServers": {
"my-database": {
"url": "http://localhost:3000/mcp"
},
"file-system": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "/path/to/allowed/dir"]
}
}
}
```
### 使用流程
1. **AI 发现技能**启动时AI 会自动获取所有可用的 Skills 列表
2. **意图识别**当你提问时AI 判断是否需要调用工具
3. **参数填充**AI 自动提取所需参数
4. **执行并返回**:调用 MCP Server获取结果后呈现给你
### 交互示例
```
你:帮我总结一下项目里的 API 接口
AI我来帮你分析一下项目中的 API 接口。
【调用 file-system skill 读取项目文件】
【调用检索 skill 查找路由定义】
找到以下接口:
1. GET /api/users - 获取用户列表
2. POST /api/users - 创建用户
3. GET /api/users/:id - 获取单个用户
...
```
## 五、MCP 生态一览
目前 MCP 生态正在快速发展,已有许多现成的 Server 可用:
| 类型 | 代表项目 | 用途 |
|------|---------|------|
| 文件系统 | `@modelcontextprotocol/server-filesystem` | 读写本地文件 |
| 数据库 | `@modelcontextprotocol/server-postgres` | PostgreSQL 查询 |
| GitHub | `@modelcontextprotocol/server-github` | 操作 GitHub |
| 浏览器 | `@browserbasehq/mcp-server-browserbase` | 自动化浏览器操作 |
| 知识库 | RAGFlow MCP | 本地文档检索 |
完整的官方列表可以在 [MCP Servers Repository](https://github.com/modelcontextprotocol/servers) 找到。
## 六、总结
| 要点 | 说明 |
|------|------|
| **MCP** | 让 AI 和工具「说同一种语言」的开放协议 |
| **Skills** | 封装好的功能模块,告诉 AI「我能做什么」 |
| **价值** | 打破信息孤岛,让 AI 真正连接你的数字世界 |
| **前景** | 越来越多的工具会支持 MCP生态会越来越丰富 |
用一句话概括:**MCP 是桥梁Skills 是地图,让 AI 从「聊天伙伴」变成「得力助手」** 🎯
---
> 💡 **延伸阅读**
> - [Windows 11 本地部署 RAGFlow 与 Cursor MCP](./windows11-ragflow-deployment-mcp.md)
> - [MCP 官方文档](https://modelcontextprotocol.io/)
> - [Anthropic MCP 介绍](https://www.anthropic.com/news/model-context-protocol)

File diff suppressed because it is too large Load Diff

View File

@@ -1,40 +0,0 @@
---
title: LeetCode 题解笔记
description: 记录LeetCode算法题的解题思路和代码实现
createTime: 2025/09/22 08:09:52
permalink: /programming/leetcode/
---
# LeetCode 题解笔记
这里是我在LeetCode刷题过程中记录的解题思路和代码实现。通过整理这些题解希望能够提高自己的算法水平和编程能力。
## 题解分类
### 数组与字符串
- [两数之和](https://leetcode-cn.com/problems/two-sum/)
- [三数之和](https://leetcode-cn.com/problems/3sum/)
### 链表
- [反转链表](https://leetcode-cn.com/problems/reverse-linked-list/)
- [合并两个有序链表](https://leetcode-cn.com/problems/merge-two-sorted-lists/)
### 动态规划
- [爬楼梯](https://leetcode-cn.com/problems/climbing-stairs/)
- [最长回文子串](https://leetcode-cn.com/problems/longest-palindromic-substring/)
## 解题技巧
1. **双指针法**:常用于数组、链表问题,如两数之和、反转链表等
2. **滑动窗口**:处理字符串子串问题
3. **动态规划**:将原问题分解为子问题,自底向上求解
4. **分治法**:将问题分成若干子问题,分别求解后合并结果
## 学习资源
- [LeetCode官方题解](https://leetcode-cn.com/problemset/all/)
- [代码随想录](https://programmercarl.com/)
- [算法导论](https://mitpress.mit.edu/books/introduction-algorithms)

View File

@@ -1,13 +0,0 @@
---
title: LeetCode 入门题单~(≧∇≦)ノ
description: 给算法初学者的题目推荐和学习路径
createTime: 2025年9月22日 08:52:52
permalink: /programming/leetcode/question_sheet/beginner/
---
# LeetCode 入门题单~(๑>◡<๑)
作为算法初学者,选择合适的题目开始练习真的超~级重要哦!这里给大家推荐一份超棒的入门题单——[「新」动计划 · 编程入门](https://leetcode.cn/studyplan/primers-list/) ~这份题单就像给小树苗精心准备的阳光和雨露一样,特别适合刚开始算法之旅的你~(悄悄告诉你,里面有两题是数据库基础,暂时可以跳过哦~)
我的小建议是:先自己试着挑战一下,如果遇到困难了,再来看题解也没关系~重要的是享受这个成长的过程呀~(♡˙︶˙♡)
## 基础语法 & 数据类型 ٩(๑>◡<๑)۶

5795
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -7,25 +7,32 @@
"engines": { "engines": {
"node": "^20.6.0 || >=22.0.0" "node": "^20.6.0 || >=22.0.0"
}, },
"overrides": {
"@vuepress/helper": "2.0.0-rc.123"
},
"scripts": { "scripts": {
"docs:dev": "vuepress dev docs", "docs:dev": "vuepress dev docs",
"docs:dev-clean": "vuepress dev docs --clean-cache --clean-temp", "docs:dev-clean": "vuepress dev docs --clean-cache --clean-temp",
"docs:clear-cache": "node scripts/clear-vuepress-cache.mjs",
"docs:build": "vuepress build docs --clean-cache --clean-temp", "docs:build": "vuepress build docs --clean-cache --clean-temp",
"docs:verify": "node scripts/verify-site.mjs",
"docs:place-ragflow-guide": "node scripts/place-ragflow-guide.mjs",
"docs:preview": "http-server docs/.vuepress/dist", "docs:preview": "http-server docs/.vuepress/dist",
"vp-update": "npx vp-update" "vp-update": "npx vp-update"
}, },
"devDependencies": { "devDependencies": {
"@vuepress/bundler-vite": "2.0.0-rc.24", "@vuepress/helper": "2.0.0-rc.123",
"@vuepress/plugin-umami-analytics": "^2.0.0-rc.112", "@vuepress/bundler-vite": "2.0.0-rc.26",
"@vuepress/plugin-umami-analytics": "2.0.0-rc.112",
"artalk": "^2.9.1", "artalk": "^2.9.1",
"http-server": "^14.1.1", "http-server": "^14.1.1",
"typescript": "^5.9.2", "typescript": "^5.9.2",
"vue": "^3.5.21", "vue": "^3.5.21",
"vuepress": "2.0.0-rc.24", "vuepress": "2.0.0-rc.26",
"vuepress-theme-plume": "1.0.0-rc.164" "vuepress-theme-plume": "1.0.0-rc.192"
}, },
"dependencies": { "dependencies": {
"@vuepress/plugin-comment": "^2.0.0-rc.112", "@vuepress/plugin-comment": "2.0.0-rc.123",
"@waline/client": "^3.13.0", "@waline/client": "^3.13.0",
"mermaid": "^11.12.1" "mermaid": "^11.12.1"
} }