* 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
* 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
* 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
* Fix node inputs not being captured, add runtime inputs as well to be captured by the tracers properly
* Fix outputs missing on traces due to them being reset before ending the traces because of race conditions
* Fallback to project name if none
* Remove 'dynamic inputs' to stop sending the component code every time
* fix: Add async flow name retrieval in graph building process
* fix: Retrieve flow name from database when building graph from data
* Fix: make session.exec call awaitable in chat API
* Refactor `_get_flow_name` to manage session internally
* Refactor session handling to use `async_session_scope` in chat API
* Refactor test cases to remove unnecessary async usage in mock functions
* [autofix.ci] apply automated fixes
---------
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
* fix: ensure unique flow names when assigning to superuser
* refactor: Creates a new function with logic to rename flows
* refactor: simplify function
* Extract STARTER_FOLDER constants to a separate module
* Filter orphaned flows by excluding those in the starter folder
---------
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
* feat: Add support for dynamic providers in Astra DB Comp
* [autofix.ci] apply automated fixes
* Make sure we return a default dict
* Rename params in starter template
* Update test_vector_store_rag.py
---------
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
* Use AsyncSession for user management
* Simplify check_key
* Don't trigger blockbuster on settings service initialize
* Fix mypy
* Fix api key update_total_uses
* Fix auto-login
* Revert making CustomComponent.list_key_names async
* new components improvements
* ✨ (create_data.py): introduce a new 'legacy' attribute to mark the component as legacy code
* [autofix.ci] apply automated fixes
* chaing langchain hub name
* 📝 (run_flow.py): remove beta flag from RunFlowComponent to indicate it is no longer in beta
📝 (extract_key.py): remove beta flag from ExtractDataKeyComponent to indicate it is no longer in beta
* Updated generic icon component to load icons if already not lazy imported
* [autofix.ci] apply automated fixes
* merge fix
* 📝 (store_message.py): add 'advanced' parameter to the 'Session ID' field to indicate it is an advanced setting
* [autofix.ci] apply automated fixes
* new components sweep
* [autofix.ci] apply automated fixes
* fix tests
* [autofix.ci] apply automated fixes
* ✨ (filterSidebar.spec.ts): Update test descriptions to reflect the correct component names for better clarity and maintainability
♻️ (freeze.spec.ts): Refactor test to use the correct component name for consistency and readability
♻️ (stop-building.spec.ts): Refactor test to use the correct component name for consistency and readability
♻️ (generalBugs-shard-9.spec.ts): Refactor test to use the correct component name for consistency and readability
♻️ (filterEdge-shard-1.spec.ts): Refactor test to use the correct component name for consistency and readability
* style: Improve YahooFinanceToolComponent description and code readability
Enhance clarity in the component's purpose and refine inline formatting to boost maintainability.
---------
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Lucas Oliveira <lucas.edu.oli@hotmail.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
* Add module parameter to build_component_instance_for_tests function for dynamic component retrieval
* Enhance component test base with detailed version mapping and error handling
- Introduced `VersionComponentMapping` TypedDict for structured version mapping.
- Updated `FILE_NAMES_MAPPING` to use a list of `VersionComponentMapping`.
- Added comprehensive error messages for missing or invalid mappings in `test_all_versions_have_a_file_name_defined`.
- Improved `test_component_versions` with detailed exception handling and error reporting.
- Ensured `component_class` is defined before running tests.
* Refactor FILE_NAMES_MAPPING to use a list of dictionaries for better structure and readability in test_prompt_component.py
* refactor: Enhance ComponentTestBase with fixture validation and improved version handling
* Refactor test setup in `test_prompt_component.py` to use fixtures for improved modularity and readability
* fix: Add PlaceholderGraph NamedTuple and handle 'graph' attribute in Component class
* Add attribute checks for 'graph' and 'vertex' to prevent errors
* Handle missing 'graph' attribute in 'store_message' method to prevent errors.
* Handle missing 'graph' attribute in Message creation to prevent errors
* Handle missing 'graph' attribute in chat message flow ID assignment
* Add component code to test instance creation and error logging
* Update SUPPORTED_VERSIONS to remove older versions
* test: add unit tests for ChatInput and TextInputComponent
Implement comprehensive tests for both ChatInput and TextInputComponent to ensure proper functionality, including message responses and handling of various input scenarios. This enhances reliability and aids in future development.
* test: add unit tests for ChatOutput and TextOutputComponent
Implement comprehensive tests for ChatOutput and TextOutputComponent, validating message responses, source properties, and behavior with various input types to ensure reliability and consistency across output components.
* Update JSON files to improve code readability and add missing info fields
- Added missing `info` fields to various input components to provide better context and descriptions.
- Improved code readability by ensuring consistent formatting and structure across JSON files.
- Updated `message_response` method to handle cases where `graph` attribute might not be present.
- Enhanced `build_vectorize_options` method to set `authentication` and `parameters` to `None` if no values are provided.
- Refined `AgentComponent` to include `info` for `agent_llm` and other fields, improving clarity on their purpose.
* Refactor: update attribute access to use private `_vertex` attribute
* test: enhance TextInputComponent tests and update properties assertions
* Remove redundant unit tests for output components in test_output_components.py
* feat: add PlaceholderGraph for backwards compatibility and enhance Component attributes
* fix: improve run_id assignment and ensure user_id is a string in PlaceholderGraph
* Add check for non-empty incoming_edges in get_properties_from_source_component
* Refactor `trace_name` property to use `_id` instead of `_vertex.id` for component identification
* Handle missing session_id attribute in component and agent classes
* Add SUPPORTED_VERSIONS constant for version tracking in tests
* Add utility to download components from GitHub in integration tests
* Rename TestComponent to ComponentForTesting to avoid conflict with pytest
* test: enhance PromptComponent tests for version support
Add parameterized testing for supported versions and a validation for the latest PromptComponent. This improves test coverage and ensures compatibility across different versions.
* refactor: move build_component_instance_for_tests utility to integration utils
* Make `from_template_and_variables` async for backwards compatibility and add sync version
* Refactor `PromptComponent` to use `Message.from_template` method across starter projects JSON files.
* add await to `from_template_and_variables` call
* Add async test for message prompt serialization and update cache directory handling
- Introduced `async` in `test_message_prompt_serialization` for asynchronous message creation.
- Added `test_message_sync_prompt_serialization` for synchronous message testing.
- Updated cache directory paths to "langflow_test" for test isolation.
- Utilized `monkeypatch` to set environment variable for cache directory in `langflow_cache_dir` fixture.
* Add fixture and existence check in test_schema_message.py
- Use `langflow_cache_dir` fixture in `test_message_with_single_image`.
- Add assertion to verify the existence of `second_image`.
* Add base test class to ensure file names are defined for all supported versions
* Remove default value for 'file_name' parameter in 'build_component_instance_for_tests' function
* Enhance `TestPromptComponent` with version-specific file name handling and base class integration
* Refactor test_prompt_component_versions to use FILE_NAMES_MAPPING directly
* Add component version tests and base classes for testing with/without client
* Simplify `build_component_instance_for_tests` by returning `cc_class` directly
* Refactor `TestPromptComponent` to use `ComponentTestBaseWithClient` and remove version tests
* Add assertion for LANGFLOW_CONFIG_DIR in test_message_with_multiple_images
* Refactor: update method call to `from_template` in `langchain_hub.py`
* Handle missing '_id' attribute in 'trace_name' method of custom_component.py
* Optimize `get_and_cache_all_types_dict` call by removing unnecessary thread usage in test.
* Enhance tool block mapping by using unique tool keys with name and run_id
* Enhance tool output rendering with Markdown and JSON formatting in ContentDisplay component
* Add animations for block title and content separators in ContentBlockDisplay component
* Allow 'size' prop to accept string values and update styling in BorderTrail component
* Adjust BorderTrail animation size and duration based on expansion state
* fix both borders trailing at the same time
* [autofix.ci] apply automated fixes
* fix text sizing
* fix spacing issues
* Adjust header title and text styling in ContentBlockDisplay and DurationDisplay components
* Refactor header title in ContentBlockDisplay component
* [autofix.ci] apply automated fixes
* Convert `test_handle_on_tool_start` to an async function and update tool content key logic
* Handle logger without 'opt' method in code parsing error handling
* Update test duration values in .test_durations file
---------
Co-authored-by: anovazzi1 <otavio2204@gmail.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
* Add cycle detection and management for graph vertices in run manager
* Refactor: Move AIMLEmbeddingsImpl to a new module path
* Add AIMLEmbeddingsImpl class for document and query embeddings using AIML API
* Add agent components for action routing, decision-making, execution, and context management
- Introduced `AgentActionRouter` to route agent flow based on action type.
- Added `DecideActionComponent` for determining actions from context and prompts.
- Implemented `ExecuteActionComponent` to execute actions using available tools.
- Created `GenerateThoughtComponent` for generating thoughts based on context.
- Developed `ProvideFinalAnswerComponent` to generate final answers from context.
- Built `AgentContextBuilder` for constructing `AgentContext` instances.
- Added `ObserveResultComponent` to process and observe action results.
- Implemented `CheckTerminationComponent` to determine if the agent should continue or terminate.
* Add AgentContext class for managing agent state and context serialization
- Introduced `AgentContext` class in `context.py` to handle agent state, including tools, language model, and context history.
- Implemented serialization methods for converting agent context to JSON-compatible format.
- Added validation for language model instances to ensure compatibility.
- Provided methods for updating and retrieving full context, including context history management.
* Add new agent components to the langflow module's init file
* Update `apply_on_outputs` to use `_outputs_map` in vertex base class
* Add _pre_run_setup method to custom component for pre-execution setup
* Handle non-list action types in decide_action method
* Enhance AgentActionRouter with iteration control and context routing logic
* Fix incorrect variable usage in tool call result message formatting
* Add AgentActionRouter to module exports in agents package
* Refactor cycle detection logic in graph base class
* Add test for complex agent flow with cyclic graph validation
* Enhance readiness checks in tracing service methods
* Add context management to Graph class with dotdict support
* Add context management methods to custom component class
- Introduced a `_ctx` attribute to store context data.
- Added `ctx` property to access the graph's context, raising an error if the graph is not built.
- Implemented `add_to_ctx` method to add key-value pairs to the context with an optional overwrite flag.
- Implemented `update_ctx` method to update the context with a dictionary of values, ensuring the graph is built and the input is a dictionary.
* Add customizable Agent component with input/output handling and action routing
* Handle non-list 'tools' attribute in 'build_context' method
* Convert `get_response` method to asynchronous and update graph processing to use async iteration.
* Add async test for Agent component in graph cycle tests
* Refactor Agent Flow JSON: Simplify input types and update agent component structure
- Removed "BaseTool" from input types for "ToolCallingAgent" to streamline tool handling.
- Updated agent component to a more modular structure with new prompts and input configurations.
- Replaced deprecated methods and fields with updated implementations for improved functionality.
- Adjusted metadata and configuration settings for better clarity and usability.
* [autofix.ci] apply automated fixes
* Add Agent import to init, improve error handling, and clean up imports
- Added `Agent` import to `__init__.py` for better module accessibility.
- Improved error handling in `aiml_embeddings.py` by raising a `ValueError` when the expected embedding count is not met.
- Cleaned up redundant imports in `test_cycles.py` to enhance code readability.
* Refactor agent component imports for improved modularity and organization
* Remove agent components and update `__init__.py` exports
* Add iteration control and default route options to ConditionalRouter component
* Refactor graph tests to include new components and update iteration logic
- Replaced complex agent flow with a simplified guessing game using OpenAI components and conditional routing.
- Introduced `TextInputComponent` and updated `ChatInput` initialization.
- Added new test `test_conditional_router_max_iterations` to validate conditional routing with max iterations.
- Updated graph cyclicity assertions and snapshot checks for improved test coverage.
- Removed deprecated agent components and related logic.
* Refactor conditional router to return message consistently and use iterate_and_stop_once method
* Add return type annotations to methods in langsmith.py
* Remove unnecessary `@override` decorator and add `# noqa: ARG002` comments for unused arguments
* Move ChatInput import inside flow_component fixture in conftest.py
* Update test to use _outputs_map for cycle outputs retrieval
* Refactor `iterate_and_stop_once` to remove redundant `_id` variable usage
* Add default route to ConditionalRouterComponent in cycle test
* Implement synchronous graph execution using threading and queues
- Removed `nest_asyncio` dependency and replaced it with a new threading-based approach for synchronous graph execution.
- Introduced a `queue.Queue` to handle results and exceptions between threads.
- Added a new thread to run asynchronous code, ensuring proper event loop management and task completion.
- Updated methods to return sorted lists of runnable vertices for consistency.
* Update import path for ModelConstants in test_model_constants.py
* [autofix.ci] apply automated fixes
* fix: add property decorator
---------
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: italojohnny <italojohnnydosanjos@gmail.com>
* remove poetry.lock
* fix: update langchain-core dependency version to 0.3.15
* feat: add functions to convert images to base64 and create data URLs
* refactor: simplify image URL handling by replacing ImagePromptTemplate with create_data_url function
* Fix image URL structure in data schema to use nested dictionary format
* Add unit tests for Data schema message conversion with text and images
* test: add unit tests for image utility functions to validate base64 conversion and data URL creation
* Refactor image URL generation to use `create_data_url` utility function instead of `ImagePromptTemplate`
* Add unit tests for message handling and image processing in schema module
- Introduce fixtures for temporary cache directory and sample image creation.
- Add tests for message creation from human and AI text.
- Implement tests for messages with single and multiple images.
- Include tests for invalid image paths and messages without sender.
- Add message serialization and conversion tests.
- Ensure cleanup of cache directory after tests.
* Use platformdirs to determine cache directory paths in test_schema_message.py
update component.py
I added a StructuredTool to define the set function in the component. This change resolved an error that occurred when the list of tools was set by the component. In the future, we may need to add tests to manage unexpected situations in the component's set function.
I also updated the pytest.
* Update content_blocks initialization and add flow_id parameter to ErrorMessage
* feat: include vertex ID in class instantiation
Pass the vertex ID to the custom component during instantiation to facilitate event tracking or management capabilities.
* fix: update message streaming logic to handle None messages and refactor _stream_message parameters
* feat: include flow_id in ChatOutput initialization
Add flow_id to the ChatOutput class to improve the tracking of conversational flows, enhancing the context management within the chat system.
* fix: update chat message source display to use 'source' instead of 'display_name'
* feat: add flow_id to message initialization in ChatOutput class
* fix: handle JSON parsing with type checks for message properties
Refine JSON loading to ensure proper type handling for message properties and content blocks, enhancing stability and preventing potential errors with non-string inputs.
* refactor: update logging structure and message handling
Improve the output logs to support logging multiple entries and ensure robust message streaming with type checking. Adjust error handling parameters for consistency.
* feat: restrict event types in registration and sending
Enhance event management by explicitly defining allowed event types, improving code clarity and reducing potential errors. This ensures only valid event types are registered and sent, leading to more robust event handling.
* Update `logs` attribute to store lists of `Log` objects in `Vertex` class
* feat: introduce TypedDicts for ContentBlock and Properties, update default values in Message model
* fix: restrict event types in send_event method to improve data validation
* Set default values for 'id', 'display_name', and 'source' fields in Source schema
* [autofix.ci] apply automated fixes
* fix: update query to use equality check for error messages
* make lint
* update simple agent test
* test: enhance EventManager tests for event_id validation
* feat: add background, chat icon, and text color properties to component toolkit
* fix: update LogComponent name to display_name for consistency
* remove playground from new cards on main page
* refactor: Update Properties handling in MessageTable and remove unused PropertiesDict
* fix: Set default value for category in MessageBase model
* fix: Update properties default factory in MessageTable model to use model_dump
* Add _build_source method to ChatOutput and update test inputs to use Message objects
* Fix incorrect parameter names in _build_source method across multiple JSON files
* ✅ (freeze.spec.ts, playground.spec.ts, stop-building.spec.ts, linkComponent.spec.ts, sliderComponent.spec.ts, tableInputComponent.spec.ts, stop-button-playground.spec.ts, generalBugs-shard-7.spec.ts): enable tests that were previously skipped to ensure proper functionality and coverage. Remove outdated comments and update test descriptions for clarity.
* Refactor agent event processing to support message streaming and improve content handling
* Refactor ChatOutput to enhance message handling and streamline property assignment
* Fix session ID assignment in send_message method for better message handling
* Add OnTokenFunctionType protocol for enhanced token handling
* Add BorderTrail component for animated border effects
* Add ContentBlockDisplay component for enhanced content visualization and loading state
* Refactor TextShimmer to use motion.create for improved component animation
* Add ContentBlockDisplay to render chat content blocks in newChatMessage component
* Refactor `ChatOutput` class to use `MessageInput` instead of `MessageTextInput` for `input_value` across starter projects.
* Update edge class name from 'runned' to 'ran' in flow components and store
* Add 'on_build_start' and 'on_build_end' events to EventManager
* Add build status updates for 'build_start' and 'build_end' events in buildUtils.ts
* Integrate event management for output function in ComponentToolkit to track build start and end events
* Refactor event handling in ComponentToolkit to improve build event tracking
* Refactor messagesStore to update existing message if it already exists
* update properties to have state attribute
* format
* Refactor chatMessage component to display loading state for partial chat messages
* Refactor reactflowUtils to handle broken edges with missing display names
* fix agent text output
* [autofix.ci] apply automated fixes
* [autofix.ci] apply automated fixes (attempt 2/3)
* fix agent component initialization
* Enhance error message formatting to include detailed exception information
* Refactor agent component for improved performance and stability
* Refactor `LCAgentComponent` to streamline agent execution logic and remove redundant methods
* Add type casting for send_message function in agent.py
* Change return type of function to 'Message' in log schema
* Add `embedding_service` and `client` fields to JSON configurations and refactor ChatOutput class
- Introduced `embedding_service` field in `Vector Store RAG.json` and `Travel Planning Agents.json` to support Astra Vectorize and embedding model selection.
- Added `client` field to `OpenAIEmbeddingsComponent` in JSON configurations for enhanced client configuration.
- Refactored `ChatOutput` class across multiple JSON files to include a new `_build_source` method for constructing `Source` objects, improving code modularity and readability.
- Updated import paths for `OpenAIEmbeddings` to reflect changes in the module structure.
* Update attribute handling in Component class to merge inputs with existing attributes
* Update ChatInput and ChatOutput initialization to include session_id
* Refactor test_load_flow_from_json_object to be asynchronous
* Add asynchronous tests for agent event handling in test_agent_events.py
* Add event handling functions for agent tool and chain events
- Implement functions to handle various agent events such as `on_chain_start`, `on_chain_end`, `on_tool_start`, `on_tool_end`, and `on_tool_error`.
- Introduce helper functions to build content blocks for agent messages.
- Create mappings for chain and tool event handlers.
- Refactor `process_agent_events` to utilize the new event handling functions.
- Remove the old `process_agent_events` implementation from `agent.py` and import the new one from `events.py`.
* feat: update content structure and validation logic
Enhance content block to accept a list of contents instead of a single item, and implement validation to ensure proper format. Refactor tool-related content types for improved clarity and functionality.
* Handle ValidationError in error message generation and update import paths
* feat: enhance error event creation to include structured error content
* move validators and remove utils.py
* feat: add event handler tests for agent tool and chain events
* refactor: streamline tool content structure
Combine multiple tool-related types into a single, more flexible interface. This simplifies the content handling by allowing optional properties for output, error, and timestamp, enhancing overall code maintainability. Adjust the ContentBlock interface to accommodate an array of contents for improved flexibility.
* feat: refactor error handling in ChatMessage component to support dynamic content blocks
* feat: enhance ContentBlockDisplay to support Markdown rendering and dynamic content handling
* Refactor agent event handling to simplify content block management
* Enhance `ContentBlockDisplay` with separators and improved content rendering logic
* add inline block to prevent text overflow in reason
* Refactor code to enhance Markdown rendering and dynamic content handling in ChatMessage component
* [autofix.ci] apply automated fixes
* Add timestamp field to BaseContent class and remove from ToolContent class
* Update timestamp validation to include fractional seconds in BaseContent class
* Add duration calculation for agent and tool events in events.py
* Refactor ContentBlock to use Pydantic's Discriminator and Tag for content types
* Add field validators for content_blocks and properties in Message class
* Add field serializer for source in Properties class
* Add type hint for serialize_properties method in MessageTable class
* create duration component and refactor contents
* [autofix.ci] apply automated fixes
* Refactor duration calculation to use perf_counter for improved accuracy and update ContentBlockDict to use dict for contents
* Update properties field validator to use 'before' mode for improved validation
* Refactor MessageTable to use ContentBlock instead of ContentBlockDict and enhance validation and serialization for properties and content_blocks
* Refactor AgentComponent to streamline agent initialization by using the set method directly
* Refactor event handling functions to use synchronous definitions and improve performance with asyncio.to_thread
* Refactor PythonREPLToolComponent to raise ToolException on error instead of returning error message
* Refactor CalculatorToolComponent to enhance error handling by raising ToolException and improving expression evaluation feedback
* Fix TextShimmer width in ContentBlockDisplay for improved layout consistency
* Enhance ContentBlockDisplay to support external links and math rendering in Markdown
* Enhance error handling in Calculator and Python REPL tools by introducing `ToolException` and improving expression evaluation logic.
* Refactor agent message properties to remove unnecessary icons and update content block titles for clarity
* feat: enhance agent and tool content messaging
Add headers to agent and tool content messages for better clarity and user experience.
* Handle nested schema structure in ContentBlock initialization
* fix: update agent input text content return type and enhance error message formatting
* Add placeholder and default value for model selection in AstraVectorStoreComponent
* Refactor event handling functions to remove `send_message_method` parameter and streamline message processing logic.
* Add model configuration to ToolContent for alias population
* Refactor agent event tests to improve message handling and content block initialization
* test: Update test durations for performance metrics
Adjust the recorded execution times for various test cases to ensure accurate performance tracking and facilitate optimization efforts.
* Refactor test_load_flow_from_json_object to improve project loading logic
* Make `HeaderDict` fields optional and update `header` field in `BaseContent`
* Enhance `Message` and `ChatOutput` with additional attributes for testing
* Update test duration metrics in .test_durations file
* Refactor `ContentDisplay` component to support multiple content types and improve rendering logic
* feat: Enhance duration display with human-readable format
Integrate the pretty-ms library to convert duration display metrics into a more user-friendly format, improving the overall user experience. Update dependencies to ensure compatibility with the latest version and optimize for newer Node.js versions.
* feat: Add optional duration and header properties to BaseContent interface
* fix: Change duration type from float to int in BaseContent class
* Remove default value for 'start_time' in duration calculations
* Enhance `ContentBlockDisplay` with dynamic header and expand/collapse animation
- Added `state` prop to `ContentBlockDisplay` to dynamically set header icon and title based on content state.
- Implemented `renderContent` function to encapsulate content rendering logic with animation.
- Integrated `ForwardedIconComponent` for displaying header icons.
- Updated `newChatMessage.tsx` to pass `state` prop to `ContentBlockDisplay`.
* Add animation to header title using AnimatePresence and motion components
* Add support for processing zip files with multithreading in FileComponent
- Enhanced FileComponent to handle individual and zipped text files.
- Introduced multithreading option for parallel processing of files within zip archives.
- Updated supported file types to include zip files.
- Improved error handling and logging for file processing.
* Expand `Message` conversion to support `AsyncIterator` and `Iterator` types.
* Remove unused function _find_or_create_tool_content from events.py
* Add header information to tool content and streamline message sending in event processing
* Add send_message_method parameter to event handlers for message dispatching
- Updated event handler functions to include a new parameter, `send_message_method`, allowing for message dispatching within the handlers.
- Modified the logic in each handler to utilize the `send_message_method` for sending messages.
- Adjusted the main event processing logic to pass the `send_message_method` to the appropriate handlers.
* Refactor ContentBlockDisplay component to improve rendering performance and user experience
* Refactor `ContentBlockDisplay.tsx` to improve readability and update header title logic
* [autofix.ci] apply automated fixes
* Add 'start_time' to event data and update test functions to include send_message mock
* Refactor ContentBlockDisplay component to include total duration and improve user experience
* Refactor ContentBlockDisplay component to handle isLoading state for total duration calculation
* Refactor animatedNumbers component and add AnimatedNumberBasic component
- Refactor the animatedNumbers component to improve readability and update the header title logic.
- Add a new component called AnimatedNumberBasic that displays an animated number with a specific value.
* Refactor agent message creation to improve event processing efficiency
* Refactor session ID assignment in run_graph_internal for improved clarity
* [autofix.ci] apply automated fixes
* fix: update agent message properties handling for improved compatibility
* fix: enhance message property validation to support dictionary input
* Add session_id to agent message initialization in tests
- Updated test cases in `test_agent_events.py` to include `session_id` in the `Message` initialization.
- Adjusted calls to `process_agent_events` to pass the `agent_message` with `session_id`.
* feat: Enhance event handling with duration tracking
Add start_time parameter to event handling functions to ensure consistent duration calculations across different stages of agent processing. This improves accuracy in measuring event durations and enhances overall event management.
* Add optional humanized value to AnimatedNumber component and update DurationDisplay usage
* Refactor `ContentDisplay` and add separator to `ContentBlockDisplay` component
* Add header to text content in agent message events
* Add separator between each content block in ContentBlockDisplay component
* Refactor layout in ContentDisplay component for improved styling and positioning
* Refactor event handlers to return updated start_time and agent_message
- Modified event handler functions to return a tuple of `agent_message` and `start_time`.
- Updated `_calculate_duration` to handle `start_time` as an integer.
- Ensured `start_time` is reset using `perf_counter()` after each event handling.
- Adjusted tool and chain event handler calls to accommodate the new return type.
* Add start_time and duration checks to agent event handlers in tests
- Updated test cases for `handle_on_chain_start`, `handle_on_chain_end`, `handle_on_tool_start`, `handle_on_tool_end`, `handle_on_tool_error`, and `handle_on_chain_stream` to include `start_time` as a return value.
- Added assertions to verify that `start_time` is a float and `duration` is an integer where applicable.
* [autofix.ci] apply automated fixes
* update colors and spacing of time
* [autofix.ci] apply automated fixes
* Refactor DurationDisplay component to display duration in seconds
* Rename case from "message" to "add_message" in buildUtils.ts switch statement
* Add event registration for message removal in EventManager
* Add category handling for message events in Component class
* Add custom exception handling for agent message processing
* Handle exceptions in agent event processing with message deletion and event notification
* Add new LLM options and refactor AgentComponent for dynamic provider handling
- Introduced new language model options: Anthropic, Groq, and NVIDIA.
- Refactored `AgentComponent` to utilize `MODEL_PROVIDERS_DICT` for dynamic provider handling.
- Simplified input management by removing hardcoded provider inputs and using a dictionary-based approach.
- Enhanced `update_build_config` to support flexible provider configurations and custom options.
* Refactor buildUtils.ts and add message removal handling
* Update Source model to allow None values for id, display_name, and source fields
* Refactor event handler functions to return tuple of Message and float
* Refactor `ChatOutput` class to use `MessageInput` instead of `MessageTextInput` for `input_value` across starter projects.
* Add test for updating component outputs with dynamic code input
* feat: add ToolModeMixin to manage tool mode state
* feat: add parameterName to mutateTemplate for enhanced template mutation
* feat: add tool mode functionality to node toolbar
Implement a toggle for tool mode, allowing users to easily switch functionalities within the node toolbar. This enhancement improves user interaction by providing a dedicated mode for tool-related tasks.
* feat: integrate ToolModeMixin into MessageTextInput for enhanced functionality
* Update parameterId to "tool_mode" in nodeToolbarComponent
* feat: implement tool mode output handling in run_and_validate_update_outputs
* feat: add conditional rendering for tool mode button based on template fields
* fix: enhance null checks for tool mode button visibility and output validation
* feat: add isToolMode property to NodeInputFieldComponentType for enhanced functionality
* feat: add isToolMode prop to NodeInputField for conditional styling
* feat: implement sorting logic for tool mode fields in GenericNode component
* feat: add isToolMode prop to NodeOutputField for conditional styling
* feat: pass isToolMode prop to NodeOutputField for conditional styling
* feat: update disabled logic in NodeInputField to include isToolMode
* Add default placeholder to getPlaceholder function and constants file
* feat: Enable dynamic placeholders in input components
Add support for customizable placeholder text across various input components to enhance usability and improve user experience.
* feat: Add optional placeholder prop to InputProps type
* feat: Add placeholder prop to InputGlobalComponent and CustomParameterComponent
* feat: Set dynamic placeholder for NodeInputField based on tool mode
* feat: Update NodeOutputField styling for tool mode and pass isToolMode prop
* feat: Add isToolMode prop to OutputComponent for dynamic styling
* feat: Add TOOL_OUTPUT_DISPLAY_NAME constant for toolset display
* feat: Update tool output display name to use TOOL_OUTPUT_DISPLAY_NAME constant
* feat: Conditionally render Freeze Path button based on tool mode
* Add support for asynchronous output methods and tool mode validation in component tools
* feat: Validate required inputs for tool mode before executing output methods
* Refactor: Rename method to indicate private access in custom_component
- Changed `get_function_entrypoint_return_type` to `_get_function_entrypoint_return_type` in `custom_component.py` to reflect its intended private usage.
- Updated references to the renamed method in `utils.py` and `directory_reader.py` to maintain consistency.
* feat: Implement tool output mapping based on tool mode presence in inputs
* Refactor tests to use private method _get_function_entrypoint_return_type
* feat: Enable tool mode for input_value in LCAgentComponent
* Add test for updating component outputs with dynamic code input
* feat: add tool mode functionality to node toolbar
Implement a toggle for tool mode, allowing users to easily switch functionalities within the node toolbar. This enhancement improves user interaction by providing a dedicated mode for tool-related tasks.
* feat: add conditional rendering for tool mode button based on template fields
* feat: add isToolMode prop to NodeInputField for conditional styling
* feat: Set dynamic placeholder for NodeInputField based on tool mode
* feat: Add TOOL_OUTPUT_DISPLAY_NAME constant for toolset display
* feat: Conditionally render Freeze Path button based on tool mode
* Add tool mode support to LCAgentComponent
- Introduced new input fields: `agent_name`, `agent_description`, and `add_tools_to_description` to support tool mode.
- Implemented methods `get_tool_name`, `get_tool_description`, `_build_tools_description`, and `to_toolkit` for handling tool-related functionalities.
- Enhanced `MessageTextInput` with additional information for better user guidance.
- Updated agent message sender name to use `agent_name` if available.
* Fix return statement placement in event handling logic
* Add tool mode enhancements and error handling in component_tool
- Introduce optional parameters `tool_name`, `tool_description`, and `callbacks` to `get_tools` method.
- Implement error handling for tool creation with `handle_tool_error` and `callbacks`.
- Ensure single tool validation when `tool_name` or `tool_description` is provided.
- Add support for `BaseModel` result serialization using `model_dump`.
* Refactor agent response method and update output configuration
* Remove unused 'input_value' field from tool_calling.py configuration
* Refactor source property assignment to use _build_source method
* Enhance callable input check and add callbacks to toolkit conversion
* Add unit tests for message update functionality in backend
- Implement tests for updating single and multiple messages.
- Add tests for handling nonexistent messages during updates.
- Include tests for updating messages with timestamps, content blocks, and nested properties.
- Ensure proper serialization and storage of message properties.
* Add field serializer for 'output' using jsonable_encoder in content_types.py
* Add tool mode fields and refactor message response in starter projects
- Introduced new fields `add_tools_to_description`, `agent_description`, and `agent_name` for tool mode configuration in JSON starter projects.
- Refactored `message_response` method to utilize `_build_source` for constructing message source properties.
- Updated method references from `get_response` to `message_response` for consistency.
- Adjusted input field descriptions and added missing metadata attributes.
* Implement no-op send_message function and patching decorator for component tools
* Refactor output handling in component tool to support Message and Data types
* Simplify exception handling by removing redundant exception re-raise
* Enhance tool assignment logic to preserve existing name and description if not provided
* feat: Enhance agent name and description handling
Refactor the agent component to dynamically include tool names in the default agent name and description. This improves clarity for users by providing more context about the agent's capabilities and ensures consistent representation of tools in the interface.
* refactor: Update agent description and name info to include default values and dynamic tool integration
* Add custom encoders for serialization and refactor schema modules
- Introduce `CUSTOM_ENCODERS` in `encoders.py` to handle serialization of `Callable` and `datetime` objects.
- Refactor `BaseContent` to use `model_serializer` for model serialization with custom encoders.
- Remove redundant `encode_callable` function and `CUSTOM_ENCODERS` definition from `artifact.py`.
- Update imports and clean up unused imports in schema modules.
* Remove 'agent_name' field and update 'get_tool_name' method in agent.py
* Enhance `serialize_model` method with `wrap` mode and improved error handling
* Add 'tool_mode' attribute to frontend node class
* Add unit tests for ContentBlock initialization and content handling
* Add unit tests for content types serialization and creation
* Refactor tool mode initialization logic in NodeToolbarComponent
* Add tool mode functionality to node toolbar and flow store
* Add updateNodeInternals call for tool_mode case in nodeToolbarComponent
* Add condition to hide handle in tool mode in NodeInputField component
* Add shortcut for activating Tool Mode and integrate into node toolbar
* Add tool_mode parameter to MessageTextInput and update attributes mapping
* Remove 'agent_name' field from Agent Flow configuration file
* Update agent message to use display_name instead of agent_name
* Add validation for required tools in agent execution and component setup
* Make 'tools' field required in AgentComponent configuration
* test: add unit tests for run_and_validate_update_outputs functionality
Implement comprehensive tests for the `run_and_validate_update_outputs` method across various scenarios, including enabling/disabling tool mode, handling invalid output structures, and supporting custom update logic. Validate that outputs are correctly updated and ensure appropriate error handling for invalid cases.
* test: update component toolkit tests to use CalculatorToolComponent
* Enhance input schema creation logic for tool mode components
* Include input expression in error responses for calculator tool
* Enhance `visit_Attribute` to check for required inputs in `tree_visitor.py`
* fix: add checks for graph attribute before accessing session and flow IDs in Component methods
* fix: set default value to None for id field in PlaygroundEvent model
* fix: remove unused add_toolkit_output flag from FeatureFlags model
* Refactor JSON configurations to remove unnecessary required inputs across starter projects
* Add tool mode validation and improve error handling
- Updated import statement for ContentBlock to fix import path.
- Modified `send_message_noop` to require a `Message` parameter and added type ignore for method assignment.
- Enhanced error message in tool mode validation to handle `None` input names.
- Changed return type of `send_error_message` to `Message` for consistency.
- Provided default value for `get_tool_name` to handle missing display names.
* Add pytest fixture to test_component_message_sending test
---------
Co-authored-by: anovazzi1 <otavio2204@gmail.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: cristhianzl <cristhian.lousa@gmail.com>
* Refactor cardComponent and storeCardComponent to comment out playground buttons
* Refactor message model to replace 'meta_data' with 'properties' and update related schema and components
* Add new schema for content types with Pydantic models
* Add ContentBlock schema with support for multiple content types
* Refactor: Import ContentBlock from langflow.schema.content_block instead of defining locally
* Add SendMessageFunctionType protocol to log schema for message handling
* Refactor chat message model to replace 'meta_data' with 'properties' and update related components
* Add ContentBlock import and enhance send_message method in component.py
- Import ContentBlock from langflow.schema.content_block.
- Replace 'meta_data' with 'properties' in message construction.
- Update send_message method to handle optional Message and text parameters.
* Add async on_chain_start method to callback for logging chain start events
* Refactor add_messagetables function to replace 'meta_data' with 'properties' in message processing
* Fix typo in 'traceback' property name in ErrorDetails interface
* Add condition to check chat history length before rendering chat lock
* Refactor error content structure and enhance message event handling
* Add `update_messages` function to handle message updates in memory module
* Add check for 'id' attribute in stored_message for message validation
* Add new content types and TypeAlias for schema in content_types.py
* Add custom serialization for UUID and BaseModel types in data schema
* Refactor `ContentType` to use `ContentTypes` union and update `content` field in `ContentBlock` model
* Update model to use specific types for properties and content_blocks fields
* Change return type of 'serialize_params' method to string
* Add sender fields and properties handling to PlaygroundEvent and create_message function
* Refactor chat message component to use 'properties' instead of 'meta_data' for chat attributes
* Refactor message handling to improve error categorization and session management
* Enhance ContentBlock initialization to update model fields with defaults
* Add new content types and update ContentBlock interface in chat types
- Introduced BaseContent interface and various content types: ErrorContent, TextContent, MediaContent, JSONContent, CodeContent, ToolStartContent, ToolEndContent, and ToolErrorContent.
- Created a union type ContentType for all content types.
- Updated ContentBlock interface to include new content structure and additional fields.
* Refactor error handling in chat messages to use `ErrorContent` type
* Add ErrorMessage class for handling error-specific messages in schema
* Add type annotations for cache and logs in custom_component.py
* Refactor error handling in custom component to use `send_error` method
* Add customizable properties for chat components
- Introduced new properties: `background_color`, `chat_icon`, and `text_color` to chat components across various starter projects.
- These properties allow for customization of the chat message appearance, including icon and text styling.
- Updated the `ChatInput` and `ChatOutput` components to handle these new properties and include them in the message response.
* Add 'category' field to MessageEvent and update create_message function
* Remove unused message handling methods from ChatComponent
* Refactor message event handling in chat module
* Add 'category' field to Message creation and pass 'id_' in _send_message_event
* Add 'category' field with Literal type to Message schema and default handling in chat IO
* Refactor message event handling in chat module
* Refactor buttonSendWrapper component to add data-testid attribute
* Refactor ChatComponent to replace 'store_message' with 'send_message' method
* refactor: streamline message handling in Component
Update message processing to utilize new methods for improved clarity and efficiency. Enhance event data management to ensure accuracy and consistency in message updates.
* feat: Update input handling and output storage for chat components
Enhance chat input and output components to improve message handling, including updates to storage and display properties. This facilitates better user experience and message management in various agent projects.
* Ensure 'id' field is set in message data dictionary if not present
* refactor: Simplify property retrieval from source component in ChatComponent
* refactor: Replace property retrieval logic with a dedicated method in ChatOutput
* Refactor `TokenEvent` class and add `timestamp` field with default factory
* refactor: Simplify message processing by removing unused parameters in async handling
* Refactor message text update logic in messagesStore
* Refactor border styling in ChatInput component
* refactor: Consolidate properties handling in PlaygroundEvent and create_message function
* refactor: Update timestamp formatting to include timezone information across multiple models
* refactor: Add StreamingError exception for better error handling in streaming components
* refactor: Add source_display_name attribute to Properties model for enhanced data representation
* refactor: Enhance ChatComponent to return source display name and update properties handling in ChatOutput
* refactor: Improve error handling in Component class and enhance create_error function with timestamp support
* feat: enhance ChatOutput component for improved message handling
Update the message_response method to include source display name and improve message storage functionality across various project templates. This enhances clarity and ensures consistent behavior of chat components.
* feat: add delete_message function to remove messages by ID from the monitor service
* Add error handling for message streaming and implement message deletion on failure
* feat: Enhance message streaming and event handling
Improve the streaming process to send message events only for non-streaming messages and ensure the initial message is sent correctly when processing chunks, enhancing the overall message handling flow.
* improve UI
* Refactor buttonSendWrapper component to add data-testid attribute and update tests
* fix edited tag
* add tooltip to add button
* fix bug after merge
* update examples
* updateinput without chat
* fix some frontend tests
* fix test
* update test
* Update fileUploadComponent.spec.ts to fix test and update input without chat
* refactor event creation functions and enhance ErrorEvent structure
* refactor ErrorMessage to use Source for sender and component details
* refactor Properties to use Source model for source details and add validation
* refactor ChatMessage component for improved readability and structure
* refactor ChatMessageType to use PropertiesType for improved structure and clarity
* Add Source ID to message properties and update exception handling
- Updated `message_response` method to include `source_id` in the `Properties` object for better traceability.
- Modified `StreamingError` to use `Source` object instead of `component_name` for more detailed error context.
- Adjusted `get_properties_from_source_component` to return `source_id` along with other properties.
* Add 'Source' property to error handling in custom_component module
- Introduced 'Source' property to enhance error message details.
- Updated error handling to include 'source' instead of 'display_name'.
- Modified exception raising to use 'source' for better traceability.
* Enhance event ID generation with event type prefix in `send_event` method
* Refactor ChatOutput class to use Properties and Source schemas for message properties
* update style in tailwind and add fallback for nullable values
* fix playground test
* Update message handling in Component class to send modified message copy on first chunk
* Add flow_id and session_id to ErrorEvent creation function
* Update content_blocks initialization and add flow_id parameter to ErrorMessage
* feat: include vertex ID in class instantiation
Pass the vertex ID to the custom component during instantiation to facilitate event tracking or management capabilities.
* fix: update message streaming logic to handle None messages and refactor _stream_message parameters
* feat: include flow_id in ChatOutput initialization
Add flow_id to the ChatOutput class to improve the tracking of conversational flows, enhancing the context management within the chat system.
* fix: update chat message source display to use 'source' instead of 'display_name'
* feat: add flow_id to message initialization in ChatOutput class
* fix: handle JSON parsing with type checks for message properties
Refine JSON loading to ensure proper type handling for message properties and content blocks, enhancing stability and preventing potential errors with non-string inputs.
* refactor: update logging structure and message handling
Improve the output logs to support logging multiple entries and ensure robust message streaming with type checking. Adjust error handling parameters for consistency.
* feat: restrict event types in registration and sending
Enhance event management by explicitly defining allowed event types, improving code clarity and reducing potential errors. This ensures only valid event types are registered and sent, leading to more robust event handling.
* Update `logs` attribute to store lists of `Log` objects in `Vertex` class
* feat: introduce TypedDicts for ContentBlock and Properties, update default values in Message model
* fix: restrict event types in send_event method to improve data validation
* Set default values for 'id', 'display_name', and 'source' fields in Source schema
* [autofix.ci] apply automated fixes
* fix: update query to use equality check for error messages
* make lint
* update simple agent test
* test: enhance EventManager tests for event_id validation
* feat: add background, chat icon, and text color properties to component toolkit
* fix: update LogComponent name to display_name for consistency
* remove playground from new cards on main page
* refactor: Update Properties handling in MessageTable and remove unused PropertiesDict
* fix: Set default value for category in MessageBase model
* fix: Update properties default factory in MessageTable model to use model_dump
* Add _build_source method to ChatOutput and update test inputs to use Message objects
* Fix incorrect parameter names in _build_source method across multiple JSON files
* ✅ (freeze.spec.ts, playground.spec.ts, stop-building.spec.ts, linkComponent.spec.ts, sliderComponent.spec.ts, tableInputComponent.spec.ts, stop-button-playground.spec.ts, generalBugs-shard-7.spec.ts): enable tests that were previously skipped to ensure proper functionality and coverage. Remove outdated comments and update test descriptions for clarity.
* Refactor agent event processing to support message streaming and improve content handling
* Refactor ChatOutput to enhance message handling and streamline property assignment
* Fix session ID assignment in send_message method for better message handling
* Add OnTokenFunctionType protocol for enhanced token handling
* Add BorderTrail component for animated border effects
* Add ContentBlockDisplay component for enhanced content visualization and loading state
* Refactor TextShimmer to use motion.create for improved component animation
* Add ContentBlockDisplay to render chat content blocks in newChatMessage component
* Refactor `ChatOutput` class to use `MessageInput` instead of `MessageTextInput` for `input_value` across starter projects.
* Update edge class name from 'runned' to 'ran' in flow components and store
* Add 'on_build_start' and 'on_build_end' events to EventManager
* Add build status updates for 'build_start' and 'build_end' events in buildUtils.ts
* Integrate event management for output function in ComponentToolkit to track build start and end events
* Refactor event handling in ComponentToolkit to improve build event tracking
* Refactor messagesStore to update existing message if it already exists
* update properties to have state attribute
* format
* Refactor chatMessage component to display loading state for partial chat messages
* Refactor reactflowUtils to handle broken edges with missing display names
* fix agent text output
* [autofix.ci] apply automated fixes
* [autofix.ci] apply automated fixes (attempt 2/3)
* fix agent component initialization
* Enhance error message formatting to include detailed exception information
* Refactor agent component for improved performance and stability
* Refactor `LCAgentComponent` to streamline agent execution logic and remove redundant methods
* Add type casting for send_message function in agent.py
* Change return type of function to 'Message' in log schema
* Add `embedding_service` and `client` fields to JSON configurations and refactor ChatOutput class
- Introduced `embedding_service` field in `Vector Store RAG.json` and `Travel Planning Agents.json` to support Astra Vectorize and embedding model selection.
- Added `client` field to `OpenAIEmbeddingsComponent` in JSON configurations for enhanced client configuration.
- Refactored `ChatOutput` class across multiple JSON files to include a new `_build_source` method for constructing `Source` objects, improving code modularity and readability.
- Updated import paths for `OpenAIEmbeddings` to reflect changes in the module structure.
* Update attribute handling in Component class to merge inputs with existing attributes
* Update ChatInput and ChatOutput initialization to include session_id
* Refactor test_load_flow_from_json_object to be asynchronous
* Add asynchronous tests for agent event handling in test_agent_events.py
* Add event handling functions for agent tool and chain events
- Implement functions to handle various agent events such as `on_chain_start`, `on_chain_end`, `on_tool_start`, `on_tool_end`, and `on_tool_error`.
- Introduce helper functions to build content blocks for agent messages.
- Create mappings for chain and tool event handlers.
- Refactor `process_agent_events` to utilize the new event handling functions.
- Remove the old `process_agent_events` implementation from `agent.py` and import the new one from `events.py`.
* feat: update content structure and validation logic
Enhance content block to accept a list of contents instead of a single item, and implement validation to ensure proper format. Refactor tool-related content types for improved clarity and functionality.
* Handle ValidationError in error message generation and update import paths
* feat: enhance error event creation to include structured error content
* move validators and remove utils.py
* feat: add event handler tests for agent tool and chain events
* refactor: streamline tool content structure
Combine multiple tool-related types into a single, more flexible interface. This simplifies the content handling by allowing optional properties for output, error, and timestamp, enhancing overall code maintainability. Adjust the ContentBlock interface to accommodate an array of contents for improved flexibility.
* feat: refactor error handling in ChatMessage component to support dynamic content blocks
* feat: enhance ContentBlockDisplay to support Markdown rendering and dynamic content handling
* Refactor agent event handling to simplify content block management
* Enhance `ContentBlockDisplay` with separators and improved content rendering logic
* add inline block to prevent text overflow in reason
* Refactor code to enhance Markdown rendering and dynamic content handling in ChatMessage component
* [autofix.ci] apply automated fixes
* Add timestamp field to BaseContent class and remove from ToolContent class
* Update timestamp validation to include fractional seconds in BaseContent class
* Add duration calculation for agent and tool events in events.py
* Refactor ContentBlock to use Pydantic's Discriminator and Tag for content types
* Add field validators for content_blocks and properties in Message class
* Add field serializer for source in Properties class
* Add type hint for serialize_properties method in MessageTable class
* create duration component and refactor contents
* [autofix.ci] apply automated fixes
* Refactor duration calculation to use perf_counter for improved accuracy and update ContentBlockDict to use dict for contents
* Update properties field validator to use 'before' mode for improved validation
* Refactor MessageTable to use ContentBlock instead of ContentBlockDict and enhance validation and serialization for properties and content_blocks
* Refactor AgentComponent to streamline agent initialization by using the set method directly
* Refactor event handling functions to use synchronous definitions and improve performance with asyncio.to_thread
* Refactor PythonREPLToolComponent to raise ToolException on error instead of returning error message
* Refactor CalculatorToolComponent to enhance error handling by raising ToolException and improving expression evaluation feedback
* Fix TextShimmer width in ContentBlockDisplay for improved layout consistency
* Enhance ContentBlockDisplay to support external links and math rendering in Markdown
* Enhance error handling in Calculator and Python REPL tools by introducing `ToolException` and improving expression evaluation logic.
* Refactor agent message properties to remove unnecessary icons and update content block titles for clarity
* feat: enhance agent and tool content messaging
Add headers to agent and tool content messages for better clarity and user experience.
* Handle nested schema structure in ContentBlock initialization
* fix: update agent input text content return type and enhance error message formatting
* Add placeholder and default value for model selection in AstraVectorStoreComponent
* Refactor event handling functions to remove `send_message_method` parameter and streamline message processing logic.
* Add model configuration to ToolContent for alias population
* Refactor agent event tests to improve message handling and content block initialization
* test: Update test durations for performance metrics
Adjust the recorded execution times for various test cases to ensure accurate performance tracking and facilitate optimization efforts.
* Refactor test_load_flow_from_json_object to improve project loading logic
* Make `HeaderDict` fields optional and update `header` field in `BaseContent`
* Enhance `Message` and `ChatOutput` with additional attributes for testing
* Update test duration metrics in .test_durations file
* Refactor `ContentDisplay` component to support multiple content types and improve rendering logic
* feat: Enhance duration display with human-readable format
Integrate the pretty-ms library to convert duration display metrics into a more user-friendly format, improving the overall user experience. Update dependencies to ensure compatibility with the latest version and optimize for newer Node.js versions.
* feat: Add optional duration and header properties to BaseContent interface
* fix: Change duration type from float to int in BaseContent class
* Remove default value for 'start_time' in duration calculations
* Enhance `ContentBlockDisplay` with dynamic header and expand/collapse animation
- Added `state` prop to `ContentBlockDisplay` to dynamically set header icon and title based on content state.
- Implemented `renderContent` function to encapsulate content rendering logic with animation.
- Integrated `ForwardedIconComponent` for displaying header icons.
- Updated `newChatMessage.tsx` to pass `state` prop to `ContentBlockDisplay`.
* Add animation to header title using AnimatePresence and motion components
* Add support for processing zip files with multithreading in FileComponent
- Enhanced FileComponent to handle individual and zipped text files.
- Introduced multithreading option for parallel processing of files within zip archives.
- Updated supported file types to include zip files.
- Improved error handling and logging for file processing.
* Expand `Message` conversion to support `AsyncIterator` and `Iterator` types.
* Remove unused function _find_or_create_tool_content from events.py
* Add header information to tool content and streamline message sending in event processing
* Add send_message_method parameter to event handlers for message dispatching
- Updated event handler functions to include a new parameter, `send_message_method`, allowing for message dispatching within the handlers.
- Modified the logic in each handler to utilize the `send_message_method` for sending messages.
- Adjusted the main event processing logic to pass the `send_message_method` to the appropriate handlers.
* Refactor ContentBlockDisplay component to improve rendering performance and user experience
* Refactor `ContentBlockDisplay.tsx` to improve readability and update header title logic
* [autofix.ci] apply automated fixes
* Add 'start_time' to event data and update test functions to include send_message mock
* Refactor ContentBlockDisplay component to include total duration and improve user experience
* Refactor ContentBlockDisplay component to handle isLoading state for total duration calculation
* Refactor animatedNumbers component and add AnimatedNumberBasic component
- Refactor the animatedNumbers component to improve readability and update the header title logic.
- Add a new component called AnimatedNumberBasic that displays an animated number with a specific value.
* Refactor agent message creation to improve event processing efficiency
* Refactor session ID assignment in run_graph_internal for improved clarity
* [autofix.ci] apply automated fixes
* fix: update agent message properties handling for improved compatibility
* fix: enhance message property validation to support dictionary input
* Add session_id to agent message initialization in tests
- Updated test cases in `test_agent_events.py` to include `session_id` in the `Message` initialization.
- Adjusted calls to `process_agent_events` to pass the `agent_message` with `session_id`.
* feat: Enhance event handling with duration tracking
Add start_time parameter to event handling functions to ensure consistent duration calculations across different stages of agent processing. This improves accuracy in measuring event durations and enhances overall event management.
* Add optional humanized value to AnimatedNumber component and update DurationDisplay usage
* Refactor `ContentDisplay` and add separator to `ContentBlockDisplay` component
* Add header to text content in agent message events
* Add separator between each content block in ContentBlockDisplay component
* Refactor layout in ContentDisplay component for improved styling and positioning
* Refactor event handlers to return updated start_time and agent_message
- Modified event handler functions to return a tuple of `agent_message` and `start_time`.
- Updated `_calculate_duration` to handle `start_time` as an integer.
- Ensured `start_time` is reset using `perf_counter()` after each event handling.
- Adjusted tool and chain event handler calls to accommodate the new return type.
* Add start_time and duration checks to agent event handlers in tests
- Updated test cases for `handle_on_chain_start`, `handle_on_chain_end`, `handle_on_tool_start`, `handle_on_tool_end`, `handle_on_tool_error`, and `handle_on_chain_stream` to include `start_time` as a return value.
- Added assertions to verify that `start_time` is a float and `duration` is an integer where applicable.
* [autofix.ci] apply automated fixes
* update colors and spacing of time
* [autofix.ci] apply automated fixes
* Refactor DurationDisplay component to display duration in seconds
* Rename case from "message" to "add_message" in buildUtils.ts switch statement
* Add event registration for message removal in EventManager
* Add category handling for message events in Component class
* Add custom exception handling for agent message processing
* Handle exceptions in agent event processing with message deletion and event notification
* Add new LLM options and refactor AgentComponent for dynamic provider handling
- Introduced new language model options: Anthropic, Groq, and NVIDIA.
- Refactored `AgentComponent` to utilize `MODEL_PROVIDERS_DICT` for dynamic provider handling.
- Simplified input management by removing hardcoded provider inputs and using a dictionary-based approach.
- Enhanced `update_build_config` to support flexible provider configurations and custom options.
* Refactor buildUtils.ts and add message removal handling
* Update Source model to allow None values for id, display_name, and source fields
* Refactor event handler functions to return tuple of Message and float
---------
Co-authored-by: anovazzi1 <otavio2204@gmail.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: cristhianzl <cristhian.lousa@gmail.com>
* fix: update assistants client import (#4150)
* remove unnecessary patch
* remove unnecessary patch
* compatible release operator
* chore: add opensearch-py dependency (#4134)
Add opensearch-py dependency to pyproject.toml
* patch version
* lock
* lock some packages to speed up pip install
* langflow-base version
* fix: fix retrieverTool component (#4201)
♻️ (RetrieverTool.py): refactor build method signature to accept additional keyword arguments for future extensibility
* Fixed save modal not exiting
* fix: object has no attribute 'set_event_manager' (#4200)
* 🐛 (base.py): fix AttributeError by checking if custom_component has set_event_manager method before calling it
* 📝 (base.py): Import Component from langflow.custom to improve code readability and maintainability
♻️ (base.py): Refactor code to use isinstance() method for checking if custom_component is an instance of Component
* Refactor: Eliminate Global Variables for Improved Code Maintainability_fix_release (#4208)
Refactor: Eliminate Global Variables for Improved Code Maintainability
- Replaced global variables with local variables or class attributes.
- Enhanced code readability and reduced potential side effects.
* fix: Update example (#4204)
update example
* fix: avoids error NameError: name 'MAX_NUMBER_OF_FIELDS' is not defin… (#4203)
fix: avoids error NameError: name 'MAX_NUMBER_OF_FIELDS' is not defined and fixes build method
Co-authored-by: Edwin Jose <edwin.jose@datastax.com>
* fix: unexpected keyword argument 'code' -> SQLExecutor and SQLDatabase (#4230)
🔧 (SQLDatabase.py): update build method signature to accept additional keyword arguments for future extensibility
🔧 (SQLExecutor.py): update method signature to accept additional keyword arguments for future extensibility
* lock httptools to 0.6.4
* Move ChatInput import to within flow_component fixture in conftest.py
* Simplify error message formatting in test cases for data components
* Add readme to dockerfile
* build: dockerfile with entrypoint (#4062)
Adds a dockerfile with an entrypoint for use with Datastax Langflow
* fixes the leading v for checking out commits correctly
* fixes on more version checkout for docker build
* ✨ (authContext.tsx): Add functionality to fetch global variables on authentication
🔧 (api.tsx): Replace universal-cookie import with react-cookie for consistency
🔧 (authStore.ts): Replace universal-cookie import with react-cookie for consistency
🔧 (use-get-global-variables.ts): Add check to only fetch global variables if user is authenticated
✨ (use-get-mutation-global-variables.ts): Add mutation function to fetch and update global variables
🔧 (authStore.ts): Replace universal-cookie import with react-cookie for consistency
* [autofix.ci] apply automated fixes
* revert changes to workflows
* upgrade lockfile
* update pyproject versions
* update lockfile again
* ⬆️ (pyproject.toml): upgrade langflow-base dependency to version 0.0.99
* ⬆️ (pyproject.toml): downgrade version from 0.0.99 to 0.0.97 to align with project requirements and dependencies.
* ⬆️ (pyproject.toml): downgrade langflow-base dependency version from 0.0.99 to 0.0.97 to resolve compatibility issues
* ⬆️ (uv.lock): downgrade langchain-core package version from 0.3.15 to 0.3.12 to resolve compatibility issues with dependencies
* ⬆️ (pyproject.toml): upgrade langflow-base dependency to version 0.0.99 to utilize the latest features and improvements
---------
Co-authored-by: Sebastián Estévez <estevezsebastian@gmail.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
Co-authored-by: Lucas Oliveira <lucas.edu.oli@hotmail.com>
Co-authored-by: Edwin Jose <edwin.jose@datastax.com>
Co-authored-by: anovazzi1 <otavio2204@gmail.com>
Co-authored-by: João <38133825+joaoguilhermeS@users.noreply.github.com>
Co-authored-by: Jordan Frazier <jordan.frazier@datastax.com>
Co-authored-by: Jordan Frazier <122494242+jordanrfrazier@users.noreply.github.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
* Add Multi-Model Provider Support to Agent Component
- Integrated model provider constants from `model_input_constants.py` into the Agent component to support multiple LLM providers
- Added dynamic field management for different model providers (OpenAI, Azure, Groq, Anthropic, NVIDIA)
- Implemented a dropdown for model provider selection with automatic input field updates
* sorted list
* Update agent.py
making custom separate from sort
* chore: remove unit test
---------
Co-authored-by: italojohnny <italojohnnydosanjos@gmail.com>
* Refactor sessionSelector component to improve session management and interaction
* Refactor IOModal component to remove unused code and improve session management
* fix typing error
* fix run chat input on component level
* prevent toogle visibility on session menu
* fix bug on rename session while in table view mode
* chore: Update setSelectedView prop type in sessionSelector component
* add first test version not working yet
* fix bug for renaming and deleting session
* refactor: Update sessionSelector component to handle session changes
* improve test
* fix rename session multiple session bugs
* change visible session from array to string
* chore: Update editMessageField component to include margin-right for text span
* [autofix.ci] apply automated fixes
* Update down_revision in Alembic migration script
* Refactor IOModal component to simplify session visibility handling
* Add new schema for playground events with various event types
- Introduce `PlaygroundEvent` base class and specific event types: `MessageEvent`, `ErrorEvent`, `WarningEvent`, `InfoEvent`, and `TokenEvent`.
- Implement `ContentBlock` class for flexible content handling.
- Add factory functions to create different event types.
- Utilize Pydantic for data validation and serialization.
* Add PlaygroundEvent to LoggableType in log schema
* Add timestamp validation utility to schema utils and refactor Message class to use it
* Add custom serialization for datetime and Decimal in data schema
* Add session_id handling to graph and chat API
- Introduce `_session_id` attribute in the graph base class.
- Implement getter and setter for `session_id` property.
- Update chat API to set `session_id` from inputs if available.
* Add error handling for event creation in EventManager
- Integrate `create_event_by_type` to generate playground events.
- Add try-except block to handle `TypeError` during event creation and log the error using `loguru`.
- Raise any other exceptions encountered during event creation.
* Enhance session ID handling in vertex base logic
* Add message handling and streaming capabilities to custom component
- Introduced `send_message` method to handle message sending with optional formatting and content blocks.
- Implemented `_store_message`, `_send_message_event`, and `_should_stream_message` for message storage and event management.
- Added `_update_stored_message` and `_stream_message` to support message streaming and updating.
- Included `_handle_async_iterator` and `_process_chunk` for processing message chunks from iterators.
* Add new schema types and properties for chat and messages components
* Add customizable chat message styles and icons in IOModal component
* Add support for handling Playground events in chat view
- Introduced `PlaygroundEvent` type to manage different event types such as message, error, warning, info, and token.
- Implemented `handlePlaygroundEvent` function to process and update chat history based on event type.
- Enhanced file parsing logic to handle empty strings and parsing errors.
- Added default values for `background_color` and `text_color` in chat messages.
* revert changes made to bypass ruff-check
* revert changes made to bypass ruff-check
* Refactor file parsing logic in ChatView component
* fix ui problem
* Refactor feature flags and chat view components
- Enable new IO modal in feature flags
- Update imports and remove unused code in newChatMessage component
- Add error icon and error message in ChatMessage component
- Update lockChat icon position in newChatView component
- Import OctagonAlert icon in styleUtils
* Refactor IOModal newModal component styles
* Refactor styles in EditMessageField and ChatMessage components
* Refactor styles in EditMessageField component
* Refactor styles in ChatMessage component to fix UI problem
* Refactor styles in UploadFileButton component and add image attachment tooltip
* Refactor styles in ChatCodeTabComponent to update language text color
* fix padding in other field views
* Refactor styles in ChatComponent and add tooltip to the playground
* Refactor styles in constants.ts to remove unused input and output types
* Refactor session selector styles
* Refactor chatView component styles
* update colors to use variables
* Refactor code tab component and update code styling
* Refactor buttonSendWrapper component styles
* update colors to use variables
* update colors to use variables
* Refactor chatComponent and chatInput styles
* update colors to use variables
* chore: add new attributes to model definition
* chore: generate database migration
* chore: add MetaData and ContentBlock models and update Message schema
* chore: add error handling to build_results and adjust message event handling
* chore: deserialize meta_data and content_blocks fields in add_messagetables
* raw
* Refactor message and chat types to include category, meta_data, and content_blocks
* raw
* Refactor error handling in component.py and newChatMessage.tsx
* add source to bot messages
* raw
* Refactor chatMessage component to include meta_data icon and source
* improve icon, background color, text color handling in chat message
* add edit flag correctly
* use svg icon logo instead of chain emoji
* add text effect
* update error colors
* fix error aligment
* add text shimmer effect
* improve is running style
* Add support for importing SVG files in Vite environment
* Add chatLogoIcon component with Chain logo
* Refactor chat message component to use chatLogoIcon component
* Refactor chatView component to use chatLogoIcon component
* remove from empty chat
* update text sizes and style
* remove icon in message logs
* fix stop button color
* update background color and sender name size
* prevent list index out of range error
* Fix onBlur event in EditMessageField component
* improve edit message field
* improve edit background behaviour
* Update chat input styling for better user experience
* Refactor ChatCodeTabComponent to remove redundant "Copy" text in button
* Refactor code to use CSS variables for background color in code blocks
* Refactor ChatCodeTabComponent to update code block styling
* Refactor code to update code block styling and improve chat input styling
* prevent Flow Running after error rendering
* Refactor code to add IOModalOpen state and setter function
* Refactor code to add IOModalOpen state and setter function
* Refactor code to remove console.log statement
* update icon and padding
* Refactor code to retrieve connected model name in ChatComponent
* run formatter
* fix stop button glitch
* update max width
* Refactor GithubStarButton component to handle null value for stars
* Refactor tailwind.config.mjs to add utility classes for fading text truncation
* improve faded truncate function
* Refactor ChatView component to handle null value for chat history category
* [autofix.ci] apply automated fixes
* Refactor DialogContent component to improve close button styling
* Refactor IOModal component to improve sidebar behavior and styling
* Refactor ChatView component to remove unused code and improve performance
* Refactor session selector component to add tooltip for options
* [autofix.ci] apply automated fixes
* update several icon sizes and hover states
* [autofix.ci] apply automated fixes
* Refactor IOModal component to improve sidebar behavior and styling
* Refactor IOModal component to handle sidebar behavior on window resize
* [autofix.ci] apply automated fixes
* fix error related to content blocks being null
* [autofix.ci] apply automated fixes
* add component id as sender to the message
* add component id as source to the message
* Add fitViewNode function to FlowStoreType
* enable closing chat on error message
* Add ClickableLinks component for rendering clickable URLs in chat messages
* add error message transition
* [autofix.ci] apply automated fixes
* [autofix.ci] apply automated fixes (attempt 2/3)
* use IsPlayground flag
* Remove console.log statement in setIOModalOpen function
* update max-w
* prevent breaking the buttons on small screen
* [autofix.ci] apply automated fixes
* remove underline when component is not clicable
* Refactor IOModal component to remove unnecessary props and update usage
- Remove the "isPlayground" prop from the IOModal component in cardComponent and storeCardComponent
- Update the usage of the IOModal component in chatComponent and newModal to use the "canvasOpen" prop instead of "isPlayground"
* fix html missing closing tag error
* [autofix.ci] apply automated fixes
* Refactor PlaygroundPage component to improve flow initialization and data fetching
* [autofix.ci] apply automated fixes
* Refactor cardComponent and storeCardComponent to comment out playground buttons
* Refactor message model to replace 'meta_data' with 'properties' and update related schema and components
* Add new schema for content types with Pydantic models
* Add ContentBlock schema with support for multiple content types
* Refactor: Import ContentBlock from langflow.schema.content_block instead of defining locally
* Add SendMessageFunctionType protocol to log schema for message handling
* Refactor chat message model to replace 'meta_data' with 'properties' and update related components
* Add ContentBlock import and enhance send_message method in component.py
- Import ContentBlock from langflow.schema.content_block.
- Replace 'meta_data' with 'properties' in message construction.
- Update send_message method to handle optional Message and text parameters.
* Add async on_chain_start method to callback for logging chain start events
* Refactor add_messagetables function to replace 'meta_data' with 'properties' in message processing
* Fix typo in 'traceback' property name in ErrorDetails interface
* Add condition to check chat history length before rendering chat lock
* Refactor error content structure and enhance message event handling
* Add `update_messages` function to handle message updates in memory module
* Add check for 'id' attribute in stored_message for message validation
* Add new content types and TypeAlias for schema in content_types.py
* Add custom serialization for UUID and BaseModel types in data schema
* Refactor `ContentType` to use `ContentTypes` union and update `content` field in `ContentBlock` model
* Update model to use specific types for properties and content_blocks fields
* Change return type of 'serialize_params' method to string
* Add sender fields and properties handling to PlaygroundEvent and create_message function
* Refactor chat message component to use 'properties' instead of 'meta_data' for chat attributes
* Refactor message handling to improve error categorization and session management
* Enhance ContentBlock initialization to update model fields with defaults
* Add new content types and update ContentBlock interface in chat types
- Introduced BaseContent interface and various content types: ErrorContent, TextContent, MediaContent, JSONContent, CodeContent, ToolStartContent, ToolEndContent, and ToolErrorContent.
- Created a union type ContentType for all content types.
- Updated ContentBlock interface to include new content structure and additional fields.
* Refactor error handling in chat messages to use `ErrorContent` type
* Add ErrorMessage class for handling error-specific messages in schema
* Add type annotations for cache and logs in custom_component.py
* Refactor error handling in custom component to use `send_error` method
* Add customizable properties for chat components
- Introduced new properties: `background_color`, `chat_icon`, and `text_color` to chat components across various starter projects.
- These properties allow for customization of the chat message appearance, including icon and text styling.
- Updated the `ChatInput` and `ChatOutput` components to handle these new properties and include them in the message response.
* Add 'category' field to MessageEvent and update create_message function
* Remove unused message handling methods from ChatComponent
* Refactor message event handling in chat module
* Add 'category' field to Message creation and pass 'id_' in _send_message_event
* Add 'category' field with Literal type to Message schema and default handling in chat IO
* Refactor message event handling in chat module
* Refactor buttonSendWrapper component to add data-testid attribute
* Refactor ChatComponent to replace 'store_message' with 'send_message' method
* refactor: streamline message handling in Component
Update message processing to utilize new methods for improved clarity and efficiency. Enhance event data management to ensure accuracy and consistency in message updates.
* feat: Update input handling and output storage for chat components
Enhance chat input and output components to improve message handling, including updates to storage and display properties. This facilitates better user experience and message management in various agent projects.
* Ensure 'id' field is set in message data dictionary if not present
* refactor: Simplify property retrieval from source component in ChatComponent
* refactor: Replace property retrieval logic with a dedicated method in ChatOutput
* Refactor `TokenEvent` class and add `timestamp` field with default factory
* refactor: Simplify message processing by removing unused parameters in async handling
* Refactor message text update logic in messagesStore
* Refactor border styling in ChatInput component
* refactor: Consolidate properties handling in PlaygroundEvent and create_message function
* refactor: Update timestamp formatting to include timezone information across multiple models
* refactor: Add StreamingError exception for better error handling in streaming components
* refactor: Add source_display_name attribute to Properties model for enhanced data representation
* refactor: Enhance ChatComponent to return source display name and update properties handling in ChatOutput
* refactor: Improve error handling in Component class and enhance create_error function with timestamp support
* feat: enhance ChatOutput component for improved message handling
Update the message_response method to include source display name and improve message storage functionality across various project templates. This enhances clarity and ensures consistent behavior of chat components.
* feat: add delete_message function to remove messages by ID from the monitor service
* Add error handling for message streaming and implement message deletion on failure
* feat: Enhance message streaming and event handling
Improve the streaming process to send message events only for non-streaming messages and ensure the initial message is sent correctly when processing chunks, enhancing the overall message handling flow.
* improve UI
* Refactor buttonSendWrapper component to add data-testid attribute and update tests
* fix edited tag
* add tooltip to add button
* fix bug after merge
* update examples
* updateinput without chat
* fix some frontend tests
* fix test
* update test
* Update fileUploadComponent.spec.ts to fix test and update input without chat
* refactor event creation functions and enhance ErrorEvent structure
* refactor ErrorMessage to use Source for sender and component details
* refactor Properties to use Source model for source details and add validation
* refactor ChatMessage component for improved readability and structure
* refactor ChatMessageType to use PropertiesType for improved structure and clarity
* Add Source ID to message properties and update exception handling
- Updated `message_response` method to include `source_id` in the `Properties` object for better traceability.
- Modified `StreamingError` to use `Source` object instead of `component_name` for more detailed error context.
- Adjusted `get_properties_from_source_component` to return `source_id` along with other properties.
* Add 'Source' property to error handling in custom_component module
- Introduced 'Source' property to enhance error message details.
- Updated error handling to include 'source' instead of 'display_name'.
- Modified exception raising to use 'source' for better traceability.
* Enhance event ID generation with event type prefix in `send_event` method
* Refactor ChatOutput class to use Properties and Source schemas for message properties
* update style in tailwind and add fallback for nullable values
* fix playground test
* Update message handling in Component class to send modified message copy on first chunk
* Add flow_id and session_id to ErrorEvent creation function
* Update content_blocks initialization and add flow_id parameter to ErrorMessage
* feat: include vertex ID in class instantiation
Pass the vertex ID to the custom component during instantiation to facilitate event tracking or management capabilities.
* fix: update message streaming logic to handle None messages and refactor _stream_message parameters
* feat: include flow_id in ChatOutput initialization
Add flow_id to the ChatOutput class to improve the tracking of conversational flows, enhancing the context management within the chat system.
* fix: update chat message source display to use 'source' instead of 'display_name'
* feat: add flow_id to message initialization in ChatOutput class
* fix: handle JSON parsing with type checks for message properties
Refine JSON loading to ensure proper type handling for message properties and content blocks, enhancing stability and preventing potential errors with non-string inputs.
* refactor: update logging structure and message handling
Improve the output logs to support logging multiple entries and ensure robust message streaming with type checking. Adjust error handling parameters for consistency.
* feat: restrict event types in registration and sending
Enhance event management by explicitly defining allowed event types, improving code clarity and reducing potential errors. This ensures only valid event types are registered and sent, leading to more robust event handling.
* Update `logs` attribute to store lists of `Log` objects in `Vertex` class
* feat: introduce TypedDicts for ContentBlock and Properties, update default values in Message model
* fix: restrict event types in send_event method to improve data validation
* Set default values for 'id', 'display_name', and 'source' fields in Source schema
* [autofix.ci] apply automated fixes
* fix: update query to use equality check for error messages
* make lint
* update simple agent test
* test: enhance EventManager tests for event_id validation
* feat: add background, chat icon, and text color properties to component toolkit
* fix: update LogComponent name to display_name for consistency
* remove playground from new cards on main page
---------
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: italojohnny <italojohnnydosanjos@gmail.com>
* feat: add benchmark markers to multiple test cases
* test: add performance tests for database initialization and app startup
Introduce benchmark tests to measure the performance of database initialization and application startup. This helps ensure efficiency and identify potential bottlenecks in the setup process.
* feat: update CodSpeed workflow to enhance test execution and duration tracking
* refactor: streamline performance tests for database initialization and app startup
* test: enhance app startup performance test with pytest benchmarking
* test: update benchmark for database initialization
Remove unnecessary benchmark call and simplify the database initialization test to enhance clarity and reliability in performance testing.
* chore: remove unnecessary pytest options from CodSpeed workflow
* Add environment setup for test_app_startup benchmark test
* Add benchmark test for app startup with database setup and flow loading
* Add benchmark markers to flow building tests in test_chat_endpoint.py
* perf: add benchmarks for service initialization and caching
Introduce benchmarks for various service initialization functions and LLM caching to improve performance evaluations.
* Remove unused benchmark marker from test function in test_chat_endpoint.py
* perf: initialize services in super user benchmark test
* Add benchmarking to test_create_starter_projects in performance tests
* Add asyncio threading to benchmark tests and remove benchmark fixture usage
* Remove database initialization benchmark test from performance suite
* refactor: reorganize langchain dependencies in pyproject.toml
* feat: add langchain-ollama dependency to pyproject.toml
* fix: update imports to use langchain_ollama for OllamaEmbeddings and ChatOllama