-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
.Net: Add Ollama Connector #7362
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Motivation and Context <!-- Thank you for your contribution to the semantic-kernel repo! Please help reviewers and future users, providing the following information: 1. Why is this change required? 2. What problem does it solve? 3. What scenario does it contribute to? 4. If it fixes an open issue, please link to the issue here. --> ### Description <!-- Describe your changes, the overall approach, the underlying design. These notes will help understanding how your code works. Thanks! --> ### Contribution Checklist <!-- Before submitting this PR, please make sure: --> - [ ] The code builds clean without any errors or warnings - [ ] The PR follows the [SK Contribution Guidelines](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md) and the [pre-submission formatting script](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md#development-scripts) raises no violations - [ ] All unit tests pass, and I have added new tests where possible - [ ] I didn't break anyone 😄
### Motivation and Context <!-- Thank you for your contribution to the semantic-kernel repo! Please help reviewers and future users, providing the following information: 1. Why is this change required? 2. What problem does it solve? 3. What scenario does it contribute to? 4. If it fixes an open issue, please link to the issue here. --> ### Description <!-- Describe your changes, the overall approach, the underlying design. These notes will help understanding how your code works. Thanks! --> ### Contribution Checklist <!-- Before submitting this PR, please make sure: --> - [ ] The code builds clean without any errors or warnings - [ ] The PR follows the [SK Contribution Guidelines](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md) and the [pre-submission formatting script](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md#development-scripts) raises no violations - [ ] All unit tests pass, and I have added new tests where possible - [ ] I didn't break anyone 😄 --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Evan Mattson <[email protected]> Co-authored-by: Dmytro Struk <[email protected]> Co-authored-by: Ikko Eltociear Ashimine <[email protected]> Co-authored-by: Chris <[email protected]> Co-authored-by: ShuaiHua Du <[email protected]> Co-authored-by: Krzysztof Kasprowicz <[email protected]> Co-authored-by: Mark Wallace <[email protected]> Co-authored-by: SergeyMenshykh <[email protected]> Co-authored-by: Nico Möller <[email protected]> Co-authored-by: Nico Möller <[email protected]> Co-authored-by: westey <[email protected]> Co-authored-by: Tao Chen <[email protected]> Co-authored-by: Eduard van Valkenburg <[email protected]> Co-authored-by: NEWTON MALLICK <[email protected]> Co-authored-by: qowlsdn8007 <[email protected]> Co-authored-by: Gil LaHaye <[email protected]>
…ustments (#7212) ### Motivation and Context - Integration Tests added - Metadata generated with new client result data - Adjustments in parameter names, following SK convention.
### Motivation and Context Using most recent update where a ChatMessage metadata can be used by OllamaSharp Client Chat(). ### Description <!-- Describe your changes, the overall approach, the underlying design. These notes will help understanding how your code works. Thanks! --> ### Contribution Checklist <!-- Before submitting this PR, please make sure: --> - [ ] The code builds clean without any errors or warnings - [ ] The PR follows the [SK Contribution Guidelines](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md) and the [pre-submission formatting script](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md#development-scripts) raises no violations - [ ] All unit tests pass, and I have added new tests where possible - [ ] I didn't break anyone 😄
markwallace-microsoft
added
.NET
Issue or Pull requests regarding .NET code
kernel
Issues or pull requests impacting the core kernel
labels
Jul 19, 2024
github-actions
bot
changed the title
Draft Merge main into connectors ollama
.Net: Draft Merge main into connectors ollama
Jul 19, 2024
RogerBarreto
changed the title
.Net: Draft Merge main into connectors ollama
.Net: [Draft] main -> feature-connectors-ollama
Jul 19, 2024
…nto upstream/feature-connectors-ollama
### Motivation and Context - Update to the latest version of `OllamaSharp` - Adapted to the new changes to Embedding API update below awaescher/OllamaSharp#60
RogerBarreto
changed the title
.Net: [Draft] main -> feature-connectors-ollama
.Net: Add support for Ollama Connector
Aug 14, 2024
RogerBarreto
changed the title
.Net: Add support for Ollama Connector
.Net: Add Ollama Connector
Aug 14, 2024
### Motivation and Context Adding missing samples using the new Ollama Connector. - Embedding generation - Text Generation - Chat Completion - AIModelRouting Demo with Ollama Connector
### Motivation and Context Small fix identified during bugbash.
dotnet/samples/Concepts/ChatCompletion/Ollama_ChatCompletionStreaming.cs
Show resolved
Hide resolved
dotnet/src/Connectors/Connectors.Ollama.UnitTests/HttpMessageHandlerStub.cs
Outdated
Show resolved
Hide resolved
dotnet/src/Connectors/Connectors.Ollama/Connectors.Ollama.csproj
Outdated
Show resolved
Hide resolved
dotnet/src/Connectors/Connectors.Ollama/Connectors.Ollama.csproj
Outdated
Show resolved
Hide resolved
dotnet/src/Connectors/Connectors.Ollama/Core/OllamaChatResponseStreamer.cs
Outdated
Show resolved
Hide resolved
dotnet/samples/Concepts/ChatCompletion/Ollama_ChatCompletion.cs
Outdated
Show resolved
Hide resolved
dotnet/samples/Concepts/ChatCompletion/Ollama_ChatCompletion.cs
Outdated
Show resolved
Hide resolved
dotnet/src/Connectors/Connectors.Ollama.UnitTests/OllamaPromptExecutionSettingsTests.cs
Outdated
Show resolved
Hide resolved
dotnet/src/Connectors/Connectors.Ollama.UnitTests/OllamaPromptExecutionSettingsTests.cs
Outdated
Show resolved
Hide resolved
dotnet/src/Connectors/Connectors.Ollama.UnitTests/OllamaTestHelper.cs
Outdated
Show resolved
Hide resolved
dotnet/src/Connectors/Connectors.Ollama.UnitTests/OllamaTestHelper.cs
Outdated
Show resolved
Hide resolved
dotnet/src/Connectors/Connectors.Ollama.UnitTests/Services/OllamaChatCompletionTests.cs
Show resolved
Hide resolved
dotnet/src/Connectors/Connectors.Ollama/Extensions/OllamaServiceCollectionExtensions.cs
Show resolved
Hide resolved
dotnet/src/Connectors/Connectors.Ollama/OllamaPromptExecutionSettings.cs
Outdated
Show resolved
Hide resolved
dotnet/src/Connectors/Connectors.Ollama/Services/OllamaChatCompletionService.cs
Show resolved
Hide resolved
### Motivation and Context Address current feature -> main PR feedback.
SergeyMenshykh
approved these changes
Sep 6, 2024
markwallace-microsoft
approved these changes
Sep 6, 2024
Thank you. I think we are many who have been waiting for this. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation and Context
This PR brings support for Ollama Connector, this Connector uses the
OllamaSharp
library client to allow usage of native Ollama Endpoints.