@friendlyrobot/discord-pi-agent 0.3.11 → 0.3.13
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/LICENSE +21 -0
- package/README.md +12 -4
- package/dist/index.js +2 -2
- package/package.json +2 -1
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 dcai
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -15,6 +15,7 @@ Reusable Discord DM bridge for persistent pi agent sessions.
|
|
|
15
15
|
|
|
16
16
|
- `!help`
|
|
17
17
|
- `!status`
|
|
18
|
+
- `!thinking`
|
|
18
19
|
- `!compact`
|
|
19
20
|
- `!reset-session`
|
|
20
21
|
|
|
@@ -35,8 +36,8 @@ const bridge = await startDiscordPiBridge({
|
|
|
35
36
|
discordBotToken: process.env.DISCORD_BOT_TOKEN!,
|
|
36
37
|
discordAllowedUserId: process.env.DISCORD_ALLOWED_USER_ID!,
|
|
37
38
|
cwd: process.cwd(),
|
|
38
|
-
modelProvider: "
|
|
39
|
-
modelId: "
|
|
39
|
+
modelProvider: "openrouter",
|
|
40
|
+
modelId: "anthropic/claude-3.5-haiku",
|
|
40
41
|
});
|
|
41
42
|
```
|
|
42
43
|
|
|
@@ -72,8 +73,9 @@ await startDiscordPiBridge(config);
|
|
|
72
73
|
### Optional
|
|
73
74
|
|
|
74
75
|
- `agentDir` default: `<cwd>/.pi-agent`
|
|
75
|
-
- `modelProvider` default: `
|
|
76
|
-
- `modelId` default: `
|
|
76
|
+
- `modelProvider` default: `openrouter`
|
|
77
|
+
- `modelId` default: `anthropic/claude-3.5-haiku`
|
|
78
|
+
- `thinkingLevel` default: `medium` (values: `off`, `minimal`, `low`, `medium`, `high`, `xhigh`)
|
|
77
79
|
- `promptTransform` default: identity
|
|
78
80
|
- `startupMessage` default: `Bot is online and ready.`
|
|
79
81
|
- `shutdownOnSignals` default: `true`
|
|
@@ -94,6 +96,12 @@ If `PI_AGENT_CWD` is missing it falls back to `process.cwd()`.
|
|
|
94
96
|
|
|
95
97
|
Set `DISCORD_STARTUP_MESSAGE=false` to disable the startup DM.
|
|
96
98
|
|
|
99
|
+
## Thinking Levels
|
|
100
|
+
|
|
101
|
+
Use `!thinking` to view the current thinking/reasoning level and available options. Use `!thinking <level>` to set it (e.g., `!thinking high`).
|
|
102
|
+
|
|
103
|
+
Not all models support thinking/reasoning. The configured `thinkingLevel` is applied automatically when the model supports it.
|
|
104
|
+
|
|
97
105
|
## Build
|
|
98
106
|
|
|
99
107
|
```bash
|
package/dist/index.js
CHANGED
|
@@ -303,8 +303,8 @@ function resolveConfig(config) {
|
|
|
303
303
|
discordAllowedUserId: readRequiredValue("discordAllowedUserId", config.discordAllowedUserId),
|
|
304
304
|
cwd: readRequiredValue("cwd", config.cwd),
|
|
305
305
|
agentDir: config.agentDir?.trim() || path2.join(config.cwd, ".pi-agent"),
|
|
306
|
-
modelProvider: config.modelProvider?.trim() || "
|
|
307
|
-
modelId: config.modelId?.trim() || "
|
|
306
|
+
modelProvider: config.modelProvider?.trim() || "openrouter",
|
|
307
|
+
modelId: config.modelId?.trim() || "anthropic/claude-3.5-haiku",
|
|
308
308
|
thinkingLevel: parseThinkingLevel(config.thinkingLevel) || "medium",
|
|
309
309
|
promptTransform: config.promptTransform || identityPromptTransform,
|
|
310
310
|
startupMessage: config.startupMessage === undefined ? "Bot is online and ready." : config.startupMessage,
|
package/package.json
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@friendlyrobot/discord-pi-agent",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.13",
|
|
4
4
|
"description": "Reusable Discord gateway bridge for persistent pi agent sessions",
|
|
5
|
+
"license": "MIT",
|
|
5
6
|
"type": "module",
|
|
6
7
|
"main": "./dist/index.js",
|
|
7
8
|
"module": "./dist/index.js",
|