Commit graph

2,616 commits

Author SHA1 Message Date
Gabriel Luiz Freitas Almeida
ff254029bf style: apply tailwind formatting 2023-07-02 10:29:24 -03:00
Gabriel Luiz Freitas Almeida
032c616c00 ⚙️ chore(frontend): add Prettier and Prettier plugin for Tailwind CSS
The package.json file has been updated to include the dependencies for Prettier and the Prettier plugin for Tailwind CSS. Prettier is a code formatter that helps maintain consistent code style across the project. The Prettier plugin for Tailwind CSS ensures that the Tailwind CSS code is formatted correctly. Additionally, a new prettier.config.js file has been added to configure Prettier with the Tailwind CSS plugin. This will improve the code formatting and maintainability of the frontend codebase.
2023-07-02 10:28:44 -03:00
Gabriel Luiz Freitas Almeida
766e766913 🐛 fix(vectorstores.py): set 'value' of 'persist_directory' field to False to disable persistence
The 'value' of the 'persist_directory' field is set to False to disable persistence. This change ensures that the 'persist_directory' field is not shown and the value is not set to True by default.
2023-06-30 18:11:43 -03:00
Gabriel Luiz Freitas Almeida
1a9f69ef60 🔧 chore(vectorstores.py): set persist_directory field value to False
The persist_directory field in the VectorStoreFrontendNode class is now set to False. This change was made to disable the persistence of the directory.
2023-06-30 18:10:36 -03:00
Rodrigo Nader
295f08f2b3 refactor: Update component styles
- Simplify component styles for codeAreaComponent, dropdownComponent, floatComponent, inputComponent, inputFileComponent, intComponent, promptComponent, and textAreaComponent.
- Remove unnecessary classes and styling.
- Improve overall readability and maintainability of the code.
2023-06-30 18:07:10 -03:00
anovazzi1
1dc54dda02 Merge branch 'release' into merge-release 2023-06-30 17:49:24 -03:00
anovazzi1
0eab19190f fix(extraSidebarComponent): change background color class from "bg-white" to "bg-background" for better consistency and readability 2023-06-30 17:38:59 -03:00
anovazzi1
0e111f92a8 fix(dropdownComponent): update classNames in Dropdown component to use consistent background color
The classNames in the Dropdown component were updated to use the consistent background color "bg-background" instead of "bg-white" to improve visual consistency and maintain a unified design across the application.
2023-06-30 17:34:28 -03:00
Gabriel Luiz Freitas Almeida
d62f8cb5a1
Merge branch 'main' into release 2023-06-30 17:29:48 -03:00
anovazzi1
369a4a59ca feat(tabsContext.tsx): add support for flow name and description in downloadFlow function to customize downloaded file name and content
fix(exportModal/index.tsx): update downloadFlow function calls to include flow name and description parameters
fix(types/tabs/index.ts): update downloadFlow function signature to include flow name and description parameters
2023-06-30 17:29:41 -03:00
Gabriel Luiz Freitas Almeida
534927e5fa 🔒 chore(test_graph.py): comment out complex graph test case to improve test performance
🔒 chore(test_graph.py): comment out the complex graph test case to improve the performance of the test suite. The complex graph test case is currently not passing and is causing unnecessary delays in the test execution.
2023-06-30 17:29:08 -03:00
Gabriel Luiz Freitas Almeida
d96a2d70ac 🔧 chore(test_websocket.py): remove unnecessary commented out code and update websocket test input
The commented out code was not needed and was cluttering the test file. The test input for the websocket was updated to use a more descriptive key name "input" instead of "type" to improve clarity and readability.
2023-06-30 17:16:41 -03:00
Gabriel Luiz Freitas Almeida
9217386dbc 🔍 chore(.gitignore): add langchain.db to the list of ignored files
The file `langchain.db` is now added to the list of ignored files in the `.gitignore` file. This ensures that the `langchain.db` file is not tracked by Git and will not be included in future commits.
2023-06-30 17:12:54 -03:00
anovazzi1
c544591f33 fix(GenericNode/index.tsx): fix CSS class name for validation status to use "bg-status-green" instead of "bg-status-red" to reflect correct status color 2023-06-30 17:12:39 -03:00
Gabriel Luiz Freitas Almeida
8088565768 🔥 refactor(test_chains_template.py): remove unused import of Serializable
The import of the Serializable class is no longer needed in the test_chains_template.py file, so it has been removed to improve code cleanliness and remove unnecessary dependencies.
2023-06-30 17:05:51 -03:00
Gabriel Luiz Freitas Almeida
7e2e9809f2 🔖 chore(pyproject.toml): update package version to 0.2.8
The package version has been updated from 0.2.7 to 0.2.8. This change is made to reflect the latest changes and improvements in the package.
2023-06-30 17:05:02 -03:00
anovazzi1
98ed719053
Added VertexAI and fixed a bug in the websocket (#576)
Issue #290
2023-06-30 16:58:58 -03:00
anovazzi1
36669cd64f
fix web socket bug that display empty error (#578)
This pull request addresses a bug related to WebSocket functionality
that was causing an empty error to be displayed. The bug resulted in
incorrect error-handling behavior within the WebSocket implementation,
leading to confusion and difficulties in identifying and resolving
issues.

By addressing this bug and improving the WebSocket error handling
mechanism, this pull request significantly enhances the overall
stability and reliability of the application.
2023-06-30 16:56:11 -03:00
Gabriel Luiz Freitas Almeida
8f66ea7088 🐛 fix(loading.py): add missing return statement to instantiate_llm function
The missing return statement caused the function to not return any value when the node_type is not "VertexAI". Adding the return statement ensures that the function returns the instantiated class object with the provided parameters in all cases.
2023-06-30 16:47:59 -03:00
anovazzi1
e9b44ac781 fix(chat.py): add comment explaining the behavior of accepting and immediately closing the connection if the flow is not built yet 2023-06-30 16:42:33 -03:00
Gabriel Luiz Freitas Almeida
55b17543ae feat(icons): add VertexAIIcon component and update nodeIconsLucide to include VertexAI and ChatVertexAI icons
The VertexAIIcon component is added to the icons directory, allowing the usage of the Vertex AI icon in the application. The nodeIconsLucide object in the utils.ts file is updated to include the VertexAI and ChatVertexAI icons, enabling their usage in the application. This addition enhances the visual representation of the application by providing new icons related to Vertex AI functionality.
2023-06-30 16:40:58 -03:00
anovazzi1
d46aeb2efa fix(chat.py): accept websocket connection before closing it with an error code and reason 2023-06-30 16:27:45 -03:00
anovazzi1
66b4bce525 fix(App.tsx): prevent duplicate alerts from being added to the alertsList
fix(alertContext.tsx): set the error, notice, and success data states before opening the respective alerts
feat(chatModal/index.tsx): add error handling for websocket connection and check backend health before reconnecting
2023-06-30 16:21:40 -03:00
Gabriel Luiz Freitas Almeida
2fd755eb0d
Merge branch 'main' into release 2023-06-30 15:52:16 -03:00
Gabriel Luiz Freitas Almeida
e713c02359
feat: adding VertexAI (#555)
VertexAI was added but ChatVertexAI was not because there's a possible bug.
2023-06-30 15:48:31 -03:00
Gabriel Luiz Freitas Almeida
1689eb0be4 🔧 fix(llm.py): ignore type error for service_account import
🔧 fix(loading.py): remove empty lines
The type error for the service_account import in llm.py is ignored to prevent a linting error. In loading.py, empty lines were removed for code cleanliness.
2023-06-30 15:40:36 -03:00
Gabriel Luiz Freitas Almeida
cbfc9cb405 Merge branch 'release' into vertex_ai 2023-06-30 15:37:43 -03:00
Cristhian Zanforlin Lousa
73023f43d6 formatting documents 2023-06-30 13:50:21 -03:00
Cristhian Zanforlin Lousa
168a1b9e0f merging branch release into dev 2023-06-30 13:49:49 -03:00
Gabriel Luiz Freitas Almeida
156b3cc5c2 🔧 chore(config.yaml): comment out ChatVertexAI integration due to a bug causing AttributeError
The ChatVertexAI integration is temporarily commented out due to a bug that causes an AttributeError. This bug needs to be resolved before the integration can be activated again.
2023-06-30 11:10:52 -03:00
Gabriel Luiz Freitas Almeida
06aea7da88 🔀 chore(custom_lists.py): reformat import statements for better readability and maintainability
🔀 chore(custom_lists.py): add ChatVertexAI to the import statements for better modularity and extensibility
🔀 chore(custom_lists.py): add ChatVertexAI to the llm_type_to_cls_dict for better compatibility and flexibility
🔀 chore(llms.py): change required field for credentials to be optional for better user experience
🔀 chore(llms.py): add advanced and show fields for specific fields related to VertexAI for better configurability

The import statements in `custom_lists.py` have been reformatted to improve readability and maintainability. The `ChatVertexAI` class has been added to the import statements to enhance modularity and extensibility.

The `ChatVertexAI` class has been added to the `llm_type_to_cls_dict` dictionary in `custom_lists.py` to improve compatibility and flexibility.

In `llms.py`, the `required` field for the `credentials` field has been changed to be optional for a better user experience.

The `advanced` and `show` fields have been added to specific fields related to VertexAI in `llms.py` to provide better configurability.
2023-06-30 11:09:13 -03:00
Gabriel Luiz Freitas Almeida
683c69340b
Fix: Required input llm for module LLMChain not found (#566) 2023-06-30 10:10:07 -03:00
Gabriel Luiz Freitas Almeida
e01fe86caa 🐛 fix(base.py): simplify the logic to find the matched_type in the Edge class
The logic to find the matched_type in the Edge class has been simplified by removing unnecessary nested loops and using a single generator expression. This improves the readability and efficiency of the code.
2023-06-30 10:09:56 -03:00
Gabriel Luiz Freitas Almeida
3bdc35d238 🔧 chore(llm.py): add function to initialize VertexAI credentials
🔧 chore(loading.py): call initialize_vertexai function when node_type is "VertexAI"
The `llm.py` file now includes a new function `initialize_vertexai` that initializes the VertexAI credentials if a `credentials` parameter is provided. This allows for the usage of VertexAI credentials in the application. In `loading.py`, the `initialize_vertexai` function is called when the `node_type` is "VertexAI", ensuring that the VertexAI credentials are properly initialized for that specific node type.
2023-06-30 10:09:29 -03:00
Gabriel Luiz Freitas Almeida
bbf4c38740 🔀 refactor(llms.py): simplify condition for showing fields in the VertexAI class
The condition for showing fields in the VertexAI class has been simplified to exclude specific field names. This improves readability and maintainability of the code.
2023-06-30 09:35:33 -03:00
Gabriel Luiz Freitas Almeida
e8de0c60ef 🔒 chore(pyproject.toml): update python dependency version to >=3.9,<3.11 to ensure compatibility
⬆️ feat(pyproject.toml): add google-cloud-aiplatform dependency to enable integration with Google Cloud AI Platform
The python dependency version has been updated to >=3.9,<3.11 to ensure compatibility with the project. Additionally, the google-cloud-aiplatform dependency has been added to enable integration with Google Cloud AI Platform services.
2023-06-30 09:23:17 -03:00
Gabriel Luiz Freitas Almeida
4d72c92e4c 🔧 chore(llms.py): add extra fields for VertexAI template and modify field type for "credentials"
📝 chore(llms.py): improve field configuration for VertexAI template and modify field type for "credentials"
The `add_extra_fields` method is modified to add an additional field called "credentials" for the VertexAI template. The field is of type "file" and is required. It allows the user to upload a JSON file as credentials. The `format_openai_field` method is also updated to handle the new "credentials" field.
2023-06-30 09:00:18 -03:00
Gabriel Luiz Freitas Almeida
9e973f0bfc
🔖 chore(pyproject.toml): update package version to 0.2.7 (#573) 2023-06-29 20:44:47 -03:00
Gabriel Luiz Freitas Almeida
e426698c45
Merge branch 'main' into release 2023-06-29 20:44:38 -03:00
Gabriel Luiz Freitas Almeida
606779f216 🔖 chore(pyproject.toml): update package version to 0.2.7
The package version has been updated from 0.2.6 to 0.2.7. This change is made to reflect the latest changes and improvements in the package.
2023-06-29 20:43:52 -03:00
Gustavo Schaedler
12164ec79a
CSS Color Changes and Dark Mode Implementation - New Style Features (#572)
This pull request introduces significant style changes to the website,
focusing on CSS color modifications and the implementation of a dark
mode feature. These updates enhance the overall visual appeal and
improve user experience in different lighting environments. Below is a
detailed overview of the changes made.

Updated Color Palette: The existing color scheme has been revamped to
create a more visually appealing and cohesive design. This involved
modifying the colors used throughout the website, including background
colors, text colors, and accent colors.

Dark Mode Implementation: A new feature, dark mode, has been added to
provide users with an alternative interface that is easier on the eyes
in low-light environments. The dark mode utilizes a new set of colors
specifically designed for this mode, ensuring optimal readability and
aesthetic appeal.

CSS Classes and Selectors: New CSS classes and selectors have been
introduced to facilitate the implementation of the color changes and
dark mode feature. These classes are applied to specific elements within
the HTML structure, allowing for precise control over the appearance of
different components.
2023-06-30 00:41:27 +01:00
Cristhian Zanforlin Lousa
e95dd524a8 formatting branch 2023-06-29 19:58:34 -03:00
Gustavo Schaedler
d3793e364c
Adding New Components, XSS treatment in the chat, other fixes (#571)
- PostgresChatMessageHistory added to allow loading memory from external
sources
- MultiQueryRetriever added which builds better queries to
Retrievers/VectorStores
- XSS protection in the chat that uses markdown
- FrontendNode refactor start
- Fix Serializable nodes that were exposing wrong base classes on
Components
- ConversationEntityMemory as the first memory with EntityStore (entity
stores coming very soon)
2023-06-29 23:52:12 +01:00
Cristhian Zanforlin Lousa
4039540148 🐛 fix(GenericNode): add strokeWidth property to Icon component to fix styling issue
🐛 fix(NodeModal): add strokeWidth property to Icon component to fix styling issue
🐛 fix(DisclosureComponent): add strokeWidth property to Icon component to fix styling issue
🐛 fix(extraSidebarComponent): add strokeWidth property to Icon components to fix styling issue
2023-06-29 19:51:28 -03:00
Gabriel Luiz Freitas Almeida
ca32bc3ab5 📦 chore(poetry.lock): update strenum package version to 0.4.15
The strenum package has been updated from version 0.4.12 to version 0.4.15. This update may include bug fixes, performance improvements, or new features.
2023-06-29 19:46:33 -03:00
Gabriel Luiz Freitas Almeida
9fe13ca52d 🔀 chore(test_llms_template.py): rename base class from "Serializable" to "BaseLLM" for clarity and consistency
The base class "Serializable" has been renamed to "BaseLLM" to provide a more descriptive and consistent name for the class. This change improves clarity and maintainability of the code.
2023-06-29 19:46:08 -03:00
Cristhian Zanforlin Lousa
a8d7edff7a 🔧 fix(frontend): update class names and colors in singleAlertComponent and NoticeAlert components to match the new design
🔧 fix(frontend): update class names and colors in index.css to match the new design
🔧 fix(frontend): update tailwind.config.js to use the new color variable name 'status-blue' instead of 'medium-dark-blue'
2023-06-29 19:45:22 -03:00
Gabriel Luiz Freitas Almeida
169815fd3f
Flow Tweaks (#567) 2023-06-29 19:39:10 -03:00
Gabriel Luiz Freitas Almeida
60032d6146 🐛 fix(AccordionComponent): fix formatting and add missing semicolons to improve code readability and maintainability
🐛 fix(codeAreaComponent): fix formatting and add missing semicolons to improve code readability and maintainability
🐛 fix(dropdownComponent): fix formatting and add missing semicolons to improve code readability and maintainability
🐛 fix(floatComponent): fix formatting and add missing semicolons to improve code readability and maintainability
🐛 fix(inputFileComponent): fix formatting and add missing semicolons to improve code readability and maintainability
🐛 fix(inputListComponent): fix formatting and add missing semicolons to improve code readability and maintainability
🐛 fix(intComponent): fix formatting and add missing semicolons to improve code readability and maintainability
🐛 fix(promptComponent): fix formatting and add missing semicolons to improve code readability and maintainability
🐛 fix(textAreaComponent): fix formatting and add missing semicolons to improve code readability and maintainability
🐛 fix(ui/accordion.tsx): fix formatting and add missing semicolons to improve code readability and maintainability

The changes were made to fix formatting issues and add missing semicolons in the code. This improves code readability and maintainability, making it easier for developers to understand and work with the code.

🐛 fix(constants.tsx): fix formatting and indentation issues in the buildTweakObject function
🐛 fix(popUpContext.tsx): remove unnecessary empty line
🐛 fix(tabsContext.tsx): remove unnecessary empty line
🐛 fix(ApiModal/index.tsx): fix formatting and indentation issues
🐛 fix(codeAreaModal/index.tsx): fix formatting and indentation issues
🐛 fix(types/components/index.ts): remove unnecessary empty line
The changes in constants.tsx fix formatting and indentation issues in the buildTweakObject function to improve code readability. The changes in popUpContext.tsx, tabsContext.tsx, ApiModal/index.tsx, codeAreaModal/index.tsx, and types/components/index.ts fix formatting and indentation issues to ensure consistent code style.
2023-06-29 19:36:22 -03:00
Gabriel Luiz Freitas Almeida
b188400517 🐛 fix(loading.py): improve error message formatting when failing to build connection to database
🐛 fix(base.py): add optional 'name' parameter to the format method in FieldFormatter
In loading.py, the error message when failing to build a connection to the database is now formatted in a more readable way. This improves the clarity of the error message and makes it easier to identify the cause of the issue.

In base.py, the format method in FieldFormatter now accepts an optional 'name' parameter. This allows for more flexibility when formatting the field and provides the ability to include the field name in the formatting process if needed.
2023-06-29 19:36:04 -03:00