fix(typo): use the correct bing name for ai-search. (#1807)

Signed-off-by: maratrixx <maratrix@163.com>
This commit is contained in:
MARATRIX Li
2025-02-25 13:37:32 +08:00
committed by GitHub
parent 49617c7a98
commit e27d3d0971
2 changed files with 5 additions and 5 deletions

View File

@@ -127,7 +127,7 @@ searchFrom:
cx: "news-search-id" # 专门搜索Google News内容的搜索引擎ID
serviceName: "google-svc.dns"
servicePort: 443
- type: being
- type: bing
apiKey: "bing-key"
serviceName: "bing-svc.dns"
servicePort: 443
@@ -190,8 +190,8 @@ searchFrom:
```yaml
needReference: true
referenceFormat: "### 数据来源\n%s"
searchFrom:
- type: being
searchFrom:
- type: bing
apiKey: "your-bing-key"
serviceName: "search-service.dns"
servicePort: 8080

View File

@@ -138,10 +138,10 @@ func parseConfig(json gjson.Result, config *Config, log wrapper.Log) error {
var internetExists, privateExists, arxivExists bool
for _, e := range json.Get("searchFrom").Array() {
switch e.Get("type").String() {
case "being":
case "bing":
searchEngine, err := bing.NewBingSearch(&e)
if err != nil {
return fmt.Errorf("being search engine init failed:%s", err)
return fmt.Errorf("bing search engine init failed:%s", err)
}
config.engine = append(config.engine, searchEngine)
internetExists = true