* feat: add base64 document attachment support to API chat endpoints
* remove parsed documents from api chat process
linting for simplicity
fix logic issues with flow of data through the pipeline
documentiation
* change var scope
---------
Co-authored-by: timothycarambat <rambat1010@gmail.com>
* 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>
* allow custom headers in upload-link endpoint
* override loader.scrape to allow for passing of headers in langchain puppeteer
* lint
* Rename some variables
move positional args to named args
update documentation to reflect arg changes and funciton sigs
validate header object before attempting to end to forward to request
* update header validation for custom headers
---------
Co-authored-by: timothycarambat <rambat1010@gmail.com>
* enable slash commands in dev api
* lint
* Remove ability to use default slash commands in API request
Add `reset` param to body that can reset chats according to the api chat execution parameters
Allow null `message` if `reset` is set in request.
Added early return for if message is null and reset is true
Enable chat to reset chat history and continue `message` execution
Added generic WorkspaceChat history reset function. Deprecated others
* update grep function comment
remove debug
---------
Co-authored-by: timothycarambat <rambat1010@gmail.com>
* feat: Add endpoint to retrieve documents by folder name
* isWithin Check on path to prevent path traversal
* feat: Add endpoint to upload documents to a specified folder
* refactor upload to folder endpoint + update jsdoc for swagger
* linting
---------
Co-authored-by: timothycarambat <rambat1010@gmail.com>
Co-authored-by: shatfield4 <seanhatfield5@gmail.com>
* feat: Add endpoint to retrieve documents by folder name
* isWithin Check on path to prevent path traversal
---------
Co-authored-by: timothycarambat <rambat1010@gmail.com>
* add writible fields to dev api new workspace endpoint
* lint
* implement validations for workspace model
* update swagger comments
* simplify validations for workspace on frontend and API
* cleanup validations
---------
Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
* Add vector search API endpoint
* Add missing import
* Modify the data that is returned
* Change similarityThreshold to scoreThreshold
As this is what is actually returned by the search
* Removing logging (oops!)
* chore: regen swagger docs for new endpoint
fix: update function to sanity check values to prevent crashes during search
---------
Co-authored-by: Scott Bowler <scott@dcsdigital.co.uk>
* thread creation additional params name and slug, with api
* typo fix
* Rebuild openai Swagger docs
Handle validations for fields to prevent invalid field inputs for .new
Enforce sluggification of `slug` to prevent breaking of URL structs
---------
Co-authored-by: abrakadobr <abrakadobr@gmail.com>
* set message limit per user
* remove old limit user messages + unused admin page
* fix daily message validation
* refactor message limit input
refactor canSendChat on user to a method on user model
---------
Co-authored-by: timothycarambat <rambat1010@gmail.com>
* Refactor api endpoint chat handler to its own function
remove legacy `chatWithWorkspace` and cleanup `index.js`
* Add `sessionId` in dev API to partition chats logically statelessly
* WIP workspace threads developer api endpoints
* fix swagger docs
* fix broken endpoints and test on single/multi user modes
* support for chatting with workspace thread by userId
* update swagger json
* Update workspace.js
adds userId to the workspaceUsers function
* Update openapi.json
Updates the workspace/users API docs to display correct 200 response example, including userId, username, role and last update datetime.
* add user management endpoints to list all users via developer api
* rename users to user management in swagger docs
* linting
---------
Co-authored-by: timothycarambat <rambat1010@gmail.com>
* Enhance API - add GET for users with access to workspace
Adds GET request endpoint for retrieving a list of users with permissions to access the specified workspace
* Update Swagger for users with access to workspace
Adds swagger docs for the endpoint used to retrieve users with access to workspace. "v1/admin/workspaces/:workspaceId/users"
* add support for voyageai embedder
* remove unneeded import
* linting
* Add ENV examples
Update how chunks are processed for Voyage
use correct langchain import
Add data handling
---------
Co-authored-by: Timothy Carambat <rambat1010@gmail.com>