Tiendil / feeds.fun

News reader with tags & AI
https://feeds.fun
Other
49 stars 4 forks source link

Universal LLM agents #245

Closed Tiendil closed 1 month ago

Tiendil commented 2 months ago

To become more agile in using different LLM providers and open-source solutions, we should migrate from using direct OpenAI clients to a unified intermediate library like LangChain.

Also, there are requests to allow alternatives to OpenAI; for example, see gh-168.

We could provide a way to construct LLM agents via configs by splitting them into three parts: text preprocessor, LLM request config, and tags parser.

We may need different keys for different processors to track usage (even for a single API provider).

Tiendil commented 2 months ago

Required features:

After examining top libs (LangChain, LLamaIndex, haystack):

Therefore, we'll not use unified libs.

Instead, we'll implement our simplified interface for interaction with LLMs in a way specific to our project.

The first implementation will support OpenAI and Gemini providers. Later, integration with OLLame will be added (by request or when needed).