Commit graph

5,500 commits

Author SHA1 Message Date
anovazzi1
b55d24101d Merge branch 'validation_fix' of personal:logspace-ai/langflow into validation_fix 2023-06-13 20:32:37 -03:00
Gabriel Luiz Freitas Almeida
8aac63b830 🐛 fix(chat.py): add try-except block to handle exceptions in init_build function
The try-except block was added to handle exceptions that may occur in the init_build function. If an exception occurs, it is logged and an HTTPException with a status code of 500 is returned. This ensures that the server does not crash and provides a more informative error message to the client.
2023-06-13 20:32:05 -03:00
anovazzi1
0b4925bddf Merge branch 'validation_fix' of personal:logspace-ai/langflow into validation_fix 2023-06-13 20:24:38 -03:00
Gabriel Luiz Freitas Almeida
044b01e6ad 🎨 style(chat.py): add status code 201 to init_build endpoint
The init_build endpoint now returns a status code of 201 to indicate that a new resource has been created. This improves the consistency of the API and makes it easier for clients to understand the response.
2023-06-13 20:23:44 -03:00
Lucas Oliveira
2def9b2e5e Merge branch 'db' into mainPage 2023-06-13 20:07:44 -03:00
Lucas Oliveira
bc254a8aee Added importing flow to the same flow 2023-06-13 20:07:08 -03:00
anovazzi1
78faae8372 Merge branch 'validation_fix' of personal:logspace-ai/langflow into validation_fix 2023-06-13 20:01:02 -03:00
Lucas Oliveira
97645884ab Added project settings modal 2023-06-13 20:00:46 -03:00
Gabriel Luiz Freitas Almeida
0259bf4acc 🎨 style(endpoints.py): rename get_load function to predict_flow for better semantics
The function name was changed to predict_flow to better reflect the functionality of the endpoint.
2023-06-13 19:53:00 -03:00
Lucas Oliveira
f1f36024e9 Added description to pages 2023-06-13 19:45:50 -03:00
Gabriel Luiz Freitas Almeida
8689c39c06 Merge remote-tracking branch 'origin/mainPage' into db 2023-06-13 19:43:56 -03:00
Gabriel Luiz Freitas Almeida
af8afea421 🚀 feat(chatComponent): update API endpoint for build stream
🚀 feat(vite.config.ts): add new API route for build stream
The API endpoint for the build stream has been updated to `/api/v1/build/stream/${flowId}` to improve consistency with the naming conventions. The `vite.config.ts` file has been updated to include the new API route for the build stream.
2023-06-13 19:42:30 -03:00
Lucas Oliveira
ddd0b05947 Added default description and redirected to new flow as soon as its created 2023-06-13 19:16:27 -03:00
Lucas Oliveira
b6757d3ac1 Removed unused functions 2023-06-13 19:10:26 -03:00
Lucas Oliveira
1a92ceca7e Added community page, fixed styling of buttons, added promise at AddFlow 2023-06-13 19:09:24 -03:00
anovazzi1
1a6406e394 Merge branch 'validation_fix' of personal:logspace-ai/langflow into validation_fix 2023-06-13 18:45:57 -03:00
anovazzi1
86751e0daf added try catch block on streamNodeData 2023-06-13 18:45:42 -03:00
Gabriel Luiz Freitas Almeida
ebf5568db0 🐛 fix(App.tsx): change fetch URL to match backend API endpoint
The fetch URL was changed to match the backend API endpoint. The previous URL was incorrect and caused the fetch request to fail.
2023-06-13 18:08:01 -03:00
Gabriel Luiz Freitas Almeida
52baae64e6 🔨 refactor(chatComponent): remove unused imports and variables, and extract postBuildInit function to API controller
 feat(API): add postBuildInit function to handle POST requests to /api/v1/build/init
The chatComponent file had unused imports and variables that were removed to improve code readability. The postBuildInit function was extracted to the API controller to improve code organization and maintainability. The function handles POST requests to /api/v1/build/init.
2023-06-13 18:05:11 -03:00
Gabriel Luiz Freitas Almeida
e07b7f546d
Update base.py 2023-06-13 17:31:53 -03:00
Gabriel Luiz Freitas Almeida
41f6aecda4 🔀 refactor(chat.py): import InitResponse and BuiltResponse from schemas module
🚀 feat(chat.py): add response models to /build/init and /build/{flow_id}/status endpoints
The InitResponse and BuiltResponse models are now imported from the schemas module to improve code organization. The /build/init and /build/{flow_id}/status endpoints now have response models to provide a clear understanding of the expected response.
2023-06-13 17:21:45 -03:00
Gabriel Luiz Freitas Almeida
cfbcedcf5f 🔖 chore(pyproject.toml): bump up version to 0.0.89
The version number in the pyproject.toml file has been updated from 0.0.87 to 0.0.89. This is a chore commit as it does not introduce any new features or fix any bugs, but rather updates the version number to reflect the changes made in the package.
2023-06-13 15:04:41 -03:00
Gabriel Luiz Freitas Almeida
188fd4ad0a 🐛 fix(custom.py): remove unnecessary type ignore comments
The type ignore comments are unnecessary as the code is already type annotated. Removing them improves code readability and maintainability.
2023-06-13 15:04:23 -03:00
gustavoschaedler
14757ca402 Rename agent - initialize_agent to AgentInitializer 2023-06-13 18:51:33 +01:00
Gabriel Luiz Freitas Almeida
09d4c89136 🐛 fix(loading.py): ensure metadata values are not None for Chroma class
The docstring for the CombineDocsChain class has been updated to reflect the correct function name. In the loading.py file, the instantiate_vectorstore function has been updated to ensure that metadata values are not None for the Chroma class. This is because Chroma requires all metadata values to not be None, and this fix ensures that the application will not encounter errors when using Chroma.
🐛 fix(custom.py): update docstring to reflect the correct function name
2023-06-13 14:07:27 -03:00
gustavoschaedler
144f2b470e Add New Chains: RetrievalQA, RetrievalQAWithSourcesChain, ConversationalRetrievalChain, CombineDocsChain 2023-06-13 17:05:40 +01:00
Gabriel Luiz Freitas Almeida
2d3428307e 🔨 refactor(constants.tsx): remove flowId from API_URL and add it to the headers as an Authorization token
The flowId is now passed as an Authorization token in the headers of the API request. This improves security as the flowId is not exposed in the URL. The API_URL now only contains the base URL without the flowId.
2023-06-13 12:49:41 -03:00
Gabriel Luiz Freitas Almeida
90a1dd9795 🔧 chore(process.py): refactor process_tweaks function to improve readability and maintainability
The process_tweaks function has been refactored to improve readability and maintainability. The function now takes in two parameters, graph_data and tweaks, and returns the modified graph_data. The tweaks parameter is a dictionary of dictionaries, where the key is the node id and the value is a dictionary of the tweaks. The function processes the graph data to add the tweaks by iterating over the nodes and checking if the node id is in the tweaks dictionary. If it is, the function applies the tweaks to the node by updating the template data with the new values. The function also prints a message to the console to indicate that a tweak has been applied.
2023-06-13 12:49:22 -03:00
Gabriel Luiz Freitas Almeida
faf44eca0e 🔧 refactor(schemas.py): add optional tweaks field to PredictRequest schema
The PredictRequest schema now includes an optional tweaks field, which is a dictionary of dictionaries. This field allows for additional customization of the prediction request, such as specifying tool names or descriptions. The tweaks field is optional, and if not provided, the default value is an empty dictionary. The schema_extra attribute has also been updated to include an example of the new tweaks field.
2023-06-13 12:49:11 -03:00
Gabriel Luiz Freitas Almeida
7cc14e83b8 🚀 feat(endpoints.py): add authentication to predict endpoint using HTTPBearer
🐛 fix(endpoints.py): change predict endpoint to use Flow object instead of flow_id
🐛 fix(endpoints.py): add support for processing tweaks in predict endpoint
The predict endpoint now requires authentication using HTTPBearer. The flow_id is now extracted from the bearer token instead of being passed as a parameter. This improves security as the flow_id is not exposed in the URL. The predict endpoint now uses the Flow object instead of the flow_id to retrieve the graph data. This improves code readability and reduces the number of database queries. The predict endpoint now supports processing tweaks, which allows for more flexibility in the processing of messages.
2023-06-13 12:48:52 -03:00
Lucas Oliveira
8b6af6b768 Undo and Redo icons changed 2023-06-13 11:41:41 -03:00
Lucas Oliveira
1452e9c7a2 added useUndoRedo to context and added Undo and Redo buttons to header 2023-06-13 11:41:03 -03:00
Cristhian Zanforlin Lousa
ab0209d399 Import shad dialog, CSS in general 2023-06-13 11:22:43 -03:00
Lucas Oliveira
1af07ec453 Fixed flow id after uploading to DB 2023-06-13 11:00:09 -03:00
Lucas Oliveira
809e4c5306 Merge branch 'mainPage' of github.com:logspace-ai/langflow into mainPage 2023-06-13 10:51:47 -03:00
Lucas Oliveira
d76d0b2d51 Upload and Download Flows done, fixed deleting flow bug 2023-06-13 10:51:10 -03:00
Gabriel Luiz Freitas Almeida
eb26216d51 🗑️ chore(langflow.db): remove langflow.db file
The langflow.db file was deleted. This commit removes the file from the repository.
2023-06-13 08:05:31 -03:00
Lucas Oliveira
74192c205c git ignore updated to ignore db 2023-06-12 22:10:57 -03:00
anovazzi1
513174fb3a scroll and general position bug fixed 2023-06-12 22:08:16 -03:00
Lucas Oliveira
35fea98301 Fixed bug with home page overflow 2023-06-12 21:47:56 -03:00
Lucas Oliveira
74954dd4b1 Fixed bug where flow disappears 2023-06-12 21:47:02 -03:00
Lucas Oliveira
91b243779c Added buttons on sidebar and fixed header visual bug 2023-06-12 21:46:21 -03:00
Lucas Oliveira
2d640c8e5a Back button added, chevron with dropdown added to flow name 2023-06-12 21:17:44 -03:00
Lucas Oliveira
e491064662 Removed menubar edit and file, added all into the project name 2023-06-12 20:44:35 -03:00
Gabriel Luiz Freitas Almeida
d14be904ad 🐛 fix(chat.py): raise HTTPException instead of returning JSONResponse on stream_build error
The function stream_build was returning a JSONResponse with an error message when an exception was raised. This is not the correct way to handle errors in FastAPI. Instead, we should raise an HTTPException with the appropriate status code and error message.
2023-06-12 20:43:55 -03:00
Gabriel Luiz Freitas Almeida
7b44b18726 🐛 fix(loading.tsx): fix broken link to the source of the Loading component
The React import is not used in the file, so it has been removed to improve code readability. The link to the source of the Loading component was broken, so it has been fixed to ensure that the component can be used properly.
🔥 chore(loading.tsx): remove unused React import
2023-06-12 20:40:44 -03:00
Gabriel Luiz Freitas Almeida
d300c0b428 💄 style(chat.py): reformat code to improve readability
The unused imports and exception handling for WebSocketDisconnect and WebSocketException were removed from the chat.py file. The code was reformatted to improve readability.
🔥 refactor(chat.py): remove unused imports and exception handling
2023-06-12 20:40:43 -03:00
anovazzi1
a41cc95abb added security check to avoid errors on building empty flows 2023-06-12 20:26:56 -03:00
anovazzi1
62b0b28b7f start websocket from chat only after build 2023-06-12 20:23:52 -03:00
Lucas Oliveira
83e592d4d7 fixed routing, working perfectly 2023-06-12 20:15:07 -03:00