Commit graph

5,553 commits

Author SHA1 Message Date
Christophe Bornet
4e36dcc2ad
ref: Add ruff rules for print (T20) (#4082)
Add ruff rules for print (T20)
2024-10-09 22:28:28 +00:00
Christophe Bornet
de055f2113
ref: Add ruff rules for asyncio tasks references (RUF006) (#4079)
Add ruff rules for asyncio tasks references (RUF006)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-09 22:12:20 +00:00
Jordan Frazier
8aeb801d52
fix: exception locations in component classes (#4087)
* fix exception locations in component classes

* print cleanups

* remove randomdbs

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2024-10-09 19:58:42 +00:00
Gabriel Luiz Freitas Almeida
f74b58f22a
fix: Refactor import statements and enhance error logging (#4071)
* Refactor import paths for `get_patched_openai_client` in astra_assistants components

* Enhance error logging with file information in directory_reader.py

* Refactor MetaphorToolkit to use new input/output structure and update imports

* Enhance error message with code snippet preview in class validation function

* update import statements and refactoring input handling in JSON files.

* [autofix.ci] apply automated fixes

* Remove unused import of 'Tool' from Metaphor.py

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2024-10-09 18:58:20 +00:00
Gabriel Luiz Freitas Almeida
65153374ed
feat: Add default value support for table columns (#4043)
* Add 'type', 'description', and 'default' fields to Table schema and enhance formatter validation

* Add type-based mapping to formatter validator in table schema

* Add default value support for new table rows in TableNodeComponent

* Add optional 'description' and 'default' fields to ColumnField interface

* Add default value inference for table columns in utils.ts

- Initialize 'default' property for table columns to null.
- Infer default value from the first row of data if available.
- Adjust column formatter determination based on sample value.

* Add default table input validation and update formatter logic in Column model

* Add unit tests for Column class in table schema module

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-09 17:10:40 +00:00
Cristhian Zanforlin Lousa
90b2c9d577
fix: rollback truncate values on transaction/vertex tables (#4078)
📝 (model.py): Add field serializers to truncate long strings in outputs, data, and artifacts fields for better data handling and readability.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-09 16:27:23 +00:00
Edwin Jose
f6e09dacb3
fix: alembic revision autogenerate script (#4069)
* update

Autogenerated code for alembic update

run alembic revision --autogenerate

* updated script

run alembic revision --autogenerate -m

* Update e4aaf16201c2_update_description_columns_type_errors.py

updated the reviews and checks if the table exists or not.

* update

Autogenerated code for alembic update

run alembic revision --autogenerate

* updated script

run alembic revision --autogenerate -m

* Update e4aaf16201c2_update_description_columns_type_errors.py

updated the reviews and checks if the table exists or not.

* replace revision

* Delete e4aaf16201c2_update_description_columns_type_errors.py

* Update 5ace73a7f223_new_remove_table_upgrade_op.py

making relevant change to remove vertex_build related upgrades and downgrades.

---------

Co-authored-by: Jordan Frazier <jordan.frazier@datastax.com>
2024-10-09 09:17:17 -07:00
Christophe Bornet
8ddab95ac4
ref: Add ruff rules for TRY2 and TRY002 (#4077)
Add ruff rules for TRY2 and TRY002
2024-10-09 14:04:00 +00:00
Christophe Bornet
66be632086
ref: Add ruff rules for blind exceptions (BLE) (#4076)
Add ruff rules for blind exceptions (BLE)
2024-10-09 15:40:53 +02:00
João
04fa6351a2
fix: refactoring Merge Data component (#4059)
* fix: refactoring Merge Data component to properly mesrge different Data objects

* fix: refactoring Merge Data component to properly mesrge different Data objects

* fix: refactoring MergeData active component
2024-10-08 21:40:45 +00:00
Christophe Bornet
d4818a37ee
ref: Add ruff rules for pygrep-hooks (PGH) (#4042)
Add ruff rules for pygrep-hooks (PGH)
2024-10-08 23:06:20 +02:00
Christophe Bornet
da6b5eadbc
ref: Fix ruff rules in preview mode (#4039)
Fix some ruff rules from preview mode
2024-10-08 19:31:13 +00:00
Christophe Bornet
ba6838c13c
ref: Use TypeError instead of ValueError when relevant (TRY004) (#4045)
Use TypeError instead of ValueError when relevant (TRY004)
2024-10-08 19:10:57 +00:00
Christophe Bornet
f01ea48d61
ref: Add ruff rules for pylint (PL) (#4032)
* Add ruff rules for pylint (PL)

* Changes following review
2024-10-08 17:56:49 +02:00
Christophe Bornet
06c8e3d6c8
ref: Select ALL ruff rules with exclusions (#4040)
Select ALL ruff rules with exclusions
2024-10-08 14:26:53 +00:00
Gabriel Luiz Freitas Almeida
e84148ed6d
refactor: change model name extraction to use list comprehension (#4067)
Refactor model name extraction to use list comprehension for improved readability
2024-10-08 06:05:37 -07:00
Marcelo Nunes Alves
bffb0f129b
fix: Update the columns that need to change their type to text (MySQL e MariaDB) (#4026)
* fix: Update the columns that need to change their type to text

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2024-10-08 04:38:25 -07:00
Sebastián Estévez
9adf1ef2e5
Feat: Shared Component Cache Service (#4052)
split branch / PR
2024-10-07 20:58:42 -04:00
Cristhian Zanforlin Lousa
7b3a8b829c
fix: add range_spec to AssemblyAITranscriptionJobPoller (#4061)
 (AssemblyAIPollTranscript.py): introduce RangeSpec field typing to define a range for polling interval in seconds
2024-10-07 21:29:13 +00:00
Christophe Bornet
ee3035be28
ref: Add ruff rules for perf (PERF) (#4047)
Add ruff rules for perf (PERF)
2024-10-07 21:08:36 +00:00
Ítalo Johnny
3e3d38a874
fix: missing 'field' argument in get_variable (#4041) 2024-10-07 20:58:16 +00:00
Ítalo Johnny
f9b014f5f8
fix: add validation for log_file settings field (#4050)
fix: add validation for log_file field
2024-10-07 17:54:06 -03:00
Ítalo Johnny
f7e58f96b0
fix: prevent langfuse initialization (#4057) 2024-10-07 20:38:28 +00:00
Eric Hare
3ea7be12e9
FIX: don't error when adding to canvas (#4055) 2024-10-07 20:25:17 +00:00
Edwin Jose
4ed00cdf0e
fix: NameError for Vertex and Graph Imports in Flow Tool (#4054)
* Update flow_tool.py

- Removed unnecessary imports from TYPE_CHECKING block.
- Cleaned up import statements for better readability and organization.

* Update flow_tool.py
2024-10-07 19:42:40 +00:00
Jordan Frazier
b0bda283ff
Revert "release: bump main 1.0.19 and base 0.0.97" (#4044)
Revert "release: bump main 1.0.19 and base 0.0.97 (#4029)"

This reverts commit b4828622bb.
2024-10-07 08:01:43 -07:00
Christophe Bornet
a021009ee5
ref: Add ruff rules for Pathlib (PTH) (#4035)
Add ruff rules for Pathlib (PTH)
2024-10-07 12:24:00 +00:00
Christophe Bornet
32b5da8d1f
ref: Propagate traceback in exception logs (#4030)
Propagate traceback in exception logs
2024-10-07 14:16:58 +02:00
EDllT
79a1257b7d
fix: modified DirectoryDataComponent to support user defined custom file types (#4017)
test_data_components.py: Updated 'test_directory_component_build_with_multithreading' to expect an extra argument
2024-10-07 04:28:12 -07:00
Jordan Frazier
b4828622bb
release: bump main 1.0.19 and base 0.0.97 (#4029)
Bump to version main 1.0.19 and base 0.0.97
2024-10-04 17:24:34 -07:00
Ítalo Johnny
e07892a88e
fix: update variable fields (#4022) 2024-10-04 16:49:36 -03:00
Cristhian Zanforlin Lousa
b10708194b
fix: remove truncate to save data on DB (#4025)
🔧 (model.py): Remove unused imports and functions related to truncating long strings in database models to clean up the code and improve readability.
2024-10-04 19:48:40 +00:00
Gabriel Luiz Freitas Almeida
54dd81a681
chore: removes Poetry references from pyproject.toml and updates the project metadata (#4019)
* Remove Poetry references from pyproject.toml and update project metadata

* Remove '--no-update' flag from 'uv lock' commands in Makefile

* Add script metadata with Python version and dependencies

* Remove Poetry references and integrate UV setup in CI workflow

* Remove Poetry setup and installation from integration tests workflow

* Remove Poetry references and update workflow to use custom setup action

* Remove references to Poetry from configuration files
2024-10-04 17:24:55 +00:00
Jordan Frazier
7fe478e4b1
fix: set folder id on flows imported on startup (#4018)
* set folder id on flows imported on startup
---------

Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
2024-10-04 17:19:08 +00:00
Marcelo Nunes Alves
b7aed91ad9
feat: Add Redis Chat Memory (#3832)
* feat: Add Redis Chat Memory

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Refactor password handling in RedisIndexChatMemory to use a local variable

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
2024-10-04 17:06:47 +00:00
Christophe Bornet
63beae1833
ref: Add ruff rules RUF (#4001)
Add ruff rules RUF
2024-10-04 15:01:56 +00:00
Christophe Bornet
e2d907f3c5
Add ruff rules for TYPE_CHECKING (TCH) (#3999) 2024-10-04 16:00:09 +02:00
Ítalo Johnny
0298596b64
fix: add user_id to component parameters to fix build (#4016) 2024-10-03 17:55:23 -03:00
Gabriel Luiz Freitas Almeida
b6546e456e
feat: add 'tags' column to 'flow' table and update models (#3986)
* Add 'tags' column to 'flow' table and update models

- Added migration script to include 'tags' column in 'flow' table.
- Updated `Flow` model to include `tags` field.
- Introduced `Tags` enum in `schema.py` for predefined tag values.

* Update `tags` column to use JSON type in Flow model

* Add conditional checks for 'tags' column in Alembic migration script

* Make 'tags' field nullable in Flow model

* Add default value for 'tags' field in Flow model

* Update default values for 'tags' field in Flow model
2024-10-03 11:20:38 -07:00
Gabriel Luiz Freitas Almeida
e395cb7f4b
chore: Add type annotation for 'status' and format multiline string in TavilyAISearch tool (#4011)
* Format multiline string in TavilySearchToolComponent description

* Add type annotation for 'status' and import 'Any' in TavilyAISearch tool
2024-10-03 17:59:57 +00:00
namastex888
350189c88d
feat(tools): add TavilyAI search tool for enhanced LLM search results (#3774)
* add tavily new icon

* feat(tools): add TavilyAI search tool for enhanced LLM search results

* [autofix.ci] apply automated fixes

* add tavily icon

* [autofix.ci] apply automated fixes

---------

Co-authored-by: cristhianzl <cristhian.lousa@gmail.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
2024-10-03 17:38:44 +00:00
Swastik-Swarup-Dash
8a84299a47
fix: modified QdrantVectorStoreComponent to use server_kwargs correctly (#3751)
* resolveQdrant Vector Store doesnt' use the advanced fields when ingesting documents #3749

* resolveQdrant Vector Store doesnt' use the advanced fields when ingesting documents #3749

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2024-10-03 10:25:03 -07:00
Ítalo Johnny
ed7ec6a332
feat: improve CLI parameter handling and cleanup unused code (#4002)
* chore: remove envvar parameter from CLI option

* chore: add show_default=False flag to CLI option

* chore: update argument type to accept None

* feat: add missing Settings to CLI options

* feat: add default path value for components

* chore: rename CLI parameters to match Settings

* feat: update function to enforce parameter hierarchy

CLI > specific env_file > default env_file

* fix: adjust CLI parameter code to pass unit tests

* fix: mypy error arg-type

* fix: little ajustments
2024-10-03 16:10:04 +00:00
Cezar Vasconcelos
b8e7a77d78
feat: Add new Data utility components for CSV/JSON parsing, routing, and filtering (#3776)
* feat: Add CurrentDateComponent for timezone-based date

* feat: Add DataConditionalRouter component

* feat: Add DataFilterComponent for filtering data

* feat(components): Add beta and name attributes to components

* feat: Add JSON to Data component

* feat: Add CSV to Data component

* feat(helpers): Add ExtractKey component for key extraction

* feat: Add list processing to DataConditionalRouter

* [autofix.ci] apply automated fixes

* feat: add MessageToData component

* feat(CSVtoData, JSONtoData): Add file input support

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Refactor error messages and improve code readability in data components utilities

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
2024-10-03 15:48:57 +00:00
Edwin Jose
461238aa0e
fix: Add session_id Parameter to run_flow_from_json Function (#3989)
This pull request fixes the `run_flow_from_json` function by adding  `session_id` parameter. This update ensures that session management is properly handled during flow execution.

Changes include:
- Added `session_id` as an optional input parameter.
- Updated function documentation to reflect the inclusion of the new parameter.
- Added unit test for run_flow_from_json input parameters

This fix enhances the function's usability by allowing for better tracking of individual sessions.
2024-10-03 15:43:31 +00:00
João
75ffe0b11b
feat: Add Elasticsearch VectorStore Component with Ingest and Advanced Search Capabilities (#3899)
* feat: adding Elasticsearch  VectorStore component code

* update: adding langchain-elasticsearch dependency

* update: adding langchain-elasticsearch dependency (ruff format fix)

* Add `langchain-elasticsearch` dependency to pyproject.toml

* Refactor type hints to use PEP 585 syntax in Elasticsearch vector store component

* Refactor ElasticsearchVectorStoreComponent for improved readability and error handling

- Consolidated import statements and removed unused imports.
- Reformatted long strings for better readability.
- Enhanced error messages with variable assignment for clarity.
- Removed redundant else clause in search_documents method.

---------

Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
2024-10-03 15:41:30 +00:00
namastex888
11283655fe
feat(YahooFinanceTool): enhance tool with new inputs for data retrieval methods (#3738)
* feat(YahooFinanceTool): enhance tool with new inputs for data retrieval methods

* test: fix test

* test: fix test units

* test: fix import

* fix: rename component

* Fix instantiation of YfinanceToolComponent in complex_agent.py

---------

Co-authored-by: italojohnny <italojohnnydosanjos@gmail.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
2024-10-03 08:33:28 -07:00
Christophe Bornet
b591d7105e
ref: Add ruff rules for builtins (A) (#4004)
Add ruff rules for builtins (A)
2024-10-03 14:26:27 +00:00
Christophe Bornet
528e676e56
ref: Add ruff rules for datetime (DTZ) (#4003)
Add ruff rules for datetime (DTZ)
2024-10-03 14:22:25 +00:00
Christophe Bornet
a3a950c290
ref: Add more ruff rules (#3994)
Add more ruff rules
2024-10-03 08:55:49 +00:00