Skip to content

Commit be29873

Browse files
ManuInNZcicoyle
andauthored
feat: Add Ollama component for conversation to support Ollama models usage (dapr#8573)
* feat: ✨ Add Ollama component for conversation to support Ollama models usage Signed-off-by: Emmanuel Auffray <[email protected]> * Temporarily fixing a repo and branch Signed-off-by: Emmanuel Auffray <[email protected]> * Temp fix pseudo version and override default contrib module Signed-off-by: Emmanuel Auffray <[email protected]> * ci: ✨ Reference the new pseudo version Signed-off-by: Emmanuel Auffray <[email protected]> * update go.mod and go.sum to include github.com/moby/sys/userns v0.1.0 and downgrade github.com/go-jose/go-jose/v3 to v3.0.1 Signed-off-by: Emmanuel Auffray <[email protected]> --------- Signed-off-by: Emmanuel Auffray <[email protected]> Co-authored-by: Cassie Coyle <[email protected]>
1 parent 1d84315 commit be29873

File tree

3 files changed

+33
-5
lines changed

3 files changed

+33
-5
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
//go:build allcomponents
2+
3+
/*
4+
Copyright 2024 The Dapr Authors
5+
Licensed under the Apache License, Version 2.0 (the "License");
6+
you may not use this file except in compliance with the License.
7+
You may obtain a copy of the License at
8+
9+
http://www.apache.org/licenses/LICENSE-2.0
10+
11+
Unless required by applicable law or agreed to in writing, software
12+
distributed under the License is distributed on an "AS IS" BASIS,
13+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
See the License for the specific language governing permissions and
15+
limitations under the License.
16+
*/
17+
18+
package components
19+
20+
import (
21+
"github.com/dapr/components-contrib/conversation/ollama"
22+
"github.com/dapr/dapr/pkg/components/conversation"
23+
)
24+
25+
func init() {
26+
conversation.DefaultRegistry.RegisterComponent(ollama.NewOllama, "ollama")
27+
}

go.mod

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ require (
1111
github.com/argoproj/argo-rollouts v1.4.1
1212
github.com/cenkalti/backoff/v4 v4.3.0
1313
github.com/cloudevents/sdk-go/v2 v2.15.2
14-
github.com/dapr/components-contrib v1.15.2
14+
github.com/dapr/components-contrib v1.15.1-0.20250323163817-47947d8770b9
1515
github.com/dapr/durabletask-go v0.6.5
1616
github.com/dapr/kit v0.15.1
1717
github.com/diagridio/go-etcd-cron v0.4.4
@@ -337,6 +337,7 @@ require (
337337
github.com/mitchellh/go-homedir v1.1.0 // indirect
338338
github.com/mitchellh/reflectwalk v1.0.2 // indirect
339339
github.com/moby/spdystream v0.4.0 // indirect
340+
github.com/moby/sys/userns v0.1.0 // indirect
340341
github.com/moby/term v0.5.0 // indirect
341342
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
342343
github.com/modern-go/reflect2 v1.0.2 // indirect

go.sum

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -478,8 +478,8 @@ github.com/dancannon/gorethink v4.0.0+incompatible h1:KFV7Gha3AuqT+gr0B/eKvGhbjm
478478
github.com/dancannon/gorethink v4.0.0+incompatible/go.mod h1:BLvkat9KmZc1efyYwhz3WnybhRZtgF1K929FD8z1avU=
479479
github.com/danieljoos/wincred v1.1.2 h1:QLdCxFs1/Yl4zduvBdcHB8goaYk9RARS2SgLLRuAyr0=
480480
github.com/danieljoos/wincred v1.1.2/go.mod h1:GijpziifJoIBfYh+S7BbkdUTU4LfM+QnGqR5Vl2tAx0=
481-
github.com/dapr/components-contrib v1.15.2 h1:HdnfBsqQX9jsA7Bd6zlUnXuFXiiMUsD4oFkhC68Ep+4=
482-
github.com/dapr/components-contrib v1.15.2/go.mod h1:A99RyJ+KMF44zLryDGF4epwj9E/TwDq22lgfmrBeYE8=
481+
github.com/dapr/components-contrib v1.15.1-0.20250323163817-47947d8770b9 h1:YLS2i/DhqbxvNuAEB3WNCMUrMFI7dGsbA3N064h7fqg=
482+
github.com/dapr/components-contrib v1.15.1-0.20250323163817-47947d8770b9/go.mod h1:xfQwDGC8O7/6BRhc7u0Zqg9ObuavQFoTR1p8+qqsN5w=
483483
github.com/dapr/durabletask-go v0.6.5 h1:aWcxMfYudojpgRjJRdUr7yyZ7rGcvLtWXUuA4cGHBR0=
484484
github.com/dapr/durabletask-go v0.6.5/go.mod h1:nTZ5fCbJLnZbVdi6Z2YxdDF1OgQZL3LroogGuetrwuA=
485485
github.com/dapr/kit v0.15.1 h1:WInC8IBveslveCBE2DDeaXh62Si4Wr2Fdv2yJ/7hrDQ=
@@ -637,8 +637,8 @@ github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2
637637
github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8=
638638
github.com/go-ini/ini v1.67.0 h1:z6ZrTEZqSWOTyH2FlglNbNgARyHG8oLW9gMELqKr06A=
639639
github.com/go-ini/ini v1.67.0/go.mod h1:ByCAeIL28uOIIG0E3PJtZPDL8WnHpFKFOtgjp+3Ies8=
640-
github.com/go-jose/go-jose/v3 v3.0.3 h1:fFKWeig/irsp7XD2zBxvnmA/XaRWp5V3CBsZXJF7G7k=
641-
github.com/go-jose/go-jose/v3 v3.0.3/go.mod h1:5b+7YgP7ZICgJDBdfjZaIt+H/9L9T/YQrVfLAMboGkQ=
640+
github.com/go-jose/go-jose/v3 v3.0.1 h1:pWmKFVtt+Jl0vBZTIpz/eAKwsm6LkIxDVVbFHKkchhA=
641+
github.com/go-jose/go-jose/v3 v3.0.1/go.mod h1:RNkWWRld676jZEYoV3+XK8L2ZnNSvIsxFMht0mSX+u8=
642642
github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
643643
github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
644644
github.com/go-kit/kit v0.10.0 h1:dXFJfIHVvUcpSgDOV+Ne6t7jXri8Tfv2uOLHUZ2XNuo=

0 commit comments

Comments
 (0)