* refactor: update default behavior for components path in Settings class * Set components path to an empty list when no value is provided, improving clarity in logging. * Remove redundant addition of BASE_COMPONENTS_PATH when it is not already included. * feat: Implement importing of Langflow components * Added `get_langflow_components_list` to asynchronously fetch built-in components using introspection and pkgutil. * Introduced `_get_langflow_components_list_sync` for synchronous processing of component classes. * Updated `get_and_cache_all_types_dict` to merge fetched components into the cache. * Enhanced error handling during module imports and component processing. * feat: Enhance component handling in custom utils for better flexibility * refactor: Simplify component retrieval logic and enhance error handling * refactor: Remove unnecessary 'required_inputs' field from multiple starter project JSON files * refactor: Change error handling to warning for component instantiation failures * refactor: Improve component type checking in get_component_instance and run_build_config functions * refactor: Update subclass check for custom_component in run_build_config function * refactor: Update component name retrieval logic to prioritize class name * refactor: Replace settings service call with direct BASE_COMPONENTS_PATH in test_get_all * refactor: Update required inputs and improve model name info across starter projects * [autofix.ci] apply automated fixes * 📝 Add docstrings to `fix-component-loading` (#8397) Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> * Build and log fixes * refactor: Improve type checking for custom component instances in `get_component_instance` * refactor: Enhance type checking for custom components in `run_build_config` * refactor: Clean up docstrings in component loading functions for clarity * refactor: Rename `get_langflow_components_list` to `import_langflow_components` for clarity * refactor: Exclude deactivated modules and improve class checking in component loading * test: Add component differences analysis for import_langflow_components and aget_all_types_dict * [autofix.ci] apply automated fixes * refactor: Simplify assert statements and improve logging in component loading tests * [autofix.ci] apply automated fixes * refactor: Consolidate __all__ declaration for retriever components * refactor: Improve comments for clarity in run_build_config function * [autofix.ci] apply automated fixes * refactor: Enhance module validation logic in _get_langflow_components_list_sync function * refactor: Update debug log message for clarity in get_and_cache_all_types_dict function * refactor: Enhance parallel processing of Langflow components import and improve logging * refactor: Improve performance testing by adding warm-up runs and clarifying output messages * refactor: Improve assertion clarity in component loading tests and add performance benchmark * [autofix.ci] apply automated fixes * [autofix.ci] apply automated fixes (attempt 2/3) * [autofix.ci] apply automated fixes (attempt 3/3) * Use Component base class instead of custom component for a few components * ⚡️ Speed up function `get_component_instance` by 365% in PR #8395 (`fix-component-loading`) (#8438) Co-authored-by: codeflash-ai[bot] <148906541+codeflash-ai[bot]@users.noreply.github.com> * [autofix.ci] apply automated fixes * [autofix.ci] apply automated fixes (attempt 2/3) * refactor: update debug log message for components cache building * refactor: update required inputs to use 'api_key' for multiple starter projects * refactor: update import statement for BaseFileComponent in nvidia_ingest.py * refactor: simplify timing results print statement in test_load_components.py * [autofix.ci] apply automated fixes * [autofix.ci] apply automated fixes (attempt 2/3) * refactor: improve assertion readability and error handling in test_load_components.py * [autofix.ci] apply automated fixes * [autofix.ci] apply automated fixes (attempt 2/3) * [autofix.ci] apply automated fixes (attempt 3/3) * feat: allow os.stat in pkgutil for component loading in blockbuster fixture * [autofix.ci] apply automated fixes * [autofix.ci] apply automated fixes (attempt 2/3) * [autofix.ci] apply automated fixes (attempt 3/3) * updates few components to new template * import fixes * [autofix.ci] apply automated fixes * [autofix.ci] apply automated fixes (attempt 2/3) * [autofix.ci] apply automated fixes (attempt 3/3) * remove unused VectaraSelfQueryRetriverComponent from vectorstores __all__ export * Update starter project configurations to require 'api_key' as a mandatory input for model output in multiple JSON files. * [autofix.ci] apply automated fixes * Refactor JSONDocumentBuilder by removing TYPE_CHECKING import and update Vectara import statement to suppress linting warning. * ⚡️ Speed up function `_process_single_module` by 1,017% in PR #8395 (`fix-component-loading`) (#8443) Co-authored-by: codeflash-ai[bot] <148906541+codeflash-ai[bot]@users.noreply.github.com> * [autofix.ci] apply automated fixes * Remove unnecessary call to `_set_output_required_inputs` in `Component` class setup * Revert "Use Component base class instead of custom component for a few components" This reverts commit 2fd61f92b2735a770d82eada3b429c4e20657335. * move components to deactivated folder AmazonKendraRetriever, JSONDocumentBuilder, ListenComponent, MetalRetrieverComponent, MultiQueryRetrieverComponent, NotifyComponent, RetrieverToolComponent, and VectaraSelfQueryRetrieverComponent These components provide various functionalities including document building, notification handling, and integration with external APIs for data retrieval. Each component includes input specifications and error handling for robust operation. * [autofix.ci] apply automated fixes * Revert "move components to deactivated folder" This reverts commit 0aa17a26d938f4a5ea622e16c4645813ea271e44. * Implement multiple new components in the deactivated folder, including AmazonKendraRetrieverComponent, JSONDocumentBuilder, ListenComponent, MetalRetrieverComponent, MultiQueryRetrieverComponent, NotifyComponent, RetrieverToolComponent, and VectaraSelfQueryRetrieverComponent. Each component is designed to enhance functionality for document handling, notifications, and API integrations, with robust input specifications and error handling for improved reliability. * feat: Enhance starter project loading with improved logging and error handling * refactor: Remove debug logging for module processing in import_langflow_components * [autofix.ci] apply automated fixes * fix: Disable mypy error for undefined attributes in deactivated components * feat: Enhance blocking behavior in blockbuster tests with additional function checks * fix: Add import error handling for boto3 in S3BucketUploaderComponent * refactor: Add debug logging for module processing in components * fix: Temporarily disable auto-use for blockbuster fixture until blocking issue is resolved * feat: Add utility function to check for preimported components * fix: Update get_component_instance to accept both CustomComponent and Component types * fix: Update import error message for boto3 installation instructions * fix: Correct class name from VectoStoreRetrieverComponent to VectorStoreRetrieverComponent * fix: Update Vectara type hints and import statements for consistency * fix: Refactor get_component_instance and build_custom_component_template_from_inputs for improved error handling and component instantiation * fix: Remove debug logging from _process_single_module to streamline module processing * ⚡️ Speed up function `is_a_preimported_component` by 24% in PR #8395 (`fix-component-loading`) Here is an optimized version of your program. **Reasoning for changes:** - The check `isinstance(custom_component, Component)` followed by `type(custom_component) is not Component` causes the interpreter to potentially look up the type and MRO twice per call. - By storing `type(custom_component)` in `klass` and using `issubclass(klass, Component)`, you avoid having Python walk the MRO twice for the same object, which is subtly more efficient especially in tight loops and heavy use scenarios. - Using `issubclass()` on the object's type is semantically equivalent to `isinstance()`, except it also works for custom metaclass scenarios and is very slightly faster when type is already known. **All program logic and comments are preserved, only the relevant portion is optimized.** * ✨ (freeze.spec.ts): introduce new function addFlowToTestOnEmptyLangflow to enhance test coverage and improve test reliability * ✨ (freeze.spec.ts): increase timeout value for waiting for "built successfully" text to appear to improve test reliability * ✨ (freeze.spec.ts): refactor code to check if firstRunLangflow is greater than 0 before calling addFlowToTestOnEmptyLangflow 🔧 (generalBugs-shard-9.spec.ts): update tags in test case to include @workspace and @components ♻️ (generalBugs-shard-9.spec.ts): refactor code to remove unnecessary steps related to sidebar search and node handling 🔧 (store-shard-0.spec.ts): update test cases to be skipped and improve readability by using async arrow functions --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@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: codeflash-ai[bot] <148906541+codeflash-ai[bot]@users.noreply.github.com> Co-authored-by: cristhianzl <cristhian.lousa@gmail.com> |
||
|---|---|---|
| .cursor/rules | ||
| .devcontainer | ||
| .github | ||
| .vscode | ||
| deploy | ||
| docker | ||
| docker_example | ||
| docs | ||
| scripts | ||
| src | ||
| test-results | ||
| .composio.lock | ||
| .env.example | ||
| .eslintrc.json | ||
| .gitattributes | ||
| .gitignore | ||
| .pre-commit-config.yaml | ||
| CODE_OF_CONDUCT.md | ||
| CONTRIBUTING.md | ||
| DEVELOPMENT.md | ||
| eslint.config.js | ||
| LICENSE | ||
| Makefile | ||
| pyproject.toml | ||
| README.md | ||
| render.yaml | ||
| uv.lock | ||
Langflow is a powerful tool for building and deploying AI-powered agents and workflows. It provides developers with both a visual authoring experience and a built-in API server that turns every agent into an API endpoint that can be integrated into applications built on any framework or stack. Langflow comes with batteries included and supports all major LLMs, vector databases and a growing library of AI tools.
✨ Highlight features
- Visual Builder to get started quickly and iterate.
- Access to Code so developers can tweak any component using Python.
- Playground to immediately test and iterate on their flows with step-by-step control.
- Multi-agent orchestration and conversation management and retrieval.
- Deploy as an API or export as JSON for Python apps.
- Observability with LangSmith, LangFuse and other integrations.
- Enterprise-ready security and scalability.
⚡️ Quickstart
Langflow works with Python 3.10 to 3.13.
Install with uv (recommended)
uv pip install langflow
Install with pip
pip install langflow
📦 Deployment
Self-managed
Langflow is completely open source and you can deploy it to all major deployment clouds. Follow this guide to learn how to use Docker to deploy Langflow.
Fully-managed by DataStax
DataStax Langflow is a full-managed environment with zero setup. Developers can sign up for a free account to get started.
⭐ Stay up-to-date
Star Langflow on GitHub to be instantly notified of new releases.
👋 Contribute
We welcome contributions from developers of all levels. If you'd like to contribute, please check our contributing guidelines and help make Langflow more accessible.