chat-heimerdinger 0.1.2 → 0.1.3
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/README.md +40 -13
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -4,6 +4,40 @@
|
|
|
4
4
|
|
|
5
5
|
Slack 与 Claude Code 的桥接工具,让你在 Slack 中直接与 Claude Code 进行对话式编程。
|
|
6
6
|
|
|
7
|
+
## 前置准备
|
|
8
|
+
|
|
9
|
+
在使用 Chat Heimerdinger 之前,请确保满足以下条件:
|
|
10
|
+
|
|
11
|
+
### 1. Node.js 环境
|
|
12
|
+
|
|
13
|
+
需要 Node.js 18.0.0 或更高版本:
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
node -v # 确认版本 >= 18.0.0
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
### 2. 安装 Claude Code
|
|
20
|
+
|
|
21
|
+
确保本机已安装并配置好 [Claude Code](https://docs.anthropic.com/en/docs/claude-code):
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
# 安装 Claude Code
|
|
25
|
+
npm install -g @anthropic-ai/claude-code
|
|
26
|
+
|
|
27
|
+
# 验证安装
|
|
28
|
+
claude --version
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
### 3. 创建 Slack Bot
|
|
32
|
+
|
|
33
|
+
1. 访问 [Slack API](https://api.slack.com/apps) 创建新应用
|
|
34
|
+
2. 选择 **From an app manifest**
|
|
35
|
+
3. 导入本仓库的 [slack-bot-demo.json](https://github.com/a1245582339/chat-heimerdinger/blob/main/slack-bot-demo.json) 文件
|
|
36
|
+
4. 安装应用到你的 Workspace
|
|
37
|
+
5. **重要配置**:进入 **App Home** -> **Show Tabs**:
|
|
38
|
+
- 开启 **Messages Tab**
|
|
39
|
+
- 勾选 **"Allow users to send Slash commands and messages from the messages tab"**(必须勾选,否则无法私聊 Bot)
|
|
40
|
+
|
|
7
41
|
## 功能特性
|
|
8
42
|
|
|
9
43
|
- **Slack 集成**:通过 Slack Bot 对话与 Claude Code 交互
|
|
@@ -25,13 +59,7 @@ npx chat-heimerdinger start
|
|
|
25
59
|
|
|
26
60
|
## 配置
|
|
27
61
|
|
|
28
|
-
### 1.
|
|
29
|
-
|
|
30
|
-
1. 访问 [Slack API](https://api.slack.com/apps) 创建新应用
|
|
31
|
-
2. 选择 **From an app manifest**,粘贴 [slack-bot-demo.yaml](./slack-bot-demo.yaml) 的内容
|
|
32
|
-
3. 安装应用到你的 Workspace
|
|
33
|
-
|
|
34
|
-
### 2. 获取 Token
|
|
62
|
+
### 1. 获取 Token
|
|
35
63
|
|
|
36
64
|
| Token | 位置 |
|
|
37
65
|
|-------|------|
|
|
@@ -39,7 +67,7 @@ npx chat-heimerdinger start
|
|
|
39
67
|
| App Token (xapp-) | Basic Information > App-Level Tokens (需创建,scope 选 `connections:write`) |
|
|
40
68
|
| Signing Secret | Basic Information > App Credentials |
|
|
41
69
|
|
|
42
|
-
###
|
|
70
|
+
### 2. 初始化配置
|
|
43
71
|
|
|
44
72
|
```bash
|
|
45
73
|
npx chat-heimerdinger init
|
|
@@ -170,11 +198,10 @@ pnpm link --global
|
|
|
170
198
|
|
|
171
199
|
## 注意事项
|
|
172
200
|
|
|
173
|
-
1.
|
|
174
|
-
2.
|
|
175
|
-
3.
|
|
176
|
-
4.
|
|
177
|
-
5. **网络要求**:服务需要能访问 Slack API(Socket Mode 使用 WebSocket)
|
|
201
|
+
1. **项目必须已初始化**:需要先在项目目录中使用过 Claude Code,才能在 Slack 中选择该项目
|
|
202
|
+
2. **Slack App 权限**:确保 Slack App 已添加所有必要的 OAuth Scopes
|
|
203
|
+
3. **语音功能可选**:如不需要语音转文字,可跳过 whisper.cpp 安装
|
|
204
|
+
4. **网络要求**:服务需要能访问 Slack API(Socket Mode 使用 WebSocket)
|
|
178
205
|
|
|
179
206
|
## 开发
|
|
180
207
|
|