flowmind 1.4.6 → 1.4.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/docs/guide.md ADDED
@@ -0,0 +1,151 @@
1
+ # FlowMind Detailed Guide
2
+
3
+ This guide is the long-form companion to the npm homepage.
4
+ Use it when you want the fuller product explanation, usage modes, and system model.
5
+
6
+ ## Core Idea
7
+
8
+ FlowMind is designed for repeatable developer operations.
9
+ Instead of rewriting the same instructions, you route work through a skill, run it through configured adapters or MCP-compatible providers, and keep explicit feedback as reusable local state.
10
+
11
+ The shortest model is:
12
+
13
+ 1. Receive a request
14
+ 2. Select a skill
15
+ 3. Execute through adapters or integrations
16
+ 4. Capture explicit feedback
17
+ 5. Reuse that feedback on similar requests later
18
+
19
+ ## Usage Modes
20
+
21
+ ### CLI
22
+
23
+ The default mode is direct CLI usage:
24
+
25
+ ```bash
26
+ flowmind "查询 traceId abc123 的日志"
27
+ flowmind "审查代码质量"
28
+ flowmind process --skill log-audit "查询最近1小时的错误日志"
29
+ ```
30
+
31
+ Use this mode when you want the fastest path with minimal setup.
32
+
33
+ ### Codex-Friendly JSON
34
+
35
+ If another tool needs machine-readable output:
36
+
37
+ ```bash
38
+ flowmind-codex "查询最近1小时的错误日志"
39
+ flowmind-codex --skill log-audit "查询 traceId abc123 的完整链路"
40
+ flowmind process --json "查询日志"
41
+ ```
42
+
43
+ Use this mode for automation, scripts, or CI.
44
+
45
+ ### MCP Client Integration
46
+
47
+ FlowMind can be exposed as an MCP server for tools such as Claude Code, Cursor, Windsurf, or Cline.
48
+ Setup details live in [integration-guide.md](integration-guide.md).
49
+
50
+ ### AI-Enhanced Routing
51
+
52
+ FlowMind can sit in front of model providers and use them for intent understanding, parameter extraction, skill selection, and result summarization.
53
+ That improves handling for more natural or multi-step requests, while still keeping a skill-based execution path.
54
+
55
+ ## How It Works
56
+
57
+ ### 1. Skill Routing
58
+
59
+ Each request is matched to a reusable skill.
60
+ That gives FlowMind a stable execution path instead of relying on a fresh prompt every time.
61
+
62
+ ### 2. Adapter Execution
63
+
64
+ Skills call adapters or providers for the actual work, such as logs, databases, API docs, knowledge bases, or workflow systems.
65
+
66
+ ### 3. Learning From Explicit Feedback
67
+
68
+ FlowMind focuses on explicit learning.
69
+ For example:
70
+
71
+ ```text
72
+ User: "Use a table next time"
73
+ FlowMind: records the preference
74
+ ```
75
+
76
+ On later similar requests, that preference can be reapplied from local learning data.
77
+
78
+ ### 4. Local Reuse
79
+
80
+ The learning layer is meant to reduce repetition, not hide work.
81
+ You can inspect the available skills, control execution explicitly, and keep the system scriptable.
82
+
83
+ ## Architecture Summary
84
+
85
+ FlowMind is organized around four layers:
86
+
87
+ 1. CLI and MCP entrypoints
88
+ 2. Skill routing and execution
89
+ 3. Provider and adapter integrations
90
+ 4. Learning and preference reuse
91
+
92
+ Common component families include:
93
+
94
+ - `logService`
95
+ - `databaseManager`
96
+ - `databaseQuery`
97
+ - `redisMonitor`
98
+ - `apiDoc`
99
+ - `knowledgeBase`
100
+ - `workflow`
101
+ - `report`
102
+
103
+ The practical goal is configuration-based switching instead of rewriting skill logic for each backend.
104
+
105
+ ## Best-Fit Use Cases
106
+
107
+ ### Log and Trace Investigation
108
+
109
+ ```bash
110
+ flowmind "排查线上问题 traceId abc123"
111
+ ```
112
+
113
+ Best when the same investigation pattern happens repeatedly.
114
+
115
+ ### Code Review
116
+
117
+ ```bash
118
+ flowmind "代码审查先检查安全漏洞,再检查代码质量"
119
+ flowmind "审查这个 PR"
120
+ ```
121
+
122
+ Best when the team has a stable review sequence or standards.
123
+
124
+ ### Data Validation
125
+
126
+ ```bash
127
+ flowmind "验证订单数据"
128
+ flowmind "检查金额计算逻辑"
129
+ ```
130
+
131
+ Best when validation repeatedly crosses logs, database state, and business logic.
132
+
133
+ ## When FlowMind Is a Good Fit
134
+
135
+ FlowMind is a strong fit when:
136
+
137
+ - You already have internal tools and want a consistent execution surface
138
+ - You repeat the same categories of investigation or review
139
+ - You want feedback to persist outside chat history
140
+
141
+ FlowMind is a weaker fit when:
142
+
143
+ - You only need a generic chat assistant
144
+ - Every task is one-off and never repeated
145
+ - You expect full autonomous engineering without configured tools or skills
146
+
147
+ ## Where To Go Next
148
+
149
+ - Demo walkthrough: [../demo/DEMO.md](../demo/DEMO.md)
150
+ - Integration setup: [integration-guide.md](integration-guide.md)
151
+ - Release history: [../CHANGELOG.md](../CHANGELOG.md)
@@ -0,0 +1,151 @@
1
+ # FlowMind 详细指南
2
+
3
+ 这份文档是 npm 首页的长说明版本。
4
+ 如果你想看更完整的产品阐述、使用方式和系统模型,就从这里继续。
5
+
6
+ ## 核心思路
7
+
8
+ FlowMind 面向的是可重复出现的开发操作。
9
+ 它不是让你每次都重写一遍指令,而是把工作交给 skill,再通过已配置的 adapter 或 MCP 兼容提供者执行,并把显式反馈沉淀为可复用的本地状态。
10
+
11
+ 最短链路可以概括为:
12
+
13
+ 1. 接收请求
14
+ 2. 选择 skill
15
+ 3. 通过 adapter / integration 执行
16
+ 4. 记录显式反馈
17
+ 5. 在相似请求里复用这些反馈
18
+
19
+ ## 使用方式
20
+
21
+ ### CLI
22
+
23
+ 默认方式就是直接通过命令行使用:
24
+
25
+ ```bash
26
+ flowmind "查询 traceId abc123 的日志"
27
+ flowmind "审查代码质量"
28
+ flowmind process --skill log-audit "查询最近1小时的错误日志"
29
+ ```
30
+
31
+ 如果你想先最快跑通,这是最直接的入口。
32
+
33
+ ### 面向 Codex 的 JSON 输出
34
+
35
+ 如果你的上层工具需要结构化输出:
36
+
37
+ ```bash
38
+ flowmind-codex "查询最近1小时的错误日志"
39
+ flowmind-codex --skill log-audit "查询 traceId abc123 的完整链路"
40
+ flowmind process --json "查询日志"
41
+ ```
42
+
43
+ 这更适合自动化脚本、CI 或工具编排。
44
+
45
+ ### MCP 客户端接入
46
+
47
+ FlowMind 可以作为 MCP Server 暴露给 Claude Code、Cursor、Windsurf、Cline 等工具使用。
48
+ 具体接入步骤见 [integration-guide.md](integration-guide.md)。
49
+
50
+ ### AI 增强路由
51
+
52
+ FlowMind 也可以接在模型前面,利用模型能力做意图理解、参数提取、skill 选择和结果摘要。
53
+ 这样复杂自然语言请求会更顺,但执行路径仍然以 skill 为核心。
54
+
55
+ ## 它是怎么工作的
56
+
57
+ ### 1. Skill 路由
58
+
59
+ 每个请求先匹配到一个可复用 skill。
60
+ 这样执行路径是稳定的,而不是每次都重新组织 prompt。
61
+
62
+ ### 2. Adapter 执行
63
+
64
+ skill 再去调用真正干活的 adapter 或 provider,比如日志、数据库、API 文档、知识库和工作流系统。
65
+
66
+ ### 3. 从显式反馈学习
67
+
68
+ FlowMind 重点学习的是显式反馈。
69
+ 例如:
70
+
71
+ ```text
72
+ 用户:"下次用表格格式"
73
+ FlowMind:记录这条偏好
74
+ ```
75
+
76
+ 之后遇到相似请求时,就可以从本地学习数据里复用。
77
+
78
+ ### 4. 本地复用
79
+
80
+ 这层学习机制的目标是减少重复,而不是隐藏执行过程。
81
+ 你依然可以查看 skill、显式控制执行,并保持流程可脚本化。
82
+
83
+ ## 架构概览
84
+
85
+ FlowMind 可以粗分为四层:
86
+
87
+ 1. CLI / MCP 入口层
88
+ 2. skill 路由与执行层
89
+ 3. provider / adapter 集成层
90
+ 4. 学习与偏好复用层
91
+
92
+ 常见组件族包括:
93
+
94
+ - `logService`
95
+ - `databaseManager`
96
+ - `databaseQuery`
97
+ - `redisMonitor`
98
+ - `apiDoc`
99
+ - `knowledgeBase`
100
+ - `workflow`
101
+ - `report`
102
+
103
+ 它的实际目标是通过配置切换后端,而不是为了换一个后端就重写 skill 逻辑。
104
+
105
+ ## 最适合的场景
106
+
107
+ ### 日志与链路排查
108
+
109
+ ```bash
110
+ flowmind "排查线上问题 traceId abc123"
111
+ ```
112
+
113
+ 适合那类经常重复出现、步骤相对稳定的问题排查。
114
+
115
+ ### 代码审查
116
+
117
+ ```bash
118
+ flowmind "代码审查先检查安全漏洞,再检查代码质量"
119
+ flowmind "审查这个 PR"
120
+ ```
121
+
122
+ 适合团队已经有固定审查顺序或标准的情况。
123
+
124
+ ### 数据校验
125
+
126
+ ```bash
127
+ flowmind "验证订单数据"
128
+ flowmind "检查金额计算逻辑"
129
+ ```
130
+
131
+ 适合日志、数据库状态和业务逻辑需要反复联合验证的场景。
132
+
133
+ ## 什么情况下值得用
134
+
135
+ 如果满足下面几条,FlowMind 通常比较合适:
136
+
137
+ - 你已经有内部工具,只是缺一个稳定的执行入口
138
+ - 某几类排查、审查、校验任务会反复出现
139
+ - 你希望反馈能脱离聊天记录,变成可复用状态
140
+
141
+ 如果是下面这些情况,FlowMind 反而不是最优解:
142
+
143
+ - 你只需要一个通用聊天助手
144
+ - 每个任务都是一次性的,从不重复
145
+ - 你期待在没有任何配置和技能的前提下完全自治式开发
146
+
147
+ ## 下一步看哪里
148
+
149
+ - 终端演示: [../demo/DEMO_CN.md](../demo/DEMO_CN.md)
150
+ - 集成接入: [integration-guide.md](integration-guide.md)
151
+ - 版本更新: [../CHANGELOG.md](../CHANGELOG.md)
@@ -0,0 +1,424 @@
1
+ # FlowMind 集成指南
2
+
3
+ ## 把 FlowMind 作为 Agent/Skill 安装到 AI CLI 工具
4
+
5
+ ---
6
+
7
+ ## 目录
8
+
9
+ - [Claude Code 集成](#claude-code-集成)
10
+ - [Cursor 集成](#cursor-集成)
11
+ - [Windsurf 集成](#windsurf-集成)
12
+ - [Cline 集成](#cline-集成)
13
+ - [Codex 集成](#codex-集成)
14
+ - [通用 MCP 客户端](#通用-mcp-客户端)
15
+
16
+ ---
17
+
18
+ ## Claude Code 集成
19
+
20
+ ### 方式 1:作为 MCP Server(推荐)
21
+
22
+ 这是最完整的集成方式,让 Claude Code 可以直接调用 FlowMind 的所有技能。
23
+
24
+ #### 步骤 1:安装 FlowMind
25
+
26
+ ```bash
27
+ npm install -g flowmind
28
+ ```
29
+
30
+ #### 步骤 2:配置 MCP Server
31
+
32
+ 在项目根目录创建或编辑 `.claude/settings.local.json`:
33
+
34
+ ```json
35
+ {
36
+ "mcpServers": {
37
+ "flowmind": {
38
+ "command": "flowmind-mcp",
39
+ "args": [],
40
+ "env": {
41
+ "OPENAI_API_KEY": "${OPENAI_API_KEY}"
42
+ }
43
+ }
44
+ }
45
+ }
46
+ ```
47
+
48
+ #### 步骤 3:重启 Claude Code
49
+
50
+ 配置完成后,重启 Claude Code 即可生效。
51
+
52
+ #### 步骤 4:使用
53
+
54
+ 在 Claude Code 中直接使用自然语言:
55
+
56
+ ```
57
+ 你:帮我查询最近1小时的错误日志
58
+ Claude:我来调用 FlowMind 帮你查询...
59
+
60
+ 你:审查一下这个项目的代码质量
61
+ Claude:我来使用 FlowMind 的代码审查技能...
62
+ ```
63
+
64
+ ### 方式 2:作为 Slash Command(技能)
65
+
66
+ 把 FlowMind 的技能注册为 Claude Code 的 Slash Command。
67
+
68
+ #### 步骤 1:创建技能目录
69
+
70
+ ```bash
71
+ mkdir -p ~/.claude/skills
72
+ ```
73
+
74
+ #### 步骤 2:创建 FlowMind 技能文件
75
+
76
+ 创建 `~/.claude/skills/flowmind.md`:
77
+
78
+ ```markdown
79
+ ---
80
+ name: flowmind
81
+ description: FlowMind - AI Agent for development workflows
82
+ ---
83
+
84
+ # FlowMind Agent
85
+
86
+ FlowMind is an intelligent development workflow automation agent.
87
+
88
+ ## Available Skills
89
+
90
+ ### Log Audit
91
+ - Trigger: "日志", "traceId", "排查"
92
+ - Usage: `flowmind "查询 traceId abc123 的日志"`
93
+
94
+ ### Code Review
95
+ - Trigger: "代码审查", "review", "PR"
96
+ - Usage: `flowmind "审查代码质量"`
97
+
98
+ ### Data Validation
99
+ - Trigger: "数据验证", "逻辑检查"
100
+ - Usage: `flowmind "验证订单数据"`
101
+
102
+ ## How to Use
103
+
104
+ When the user asks about:
105
+ 1. Log analysis or debugging → Use flowmind log-audit skill
106
+ 2. Code review or quality check → Use flowmind code-review skill
107
+ 3. Data validation → Use flowmind data-validation skill
108
+ 4. API documentation → Use flowmind api-sync skill
109
+
110
+ Execute: `flowmind "user's request"`
111
+ ```
112
+
113
+ #### 步骤 3:使用
114
+
115
+ 在 Claude Code 中输入 `/flowmind` 即可调用。
116
+
117
+ ### 方式 3:作为 Tool(工具)
118
+
119
+ 在 Claude Code 的 `settings.json` 中注册 FlowMind 为自定义工具。
120
+
121
+ ```json
122
+ {
123
+ "tools": {
124
+ "flowmind": {
125
+ "command": "flowmind",
126
+ "args": ["process", "--json", "{{input}}"],
127
+ "description": "FlowMind AI Agent for development workflows"
128
+ }
129
+ }
130
+ }
131
+ ```
132
+
133
+ ---
134
+
135
+ ## Cursor 集成
136
+
137
+ Cursor 支持 MCP 协议,可以像 Claude Code 一样集成 FlowMind。
138
+
139
+ ### 步骤 1:配置 MCP Server
140
+
141
+ 在 Cursor 的设置中,找到 MCP Server 配置,添加:
142
+
143
+ ```json
144
+ {
145
+ "flowmind": {
146
+ "command": "flowmind-mcp",
147
+ "args": []
148
+ }
149
+ }
150
+ ```
151
+
152
+ ### 步骤 2:使用
153
+
154
+ 在 Cursor 的 AI 对话中直接使用:
155
+
156
+ ```
157
+ @flowmind 查询最近1小时的错误日志
158
+ @flowmind 审查代码质量
159
+ ```
160
+
161
+ ---
162
+
163
+ ## Windsurf 集成
164
+
165
+ Windsurf 是 Codeium 的 AI IDE,支持 MCP 协议。
166
+
167
+ ### 步骤 1:配置 MCP Server
168
+
169
+ 在 Windsurf 的设置中,找到 MCP 配置,添加:
170
+
171
+ ```json
172
+ {
173
+ "mcpServers": {
174
+ "flowmind": {
175
+ "command": "flowmind-mcp",
176
+ "args": []
177
+ }
178
+ }
179
+ }
180
+ ```
181
+
182
+ ### 步骤 2:使用
183
+
184
+ 在 Windsurf 的 AI 聊天中使用 FlowMind。
185
+
186
+ ---
187
+
188
+ ## Cline 集成
189
+
190
+ Cline 是 VS Code 的 AI 编程助手,支持 MCP 协议。
191
+
192
+ ### 步骤 1:安装 Cline
193
+
194
+ 在 VS Code 中安装 Cline 扩展。
195
+
196
+ ### 步骤 2:配置 MCP Server
197
+
198
+ 在 Cline 的设置中,找到 MCP Servers 配置,添加:
199
+
200
+ ```json
201
+ {
202
+ "flowmind": {
203
+ "command": "flowmind-mcp",
204
+ "args": []
205
+ }
206
+ }
207
+ ```
208
+
209
+ ### 步骤 3:使用
210
+
211
+ 在 Cline 的聊天中直接使用 FlowMind。
212
+
213
+ ---
214
+
215
+ ## Codex 集成
216
+
217
+ Codex 是 OpenAI 的 CLI 工具,通过 JSON 输出集成 FlowMind。
218
+
219
+ ### 方式 1:使用 `flowmind-codex`(推荐)
220
+
221
+ 安装后直接使用专门的 Codex 包装命令:
222
+
223
+ ```bash
224
+ # 处理请求
225
+ flowmind-codex "查询最近1小时的错误日志"
226
+
227
+ # 强制指定技能
228
+ flowmind-codex --skill log-audit "查询 traceId abc123 的完整链路"
229
+
230
+ # 列出技能
231
+ flowmind-codex skills
232
+
233
+ # 查看单个技能
234
+ flowmind-codex skill log-audit
235
+
236
+ # 健康检查
237
+ flowmind-codex doctor
238
+ ```
239
+
240
+ 这个命令固定输出 JSON,适合 Codex、脚本和 CI 直接消费。
241
+ 默认会把配置、缓存和学习数据写到当前工作区的 `.flowmind-codex/`。
242
+ 如需改路径,可设置 `FLOWMIND_CODEX_HOME=/your/path`。
243
+
244
+ ### 方式 2:直接调用 `flowmind --json`
245
+
246
+ ```bash
247
+ # 获取技能列表
248
+ flowmind skills --json
249
+
250
+ # 执行任务
251
+ flowmind process --json "查询日志"
252
+ ```
253
+
254
+ ### 方式 3:创建 Wrapper 脚本
255
+
256
+ 创建 `flowmind-codex.sh`:
257
+
258
+ ```bash
259
+ #!/bin/bash
260
+ # FlowMind Codex Integration Wrapper
261
+
262
+ INPUT="$1"
263
+ RESULT=$(flowmind process --json "$INPUT")
264
+
265
+ # 提取结果
266
+ echo "$RESULT" | jq -r '.data // .message // .error'
267
+ ```
268
+
269
+ ### 方式 4:Python 集成
270
+
271
+ ```python
272
+ import subprocess
273
+ import json
274
+
275
+ class FlowMindAgent:
276
+ def __init__(self):
277
+ self.name = "flowmind"
278
+
279
+ def run(self, query: str) -> dict:
280
+ result = subprocess.run(
281
+ ['flowmind', 'process', '--json', query],
282
+ capture_output=True,
283
+ text=True
284
+ )
285
+ return json.loads(result.stdout)
286
+
287
+ def list_skills(self) -> list:
288
+ result = subprocess.run(
289
+ ['flowmind', 'skills', '--json'],
290
+ capture_output=True,
291
+ text=True
292
+ )
293
+ return json.loads(result.stdout)['skills']
294
+
295
+ # 使用
296
+ agent = FlowMindAgent()
297
+ result = agent.run("查询 traceId abc123 的日志")
298
+ print(result)
299
+ ```
300
+
301
+ ---
302
+
303
+ ## 通用 MCP 客户端
304
+
305
+ 任何支持 MCP 协议的客户端都可以集成 FlowMind。
306
+
307
+ ### MCP Server 配置
308
+
309
+ ```json
310
+ {
311
+ "name": "flowmind",
312
+ "transport": {
313
+ "type": "stdio",
314
+ "command": "flowmind-mcp",
315
+ "args": []
316
+ }
317
+ }
318
+ ```
319
+
320
+ ### MCP 工具列表
321
+
322
+ | 工具名称 | 描述 | 参数 |
323
+ |---------|------|------|
324
+ | `flowmind_process` | 处理请求 | `{input: string, context?: object}` |
325
+ | `flowmind_list_skills` | 列出技能 | `{}` |
326
+ | `flowmind_get_skill` | 技能详情 | `{name: string}` |
327
+ | `flowmind_ai_status` | AI 状态 | `{}` |
328
+ | `flowmind_learning_stats` | 学习统计 | `{}` |
329
+ | `flowmind_skill_<name>` | 执行技能 | `{input: string, context?: object}` |
330
+
331
+ ---
332
+
333
+ ## 集成架构图
334
+
335
+ ```
336
+ ┌─────────────────────────────────────────────────────────────┐
337
+ │ AI CLI 工具 │
338
+ │ (Claude Code / Cursor / Windsurf / Cline) │
339
+ └───────────────────────────┬─────────────────────────────────┘
340
+
341
+ │ MCP Protocol
342
+
343
+ ┌───────────────────────────v─────────────────────────────────┐
344
+ │ FlowMind MCP Server │
345
+ │ (mcp/server.js) │
346
+ ├─────────────────────────────────────────────────────────────┤
347
+ │ ┌─────────────┐ ┌─────────────┐ ┌─────────────┐ │
348
+ │ │ Intent │ │ Skill │ │ Learning │ │
349
+ │ │ Understanding│ │ Selection │ │ Engine │ │
350
+ │ └─────────────┘ └─────────────┘ └─────────────┘ │
351
+ ├─────────────────────────────────────────────────────────────┤
352
+ │ ┌─────────────────────────────────────────────────────┐ │
353
+ │ │ FlowMind Skills │ │
354
+ │ │ log-audit │ code-review │ data-validation │ ... │ │
355
+ │ └─────────────────────────────────────────────────────┘ │
356
+ ├─────────────────────────────────────────────────────────────┤
357
+ │ ┌─────────────────────────────────────────────────────┐ │
358
+ │ │ External Services (MCP) │ │
359
+ │ │ SLS │ DMS │ Redis │ YApi │ Yuque │ Friday │ ... │ │
360
+ │ └─────────────────────────────────────────────────────┘ │
361
+ └─────────────────────────────────────────────────────────────┘
362
+ ```
363
+
364
+ ---
365
+
366
+ ## 常见问题
367
+
368
+ ### Q1: Claude Code 无法识别 FlowMind MCP Server?
369
+
370
+ 1. 检查 `.claude/settings.local.json` 配置是否正确
371
+ 2. 确认 `flowmind-mcp` 命令可用:`which flowmind-mcp`
372
+ 3. 重启 Claude Code
373
+
374
+ ### Q2: 如何让 FlowMind 在所有项目中可用?
375
+
376
+ 在用户级别配置 MCP Server:
377
+
378
+ ```bash
379
+ # 编辑全局配置
380
+ vim ~/.claude/settings.json
381
+ ```
382
+
383
+ 添加:
384
+ ```json
385
+ {
386
+ "mcpServers": {
387
+ "flowmind": {
388
+ "command": "flowmind-mcp",
389
+ "args": []
390
+ }
391
+ }
392
+ }
393
+ ```
394
+
395
+ ### Q3: 如何同时使用多个 AI CLI 工具?
396
+
397
+ FlowMind 支持同时被多个客户端调用,学习数据会自动同步。
398
+
399
+ ### Q4: 如何自定义 FlowMind 技能?
400
+
401
+ 1. 在 `skills/` 目录创建新技能
402
+ 2. 创建 `SKILL.md` 定义触发词
403
+ 3. 创建 `index.js` 实现逻辑
404
+ 4. 重启 MCP Server
405
+
406
+ ---
407
+
408
+ ## 快速开始
409
+
410
+ ```bash
411
+ # 1. 安装 FlowMind
412
+ npm install -g flowmind
413
+
414
+ # 2. 初始化
415
+ flowmind init --ai openai
416
+
417
+ # 3. 配置 Claude Code
418
+ echo '{"mcpServers":{"flowmind":{"command":"flowmind-mcp"}}}' > .claude/settings.local.json
419
+
420
+ # 4. 重启 Claude Code
421
+
422
+ # 5. 使用
423
+ # 在 Claude Code 中直接说:帮我查询日志
424
+ ```