Merge f2358a9f662fea3efd9000aad113ffc14977e39d into 5e417b44e1540f528d2ae63e3e20229a902d1db2
This commit is contained in:
commit
d3f8ec3514
@ -581,6 +581,8 @@ export class AcpxRuntime implements AcpRuntime {
|
||||
if (attachment.mediaType.startsWith("image/")) {
|
||||
blocks.push({ type: "image", mimeType: attachment.mediaType, data: attachment.data });
|
||||
}
|
||||
// Non-image attachments (documents, PDFs, audio, video) are not supported
|
||||
// as binary content blocks in the ACP protocol — skip silently.
|
||||
}
|
||||
child.stdin.end(blocks.length > 0 ? JSON.stringify(blocks) : input.text);
|
||||
} else {
|
||||
|
||||
@ -64,7 +64,7 @@ function resolveAcpPromptText(ctx: FinalizedMsgContext): string {
|
||||
]).trim();
|
||||
}
|
||||
|
||||
const ACP_ATTACHMENT_MAX_BYTES = 10 * 1024 * 1024;
|
||||
const ACP_ATTACHMENT_MAX_BYTES = 10 * 1024 * 1024; // 10 MB — consistent with Telegram mediaMaxMb default
|
||||
|
||||
async function resolveAcpAttachments(ctx: FinalizedMsgContext): Promise<AcpTurnAttachment[]> {
|
||||
const mediaAttachments = normalizeAttachments(ctx);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user