Skip to content

Commit

Permalink
修改: bot/adapters/storage/memorystorage.go
Browse files Browse the repository at this point in the history
  • Loading branch information
TsaoLun committed Aug 15, 2023
1 parent 0514fdc commit dac2de9
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions bot/adapters/storage/memorystorage.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@ var (
thresholdForKeywords = 5
maxSearchResults = 100
thresholdForStopWords = 100
dictFile = "../etc/dict.txt"
idfFile = "../etc/idf.txt"
stopWordsFile = "../etc/stop_words.txt"
generatedStopWordsFile = "../etc/stopwords.txt"
dictFile = "./etc/dict.txt"
idfFile = "./etc/idf.txt"
stopWordsFile = "./etc/stop_words.txt"
generatedStopWordsFile = "./etc/stopwords.txt"
)

func init() {
// 获取当前文件的绝对路径
dir := os.Args[0]
dir, _ := os.Getwd()
dictFile = path.Join(dir, dictFile)
idfFile = path.Join(dir, idfFile)
stopWordsFile = path.Join(dir, stopWordsFile)
Expand Down

0 comments on commit dac2de9

Please sign in to comment.