Commit graph

10,452 commits

Author SHA1 Message Date
Matt Bajorek
5fe118a68a
Fix AWS deployment (#1893) 2024-05-19 17:13:22 -07:00
anovazzi1
75642cc2d6
"Fix allowExport prop in CodeTabsComponent and ApiModal" (#1918)
* fix(codeTabsComponent): add allowExport prop to CodeTabsComponent to conditionally
render ExportModal component based on the prop value
feat(apiModal): pass allowExport prop to CodeTabsComponent in ApiModal view
feat(types): add allowExport prop to codeTabsPropsType in components index file

* fix bug on delete edge
2024-05-19 17:12:47 -07:00
ogabrielluiz
09cfe156cc Add fallback_to_env_vars reference to code example 2024-05-19 16:50:07 -07:00
ogabrielluiz
0fd6660cf6 chore: Fix fallback to environment variables in loading.py
This commit fixes an issue in the `loading.py` file where environment variables were not being properly fallbacked to if not found in custom component keys. It also updates the documentation to inform users about the new feature of falling back to environment variables if the variable value is not found in custom component keys.
2024-05-19 16:28:21 -07:00
ogabrielluiz
b457f9c7c0 chore: Fix issue with tweak object being an array in ApiModal views 2024-05-19 16:12:31 -07:00
Gabriel Luiz Freitas Almeida
ec910f3bd7
Fix fallback to environment variables in loading.py (#1921)
* 🐛 (loading.py): Fix issue where environment variables were not being properly fallbacked to if not found in custom component keys
📝 (loading.py): Update documentation to inform users about the new feature of falling back to environment variables if variable value is not found in custom component keys

* add fallback_to_env_vars to build vertex
2024-05-19 11:21:45 -07:00
ogabrielluiz
c115f5b67d chore: Update README.md with Railway deployment templates 2024-05-17 16:26:03 -07:00
ogabrielluiz
2c79f35feb chore: Update README.md with Railway deployment templates 2024-05-17 16:18:58 -07:00
Gabriel Luiz Freitas Almeida
c3353bec37
Fix visited set bug in Graph class and refactor GenericNode component (#1917)
* format

* chore: Fix visited set bug in Graph class

* Refactor GenericNode component to improve build status handling
2024-05-17 15:28:02 -07:00
Lucas Oliveira
e43f56df32 Fixed dropdown going upwards 2024-05-17 20:55:59 +01:00
Mendon Kissling
fff9bd0e28
[Docs] - Playground (#1891)
Document running a flow with the Playground.
2024-05-17 14:59:08 -04:00
Mendon Kissling
24d98c6b1e cleanup-env 2024-05-17 14:27:35 -04:00
Mendon Kissling
2a13e24e93 cleanup 2024-05-17 14:08:45 -04:00
Mendon Kissling
8e221d31b4 Merge branch 'dev' into docs-playground 2024-05-17 14:02:20 -04:00
Mendon Kissling
1d8a2bbf5c
[Docs] - Global environment variables (#1885)
Document adding a global variable to a project.

Question - what does the generic/credential value control?
2024-05-17 13:59:56 -04:00
Mendon Kissling
e24f14cadc Merge branch 'dev' into docs-playground 2024-05-17 13:40:15 -04:00
Mendon Kissling
0110839277 interaction panel 2024-05-17 13:40:08 -04:00
Gabriel Luiz Freitas Almeida
b9fa68dcfb
feat: Add get_final_results_only parameter to build_records_from_result_data method (#1912)
* feat: Add get_final_results_only parameter to build_records_from_result_data method

The `build_records_from_result_data` method in the `SubFlowComponent` class now accepts a `get_final_results_only` parameter. This parameter controls whether the output will contain all outputs from the flow or only the final results. This change allows for more flexibility in handling the result data.
2024-05-16 16:50:00 -07:00
Gabriel Luiz Freitas Almeida
c4e60d71bc
Upgrade Python base image to 3.12 and add gcc as dependency (#1908)
* 🔧 (build_and_push.Dockerfile): Upgrade Python base image from 3.10 to 3.12 for compatibility and updated dependencies
🔧 (build_and_push.Dockerfile): Add gcc to the list of dependencies for building Python dependencies
🔧 (build_and_push.Dockerfile): Update pip install command to specify the exact path for the .tar.gz file
🔧 (build_and_push_base.Dockerfile): Upgrade Python base image from 3.10 to 3.12 for compatibility and updated dependencies
🔧 (build_and_push_base.Dockerfile): Add gcc to the list of dependencies for building Python dependencies
🔧 (build_and_push_base.Dockerfile): Update pip install command to specify the exact path for the .tar.gz file

* Merge remote-tracking branch 'origin/dev' into fix_docker_images
2024-05-16 00:27:07 -03:00
Gabriel Luiz Freitas Almeida
53dc025b5e
Changes default location for the database and adds the option to use the previous behavior (#1907)
* chore: Refactor loading of settings and handle missing keys

* chore: Update .env.example file with new configuration options

* Ignore database files in .gitignore

* Refactor loading of settings and handle missing keys

* Update DOWNLOAD_WEBHOOK_URL in base settings to use the correct URL for triggering flows in the Langflow store.

* 🐛 (base.py): Fix condition to copy existing database to new location only if SAVE_DB_IN_CONFIG_DIR is true

* 🐛 (base.py): update log message to accurately reflect the action being taken when creating a new database
2024-05-15 20:41:01 -03:00
Igor Carvalho
fdf1881f00
Refactor: Disable group button when its not possible to group (#1878) 2024-05-15 16:53:56 -03:00
Lucas Oliveira
06afef340e
Fixed Undo bug when adding edge to input with text (#1900) 2024-05-15 16:08:45 +02:00
Lucas Oliveira
d42925c16c Fixed Undo bug adding Skip Snapshot to function that resets inputs when disabled 2024-05-15 13:59:50 +02:00
anovazzi1
14ff98213d
add export flow on API modal and fix .env bug (#1896)
* feat(codeTabsComponent): add ExportModal component to enable exporting flow data in CodeTabsComponent

* refactor(service.py): update VariableService to handle environment variables with
whitespace by stripping the value before creating the variable

* chore: Update package versions to 1.0.0a33 and 0.0.44 for 'langflow' and 'langflow-base' respectively

* make lock
2024-05-14 19:23:36 -03:00
anovazzi1
30ac9fa05a Merge branch 'dev' of personal:logspace-ai/langflow into dev 2024-05-14 14:47:26 -03:00
anovazzi1
c464e16d28 refactor: Update expandGroupNode function to handle template proxy values 2024-05-14 14:47:20 -03:00
anovazzi1
3abc7eedc3
Fix duplicate group bug (#1859)
* fix duplicate group bug

* remove commented console.log
2024-05-14 14:46:44 -03:00
Mendon Kissling
9e01e1bfb0 cleanup 2024-05-14 10:50:11 -04:00
Mendon Kissling
f6a6241b66 initial-content 2024-05-13 18:37:39 -04:00
Mendon Kissling
3af526734c title 2024-05-13 15:07:13 -04:00
Mendon Kissling
d8c8f4db7a initial-content 2024-05-13 15:06:26 -04:00
Gabriel Luiz Freitas Almeida
1ea9fcde25 chore: Update package versions to 1.0.0a32 and 0.0.43 for 'langflow' and 'langflow-base' respectively 2024-05-13 11:11:04 -07:00
Gabriel Luiz Freitas Almeida
cdda788e0d
Add gpt-4o model (#1884)
This pull request adds the gpt-4o model to the existing list of models. The gpt-4o model is now available for use in the application.
2024-05-13 15:07:56 -03:00
Gabriel Luiz Freitas Almeida
8b873b78c9 Add gpt-4o model 2024-05-13 11:07:28 -07:00
Gabriel Luiz Freitas Almeida
da256785d0
refactor: Improve variable creation logic in VariableService (#1875)
* refactor: Improve variable creation logic in VariableService
2024-05-10 12:34:24 -03:00
Gabriel Luiz Freitas Almeida
e36901bb34 (pyproject.toml): update package versions to 1.0.0a31 and 0.0.42 for 'langflow' and 'langflow-base' respectively 2024-05-10 12:33:05 -03:00
Cristhian Zanforlin Lousa
c69f950cba
Migrate Tweaks Module to Zustand Library and Add All Flows (#1847)
*  (codeTabsComponent/index.tsx): refactor code to remove unnecessary code and improve readability
📝 (codeTabsComponent/index.tsx): update comments in source code to provide better understanding of the code logic
♻️ (apiModal/index.tsx): refactor code to remove unnecessary code and improve readability
📝 (apiModal/index.tsx): update comments in source code to provide better understanding of the code logic
🔧 (tweaksStore.ts): add new store for managing tweaks data

📝 (components/index.ts): update codeTabsPropsType to use array syntax for tweak and tweaksList properties for better readability and consistency
♻️ (utils/utils.ts): refactor toTitleCase function to remove unnecessary comma and improve code readability
♻️ (utils/utils.ts): refactor groupByFamily function to remove unnecessary comma and improve code readability
♻️ (utils/utils.ts): refactor getPythonApiCode function to remove unnecessary comma and improve code readability
♻️ (utils/utils.ts): refactor getCurlCode function to remove unnecessary comma and improve code readability
♻️ (utils/utils.ts): refactor getPythonCode function to remove unnecessary comma and improve code readability
♻️ (utils/utils.ts): refactor getWidgetCode function to remove unnecessary comma and improve code readability
♻️ (utils/utils.ts): refactor getFieldTitle function to remove unnecessary comma and improve code readability
♻️ (utils/utils.ts): refactor IncrementObjectKey function to remove unnecessary comma and improve code readability
♻️ (utils/utils.ts): refactor getSetFromObject function to remove unnecessary comma and improve code readability
♻️ (utils/utils.ts): refactor getRandomName function to remove unnecessary comma and improve code readability

* 📝 (codeTabsComponent/index.tsx): remove unnecessary whitespace in className
♻️ (codeTabsComponent/index.tsx): refactor code to improve readability and remove unnecessary code
♻️ (apiModal/index.tsx): refactor code to improve readability and remove unnecessary code
♻️ (tweaksStore.ts): refactor code to improve readability and remove unnecessary code
 (zustand/tweaks/index.ts): add types for tweaks store

*  (codeTabsComponent/index.tsx): refactor code to improve readability and remove unnecessary code
♻️ (codeTabsComponent/index.tsx): refactor code to improve readability and remove unnecessary code
♻️ (utils/utils.ts): refactor code to improve readability and remove unnecessary code

 (tweaks_test.spec.ts): add end-to-end test to check if tweaks are updating when something on the flow changes

* 🐛 (accordionComponent/index.tsx): fix variable name from 'trigger' to 'keyValue' for better clarity and readability
♻️ (accordionComponent/index.tsx): refactor code to use 'defaultValue' prop instead of manually setting the value in the AccordionItem component
🐛 (codeTabsComponent/index.tsx): remove unused 'openAccordions' function
♻️ (codeTabsComponent/index.tsx): refactor code to remove unnecessary condition for opening accordions in the onValueChange event handler
♻️ (codeTabsComponent/index.tsx): refactor code to remove unused 'open' prop in AccordionItem component
♻️ (codeTabsComponent/index.tsx): refactor code to remove unused 'openAccordion' state variable
♻️ (codeTabsComponent/index.tsx): refactor code to remove unused 'openAccordions' function call in the onValueChange event handler

* 🐛 (apiModal/index.tsx): remove unnecessary comma after ref parameter in ApiModal component
♻️ (apiModal/index.tsx): refactor code to improve readability and remove unnecessary commas in function parameters
 (apiModal/index.tsx): add conditional check before assigning values to tabs array to prevent errors when tabs is undefined or empty

* 🐛 (index.tsx): remove unnecessary defaultValue prop from Accordion component
♻️ (index.tsx): refactor AccordionItem component to remove defaultValue prop and simplify code

* 🐛 (apiModal/index.tsx): remove unnecessary comma after ref parameter in function signature
♻️ (apiModal/index.tsx): refactor code to improve readability and remove unnecessary comma after ref parameter in function signature

* refactor tweaks

*  (codeTabsComponent/index.tsx): add autoFocus prop to the tweaks switch to prevent it from automatically gaining focus when rendered
♻️ (codeTabsComponent/index.tsx): refactor classNames in the api-modal-according-display div to remove unnecessary whitespace
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api-modal-according-display div to improve readability and remove unnecessary parentheses
♻️ (codeTabsComponent/index.tsx): refactor mapping of templateFields in the api

* fix tests on tweaks
2024-05-10 12:30:45 -03:00
dependabot[bot]
71324440a2
Bump jinja2 from 3.1.3 to 3.1.4 (#1840)
Bumps [jinja2](https://github.com/pallets/jinja) from 3.1.3 to 3.1.4.
- [Release notes](https://github.com/pallets/jinja/releases)
- [Changelog](https://github.com/pallets/jinja/blob/main/CHANGES.rst)
- [Commits](https://github.com/pallets/jinja/compare/3.1.3...3.1.4)

---
updated-dependencies:
- dependency-name: jinja2
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-10 12:26:58 -03:00
dependabot[bot]
08c0732cfd
Bump werkzeug from 3.0.2 to 3.0.3 (#1841)
Bumps [werkzeug](https://github.com/pallets/werkzeug) from 3.0.2 to 3.0.3.
- [Release notes](https://github.com/pallets/werkzeug/releases)
- [Changelog](https://github.com/pallets/werkzeug/blob/main/CHANGES.rst)
- [Commits](https://github.com/pallets/werkzeug/compare/3.0.2...3.0.3)

---
updated-dependencies:
- dependency-name: werkzeug
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-10 12:26:44 -03:00
Gabriel Luiz Freitas Almeida
5ca1c22893
Add support for Python 3.12 (#1873)
* Add support for Python 3.12

* chore: Update Python version to 3.11 and DuckDB dependency to 0.10.2

* chore: fix mistral components lint

* Update SQLAgent and SQLExecutor imports to use langchain_community utilities

* Update langchain import to langchain_community

* Update langchain import to langchain_community

* 📝 (langflow/__main__.py): Import warnings module to suppress warnings during app execution
📝 (langflow/api/v1/schemas.py): Update timestamp field default value to use datetime.now with timezone.utc
📝 (auth/utils.py): Ignore warnings related to datetime.utcnow when decoding JWT tokens and creating refresh tokens
📝 (models/flow/model.py): Update updated_at field default value to use lambda function with timezone.utc
📝 (models/user/model.py): Update create_at and updated_at field default values to use lambda function with timezone.utc
2024-05-10 12:25:34 -03:00
cristhianzl
919db5d928 (raw-component): create a new raw component called RawComponent
📝 (raw-component): add a basic implementation of the RawComponent with a simple div element inside
2024-05-10 11:23:37 -03:00
h-arnold
12d1a9a426
Added MistralAI LLM and Embedding (#1865)
* Added Mistral AI LLM Model and added MistralAI embeddings.

* Added tracking to the new MistralAIEmbeddings.py and MistalModel.py

* Added MistralAI model specs and added the correct models list to the Mistral Model LLM component.

* Actually added the MistralAI model specs this time.
2024-05-09 15:54:16 -03:00
Mendon Kissling
561765c74c
[Docs] How to contribute components (#1838)
Document how to contribute components to Langflow.
2024-05-09 12:33:36 -04:00
Mendon Kissling
b0a96928f1 fix-folder-path 2024-05-09 12:28:02 -04:00
Mendon Kissling
a9a1259852 Merge branch 'dev' into docs-how-to-contribute-components 2024-05-09 12:23:49 -04:00
Mendon Kissling
436c290ee7 submit-to-store 2024-05-08 11:47:51 -04:00
Cristhian Zanforlin Lousa
b3fa552bf9
fix state error when is debouncing changes on integers inputs (#1848)
🐛 (index.tsx): fix missing line break after handleUpdateValues function
call
 (index.tsx): improve performance by debouncing handleUpdateValues
function call for certain types of parameters
📝 (parameterUtils.ts): update handleUpdateValues function to use
optional chaining for accessing template properties
🚀 (chatInputOutput.spec.ts): remove unused imports and commented code
🚀 (dragAndDrop.spec.ts): fix typo in test description
2024-05-08 11:56:29 -03:00
Gabriel Luiz Freitas Almeida
1a54582b95
Update ZepMessageReader and ZepMessageWriter to avoid 404 error (#1844)
* Update ZepMessageReader and ZepMessageWriter to avoid 404 error

* Update ZepMessageReader and ZepMessageWriter to use API Base Path option

* Update ZepMessageReader and ZepMessageWriter to fix API Base Path and avoid 404 error

* Update ZepMessageReader and ZepMessageWriter to use API Base Path option
2024-05-08 11:46:48 -03:00
Gabriel Luiz Freitas Almeida
fa87284937 Update starter projects 2024-05-08 10:30:33 -03:00
Rodrigo Nader
03f781c0f4
Refactor SplitText (#1836)
Refactor LCModelComponent status message formatting for better readability
2024-05-08 09:59:43 -03:00