camel icon indicating copy to clipboard operation
camel copied to clipboard

[Feature Request] Unify `loaders` interfaces

Open lightaime opened this issue 10 months ago • 2 comments

Required prerequisites

  • [x] I have searched the Issue Tracker and Discussions that this hasn't already been reported. (+1 or comment there if it has.)
  • [ ] Consider asking first in a Discussion.

Motivation

The interfaces of loaders https://docs.camel-ai.org/key_modules/loaders.html is totally different. We should introduce a BaseLoader to unify the interfaces.

Rename xxx_reader to xxx_loader for better readability.

Solution

No response

Alternatives

No response

Additional context

No response

lightaime avatar Feb 11 '25 18:02 lightaime

@Wendong-Fan , I can take this one. Besides, I will probably need more information about BaseLoader.

JoyceXu02 avatar Feb 24 '25 03:02 JoyceXu02

Thanks @JoyceXu02 ! This abstract class need to defines the standard interface that all loaders must implement and providing a unified way to load and process different types of data sources

some components could be: init(config): Common configuration initialization load(source, **kwargs): Main abstract method for loading data supported_formats: Property to declare supported formats

let me know if there's anything else I could support!

Wendong-Fan avatar Feb 24 '25 05:02 Wendong-Fan