@poncho-ai/cli 0.33.3 → 0.33.4
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/.turbo/turbo-build.log +6 -6
- package/CHANGELOG.md +9 -0
- package/dist/{chunk-METMUDY6.js → chunk-QVCJIXPQ.js} +17 -3
- package/dist/cli.js +1 -1
- package/dist/index.js +1 -1
- package/dist/{run-interactive-ink-XQM7OIZT.js → run-interactive-ink-JO343QM2.js} +1 -1
- package/package.json +2 -2
- package/src/index.ts +20 -3
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @poncho-ai/cli@0.33.
|
|
2
|
+
> @poncho-ai/cli@0.33.4 build /home/runner/work/poncho-ai/poncho-ai/packages/cli
|
|
3
3
|
> tsup src/index.ts src/cli.ts --format esm --dts
|
|
4
4
|
|
|
5
5
|
[34mCLI[39m Building entry: src/cli.ts, src/index.ts
|
|
@@ -7,12 +7,12 @@
|
|
|
7
7
|
[34mCLI[39m tsup v8.5.1
|
|
8
8
|
[34mCLI[39m Target: es2022
|
|
9
9
|
[34mESM[39m Build start
|
|
10
|
-
[32mESM[39m [1mdist/index.js [22m[32m917.00 B[39m
|
|
11
10
|
[32mESM[39m [1mdist/cli.js [22m[32m94.00 B[39m
|
|
12
|
-
[32mESM[39m [1mdist/
|
|
13
|
-
[32mESM[39m [1mdist/
|
|
14
|
-
[32mESM[39m
|
|
11
|
+
[32mESM[39m [1mdist/index.js [22m[32m917.00 B[39m
|
|
12
|
+
[32mESM[39m [1mdist/run-interactive-ink-JO343QM2.js [22m[32m56.86 KB[39m
|
|
13
|
+
[32mESM[39m [1mdist/chunk-QVCJIXPQ.js [22m[32m529.65 KB[39m
|
|
14
|
+
[32mESM[39m ⚡️ Build success in 75ms
|
|
15
15
|
[34mDTS[39m Build start
|
|
16
|
-
[32mDTS[39m ⚡️ Build success in
|
|
16
|
+
[32mDTS[39m ⚡️ Build success in 4620ms
|
|
17
17
|
[32mDTS[39m [1mdist/cli.d.ts [22m[32m20.00 B[39m
|
|
18
18
|
[32mDTS[39m [1mdist/index.d.ts [22m[32m7.07 KB[39m
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# @poncho-ai/cli
|
|
2
2
|
|
|
3
|
+
## 0.33.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#73](https://github.com/cesr/poncho-ai/pull/73) [`f72f202`](https://github.com/cesr/poncho-ai/commit/f72f202d839dbbb8240336ec76eb6340aba20f06) Thanks [@cesr](https://github.com/cesr)! - Fix Telegram approval message ordering: send accumulated assistant text before approval buttons so the conversation reads naturally. Skip empty bridge replies when text was already sent at checkpoint.
|
|
8
|
+
|
|
9
|
+
- Updated dependencies [[`f72f202`](https://github.com/cesr/poncho-ai/commit/f72f202d839dbbb8240336ec76eb6340aba20f06)]:
|
|
10
|
+
- @poncho-ai/messaging@0.7.10
|
|
11
|
+
|
|
3
12
|
## 0.33.3
|
|
4
13
|
|
|
5
14
|
### Patch Changes
|
|
@@ -10178,6 +10178,7 @@ ${resultBody}`,
|
|
|
10178
10178
|
let latestRunId = "";
|
|
10179
10179
|
const draft = createTurnDraftState();
|
|
10180
10180
|
let checkpointedRun = false;
|
|
10181
|
+
let checkpointTextAlreadySent = false;
|
|
10181
10182
|
let runContextTokens = 0;
|
|
10182
10183
|
let runContextWindow = 0;
|
|
10183
10184
|
let runContinuation2 = false;
|
|
@@ -10268,6 +10269,19 @@ ${resultBody}`,
|
|
|
10268
10269
|
if (conv?.channelMeta?.platform === "telegram") {
|
|
10269
10270
|
const tgAdapter = messagingAdapters.get("telegram");
|
|
10270
10271
|
if (tgAdapter) {
|
|
10272
|
+
const threadRef = {
|
|
10273
|
+
channelId: conv.channelMeta.channelId,
|
|
10274
|
+
platformThreadId: conv.channelMeta.platformThreadId
|
|
10275
|
+
};
|
|
10276
|
+
const pendingText = draft.assistantResponse.trim();
|
|
10277
|
+
if (pendingText) {
|
|
10278
|
+
try {
|
|
10279
|
+
await tgAdapter.sendReply(threadRef, pendingText);
|
|
10280
|
+
checkpointTextAlreadySent = true;
|
|
10281
|
+
} catch (err) {
|
|
10282
|
+
console.error("[messaging-runner] failed to send pre-approval text:", err instanceof Error ? err.message : err);
|
|
10283
|
+
}
|
|
10284
|
+
}
|
|
10271
10285
|
const approvals = event.approvals.map((a) => ({
|
|
10272
10286
|
approvalId: a.approvalId,
|
|
10273
10287
|
tool: a.tool,
|
|
@@ -10351,8 +10365,8 @@ ${resultBody}`,
|
|
|
10351
10365
|
runOwners.delete(latestRunId);
|
|
10352
10366
|
runConversations.delete(latestRunId);
|
|
10353
10367
|
}
|
|
10354
|
-
|
|
10355
|
-
|
|
10368
|
+
const response = checkpointTextAlreadySent ? "" : draft.assistantResponse;
|
|
10369
|
+
console.log("[messaging-runner] run complete, response length:", response.length, checkpointTextAlreadySent ? "(text sent at checkpoint)" : "", runContinuation2 ? "(continuation)" : "");
|
|
10356
10370
|
return {
|
|
10357
10371
|
response,
|
|
10358
10372
|
continuation: runContinuation2,
|
|
@@ -13075,7 +13089,7 @@ var runInteractive = async (workingDir, params) => {
|
|
|
13075
13089
|
await harness.initialize();
|
|
13076
13090
|
const identity = await ensureAgentIdentity2(workingDir);
|
|
13077
13091
|
try {
|
|
13078
|
-
const { runInteractiveInk } = await import("./run-interactive-ink-
|
|
13092
|
+
const { runInteractiveInk } = await import("./run-interactive-ink-JO343QM2.js");
|
|
13079
13093
|
await runInteractiveInk({
|
|
13080
13094
|
harness,
|
|
13081
13095
|
params,
|
package/dist/cli.js
CHANGED
package/dist/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@poncho-ai/cli",
|
|
3
|
-
"version": "0.33.
|
|
3
|
+
"version": "0.33.4",
|
|
4
4
|
"description": "CLI for building and deploying AI agents",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -27,8 +27,8 @@
|
|
|
27
27
|
"react": "^19.2.4",
|
|
28
28
|
"react-devtools-core": "^6.1.5",
|
|
29
29
|
"yaml": "^2.8.1",
|
|
30
|
+
"@poncho-ai/messaging": "0.7.10",
|
|
30
31
|
"@poncho-ai/harness": "0.32.1",
|
|
31
|
-
"@poncho-ai/messaging": "0.7.9",
|
|
32
32
|
"@poncho-ai/sdk": "1.7.1"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
package/src/index.ts
CHANGED
|
@@ -3385,6 +3385,7 @@ export const createRequestHandler = async (options?: {
|
|
|
3385
3385
|
let latestRunId = "";
|
|
3386
3386
|
const draft = createTurnDraftState();
|
|
3387
3387
|
let checkpointedRun = false;
|
|
3388
|
+
let checkpointTextAlreadySent = false;
|
|
3388
3389
|
let runContextTokens = 0;
|
|
3389
3390
|
let runContextWindow = 0;
|
|
3390
3391
|
let runContinuation = false;
|
|
@@ -3479,11 +3480,27 @@ export const createRequestHandler = async (options?: {
|
|
|
3479
3480
|
});
|
|
3480
3481
|
checkpointedRun = true;
|
|
3481
3482
|
|
|
3482
|
-
// Send inline keyboard approval buttons to Telegram
|
|
3483
3483
|
const conv = await conversationStore.get(conversationId);
|
|
3484
3484
|
if (conv?.channelMeta?.platform === "telegram") {
|
|
3485
3485
|
const tgAdapter = messagingAdapters.get("telegram") as TelegramAdapter | undefined;
|
|
3486
3486
|
if (tgAdapter) {
|
|
3487
|
+
const threadRef: import("@poncho-ai/messaging").ThreadRef = {
|
|
3488
|
+
channelId: conv.channelMeta.channelId,
|
|
3489
|
+
platformThreadId: conv.channelMeta.platformThreadId,
|
|
3490
|
+
};
|
|
3491
|
+
|
|
3492
|
+
// Send accumulated text BEFORE approval buttons so Telegram
|
|
3493
|
+
// shows them in the natural order (text → approval request).
|
|
3494
|
+
const pendingText = draft.assistantResponse.trim();
|
|
3495
|
+
if (pendingText) {
|
|
3496
|
+
try {
|
|
3497
|
+
await tgAdapter.sendReply(threadRef, pendingText);
|
|
3498
|
+
checkpointTextAlreadySent = true;
|
|
3499
|
+
} catch (err: unknown) {
|
|
3500
|
+
console.error("[messaging-runner] failed to send pre-approval text:", err instanceof Error ? err.message : err);
|
|
3501
|
+
}
|
|
3502
|
+
}
|
|
3503
|
+
|
|
3487
3504
|
const approvals = event.approvals.map(a => ({
|
|
3488
3505
|
approvalId: a.approvalId,
|
|
3489
3506
|
tool: a.tool,
|
|
@@ -3571,8 +3588,8 @@ export const createRequestHandler = async (options?: {
|
|
|
3571
3588
|
runConversations.delete(latestRunId);
|
|
3572
3589
|
}
|
|
3573
3590
|
|
|
3574
|
-
|
|
3575
|
-
|
|
3591
|
+
const response = checkpointTextAlreadySent ? "" : draft.assistantResponse;
|
|
3592
|
+
console.log("[messaging-runner] run complete, response length:", response.length, checkpointTextAlreadySent ? "(text sent at checkpoint)" : "", runContinuation ? "(continuation)" : "");
|
|
3576
3593
|
|
|
3577
3594
|
return {
|
|
3578
3595
|
response,
|