Commit graph

11,619 commits

Author SHA1 Message Date
Lanznx
12453d1187 feat: redis vector store client 2023-11-06 15:31:58 +08:00
Gabriel Luiz Freitas Almeida
650398f2f4
modify get_current_user to accept api_key as authentication method (#1108) 2023-11-04 10:29:31 -03:00
Maryam Abdoli
b5b66ef077 fix tests by reverting the chat endpoint dependecies 2023-11-03 18:29:51 -04:00
Gabriel Luiz Freitas Almeida
5bd31250da
fix(deps): change appdirs dependency to platformdirs (#1111) 2023-11-03 17:21:34 -03:00
Gabriel Luiz Freitas Almeida
3079318d6a 🔧 chore(constants.py): import BasePromptTemplate to improve code organization and maintainability 2023-11-03 16:47:44 -03:00
Gabriel Luiz Freitas Almeida
00634a2354 Refactor field typing in LLMChainComponent and
related modules
2023-11-03 16:38:56 -03:00
Gabriel Luiz Freitas Almeida
9b23dae530 🐛 fix(chat.py): remove unused user dependency in stream_build function
🐛 fix(chat.py): handle KeyError when retrieving user_id from cache_service
 feat(chat.py): use user_id from cache_service instead of user.id in try_running_celery_task and vertex.build functions
🔧 chore(config.yaml): comment out ConversationChain in chains configuration
🔧 chore(base.py): import SQLDatabaseChain from langchain_experimental.sql module and add it to type_dict
2023-11-03 16:13:15 -03:00
Maryam Abdoli
ef949838e2 fix lints and also the bug in the get_current_user 2023-11-03 13:01:28 -04:00
Gabriel Luiz Freitas Almeida
364d36d194 Fix issues with user authentication and custom
component field config
2023-11-03 13:57:14 -03:00
Gabriel Luiz Freitas Almeida
af8094721f 🔧 chore(custom_component.py): refactor display_name and description attributes to be optional and provide default values 2023-11-03 12:05:21 -03:00
Gabriel Luiz Freitas Almeida
87db2f4d0b 🐛 fix(PromptRunner.py): change beta variable type from string to boolean to match expected type
🐛 fix(Metaphor.py): change beta variable type from string to boolean to match expected type
🐛 fix(GetRequest.py): change beta variable type from string to boolean to match expected type
🐛 fix(JSONDocumentBuilder.py): change beta variable type from string to boolean to match expected type
🐛 fix(PostRequest.py): change beta variable type from string to boolean to match expected type
🐛 fix(UpdateRequest.py): change beta variable type from string to boolean to match expected type
🐛 fix(Chroma.py): change beta variable type from string to boolean to match expected type
🐛 fix(Vectara.py): change beta variable type from string to boolean to match expected type
🐛 fix(component.py): change ERROR_CODE_NULL variable type from dict to string to match expected type
🐛 fix(custom_component.py): change code_class_base_inheritance variable type from dict to string to match expected type
🐛 fix(custom_component.py): change function_entrypoint_name variable type from dict to string to match expected type
🐛 fix(initialize/vector_store.py): change chromadb variable name to chromadb_instance for clarity
🐛 fix(database/manager.py): change expected_columns to use model_fields instead of __fields__ to match new SQLModel version
🐛 fix(database/models/base.py): remove unused model_config variable
🐛 fix(database/models/flow/flow.py): change validator decorator to field_validator to match new pydantic version
🐛 fix(settings.py): change root_validator decorator to model_validator to match new pydantic version
2023-11-03 11:50:03 -03:00
Gabriel Luiz Freitas Almeida
4f2a4ce13c 🔧 chore(custom_component.py): refactor class variables to use assignment instead of type annotations for better readability and consistency 2023-11-03 11:11:30 -03:00
Gabriel Luiz Freitas Almeida
1a8825f491 Add memory info to ConversationChainComponent 2023-11-03 11:11:10 -03:00
Gabriel Luiz Freitas Almeida
12cc665566 🔧 chore(pyproject.toml): update black, mypy, pytest, types-requests, requests, and pytest-cov dependencies to their latest versions for better compatibility and functionality 2023-11-03 11:05:59 -03:00
Gabriel Luiz Freitas Almeida
8887b5ca28 🐛 fix(util.py): add logic to extract type from Union[Literal['f-string'], Literal['jinja2']] to improve type formatting
🐛 fix(test_prompts_template.py): fix incorrect value for "validate_template" field in test case
2023-11-03 10:47:58 -03:00
Maryam Abdoli
83425b09cd handle all exceptions during user retrieving 2023-11-03 09:29:24 -04:00
cristhianzl
4b8349d131 fix(baseModal): add "smaller-h-full" size option to improve modal size flexibility
fix(exportModal): update size prop of BaseModal to "smaller-h-full" to match the new size option
2023-11-03 10:21:08 -03:00
Gabriel Luiz Freitas Almeida
71aeda669e 🔨 refactor(test_chains_template.py): remove unused test functions to improve code readability and maintainability 2023-11-03 09:37:23 -03:00
Gladson
819c283fe3
fix(base.py): change import to from platformdirs 2023-11-03 02:36:05 -04:00
Gladson
7713173da7
fix(logger.py): change appdirs dependency to platformdirs 2023-11-03 02:11:12 -04:00
Gladson
307c526d6a
fix(base.py): change appdirs dependency to platformdirs 2023-11-03 02:08:36 -04:00
Gladson
1023522e5e
fix(utils.py): change appdirs dependency to platformdirs 2023-11-03 02:06:25 -04:00
Gladson
1fe868e4d8
fix(pyproject.toml): change appdirs dependency to platformdirs 2023-11-03 02:03:18 -04:00
Gabriel Luiz Freitas Almeida
941cdd4990 📦 chore(ConversationChain.py): add ConversationChain component to handle conversations and load context from memory
📦 chore(LLMChain.py): add optional memory parameter to LLMChain build method to support loading context from memory
2023-11-02 22:54:17 -03:00
Gabriel Luiz Freitas Almeida
c23d797677 Add LLMChain component for running queries against
LLMs
2023-11-02 22:46:15 -03:00
Gabriel Luiz Freitas Almeida
d87b6228df Update function base classes to use Callable
instead of function
2023-11-02 22:45:49 -03:00
Gabriel Luiz Freitas Almeida
5c5ef227d1 Add Callable to field_typing constants 2023-11-02 22:45:16 -03:00
Gabriel Luiz Freitas Almeida
cef6d78070 🔥 refactor(config.yaml): comment out LLMChain to disable it temporarily
The LLMChain has been commented out in the config.yaml file to disable it temporarily. This change was made to prevent the LLMChain from being used until further notice.
2023-11-02 22:44:43 -03:00
Gabriel Luiz Freitas Almeida
4472263c24 ⬆️ chore(pyproject.toml): update chromadb version from 0.3.21 to 0.4.0 for compatibility and bug fixes
⬆️ chore(pyproject.toml): update pypdf version from 3.15.0 to 3.17.0 for compatibility and bug fixes
2023-11-02 22:43:09 -03:00
Gabriel Luiz Freitas Almeida
c90fe4cc8f 🐛 fix(test_user.py): fix linting issue by adding noqa comment to long lines 2023-11-02 22:35:24 -03:00
Gabriel Luiz Freitas Almeida
640c2b6ef2 🐛 fix(flow.py): make description field nullable with a default value of None to allow empty descriptions
🐛 fix(user.py): make last_login_at field nullable to handle cases where user has not logged in yet
🐛 fix(user.py): set default values for optional fields in UserUpdate model to None to avoid unexpected behavior
2023-11-02 22:21:10 -03:00
Gabriel Luiz Freitas Almeida
4bfaca5f21 🐛 fix(custom_component.py): fix syntax error in CustomComponent class definition
 feat(custom_component.py): add display_name and description class variables to CustomComponent for better customization and documentation
2023-11-02 22:20:57 -03:00
Gabriel Luiz Freitas Almeida
93d0ba79f1 🔧 fix(conftest.py): add description field to the FlowCreate object to provide additional information about the flow 2023-11-02 22:20:16 -03:00
Gabriel Luiz Freitas Almeida
780b0d68d8 🔧 fix(test_database.py): add description field to FlowCreate object to fix test failure caused by missing required field
🐛 fix(test_user.py): update error message and details for invalid UUID input in test_patch_user_wrong_id and test_delete_user_wrong_id to provide more specific information
2023-11-02 22:19:58 -03:00
Gabriel Luiz Freitas Almeida
5320da2f06 🔧 fix(field_typing): import BaseLanguageModel in __init__.py to resolve missing import error
🔧 fix(constants.py): import BaseLanguageModel in constants.py to resolve missing import error
2023-11-02 22:19:19 -03:00
Gabriel Luiz Freitas Almeida
3fe4660c0e 🔀 chore(custom.py): update import statements to reflect changes in package structure 2023-11-02 22:18:38 -03:00
Maryam Abdoli
5686a6fd63 pass the oauth2 token to the fastapi Security 2023-11-02 16:35:00 -04:00
cristhianzl
dd63dadd51 fix(extraSidebarComponent): remove unnecessary export functionality and update tooltip content to "Import" for clarity
The export functionality was removed from the ExtraSidebar component as it was not being used. The tooltip content for the button was also updated to "Import" to accurately reflect its purpose.
2023-11-02 17:28:47 -03:00
cristhianzl
805ee58254 fix(tagsSelectorComponent): reduce the gap between tags in the TagsSelector component for better visual alignment
fix(ConfirmationModal): add top margin to the confirmation button in the ConfirmationModal component to improve spacing

fix(extraSidebarComponent): change the size prop value of the ShareFlowButton component to "small-h-full" for better visual alignment

fix(extraSidebarComponent): add cursor pointer and click event to the text indicating the sharing status in the ShareFlowButton component to toggle the sharePublic state

fix(extraSidebarComponent): reduce the gap between elements in the ConfirmationModal content for better visual alignment

fix(extraSidebarComponent): change the className of the ExportModal button to "extra-side-bar-buttons" and add an onClick event to trigger the uploadFlow function

fix(extraSidebarComponent): change the className of the ExportModal button to "extra-side-bar-buttons" and add an onClick event to trigger the uploadFlow function

fix(extraSidebarComponent): change the className of the Save button in the ExtraSidebar component to "extra-side-bar-buttons" and add an onClick event to trigger the saveFlow function

fix(StorePage): remove console.log statement in the StorePage component

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class

fix(applies.css): remove unnecessary padding-bottom from the .main-page-flows-display class
2023-11-02 17:24:35 -03:00
Gabriel Luiz Freitas Almeida
15e244f17a Merge remote-tracking branch 'origin/dev' into v2 2023-11-02 17:09:04 -03:00
Gabriel Luiz Freitas Almeida
008dbd1237 🔀 merge(base.py): merge changes from langfuse branch to base.py
🔀 merge(base.py): merge changes from langfuse branch to base.py to fix import and callback initialization
2023-11-02 16:51:40 -03:00
Gabriel Luiz Freitas Almeida
faa2a79c2b 🔧 fix(getters.py): add import statement for PluginService in getters.py to fix import error
 feat(plugins/base.py): add BasePlugin class with initialize, teardown, and get methods to serve as base class for plugins
 feat(plugins/factory.py): add PluginServiceFactory class to create PluginService instance and load plugins
 feat(plugins/langfuse.py): add LangfusePlugin class with initialize, teardown, and get methods to serve as a plugin for Langfuse
 feat(plugins/service.py): add PluginService class to manage plugins, load plugins, register plugins, get plugins, and teardown plugins
 feat(schema.py): add PLUGIN_SERVICE to ServiceType enum to support plugin service
🔧 fix(settings/base.py): add PLUGIN_DIR optional setting to support specifying plugin directory
🔧 fix(utils.py): add import statement for plugins_factory in utils.py to fix import error
2023-11-02 16:51:03 -03:00
Gabriel Luiz Freitas Almeida
0a4de7ca94 🔧 fix(endpoints.py): update import statement for TaskService to match new file structure
🔧 fix(service.py): update import statement for SettingsService to match new file structure
🔧 fix(__init__.py): update import statement for service module to match new file structure
🔧 fix(factory.py): update import statement for SettingsService to match new file structure
🔧 fix(factory.py): update import statement for TaskService to match new file structure
🔧 fix(conftest.py): update import statement for DatabaseService to match new file structure
2023-11-02 16:18:50 -03:00
Gabriel Luiz Freitas Almeida
75ac412662 🔧 fix(env.py): update import statement for SQLModel in env.py to match new file structure
🔧 fix(chat.py): update import statements for ChatService and BaseCacheService in chat.py to match new file structure
🔧 fix(__init__.py): update import statement for InMemoryCache in __init__.py to match new file structure
🔧 fix(factory.py): update import statement for InMemoryCache, RedisCache, and BaseCacheService in factory.py to match new file structure
🔧 fix(service.py): create new file service.py and move InMemoryCache class from base.py to service.py
 feat(service.py): add InMemoryCache class to provide a simple in-memory cache implementation
 feat(service.py): add RedisCache class to provide a Redis-based cache implementation

🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py): update import statements to reflect changes in file structure
🔨 refactor(factory.py):

📦 chore(service.py): add new file `service.py` to implement DatabaseService class
📦 chore(utils.py): add import statement for DatabaseService in `utils.py`
📦 chore(getters.py): add import statement for DatabaseService in `getters.py`
📦 chore(factory.py): add import statement for SessionService in `factory.py`
📦 chore(service.py): add new file `service.py` to implement SessionService class

📦 chore(service.py): add SettingsService and TaskService classes to handle settings and tasks respectively
🔧 refactor(service.py): refactor load_settings_from_yaml method to load settings from a YAML file and convert keys to uppercase for consistency
🔧 refactor(service.py): refactor get_backend method to return the appropriate backend based on USE_CELERY flag
🔧 refactor(service.py): refactor launch_and_await_task method to handle launching and awaiting tasks based on USE_CELERY flag
🔧 refactor(service.py): refactor launch_task method to handle launching tasks based on USE_CELERY flag
🔧 refactor(service.py): refactor get_task method to get a task based on USE_CELERY flag
🔧 refactor(service.py): refactor check_celery_availability method to check if Celery is available and return its status
🔧 refactor(service.py): refactor USE_CELERY flag to check if Celery is available and set it accordingly
2023-11-02 16:17:24 -03:00
Maryam Abdoli
a39cdb93ee modify get_current_user to accept api_key as authentication method 2023-11-02 10:26:10 -04:00
cristhianzl
192f8f061e Merge branch 'feature/store' of github.com:logspace-ai/langflow into feature/store 2023-11-02 09:57:13 -03:00
cristhianzl
b3bb568526 feat(storeContext.tsx): add hasApiKey state and setHasApiKey function to storeContext to track if API key is present
fix(StorePage/index.tsx): fix useEffect dependencies and add missing handleChangeTab function
fix(API/index.ts): rename getNumberOfComponents function to getCountComponents to improve semantics
2023-11-02 09:57:03 -03:00
Gabriel Luiz Freitas Almeida
c1bc2de720 🐛 fix(buildTrigger): rename import of TabsState to FlowsState to improve semantics
🐛 fix(EditNodeModal): rename import of TabsState to FlowsState to improve semantics
🐛 fix(formModal): rename import of TabsState to FlowsState to improve semantics
🐛 fix(PageComponent): rename import of TabsState to FlowsState to improve semantics
🐛 fix(reactflowUtils): rename import of TabsState to FlowsState to improve semantics
🐛 fix(utils): rename import of TabsState to FlowsState to improve semantics
🚚 chore(server.ts): change port variable case from lowercase port to uppercase PORT to improve semantics
 feat(server.ts): add support for process.env.PORT environment variable to be able to run app on a configurable port
2023-11-02 09:41:39 -03:00
Gabriel Luiz Freitas Almeida
7ca750bbde 🔧 fix(store.py): add support for filtering components based on is_component parameter in count_components function
🔧 fix(service.py): add support for filtering components based on is_component parameter in StoreService.count_components method
2023-11-02 09:37:41 -03:00
Gabriel Luiz Freitas Almeida
0c90c12c94 🔍 refactor(store.py): add support for filtering components based on is_component flag in list_components function
🔍 refactor(service.py): add support for filtering components based on is_component flag in get_components function
2023-11-02 09:34:02 -03:00