Commit Graph

1717 Commits

Author SHA1 Message Date
timothycarambat
bdfa0328db update comment about parseOnly 2025-10-01 20:45:52 -07:00
Sean Hatfield
599a3fd8b8
Microsoft Foundry Local LLM provider & agent provider (#4435)
* add microsoft foundry local llm and agent providers

* minor change to fix early stop token + overloading of context window
always use user defined window _unless_ it is larger than the models real contenxt window
cache the context windows when we can from the API (0.7.*)+
Unload model forcefully on model change to prevent resource hogging

* add back token preference since some models have very large windows and can crash a machine
normalize cases

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2025-10-01 20:04:13 -07:00
Timothy Carambat
8f0f9df4fc
Migrate OpenAI Agent to use ResponsesAPI (#4467)
resolves #4465'
2025-10-01 16:07:30 -07:00
Marcello Fitton
f7b90571be
Fetch, Parse, and Create Documents for Statically Hosted Files (#4398)
* Add capability to web scraping feature for document creation to download and parse statically hosted files

* lint

* Remove unneeded comment

* Simplified process by using key of ACCEPTED_MIMES to validate the response content type, as a result unlocked all supported files

* Add TODO comments for future implementation of asDoc.js to handle standard MS Word files in constants.js

* Return captureAs argument to be exposed by scrapeGenericUrl and passed into getPageContent | Return explicit argument of captureAs into scrapeGenericUrl in processLink fn

* Return debug log for scrapeGenericUrl

* Change conditional to a guard clause.

* Add error handling, validation, and JSDOC to getContentType helper fn

* remove unneeded comments

* Simplify URL validation by reusing module

* Rename downloadFileToHotDir to downloadURIToFile and moved up to a global module | Add URL valuidation to downloadURIToFile

* refactor

* add support for webp
remove unused imports

---------

Co-authored-by: timothycarambat <rambat1010@gmail.com>
2025-10-01 15:49:05 -07:00
Marcello Fitton
004327264a
Add stream options to Gemini LLM for usage tracking (#4466)
* Add stream options to Gemini LLM for usage tracking

* Update Gemini LLM to disable prompt token calculation

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2025-10-01 14:00:26 -07:00
Timothy Carambat
d6f0d305ab
Enable real-time agent tool call streaming for all providers (#4279)
* WIP agentic tool call streaming
- OpenAI
- Anthropic
- Azure OpenAI

* WIP rest of providers EXCLUDES Bedrock and GenericOpenAI

* patch untooled complete/streaming to use chatCallback provider from provider class and not assume OpenAI client struct
example: Ollama

* modify ollama to function with its own overrides
normalize completion/stream outputs across providers/untooled

* dev build

* fix message sanization for anthropic agent streaming

* wip fix anthropic agentic streaming sanitization

* patch gemini, webgenui, generic aibitat providers + disable providers unable to test

* refactor anthropic aibitat provider for empty message and tool call formatting

* Add frontend missing prop check
update Azure for streaming support
update Gemini to streamting support on gemini-* models
generic OpenAI disable streaming
verify localAI support
verify NVIDIA Nim support

* DPAIS, remove temp from call, support streaming'

* remove 0 temp to remove possibility of bad temp error/500s/400s

* Patch condition where model is non-streamable and no tools are present or called resulting in the provider `handleFunctionCallChat` being called - which returns a string.

This would then fail in Untooled.complete since response would be a string and not the expected `response.choices?.[0]?.message`

Modified this line to handle both conditions for stream/non-streaming and tool presence or lack thereof

* Allow generic Openai to be streamable since using untooled it should work fine
honor disabled streaming for provider where that concern may apply for regular chats

* rename function and more gemini-specific function to gemini provider

* add comments for readability
.complete on azure should be non-streaming as this is the sync response

* migrate CometAPI, but disable as we cannot test

---------

Co-authored-by: shatfield4 <seanhatfield5@gmail.com>
2025-10-01 10:17:18 -07:00
Vansh
d24f9c3414
fix(uiux): correct typo in System Prompt description text (#4461)
* fix(uiux): correct typo in System Prompt description text

* translate

---------

Co-authored-by: timothycarambat <rambat1010@gmail.com>
2025-10-01 09:26:52 -07:00
Timothy Carambat
cd34063111
Patch OpenAI metrics (#4458)
resolves #4457
2025-09-30 15:19:34 -07:00
Timothy Carambat
be7e2b6bc6
Apply renderer from chat widget history to workspace chats (#4456)
Apply renderer from chat widget history to workspace chats #4455
resolves #4455
Fixes bug with codeblocks since hljs import was missing
2025-09-30 14:48:41 -07:00
timothycarambat
d800f8a073 Merge branch 'master' of github.com:Mintplex-Labs/anything-llm 2025-09-30 14:35:41 -07:00
timothycarambat
d1e39e1753 Fix issue where filenames with spaces could be marked as orphaned and pruned from threads they are attached to - resulting in the model not seeing a file during chat after the backend boots 2025-09-30 14:35:14 -07:00
Marcello Fitton
96bf127696
New Default System Prompt Variables (User ID, Workspace ID, & Workspace Name) (#4414)
* Fix system prompt variable color logic by removing unused variable type from switch statement and adding new types.

* Add workspace id, name and user id as default system prompt variables

* Combine user and workspace  variable evaluations into a single if statment, reducing redundant code.

* minor refactor

* add systemPromptVariable expandSystemPromptVariables test cases

---------

Co-authored-by: timothycarambat <rambat1010@gmail.com>
2025-09-29 14:32:56 -07:00
Marcello Fitton
7ca2753c24
Sanitize Metadata Before PG Vector Database Insertion (#4434)
* Fix JSDOC for updateOrCreateCollection

* Add sanitizeForJsonb method to PGVector for safe JSONB handling

This new method recursively sanitizes values intended for JSONB storage, removing disallowed control characters and ensuring safe insertion into PostgreSQL. The method is integrated into the vector insertion process to sanitize metadata before database operations.

* Add unit tests for PGVector.sanitizeForJsonb method

This commit introduces a comprehensive test suite for the PGVector.sanitizeForJsonb method, ensuring it correctly handles various input types, including null, undefined, strings with disallowed control characters, objects, arrays, and Date objects. The tests verify that the method sanitizes inputs without mutating the original data structures.

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2025-09-29 13:49:45 -07:00
Marcello Fitton
eb77876127
Add HTTP request/response logging middleware for development mode (#4425)
* Add HTTP request logging middleware for development mode

- Introduced httpLogger middleware to log HTTP requests and responses.
- Enabled logging only in development mode to assist with debugging.

* Update httpLogger middleware to disable time logging by default

* Add httpLogger middleware for development mode in collector service

* Refactor httpLogger middleware to rename timeLogs parameter to enableTimestamps for clarity

* Make HTTP Logger only mount in development and environment flag is enabled.

* Update .env.example to clarify HTTP Logger configuration comments

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2025-09-29 13:33:15 -07:00
AoiYamada
8fc1f24d1b
fix: youtube transcript collector not work well with non en or non asr caption (#4442)
* fix: youtube transcript collector not work well with non en or non asr caption

* stub YT test in Github actions

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2025-09-29 13:22:50 -07:00
Timothy Carambat
c8f13d5f27
Enable custom HTTP response timeout for ollama (#4448) 2025-09-29 12:32:55 -07:00
Marcello Fitton
ac444c8fa5
Change incorrect notation of Weaviate to PG Vector in env.example (#4439)
Change incorrect notation of Weaviate to PG Vector
2025-09-29 10:01:01 -07:00
Marcello Fitton
6855bbf695
Refactor Class Name Logging (#4426)
* Add className property to various LLM and embedder classes to fix logging bug after minification

* Fix bug with this.log method by applying the missing private field symbol
2025-09-25 15:34:19 -10:00
Neha Prasad
473ff9068a
fix: resolve Firefox search icon overlapping placeholder text (#4390)
* fix: resolve Firefox search icon overlapping placeholder text

- Increase input left padding from pl-4 to pl-9 to provide clearance
- Remove redundant placeholder:pl-4 class
- Ensures 24px spacing between search icon and text content

* Update SearchBox component to adjust padding on focus state

---------

Co-authored-by: neha <neha@posthog.com>
Co-authored-by: angelplusultra <macfittondev@gmail.com>
Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2025-09-25 15:27:37 -10:00
Marcello Fitton
2226f29a96
Add PostgreSQL vector extension in createTableIfNotExists function (#4430)
* Add PostgreSQL vector extension in createTableIfNotExists function

* move extension sql to function

---------

Co-authored-by: shatfield4 <seanhatfield5@gmail.com>
Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2025-09-25 15:16:03 -10:00
Spencer Bull
3cb54fdb9c
[BUGFIX] Update Dell Pro AI Studio Default URL (#4433)
Update DPAISOptions component and constants to use new OpenAI endpoint (#4432)

- Changed placeholder in DPAISOptions component to reflect updated endpoint.
- Updated DPAIS_COMMON_URLS in constants to include '/openai' in URLs.
2025-09-25 13:47:18 -10:00
Timothy Carambat
9466f67162
Update the timeout value on all stream-timeout providers: (#4412)
- OpenRouter
- Novita
- CometAPI
updated to 3,000ms default with 500ms min
2025-09-19 08:52:20 -07:00
Sean Hatfield
1209606d9a
Migrate OpenAI LLM provider to use Responses API (#4404)
* migrate openai llm provider to use responses api

* add back image support

* dont recalc tokens from OpenAI since we get metrics back

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2025-09-18 21:15:19 -07:00
Sean Hatfield
f0cdea4e35
Ignore hasOwnProperty linting errors (#4406)
ignore hasOwnProperty linting errors
2025-09-18 19:16:52 -07:00
Máté Kristóf
01a3cc92d0
Enhanced Chat Embed History View (#4281)
* Enhanced Chat Embed History View

* Robust Markdown Rendering
Improved "Thinking" View

* feat: Improve markdown rendering in chat embed history

* update ui for show/hide thoughts in embed chat history

* refactor -always show thoughts if available

* patch unused imports and use safeJsonParse

* update fallback for loading state to always reset

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
Co-authored-by: shatfield4 <seanhatfield5@gmail.com>
2025-09-17 21:14:18 -07:00
Chaser Huang
226802d35a
API request delay for Generic OpenAI embedding engine (#4317)
* Add ENV to configure api request delay for generic open ai embedding engine

* yarn lint formatting

* refactor

---------

Co-authored-by: timothycarambat <rambat1010@gmail.com>
2025-09-17 20:53:41 -07:00
Timothy Carambat
95557ee16f
Allow user to specify args for chromium process so they dont need SYS_ADMIN on container. (#4397)
* allow user to specify args for chromium process so they dont need SYS_ADMIN perms

* use arg flag content

* update console outputs
2025-09-17 16:31:08 -07:00
Timothy Carambat
7864e1a970
Report sources in API responses on finalized chunk (#4396) 2025-09-17 15:16:35 -07:00
Marcello Fitton
50d4a198a4
Add User-Agent header on the requests sent by Generic OpenAI providers. (#4393)
* Add User-Agent header on the requests sent by Generic OpenAI providers.

* Moved getAnythingLLMUserAgent helper fn to server/endpoints/utils.js and changed fallback version string to "unknown"

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2025-09-17 13:08:18 -07:00
Timothy Carambat
e81bd471dd
patch folder name GET request response (#4395)
* patch folder name GET request response

* fix response cb
2025-09-17 13:05:11 -07:00
Timothy Carambat
cd063af4d1
Add support for SIMPLE_SSO_NO_LOGIN_REDIRECT config setting (#4394)
* Add support for `SIMPLE_SSO_NO_LOGIN_REDIRECT` config setting

* reset changes on simple page

* redirect at root

* remove paths change
2025-09-17 12:51:00 -07:00
Jonas Stawski
b8d4cc3454
Added metadata parameter to document/upload, document/upload/{folderName}, and document/upload-link (#4342)
* Added the ability to pass in metadata to the /document/upload/{folderName} endpoint

* Added the ability to pass in metadata to the /document/upload-link endpoint

* feat: added metadata to document/upload api endpoint

* simplify optional metadata in document dev api endpoints

* lint

* patch handling of metadata in dev api

* Linting, small comments

---------

Co-authored-by: jstawskigmi <jstawski@getmyinterns.org>
Co-authored-by: shatfield4 <seanhatfield5@gmail.com>
Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2025-09-17 11:17:29 -07:00
Timothy Carambat
9841deb513
update save file agent text (#4389)
resolves #4388
2025-09-16 19:00:49 -07:00
Sean Hatfield
a97b51496d
Resize chat textarea on paste (#4369)
resize chat textarea on paste
2025-09-16 16:35:06 -07:00
TensorNull
5922349bb7
feat: Implement CometAPI integration for chat completions and model m… (#4379)
* feat: Implement CometAPI integration for chat completions and model management

- Added CometApiLLM class for handling chat completions using CometAPI.
- Implemented model synchronization and caching mechanisms.
- Introduced streaming support for chat responses with timeout handling.
- Created CometApiProvider class for agent interactions with CometAPI.
- Enhanced error handling and logging throughout the integration.
- Established a structure for managing function calls and completions.

* linting

---------

Co-authored-by: timothycarambat <rambat1010@gmail.com>
2025-09-16 14:38:49 -07:00
timothycarambat
631dd2e7cd Update Sponsors README 2025-09-10 12:10:02 +00:00
timothycarambat
eb3cc98a3c update bare metal docs 2025-09-03 11:12:07 -07:00
beckeryuri
4f86a513fc
feat(i18n): add missing Portuguese (Brazil) translations (#4328)
* feat(i18n): add missing Portuguese (Brazil) translations

- Add missing translations for common UI elements
- Fix null values in pt_BR locale file
- Complete translation coverage for Portuguese Brazilian users

* normalized and verified

* linting

---------

Co-authored-by: timothycarambat <rambat1010@gmail.com>
2025-09-03 11:02:39 -07:00
Colin Perry
2500c94b83
Fix: missing edit icon for prompts (#4344)
consolidated duplicate handler to fix prompt icon behavior

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2025-09-03 10:44:27 -07:00
Sean Hatfield
e31465a639
Export image support for JSON and JSONL (#4359)
* export image support for json and jsonl

* add tests and cleanup functionality

* add test for convertTo prepare function

* comment

---------

Co-authored-by: timothycarambat <rambat1010@gmail.com>
2025-09-03 10:30:57 -07:00
timothycarambat
bb7d65f0eb patch missing options
resolves #4316
2025-08-20 10:51:14 -07:00
timothycarambat
6358d087c2 Fix /openai/models compat endpoint to return correct response schema
resolves #4295
2025-08-15 14:46:51 -07:00
Sean Hatfield
b44cf21caa
Allow default users to reorder workspaces (#4292)
* allow default users to reorder workspaces

* unneeded prop

---------

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2025-08-14 20:50:11 -07:00
timothycarambat
a4a84f9bdd forgot 1.8.5 tag :) 2025-08-14 17:43:55 -07:00
timothycarambat
e6a33ec091 patch paths 2025-08-14 13:40:57 -07:00
timothycarambat
0200e647b8 add back normalization + docs link 2025-08-14 11:43:04 -07:00
Ashika Anand Babu
43e5d04053
Update Security UI to match all other Settings (#4274)
* Update Security UI to match all other Settings

* Normalizing translations

* Running yarn lint

* Set back all the null values

* fix spacing + lint

* remap name

---------

Co-authored-by: timothycarambat <rambat1010@gmail.com>
2025-08-12 16:34:54 -07:00
Sean Hatfield
c6e1b9c3e2
Chroma Cloud vector db provider (#4273)
* add chroma cloud as new vector db provider

* update docker example env

* extend chroma class to chroma cloud

* update readme

---------

Co-authored-by: timothycarambat <rambat1010@gmail.com>
2025-08-12 16:21:14 -07:00
dp
a432f82b4a
Update common.js (#4278)
* Update common.js

Improving the Romanian translation and filling in missing elements.

* linting

---------

Co-authored-by: timothycarambat <rambat1010@gmail.com>
2025-08-12 16:18:15 -07:00
Neha Prasad
a230a44f5c
feat: Add Exa as a Search Provider (#4258)
* Added exa-search case to the search provider switch in web-browsing.js

* Added ExaSearchOptions component for API key input

* update

* Patch missing image crashing UI
Fix issue where ENV key did not exist or was saved on click
Update copy for provider
Add Docs for ENV keys for manual placements
update systemssettings for returning key saved to UI

---------

Co-authored-by: timothycarambat <rambat1010@gmail.com>
2025-08-11 09:46:50 -07:00