microsoft / semantic-kernel

Integrate cutting-edge LLM technology quickly and easily into your apps
https://aka.ms/semantic-kernel
MIT License
20.48k stars 2.97k forks source link

Python: Add Support for Ollama SDK Connector #6841

Open alliscode opened 2 weeks ago

alliscode commented 2 weeks ago

Add support for Ollama using the Python Ollama SDK. This is separate from Ollama support using the OpenAI Connector.

AndreasKunar commented 1 week ago

If you redo the connectors.AI.ollama, please also think about providing some basic OpenAIPromptExecutionSettings compatibility for OllamaAIPromptExecutionSettings. Currently e.g. "temperature" with OpenAIPromptExecutionSettings becomes "options"."temperature" with OllamaPromptExecutionSettings. This is e.g. breaking the SequentialPlanning settings from python/semantic_kernel/planners/sequential_planner/Plugins/SequentialPlanning/config.json. Yes, I know that Ollama uses "options", but I think exposing this difference to SK plugins,... is bad for the most common parameters like: