@friendlyrobot/discord-pi-agent 0.18.2 → 0.19.0

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/dist/index.js CHANGED
@@ -558,11 +558,12 @@ import path2 from "node:path";
558
558
  import dotenv from "dotenv";
559
559
  function resolveConfig(config) {
560
560
  const discordAllowedUserId = requireNonEmptyConfigValue("discordAllowedUserId", config.discordAllowedUserId);
561
+ const cwd = requireNonEmptyConfigValue("cwd", config.cwd);
561
562
  return {
562
563
  discordBotToken: requireNonEmptyConfigValue("discordBotToken", config.discordBotToken),
563
564
  discordAllowedUserId,
564
- cwd: requireNonEmptyConfigValue("cwd", config.cwd),
565
- agentDir: config.agentDir?.trim() || path2.join(config.cwd, ".pi-agent"),
565
+ cwd,
566
+ agentDir: config.agentDir?.trim() || path2.join(cwd, ".pi-agent"),
566
567
  modelProvider: config.modelProvider?.trim() || "openrouter",
567
568
  modelId: config.modelId?.trim() || "anthropic/claude-3.5-haiku",
568
569
  thinkingLevel: parseThinkingLevel(config.thinkingLevel) || "medium",
@@ -573,7 +574,9 @@ function resolveConfig(config) {
573
574
  shutdownOnSignals: config.shutdownOnSignals ?? true,
574
575
  visionModelId: config.visionModelId?.trim() || null,
575
576
  discordAllowedForumChannelIds: config.discordAllowedForumChannelIds ?? [],
576
- discordAllowedUserIds: config.discordAllowedUserIds ?? [discordAllowedUserId]
577
+ discordAllowedUserIds: config.discordAllowedUserIds ?? [
578
+ discordAllowedUserId
579
+ ]
577
580
  };
578
581
  }
579
582
  function loadDiscordGatewayConfigFromEnv(overrides = {}) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@friendlyrobot/discord-pi-agent",
3
- "version": "0.18.2",
3
+ "version": "0.19.0",
4
4
  "description": "Reusable Discord gateway for persistent pi agent sessions",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -30,7 +30,7 @@
30
30
  "test:coverage": "vitest run --coverage",
31
31
  "format": "prettier --write .",
32
32
  "build:01-clean": "rm -rf dist",
33
- "build:02-tsgo": "tsgo -p tsconfig.json --emitDeclarationOnly --declaration --declarationMap false",
33
+ "build:02-tsgo": "tsgo -p tsconfig.build.json --emitDeclarationOnly --declaration --declarationMap false",
34
34
  "build:03-build": "bun build ./src/index.ts --outdir ./dist --target node --format esm --packages external",
35
35
  "build": "bun run --sequential 'build:*'",
36
36
  "typecheck": "tsgo --noEmit -p tsconfig.json"
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export {};