LocalAI/core/http/react-ui
Daniel Liljeberg fc3980dadd
fix: inject text-file content into chat completions messages (#9896)
Non-image/non-audio file attachments (txt, md, csv, json) were being
  stored in the 'files' metadata field but never added to the message
  content array sent to /v1/chat/completions. Images and audio correctly
  received content blocks; files did not.

  Fix: push a text content block into messageContent when textContent is
  present, matching the pattern used for image_url and audio_url.

  Also fixes Home.jsx addFiles which never called file.text() at all,
  meaning files attached on the home screen had empty textContent even
  before reaching useChat.js.

  Note: PDF files use file.text() which returns raw bytes rather than
  parsed text. Proper PDF support would require PDF.js or server-side
  extraction and is not part of this fix.

Signed-off-by: Daniel Liljeberg <damien_@hotmail.com>
2026-05-20 01:00:32 +02:00
..
e2e feat(gallery): Speed up load times and clean gallery entries (#9211) 2026-05-06 14:51:38 +02:00
public/locales feat(realtime): Add Liquid Audio s2s model and assistant mode on talk page (#9801) 2026-05-13 21:57:27 +02:00
scripts feat(react-ui): add multilingual (i18n) support (#9642) 2026-05-02 22:42:08 +02:00
src fix: inject text-file content into chat completions messages (#9896) 2026-05-20 01:00:32 +02:00
bun.lock chore: Security hardening (#9719) 2026-05-08 16:25:45 +02:00
eslint.config.js feat(ui): move to React for frontend (#8772) 2026-03-05 21:47:12 +01:00
i18next-parser.config.js feat(react-ui): add multilingual (i18n) support (#9642) 2026-05-02 22:42:08 +02:00
index.html chore: Security hardening (#9719) 2026-05-08 16:25:45 +02:00
package-lock.json chore(deps): bump the npm_and_yarn group across 1 directory with 3 updates (#9728) 2026-05-12 09:54:38 +02:00
package.json chore: Security hardening (#9719) 2026-05-08 16:25:45 +02:00
playwright.config.js feat(ui, gallery): Show model backends and add searchable model/backend selector (#9060) 2026-03-18 21:14:41 +01:00
vite.config.js fix(ui): fix /app redirect 2026-03-05 21:43:46 +00:00