From 7133daec0545ea20774067ce2b20e4a71630ff94 Mon Sep 17 00:00:00 2001
From: Steven Enamakel <31011319+senamakel@users.noreply.github.com>
Date: Sun, 7 Jun 2026 01:11:07 -0400
Subject: [PATCH] feat(chat): enable reasoning multimodal attachments (#3458)
---
app/src/components/chat/AttachmentPreview.tsx | 33 ++-
app/src/components/chat/ChatComposer.tsx | 6 +-
.../chat/__tests__/AttachmentPreview.test.tsx | 19 ++
.../chat/__tests__/ChatComposer.test.tsx | 4 +
app/src/lib/attachments.test.ts | 53 ++++-
app/src/lib/attachments.ts | 163 +++++++++++---
app/src/lib/i18n/ar.ts | 1 +
app/src/lib/i18n/bn.ts | 1 +
app/src/lib/i18n/de.ts | 1 +
app/src/lib/i18n/en.ts | 1 +
app/src/lib/i18n/es.ts | 1 +
app/src/lib/i18n/fr.ts | 1 +
app/src/lib/i18n/hi.ts | 1 +
app/src/lib/i18n/id.ts | 1 +
app/src/lib/i18n/it.ts | 1 +
app/src/lib/i18n/ko.ts | 1 +
app/src/lib/i18n/pl.ts | 1 +
app/src/lib/i18n/pt.ts | 1 +
app/src/lib/i18n/ru.ts | 1 +
app/src/lib/i18n/zh-CN.ts | 1 +
app/src/pages/Conversations.tsx | 57 +++--
.../Conversations.attachments.test.tsx | 173 +++++++++++----
.../__tests__/Conversations.render.test.tsx | 10 +-
app/src/test/setup.ts | 2 +-
app/src/utils/config.ts | 15 +-
.../specs/chat-harness-subagent.spec.ts | 33 +--
.../specs/chat-management-functional.spec.ts | 72 +++++-
.../specs/chat-multi-tool-round.spec.ts | 2 +-
.../specs/chat-tool-call-flow.spec.ts | 2 +-
src/openhuman/agent/multimodal.rs | 208 ++++++++++++++----
src/openhuman/agent/multimodal_tests.rs | 121 +++++++++-
.../inference/provider/compatible.rs | 14 ++
.../provider/compatible_provider_impl.rs | 5 +-
.../inference/provider/compatible_tests.rs | 9 +
src/openhuman/inference/provider/factory.rs | 4 +
.../inference/provider/factory_tests.rs | 27 ++-
.../inference/provider/openhuman_backend.rs | 11 +-
tests/inference_agent_raw_coverage_e2e.rs | 2 +-
38 files changed, 870 insertions(+), 189 deletions(-)
diff --git a/app/src/components/chat/AttachmentPreview.tsx b/app/src/components/chat/AttachmentPreview.tsx
index 2f7c62744..d875f4c1b 100644
--- a/app/src/components/chat/AttachmentPreview.tsx
+++ b/app/src/components/chat/AttachmentPreview.tsx
@@ -22,15 +22,36 @@ export default function AttachmentPreview({
-

+ {attachment.kind === 'image' ? (
+

+ ) : (
+
+ )}
{attachment.file.name}
- {formatFileSize(attachment.file.size)}
+ {formatFileSize(attachment.payloadSizeBytes)}