@friendlyrobot/discord-pi-agent 0.19.2 → 0.19.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.
@@ -3,5 +3,5 @@ import type { ImageContent } from "@earendil-works/pi-ai";
3
3
  type CollectReplyOptions = {
4
4
  images?: ImageContent[];
5
5
  };
6
- export declare function runPromptAndCollectReply(session: AgentSession, prompt: string, options?: CollectReplyOptions): Promise<string>;
6
+ export declare function runAgentTurn(session: AgentSession, prompt: string, options?: CollectReplyOptions): Promise<string>;
7
7
  export {};
package/dist/index.js CHANGED
@@ -302,9 +302,9 @@ async function formatWithPrettier(text) {
302
302
  }
303
303
  }
304
304
 
305
- // src/reply-buffer.ts
306
- var logger4 = createModuleLogger("reply-buffer");
307
- async function runPromptAndCollectReply(session, prompt, options = {}) {
305
+ // src/agent-turn-runner.ts
306
+ var logger4 = createModuleLogger("agent-turn-runner");
307
+ async function runAgentTurn(session, prompt, options = {}) {
308
308
  let streamedText = "";
309
309
  let eventCount = 0;
310
310
  let toolCount = 0;
@@ -454,7 +454,7 @@ class AgentService {
454
454
  async prompt(text) {
455
455
  const session = this.requireSession();
456
456
  const transformedPrompt = await this.config.promptTransform(text);
457
- return runPromptAndCollectReply(session, transformedPrompt);
457
+ return runAgentTurn(session, transformedPrompt);
458
458
  }
459
459
  async compact() {
460
460
  const session = this.requireSession();
@@ -1552,7 +1552,7 @@ ${attachment.content}`;
1552
1552
  }
1553
1553
  const wrappedContent = buildDiscordPromptContent(message, scope, promptContent, config);
1554
1554
  const transformedPrompt = await config.promptTransform(wrappedContent);
1555
- return runPromptAndCollectReply(session, transformedPrompt, {
1555
+ return runAgentTurn(session, transformedPrompt, {
1556
1556
  images: promptImages
1557
1557
  });
1558
1558
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@friendlyrobot/discord-pi-agent",
3
- "version": "0.19.2",
3
+ "version": "0.19.3",
4
4
  "description": "Reusable Discord gateway for persistent pi agent sessions",
5
5
  "license": "MIT",
6
6
  "type": "module",