Commit Graph

1904 Commits

Author SHA1 Message Date
Timothy Carambat
0325598197 Update TG Transient error code and unclosed tag handler 2026-04-10 08:49:12 -07:00
Timothy Carambat
67d871bbe4 Migrate to org-maintained mdpdf for lang support (Hangul, Simplified Chinese, Kanji) (#5392)
move to custom mdpdf for lang support (Hangul, Simplified Chinese)
2026-04-08 22:00:08 -07:00
Timothy Carambat
91c8319d8f Add retry handling to TG for transient failures (#5391)
* Add retry handling to TG for transient failures

* add async to promise
2026-04-08 15:10:02 -07:00
Timothy Carambat
82ef164314 Merge branch 'master' of github.com:Mintplex-Labs/anything-llm 2026-04-08 14:17:49 -07:00
Timothy Carambat
4af0257263 Fix Telegram thread being null, actually wait for disconnect to prevent conflict at runtime 2026-04-08 14:17:43 -07:00
Timothy Carambat
b2404801d1 Fix streaming issue for LLM instruction blocks (#5382) 2026-04-07 12:03:07 -07:00
Timothy Carambat
b7dfa4c278 Enable final tool call in MAX_STACK to run (#5381) 2026-04-07 11:53:22 -07:00
Timothy Carambat
e344109bcb Update Lemonade Integration to support v10.1.0 changes (#5378)
Update Lemonade Integraion
Fix ApiKey nullification check causing hard throw
2026-04-07 11:21:28 -07:00
Marcello Fitton
42a41201a8 feat: Document Embedding Status Events | Refactor Document Embedding to Job Queue and Forked Process (#5254)
* implement native embedder job queue

* persist embedding progress across renders

* add development worker timeouts

* change to static method

* native reranker

* remove useless return

* lint

* simplify

* make embedding worker timeout value configurable by admin

* add event emission for missing data

* lint

* remove onProgress callback argument

* make rerank to rerankDirect

* persists progress state across app reloads

* remove chunk level progress reporting

* remove unuse dvariable

* make NATIVE_RERANKING_WORKER_TIMEOUT user configurable

* remove dead code

* scope embedding progress per-user and clear stale state on SSE reconnect

* lint

* revert vector databases and embedding engines to call their original methods

* simplify rerank

* simplify progress fetching by removing updateProgressFromApi

* remove duplicate jsdoc

* replace sessionStorage persistence with server-side history replay for embedding progress

* fix old comment

* fix: ignore premature SSE all_complete when embedding hasn't started yet

The SSE connection opens before the embedding API call fires, so the
server sees no buffered history and immediately sends all_complete.
Firefox dispatches this eagerly enough that it closes the EventSource
before real progress events arrive, causing the progress UI to clear
and fall back to the loading spinner. Chrome's EventSource timing
masks the race.

Track slugs where startEmbedding was called but no real progress event
has arrived yet via awaitingProgressRef. Ignore the first all_complete
for those slugs and keep the connection open for the real events.

* reduce duplication with progress emissions

* remove dead code

* refactor: streamline embedding progress handling

Removed unnecessary tracking of slugs for premature all_complete events in the EmbeddingProgressProvider. Updated the server-side logic to avoid sending all_complete when no embedding is in progress, allowing the connection to remain open for real events. Adjusted the embedding initiation flow to ensure the server processes the job before the SSE connection opens, improving the reliability of progress updates.

* fix stale comment

* remove unused function

* fix event emissions for document creation failure

* refactor: move Reranking Worker Idle Timeout input to LanceDBOptions component

Extracted the Reranking Worker Idle Timeout input from GeneralEmbeddingPreference and integrated it into the LanceDBOptions component. This change enhances modularity and maintains a cleaner structure for the settings interface.

* lint

* remove unused hadHistory vars

* refactor workspace directory by hoisting component and converting into functions

* moved EmbeddingProgressProvider to wrap Document Manager Modal

* refactor embed progress SSE connection to use fetchEventSource instead of native EventSource API.

* refactor message handlng into a function and reduce duplication

* refactor: utilize writeResponseChunk for event emissions in document embedding progress SSE

* refactor: explicit in-proc embedding and rerank methods that are called by workers instead of process.send checks

* Abstract EmbeddingProgressBus and Worker Queue into modules

* remove error and toast messages on embed process result

* use safeJsonParse

* add chunk-level progress events with per-document progress bar in UI

* remove unused parameter

* rename all worker timeout references to use ttl | remove ttl updating from UI

* refactor: pass embedding context through job payload instead of global state

* lint

* add graceful shutdown for workers

* apply figma styles

* refactor embedding worker to use bree

* use existing WorkerQueue class as the management layer for jobs

* lint

* revert all reranking worker changes back to master state

Removes the reranking worker queue, rerankViaWorker/rerankInProcess
renames, and NATIVE_RERANKING_WORKER_TTL config so this branch
only contains the embedding worker job queue feature.

* remove breeManaged flag — WorkerQueue always spawns via Bree

* fix prompt embedding bug

* have embedTextInput call embedChunksInProcess

* add message field to `process.send()`

* remove nullish check and error throw

* remove bespoke graceful shutdown logix

* add spawnWorker method and asbtract redudant flows into helper methods

* remove unneeded comment

* remove recomputation of TTL value

* frontend cleanup and refactor

* wip on backend refactor

* backend overhaul

* small lint

* second pass

* add logging, update endpoint

* simple refactor

* add reporting to all embedder providers

* fix styles

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2026-04-06 17:00:15 -07:00
Timothy Carambat
0645f3c4bf Reapply "Remove illegal chars for Windows on files (#5364)"
This reverts commit 869be87ef6.
2026-04-06 14:05:25 -07:00
Timothy Carambat
869be87ef6 Revert "Remove illegal chars for Windows on files (#5364)"
This reverts commit 8ed1d35ab3.
2026-04-06 14:03:53 -07:00
Timothy Carambat
5a91608d9e add provider/embedder to bug report for clarity
resolves #5363
2026-04-06 13:23:42 -07:00
Timothy Carambat
e32ad528bb add provider/embedder to bug report for clarity
resolves #5363
2026-04-06 13:23:33 -07:00
Timothy Carambat
8ed1d35ab3 Remove illegal chars for Windows on files (#5364) 2026-04-06 11:12:13 -07:00
Timothy Carambat
3444b9b0aa admin only flow-plugin path validation 2026-04-05 11:57:48 -07:00
Timothy Carambat
4c37b487f5 hide cluttered menus on small screens
resolves #5055
closes #5132
2026-04-03 15:39:33 -07:00
Timothy Carambat
3c2682eb5f Fix Agent Flow toggle state sync (#5348) 2026-04-03 15:00:03 -07:00
suyua9
a841486c5e fix(agent-flows): keep flow menu visible in narrow windows (#5341)
* fix(agent-flows): keep flow menu visible in narrow windows

* fix(agent-flows): prevent gear menu text clipping

Signed-off-by: suyua9 <1521777066@qq.com>

---------

Signed-off-by: suyua9 <1521777066@qq.com>
Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2026-04-03 14:33:46 -07:00
Timothy Carambat
37f269d59a Fix light mode docgen page (#5347)
Fix light mode docgen
2026-04-03 14:31:08 -07:00
Neha Prasad
09d2161476 fix(lemonade): throw on embedding failures instead of returning empty (#5325)
* fix(lemonade): throw on embedding failures instead of returning empty vectors

* use class logger

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2026-04-02 14:57:54 -07:00
S. Neuhaus
a70eb3a28f German translation fixes (#5319)
* Fix German login welcome message

* More German translation fixes

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2026-04-02 14:51:51 -07:00
Timothy Carambat
f6f1c80042 1.12.0 release (#5331) v1.12.0 2026-04-02 13:52:00 -07:00
Timothy Carambat
5a2393e632 Fix chat UI event listener bloat (#5323) 2026-04-01 17:00:32 -07:00
Timothy Carambat
88ea47b9f4 Merge branch 'master' of github.com:Mintplex-Labs/anything-llm 2026-03-31 20:51:46 -07:00
Timothy Carambat
527ccab2ca remove log 2026-03-31 20:51:39 -07:00
Sean Hatfield
b9f0d98345 Redesign Telegram bot settings UI (#5306)
* redesign telegram bot settings ui/refactor ui components

* fix positioning of user row

* move ConnectedBotCard to subcomponent

* fix redirect

* remove redundant guard

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2026-03-31 13:34:59 -07:00
Timothy Carambat
3934b1a585 show links in /proof on TG 2026-03-31 13:22:21 -07:00
Timothy Carambat
e1ad9080de Automatic mode is now default 2026-03-31 13:11:46 -07:00
Timothy Carambat
ddc89851fa Merge branch 'master' of github.com:Mintplex-Labs/anything-llm 2026-03-30 21:47:13 -07:00
Timothy Carambat
77d42e6564 add batching Intelligent Tool Selector for performance and scoring 2026-03-30 21:47:07 -07:00
Timothy Carambat
7aaea7f514 File creation agent skills (#5280)
* Powerpoint File Creation (#5278)

* wip

* download card

* UI for downloading

* move to fs system with endpoint to pull files

* refactor UI

* final-pass

* remove save-file-browser skill and refactor

* remove fileDownload event

* reset

* reset file

* reset timeout

* persist toggle

* Txt creation (#5279)

* wip

* download card

* UI for downloading

* move to fs system with endpoint to pull files

* refactor UI

* final-pass

* remove save-file-browser skill and refactor

* remove fileDownload event

* reset

* reset file

* reset timeout

* wip

* persist toggle

* add arbitrary text creation file

* Add PDF document generation with markdown formatting (#5283)

add support for branding in bottom right corner
refactor core utils and frontend rendering

* Xlsx document creation (#5284)

add Excel doc & sheet creation

* Basic docx creation (#5285)

* Basic docx creation

* add test theme support + styling and title pages

* simplify skill selection

* handle TG attachments

* send documents over tg

* lazy import

* pin deps

* fix lock

* i18n for file creation (#5286)

i18n for file-creation
connect #5280

* theme overhaul

* Add PPTX subagent for better results

* forgot files

* Add PPTX subagent for better results (#5287)

* Add PPTX subagent for better results

* forgot files

* make sub-agent use proper tool calling if it can and better UI hints
2026-03-30 15:13:39 -07:00
Marcello Fitton
0bfd27c6df feat: add optional API key support for Lemonade provider (#5281)
* add API key param to Lemonade LLM Provider and Embedding Provider

* add LEMONADE_LLM_API_KEY to .env.example

* add api key to aibitat provider

* fix api key from being sent to frontend

* fix tooltip id

* add null fallback for `apiKey`

* remove console log

* add missing api keys

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2026-03-30 14:44:12 -07:00
Timothy Carambat
3f9eaa1a76 fix openapi spec 2026-03-30 14:42:54 -07:00
Marcello Fitton
b15353cd39 feat: add missing Lemonade LLM provider env vars to .env.example (#5275)
add llm provider lemonade env vars to .env.example
2026-03-26 21:43:44 -07:00
Timothy Carambat
fb4dff618f remove legacy cost estimate for embedding 2026-03-26 15:02:23 -07:00
Neha Prasad
d767c398c7 feat : auto-select newly uploaded docs/URLs in my documents list (#5222)
* auto-select newly uploaded docs/URLs in My Documents list

* fix: improve auto-select reliability and fix debounce/selection bugs

- Add missing `await` on fetchKeys in handleSendLink so loading state
  and auto-select timing work correctly
- Use functional update for setSelectedItems to merge with existing
  selections instead of replacing them
- Stabilize debounced fetchKeys with useRef so rapid uploads actually
  debounce instead of creating independent timers per render
- Rename shadowed local variables (availableDocs -> filteredAvailableDocs)
  for clarity

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2026-03-26 14:59:25 -07:00
Timothy Carambat
7ecc4ae005 fix es translation entry 2026-03-26 14:21:01 -07:00
Timothy Carambat
3dedcede34 Filesystem Agent Skill overhaul (#5260)
* wip

* collector parse fixes

* refactor for class and also operation for reading

* add skill management panel

* management panel + lint

* management panel + lint

* Hide skill in non-docker context

* add ask-prompt for edit tool calls

* fix dep

* fix execa pkg (unused in codebase)

* simplify search with ripgrep only and build deps

* Fs skill i18n (#5264)

i18n

* add copy file support

* fix translations
2026-03-26 14:07:46 -07:00
Marcello Fitton
e9883f4d09 Refactor onboarding welcome screen to v2 design (#5262)
* refactor onboarding home page to v2 design

* fixc typography and buttons

* refactor useTheme to return isLight variable | call useTheme from inside SVG component | apply light mode background gradient | polish styles to match designs

* add welcome i18n

* simplify isLight variable

* add new welcome translation key to locales

* delete unused images

* move OnboardingLogoSVG into module | compute isLight directly in component

* add type button | add border-none | add hover state

* update hook with doc

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2026-03-24 22:06:58 -07:00
Timothy Carambat
7e9737dd86 add ask to run prompt for tool calls (demo) (#5261)
* add ask to run prompt for tools

* border-none on buttons

* translations

* linting

* i18n (#5263)

* extend approve/deny requests to telegram

* break up handler
2026-03-24 15:18:17 -07:00
Timothy Carambat
8937b8a98b whitelist valid dynamic translation 2026-03-24 08:24:05 -07:00
Timothy Carambat
a2ae761f1a Merge branch 'master' of github.com:Mintplex-Labs/anything-llm 2026-03-24 08:17:48 -07:00
Timothy Carambat
bf944bc903 fix pruned translations 2026-03-24 08:17:42 -07:00
Timothy Carambat
3168a4c9ae fix Firefox LaTeX rendering (#5258) 2026-03-23 21:06:36 -07:00
Timothy Carambat
1b0add0318 add Dynamic max_tokens retreival for Anthropic models (#5255) 2026-03-23 15:45:22 -07:00
Mike Lambert
9d242bc053 Add User-Agent header for Anthropic API calls (#5174)
* Add User-Agent header for Anthropic API calls

Passes User-Agent: AnythingLLM/{version} to the Anthropic SDK
so Anthropic can identify traffic from AnythingLLM.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* remove test, simplify header default

* unset change to spread

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2026-03-23 15:19:33 -07:00
Sean Hatfield
192ca411f2 Telegram bot connector (#5190)
* wip telegram bot connector

* encrypt bot token, reorg telegram bot modules, secure pairing codes

* offload telegram chat to background worker, add @agent support with chart png rendering, reconnect ui

* refactor telegram bot settings page into subcomponents

* response.locals for mum, telemetry for connecting to telegram

* simplify telegram command registration

* improve telegram bot ux: rework switch/history/resume commands

* add voice, photo, and TTS support to telegram bot with long message handling

* lint

* rename external_connectors to external_communication_connectors, add voice response mode, persist chat workspace/thread selection

* lint

* fix telegram bot connect/disconnect bugs, kill telegram bot on multiuser mode enable

* add english translations

* fix qr code in light mode

* repatch migration

* WIP checkpoint

* pipeline overhaul for using response obj

* format functions

* fix comment block

* remove conditional dumpENV + lint

* remove .end() from sendStatus calls

* patch broken streaming where streaming only first chunk

* refactor

* use Ephemeral handler now

* show metrics and citations in real GUI

* bugfixes

* prevent MuM persistence, UI cleanup, styling for status

* add new workspace flow in UI
Add thread chat count
fix 69 byte payload callback limit bug

* handle pagination for workspaces, threads, and models

* modularize commands and navigation

* add /proof support for citation recall

* handle backlog message spam

* support abort of response streams

* code cleanup

* spam prevention

* fix translations, update voice typing indicator, fix token bug

* frontend refactor, update tips on /status and voice response improvements

* collapse agent though blocks

* support images

* Fix mime issues with audio from other devices

* fix config issue post server stop

* persist image on agentic chats

* 5189 i18n (#5245)

* i18n translations
connect #5189

* prune translations

* fix errors

* fix translation gaps

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2026-03-23 15:10:21 -07:00
arvydev
e02faa8984 feat: add Lithuanian locale and register in resources (#5243)
* feat: add Lithuanian locale and register in resources

* sync

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2026-03-23 13:05:16 -07:00
Yitong Li
2f7a818744 fix(collector): infer file extension from Content-Type for URLs without explicit extensions (#5252)
* fix(collector): infer file extension from Content-Type for URLs without explicit extensions

When downloading files from URLs like https://arxiv.org/pdf/2307.10265,
the path has no recognizable file extension. The downloaded file gets
saved without an extension (or with a nonsensical one like .10265),
causing processSingleFile to reject it with 'File extension .10265
not supported for parsing'.

Fix: after downloading, check if the filename has a supported file
extension. If not, inspect the response Content-Type header and map
it to the correct extension using the existing ACCEPTED_MIMES table.

For example, a response with Content-Type: application/pdf will cause
the file to be saved with a .pdf extension, allowing it to be processed
correctly.

Fixes #4513

* small refactor

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2026-03-23 09:40:22 -07:00
Timothy Carambat
02ee24baac README updates (#5238)
* README updates

* Update README.md

* Update README.md

* remove unused images

* updates

* copy updates
2026-03-19 12:21:26 -07:00