Commit graph

5,833 commits

Author SHA1 Message Date
Gabriel Luiz Freitas Almeida
cd3848661a
fix: allow passing curly braces in messages to the Agent component (#4960) 2024-11-30 18:39:08 +00:00
Gabriel Luiz Freitas Almeida
ee37ce04ef
fix: Handle DataFrame serialization and export in langflow.io (#4956) 2024-11-30 18:15:03 +00:00
Cristhian Zanforlin Lousa
ce12ac096c
feat: Add toolset component utilities and refactor tool mode handling (#4946) 2024-11-30 18:10:36 +00:00
Soham
9cee720365
fix: composio component not updating config state on refresh (#4910)
* fix: not changing config state on refresh

* [autofix.ci] apply automated fixes

* fix ruff check

* fix:reverted change in cloudflare

* fix:removed unused code

* [autofix.ci] apply automated fixes

* removed commented code

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Edwin Jose <edwin.jose@datastax.com>
2024-11-29 16:34:49 -05:00
anovazzi1
f313bd248a
fix: Add icon SQLDatabaseComponent (#4756)
* refactor: Add icon to SpiderTool class in spider.py

* refactor: Add icon to SQLDatabaseComponent class in sql_database.py

* remove langchain icon in spider component
2024-11-29 20:50:59 +00:00
Gabriel Luiz Freitas Almeida
df7ee68210
fix: update sort logic to handle cycles when running component (#4957)
fix: handle cycle scenario by adjusting stop component logic in graph sorting

Co-authored-by: anovazzi1 <otavio2204@gmail.com>
2024-11-29 17:30:02 -03:00
Ítalo Johnny
22482d7258
fix: update temperature input type and set min/max values (#4939)
* fix: update input type and define its min and max values

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2024-11-29 20:02:50 +00:00
anovazzi1
f8c9ac3289
Refactor: Update Data class to handle different types of text inputs (#4938)
The Data class in the langflow schema has been updated to handle different types of text inputs. Previously, the page_content attribute was expected to be a string, but now it can also accept other types. If the input is already a string, it is used as is. Otherwise, it is converted to a string before being assigned to the page_content attribute of the Document object.

This change improves the flexibility and robustness of the Data class, allowing it to handle a wider range of input types.
2024-11-29 13:45:30 -03:00
Ítalo Johnny
3ed44430ef
test: re-enable unit test (#4455) 2024-11-29 13:23:50 +00:00
Gabriel Luiz Freitas Almeida
c99f2a35bd
fix: adds better boolean check for DataFrame and fixes output display (#4933)
* feat: Add DataFrameInput to inputs module

* feat: add DataFrame support and refactor array processing

* feat: add truth value testing for DataFrame class

* refactor: remove Python 2 compatibility method from DataFrame class
2024-11-28 17:58:50 -03:00
Christophe Bornet
c816832b44
fix: Use async_open in a few places (#4929)
Use async_open in a few places
2024-11-28 18:06:01 +00:00
Lucas Oliveira
79e3d3f50d
fix: removed beta from current date (#4901)
* Removed beta from current date

* [autofix.ci] apply automated fixes

* refactor: improve error message handling in CloudflareWorkersAIEmbeddings

* Fix filter sidebar test

---------

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-11-28 09:02:15 -08:00
Gabriel Luiz Freitas Almeida
f10dc27dfc
refactor: Remove load_from_db attribute from FIELD_FORMAT_ATTRIBUTES (#4884)
refactor: remove load_from_db attribute from template fields
2024-11-28 16:21:15 +00:00
Gabriel Luiz Freitas Almeida
712a43958c
fix: updates file size limit to use middleware and add tests for uploads (#4883) 2024-11-28 12:25:26 +00:00
Lucas Oliveira
2eec720a0c
fix: auto fix starter projects (#4907)
auto fix starter projects
2024-11-28 04:05:44 -08:00
Luis Felipe Salazar Ucros
cfc5365b73
feat: add sambanova component (#4908)
* feat: add sambanova component

* update param name

* add multimodal models

* feat: add sambanova icon

* feat: add sambanova

* feat: format

* feat: add sambanova import

* feat: add sambanova

* feat: add sambanova docs
2024-11-28 04:05:32 -08:00
Siavash Safi
5307f0683f
feat: add cloudflare workers ai embeddings (#3697) 2024-11-28 00:45:48 +00:00
Eric Hare
e38af369e5
fix: Use global var if available for api endpoint (#4909)
* fix: Use global var if available for api endpoint

* Update astradb.py
2024-11-28 00:39:23 +00:00
Eric Hare
6902f1611d
fix: Successfully return agents in the Sequential Crew Component (#4899)
* fix: return the agents list in the crew code

* fix: return the agents list in the crew code

* Update crew.py
2024-11-27 13:29:18 -08:00
Gabriel Luiz Freitas Almeida
e6ebe7e206
feat: Add DataFrameInput and refactor DataSet references (#4898)
* refactor: rename DataSet to DataFrame

* feat: add DataFrameInput type and update InputTypes definition

* feat: add DataFrame type to CUSTOM_COMPONENT_SUPPORTED_TYPES

* refactor: replace DataSet with DataFrame in schema and tests
2024-11-27 21:14:04 +00:00
Christophe Bornet
eb46bd4606
fix: Fix get_default_folder_id (#4893)
Fix get_default_folder_id
2024-11-27 12:41:28 -08:00
TarunAdvaithK
2a434f6844
feat: Add combinatorial reasoning as a component (#4782)
* Add Icosa's Combinatorial Reasoner as component under tools

* Remove temporary testing tool revert unit test script

* reverting changes to locks

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

* Moved combinatorial reasoner component to separate icosacomputing folder for Icosa's bundle

---------

Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2024-11-27 09:28:22 -08:00
Cezar Vasconcelos
4c35e0567a
fix: add missing component URLs in Component Maker (#4820)
* fix: missing component URLs

* add tags, gradient and icon to Custom Component Maker template

* Add descriptive error messages to project data assertions

---------

Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
2024-11-27 15:13:15 +00:00
Thomas Kraxner
1e6ada3a3a
feat: make log format configurable (#4851)
* made logformat configurable

* [autofix.ci] apply automated fixes

* documentation of log format env var

* log stuff at one place in documentation

* added documentation of log environment

* check for log format

* [autofix.ci] apply automated fixes

* just load log format on custom logenv

* [autofix.ci] apply automated fixes

* no more invalid whitespaces

* fixed br s with escape

* logging error in case of invalid format string

---------

Co-authored-by: Kraxner Thomas <thomas.kraxner@illwerkevkw.at>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2024-11-27 06:28:50 -08:00
Phil Miesle
2de119b8d5
feat: defaulting tool description to the flow description in Flow as Tool (#4873)
defaulting tool description to the flow description
2024-11-27 00:48:21 +00:00
Gabriel Luiz Freitas Almeida
7e88a4760b
feat: add easier initialization to DataSet (#4864)
* feat: enhance DataSet class with improved constructor and methods for better data handling

- Added custom constructor to support various input formats including lists of Data objects, dictionaries, and existing DataFrames.
- Introduced methods `add_row` and `add_rows` for adding single or multiple rows to the DataSet.
- Updated docstrings and examples for clarity and usability.
- Ensured compatibility with pandas DataFrame operations while preserving Data object structures.

* test: add comprehensive tests for DataSet initialization and row operations

* feat: add DataSet class to schema module

* refactor: simplify DataSet initialization and improve data validation
2024-11-27 00:01:08 +00:00
Cristhian Zanforlin Lousa
159f6e5906
fix: enable database loading for OpenAI API base URL in Instagram Copywriter (#4843)
* 🐛 (Instagram Copywriter.json): fix load_from_db field to be set to true instead of false to correctly load data from the database.

* 🐛 (setup.py): Fix condition to update component versions by excluding "load_from_db" attribute
🐛 (Instagram Copywriter.json): Fix incorrect "load_from_db" value for "api_key" and "openai_api_base" properties
2024-11-26 23:32:34 +00:00
Ítalo Johnny
cf30b88a91
fix: node display_name updates and display for users (#4875) 2024-11-26 21:58:06 +00:00
anovazzi1
907d9929e4
Fix: prevent infinity bug on agent (#4876)
* Fix error handling and logging in build_flow function

* Refactor: Update serialize_field function in utils.py

This commit refactors the serialize_field function in utils.py to handle additional data types. It now properly serializes BaseModel objects and dictionaries by recursively calling the serialize_field function on their values. Additionally, it ensures that all other data types are converted to strings before returning.

#4873

* update serialize
2024-11-26 21:48:00 +00:00
Gabriel Luiz Freitas Almeida
77289793c5
fix: handle different output formats in agent message processing (#4867)
* fix: handle different output formats in agent message processing

* fix: correct condition for handling Anthropic message output

* refactor: extract text output handling into separate function
2024-11-26 21:43:46 +00:00
Gabriel Luiz Freitas Almeida
1a057571c9
feat: introduces DataSet class to improve the experience with lists of Data (#4834)
* Add DataSet class to handle conversion between Data objects and DataFrame

* feat: enhance DataSet class with detailed docstrings and examples for better usability

* feat: add custom constructor property to DataSet for improved DataFrame compatibility

* test: add unit tests for DataSet class methods and functionality
2024-11-26 05:04:44 -08:00
Phil Miesle
97fe69c12c
Expanding Unstructured loader to take server file inputs, more file types, and API parameters (#4738)
* adding ability for APIRequest to retry and save to a file

* [autofix.ci] apply automated fixes

* adding ability for APIRequest to retry and save to a file

* [autofix.ci] apply automated fixes

* initial refactor of FileComponent to handle Data input

* shifting potentially common logic into BaseFileComponent

* improving readability and fixing problems

* [autofix.ci] apply automated fixes

* addressing linting

* [autofix.ci] apply automated fixes

* linting part 2

* [autofix.ci] apply automated fixes

* linting part 3

* preserve input fields on data objects

* [autofix.ci] apply automated fixes

* ensuring processed data is linked to correct file data object

* [autofix.ci] apply automated fixes

* addressing linting

* [autofix.ci] apply automated fixes

* refactor Unstructured to BaseFileComponent

* [autofix.ci] apply automated fixes

* linting

* refactor to new BaseData

* adding chunking strategy selector

* [autofix.ci] apply automated fixes

* fixing edge case

* allowing specific failure of missing file without forcing silent_errors

* [autofix.ci] apply automated fixes

* Fix mypy issues

* Update unstructured.py

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Eric Hare <ericrhare@gmail.com>
2024-11-25 21:07:25 -08:00
Phil Miesle
8e55a0e5f4
feat: new AlterMetadataComponent enhances Data and Message objects with dict or Data object entries (#4634)
* creating AddMetadataComponent

* [autofix.ci] apply automated fixes

* fixing lint

* allow removal of metadata fields

* [autofix.ci] apply automated fixes

* Fix the name of alter metadata

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Eric Hare <ericrhare@gmail.com>
2024-11-25 20:48:45 -08:00
Phil Miesle
e439d71bfa
feat: adding list of Data output to Parse Data (#4598)
* adding list of Data output to Parse Data

* [autofix.ci] apply automated fixes

* enabling connection from more List outputs

* [autofix.ci] apply automated fixes

* refactor to have single return type

* [autofix.ci] apply automated fixes

* addressing linting comments

* [autofix.ci] apply automated fixes

* apparently lint was missed...

* sigh

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Eric Hare <ericrhare@gmail.com>
2024-11-25 20:40:59 -08:00
Phil Miesle
c6f27b5af8
Creating BaseFileComponent, integrating with API Request "to file" feature (#4731)
* adding ability for APIRequest to retry and save to a file

* [autofix.ci] apply automated fixes

* adding ability for APIRequest to retry and save to a file

* [autofix.ci] apply automated fixes

* initial refactor of FileComponent to handle Data input

* shifting potentially common logic into BaseFileComponent

* improving readability and fixing problems

* [autofix.ci] apply automated fixes

* addressing linting

* [autofix.ci] apply automated fixes

* linting part 2

* [autofix.ci] apply automated fixes

* linting part 3

* preserve input fields on data objects

* [autofix.ci] apply automated fixes

* ensuring processed data is linked to correct file data object

* [autofix.ci] apply automated fixes

* addressing linting

* [autofix.ci] apply automated fixes

* fixing edge case

* allowing specific failure of missing file without forcing silent_errors

* Base_file mypy errors

* [autofix.ci] apply automated fixes

* Update base_file.py

* Update base_file.py

* Fix starter templates

* Update test_vector_store_rag.py

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Eric Hare <ericrhare@gmail.com>
2024-11-25 20:36:17 -08:00
Phil Miesle
654b44347b
adding ability for APIRequest to retry and save to a file (#4677)
* re-adding ability for APIRequest to retry and save to a file

* [autofix.ci] apply automated fixes

* enabling selective inclusion of httpx headers, along with response header

* [autofix.ci] apply automated fixes

* Update api_request.py

* [autofix.ci] apply automated fixes

* Update test_data_components.py

* Update test_data_components.py

* [autofix.ci] apply automated fixes

* Update api_request.py

* Update api_request.py

* Update api_request.py

* Update api_request.py

* Update api_request.py

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Eric Hare <ericrhare@gmail.com>
2024-11-25 19:58:48 -08:00
Ítalo Johnny
3c83e153ec
chore: remove unused plugin-related code (#4826)
chore: refactor: remove unused plugin-related code
2024-11-26 00:43:40 +00:00
Christophe Bornet
1962e48266
ref: Remove usage of deprecated get_event_loop (#4697)
Remove usage of deprecated get_event_loop
2024-11-26 00:17:29 +00:00
Christophe Bornet
1ba2e0e71b
ref: Add aiofile to do async file operations (#4705)
Add aiofile to do async file operations
2024-11-25 23:50:25 +00:00
Christophe Bornet
598e6bc5ae
ref: Apply ruff rules preview autofix (#4699)
Apply ruff rules preview autofix
2024-11-25 23:42:38 +00:00
Csongor Barabasi
394cc55ab7
fix: Expose chosen model by NotDiamond router (#4833)
* Show the chosen model on the NotDiamond component

* Formatting and linting
2024-11-25 12:23:42 -08:00
Ítalo Johnny
9b50b81e7d
chore: set log level to debug (#4830) 2024-11-25 11:25:43 -08:00
Gabriel Luiz Freitas Almeida
091944095f
chore: Bump package versions for langflow and langflow-base (#4816)
fix: bump package versions to 1.1.1 and 0.1.1 for langflow and langflow-base
2024-11-25 16:14:39 +00:00
Mendon Kissling
aa73e6f19c
fix: swap descriptions for Load Data Flow and Retriever Flow in template (#4814)
fix: swap descriptions for Load Data Flow and Retriever Flow in JSON configuration
2024-11-25 15:24:59 +00:00
Ítalo Johnny
450b371566
fix: raise ImportError instead of silencing AttributeError (#4812)
* fix: raise ImportError instead of silencing AttributeError

* chore: add Message class to init for import standardization

* feat: add exception message pattern check for import errors

* refactor: simplify code
2024-11-25 14:14:57 +00:00
Gabriel Luiz Freitas Almeida
bd15071b33
refactor: updates import statements to use Pydantic in aiml_embeddings.py (#4801)
Fix import statements for Pydantic in aiml_embeddings.py
2024-11-24 09:25:36 +01:00
Karan Vaidya
3e1b22b23f
feat: improve composio oauth experience (#4613) 2024-11-23 15:23:57 +00:00
Christophe Bornet
ab63ddddbd
ref: Use blockbuster package (#4777)
* Use blockbuster package

* Upgrade blockbuster to v1.1
2024-11-23 15:05:56 +00:00
Gabriel Luiz Freitas Almeida
e61fb96504
refactor: Improve error messaging for missing message fields in memory module (#4779)
* Improve error messaging for missing message fields in memory module

* fix: Simplify return statement in NotDiamondComponent's chat result method

* Update .gitignore to exclude all .db files
2024-11-23 13:04:20 +00:00
Csongor Barabasi
ef2199b317
feat: LLM routing integration via NotDiamond (#4543)
* WIP

* Integrate Notdiamond via API call

* Fix frontend lock

* Update

* Update ND integration to use HandleInput for LLM models

* Move NotDiamond out into bundles and add fallback call

* Update src/backend/base/langflow/components/notdiamond/notdiamond.py

Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>

* Update src/backend/base/langflow/components/notdiamond/notdiamond.py

Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>

* Update src/frontend/src/icons/NotDiamond/NotDiamondIcon.jsx

Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>

---------

Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
2024-11-23 12:20:53 +00:00