Skip to content

Commit

Permalink
update go-zero to v1.3.0
Browse files Browse the repository at this point in the history
  • Loading branch information
kevwan committed Feb 5, 2022
1 parent afc1431 commit a04c729
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 45 deletions.
4 changes: 2 additions & 2 deletions bot/adapters/logic/closestmatch.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (

"github.com/kevwan/chatbot/bot/adapters/storage"
"github.com/kevwan/chatbot/bot/nlp"
"github.com/tal-tech/go-zero/core/mr"
"github.com/zeromicro/go-zero/core/mr"
)

const (
Expand Down Expand Up @@ -96,7 +96,7 @@ func (match *closestMatch) processExactMatch(responses map[string]int) []Answer

func (match *closestMatch) processSimilarMatch(text string) []Answer {
result, err := mr.MapReduce(generator(match, text), mapper(match), reducer(match))
if err != nil{
if err != nil {
return nil
}

Expand Down
6 changes: 3 additions & 3 deletions bot/adapters/storage/memorystorage.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ import (
"os"
"sort"

"github.com/tal-tech/go-zero/core/lang"
"github.com/tal-tech/go-zero/core/logx"
"github.com/tal-tech/go-zero/core/mr"
"github.com/wangbin/jiebago"
"github.com/wangbin/jiebago/analyse"
"github.com/zeromicro/go-zero/core/lang"
"github.com/zeromicro/go-zero/core/logx"
"github.com/zeromicro/go-zero/core/mr"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion bot/nlp/sentencedetect.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"strings"
"unicode"

"github.com/tal-tech/go-zero/core/lang"
"github.com/zeromicro/go-zero/core/lang"
)

var (
Expand Down
5 changes: 1 addition & 4 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,17 @@ module github.com/kevwan/chatbot
go 1.17

require (
github.com/tal-tech/go-zero v1.2.5
github.com/wangbin/jiebago v0.3.2
github.com/zeromicro/go-zero v1.3.0
gopkg.in/yaml.v2 v2.4.0
)

require (
github.com/go-logr/logr v1.2.2 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/google/go-cmp v0.5.7 // indirect
github.com/kr/pretty v0.3.0 // indirect
github.com/rogpeppe/go-internal v1.8.1 // indirect
github.com/spaolacci/murmur3 v1.1.0 // indirect
go.opentelemetry.io/otel v1.3.0 // indirect
go.opentelemetry.io/otel/sdk v1.3.0 // indirect
go.opentelemetry.io/otel/trace v1.3.0 // indirect
go.uber.org/automaxprocs v1.4.0 // indirect
golang.org/x/sys v0.0.0-20220114195835-da31bd327af9 // indirect
Expand Down
Loading

0 comments on commit a04c729

Please sign in to comment.