agent-window 1.0.0 → 1.0.1

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 CHANGED
@@ -5,19 +5,32 @@
5
5
  </p>
6
6
 
7
7
  <p align="center">
8
- Simplified interaction, powerful backend capabilities
8
+ <i>A simple yet powerful interface to interact with AI agents through familiar chat platforms</i>
9
+ </p>
10
+
11
+ <p align="center">
12
+ <a href="README.zh-CN.md">中文版</a> | <a href="README.md">English</a>
9
13
  </p>
10
14
 
11
15
  ---
12
16
 
13
- ## Features
17
+ ## Why AgentWindow?
18
+
19
+ **AgentWindow = Your Chat App + Powerful AI Backend**
20
+
21
+ - **Dead Simple Interaction** - Chat naturally in Discord/Slack/Telegram, no new UI to learn
22
+ - **Unified Window** - All AI agent capabilities presented through one familiar interface
23
+ - **Multi-Platform Ready** - Discord today, seamlessly switch to Slack or Telegram tomorrow
24
+ - **Secure Isolation** - Docker sandboxed environment keeps AI operations separate from your system
25
+ - **Permission Control** - Approve sensitive operations via chat buttons, stay in control
26
+ - **Multi-Bot Management** - One codebase, multiple projects, unified management
27
+
28
+ ### Use Cases
14
29
 
15
- - **Simplicity First** - Easy chat-based interaction with AI agents
16
- - **Multi-Platform Ready** - Discord today, Slack/Telegram coming soon
17
- - **Docker Sandbox** - Secure isolated execution environment
18
- - **Permission Control** - Approve operations via chat buttons
19
- - **Session Management** - Resume conversations, channel binding
20
- - **Multi-Bot Ready** - Unified management for multiple instances
30
+ - **Code Collaboration** - Have an AI team work directly in your development channels
31
+ - **Document Processing** - Feed documents to AI, get structured outputs
32
+ - **Data Analysis** - Describe requirements, AI processes and returns results
33
+ - **Task Automation** - Trigger scripts and scheduled tasks via chat
21
34
 
22
35
  ---
23
36
 
@@ -0,0 +1,151 @@
1
+ # AgentWindow
2
+
3
+ <p align="center">
4
+ <strong>简单而强大的 AI 代理交互窗口</strong>
5
+ </p>
6
+
7
+ <p align="center">
8
+ <i>通过熟悉的聊天平台,轻松驾驭后端 AI 能力</i>
9
+ </p>
10
+
11
+ <p align="center">
12
+ <a href="README.zh-CN.md">🇨🇳 中文版</a> | <a href="README.md">🇺🇸 English</a>
13
+ </p>
14
+
15
+ ---
16
+
17
+ ## 为什么选择 AgentWindow?
18
+
19
+ **AgentWindow = 你的聊天软件 + 强大 AI 后端**
20
+
21
+ - **极简交互** - 在 Discord/Slack/Telegram 中自然对话,无需学习新界面
22
+ - **统一窗口** - 所有 AI 代理能力通过一个"窗口"呈现,像使用同事一样简单
23
+ - **多平台支持** - 今天用 Discord,明天无缝切换到 Slack 或 Telegram
24
+ - **安全隔离** - Docker 沙箱环境,AI 操作与你的系统安全隔离
25
+ - **权限可控** - 通过聊天按钮批准敏感操作,完全掌控 AI 行为
26
+ - **多实例管理** - 一套代码,多个项目,统一管理
27
+
28
+ ### 适用场景
29
+
30
+ - **代码协作** - 让 AI 团队直接在你的开发频道中工作
31
+ - **文档处理** - 扔给 AI 文档,获得结构化输出
32
+ - **数据分析** - 描述需求,AI 处理后返回结果
33
+ - **自动化任务** - 通过聊天触发脚本和定时任务
34
+
35
+ ---
36
+
37
+ ## 快速开始
38
+
39
+ ```bash
40
+ # 全局安装
41
+ npm install -g agent-window
42
+
43
+ # 初始化多机器人目录
44
+ agent-window init
45
+
46
+ # 添加一个机器人实例
47
+ agent-window add-bot myproject
48
+
49
+ # 启动所有机器人
50
+ pm2 start ~/bots/ecosystem.config.cjs
51
+ ```
52
+
53
+ ---
54
+
55
+ ## CLI 命令
56
+
57
+ ```bash
58
+ # 单机器人命令
59
+ agent-window setup # 交互式设置向导
60
+ agent-window start # 启动网关
61
+ agent-window stop # 停止网关
62
+ agent-window restart # 重启网关
63
+ agent-window status # 显示状态
64
+ agent-window logs # 查看日志(实时)
65
+ agent-window update # 更新到最新版本
66
+ agent-window config # 显示配置位置
67
+
68
+ # 多机器人命令
69
+ agent-window init # 初始化 ~/bots 目录
70
+ agent-window add-bot <name> # 添加新的机器人实例
71
+ ```
72
+
73
+ ---
74
+
75
+ ## 配置
76
+
77
+ 每个机器人实例都有自己的 `config.json`:
78
+
79
+ ```json
80
+ {
81
+ "BOT_TOKEN": "你的 Discord 机器人令牌",
82
+ "CLAUDE_CODE_OAUTH_TOKEN": "你的 Claude Code OAuth 令牌",
83
+ "PROJECT_DIR": "/你的/项目/路径",
84
+ "ALLOWED_CHANNELS": "频道ID-1,频道ID-2"
85
+ }
86
+ ```
87
+
88
+ ### 必填项
89
+
90
+ | 键 | 说明 |
91
+ |-----|------|
92
+ | `BOT_TOKEN` | Discord 机器人令牌 |
93
+ | `CLAUDE_CODE_OAUTH_TOKEN` | Claude Code OAuth 令牌 |
94
+ | `PROJECT_DIR` | 要工作的项目目录 |
95
+ | `ALLOWED_CHANNELS` | 逗号分隔的频道 ID |
96
+
97
+ ### 可选项
98
+
99
+ 查看 `config/config.example.json` 了解所有选项。
100
+
101
+ ---
102
+
103
+ ## 聊天命令
104
+
105
+ 在 Discord 中,提及机器人:
106
+
107
+ ```
108
+ @bot <消息> # 发送消息(继续上次会话)
109
+ @bot -n <消息> # 开始新会话
110
+ @bot -r <会话ID> <消息> # 恢复指定会话
111
+ @bot /pick # 选择会话(按钮界面)
112
+ @bot /sessions # 列出最近的会话
113
+ @bot /status # 显示机器人状态
114
+ @bot /help # 显示帮助
115
+ ```
116
+
117
+ ---
118
+
119
+ ## 多机器人管理
120
+
121
+ 在一个目录中组织多个机器人实例:
122
+
123
+ ```
124
+ ~/bots/
125
+ ├── agent-window/ # 共享代码(链接到全局安装)
126
+ ├── project1/config.json # 机器人1 配置
127
+ ├── project2/config.json # 机器人2 配置
128
+ └── ecosystem.config.cjs # PM2 统一管理
129
+ ```
130
+
131
+ **统一命令:**
132
+ ```bash
133
+ pm2 start ~/bots/ecosystem.config.cjs # 启动所有
134
+ pm2 stop all # 停止所有
135
+ pm2 restart all # 重启所有
136
+ pm2 logs # 查看所有日志
137
+ ```
138
+
139
+ ---
140
+
141
+ ## 更新
142
+
143
+ ```bash
144
+ agent-window update
145
+ ```
146
+
147
+ ---
148
+
149
+ ## 许可证
150
+
151
+ MIT
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agent-window",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
4
  "description": "A window to interact with AI agents through chat interfaces. Simplified interaction, powerful backend capabilities.",
5
5
  "type": "module",
6
6
  "main": "src/bot.js",
@@ -38,8 +38,11 @@
38
38
  "dependencies": {
39
39
  "discord.js": "^14.14.1"
40
40
  },
41
+ "overrides": {
42
+ "undici": "^7.19.0"
43
+ },
41
44
  "repository": {
42
45
  "type": "git",
43
- "url": "https://github.com/YOUR_USERNAME/AgentWindow"
46
+ "url": "https://github.com/Observer-GGboy/AgentWindow"
44
47
  }
45
48
  }