Skip to content

th-3be564: multimodal Big Smooth chat — attach + see images - #169

Merged
brentrager merged 4 commits into
mainfrom
th-3be564-multimodal
Jul 4, 2026
Merged

th-3be564: multimodal Big Smooth chat — attach + see images#169
brentrager merged 4 commits into
mainfrom
th-3be564-multimodal

Conversation

@brentrager

Copy link
Copy Markdown
Contributor

Epic th-3be564, Phases 1–3. Big Smooth chat can now take image attachments and the assistant actually sees them.

What you get

Wire contract (back-compatible)

POST /api/chat/sessions/{id}/messages body → { content, attachments?: [{ name, mime, data(base64, no prefix) }] }. attachments is optional (#[serde(default)]) — existing {content} sends are byte-identical.

Scope / follow-ups

  • Documents are marker-only this PR (a [attached document: x.pdf] text marker reaches the model). Real ingest — Gemini-native PDF vs. a docling microVM — is Phase 4 (th-1b14d6).
  • Images ride the current turn only (history fold is text-only; no multi-turn image re-feed) — noted with ponytail: ceilings in code.
  • Engine pin is a decoupled side-branch rev (multimodal WITHOUT core-main's unrelated post_call change, th-10eb50) — documented at Cargo.toml:194.

Tests

  • Engine: 6 wire/round-trip tests + builder test (in core PRs).
  • Daemon: classify, content-address store + dedupe + round-trip, bad-base64, pick_model precedence, back-compat + with-attachments body parse (7). Full bigsmooth suite 322 pass.
  • Web: pnpm build (tsc + vite) clean.
  • Full cargo build --workspace + web bundle build clean.

🤖 Generated with Claude Code

Web: paperclip/paste/drag-drop image+PDF attachments, composer thumbnails,
inline <img> render in the user bubble. Sends {content, attachments:[{name,
mime,data(base64)}]} — optional field, text-only sends unchanged.

Daemon: chat routes accept attachments, content-address bytes under
~/.smooth/attachments/, build a multimodal turn via Message::user_with_images.
Image turns auto-route to gemini-2.5-flash-lite (cheap vision, native PDF);
text-only keeps the default model; explicit body.model still wins. Documents
are marker-only (Phase 4 does real ingest).

Engine: pins smooth-operator-core rev b43c04fe (multimodal Message content +
image_url wire + AgentConfig::with_user_images; PRs #58/#62). Decoupled from
core main's post_call change (th-10eb50) — see Cargo.toml comment.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@changeset-bot

changeset-bot Bot commented Jul 4, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 72c21f9

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@smooai/smooth Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@brentrager
brentrager enabled auto-merge (squash) July 4, 2026 21:42
brentrager and others added 3 commits July 4, 2026 17:42
Verified live against llm.smoo.ai: a PDF sent as a data:application/pdf
image_url part to gemini-2.5-flash-lite is read natively (answered a
question about the file). So PDF 'documents' need no separate ingest —
add an AttachmentKind::Pdf that rides the same multimodal/vision path as
images (is_model_media). docx/xlsx stay marker-only (docling microVM is
the future upgrade).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@brentrager
brentrager merged commit 5f7dc65 into main Jul 4, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant