tryAGI / LangChain

C# implementation of LangChain. We try to be as close to the original as possible in terms of abstractions, but are open to new entities.
https://tryagi.github.io/LangChain/
MIT License
507 stars 78 forks source link

Providers: Universal Source Generator for tools/functions #248

Closed HavenDV closed 1 month ago

HavenDV commented 4 months ago

this part seems weird to me var service = new BookStoreService(); model.AddGlobalTools(service.AsAnthropicTools(), service.AsAnthropicCalls()); seems like it should be more like model.GetService()

unfortunately I have not yet abstracted the functions, so far this has only been implemented for a few providers, including OpenAI, Antropic and Gemini

They can be in different formats (both in OpenAPI and xml), I would like to have a more universal generator that also has a fallback for any model

HavenDV commented 1 month ago

Closed in #419