diff --git a/docs/newsnow_plugin_config.md b/docs/newsnow_plugin_config.md index 8be887c25..dda1c1a45 100644 --- a/docs/newsnow_plugin_config.md +++ b/docs/newsnow_plugin_config.md @@ -1,105 +1,105 @@ -# get_news_from_newsnow 插件新闻源配置指南 +# get_news_from_newsnow plugin news source configuration guide -## 概述 +## Overview -`get_news_from_newsnow` 插件现在支持通过Web管理界面动态配置新闻源,不再需要修改代码。用户可以在智控台中为每个智能体配置不同的新闻源。 +The `get_news_from_newsnow` plugin now supports dynamic configuration of news sources through the web management interface, eliminating the need for code modifications. Users can configure different news sources for each agent in the dashboard. -## 配置方式 +## Configuration -### 1. 通过Web管理界面配置(推荐) +### 1. Configuration via the Web Management Interface (Recommended) -1. 登录智控台 -2. 进入"角色配置"页面 -3. 选择要配置的智能体 -4. 点击"编辑功能"按钮 -5. 在右侧参数配置区域找到"newsnow新闻聚合"插件 -6. 在"新闻源配置"字段中输入分号分隔的中文名称 +1. Log in to the smart console +2. Enter the "Role Configuration" page +3. Select the agent to configure +4. Click the "Edit Function" button +5. Find the "newsnow news aggregation" plug-in in the parameter configuration area on the right +6. Enter the Chinese name separated by semicolons in the "News Source Configuration" field -### 2. 配置文件方式 +### 2. Configuration file method -在 `config.yaml` 中配置: +Configure in `config.yaml`: ```yaml plugins: get_news_from_newsnow: url: "https://newsnow.busiyi.world/api/s?id=" - news_sources: "澎湃新闻;百度热搜;财联社;微博;抖音" + news_sources: "The Paper; Baidu Trending Search; Cailianshe; Weibo; TikTok" ``` -## 新闻源配置格式 +## News source configuration format -新闻源配置使用分号分隔的中文名称,格式为: +The news source configuration uses Chinese names separated by semicolons in the following format: ``` -中文名称1;中文名称2;中文名称3 +Chinese name 1; Chinese name 2; Chinese name 3 ``` -### 配置示例 +### Configuration Example ``` -澎湃新闻;百度热搜;财联社;微博;抖音;知乎;36氪 +The Paper; Baidu Trending Search; Cailianshe; Weibo; Douyin; Zhihu; 36Kr ``` -## 支持的新闻源 +## Supported News Sources -插件支持以下新闻源的中文名称: +The plugin supports the following Chinese names of news sources: -- 澎湃新闻 -- 百度热搜 -- 财联社 -- 微博 -- 抖音 -- 知乎 -- 36氪 -- 华尔街见闻 -- IT之家 -- 今日头条 -- 虎扑 -- 哔哩哔哩 -- 快手 -- 雪球 -- 格隆汇 -- 法布财经 -- 金十数据 -- 牛客 -- 少数派 -- 稀土掘金 -- 凤凰网 -- 虫部落 -- 联合早报 -- 酷安 -- 远景论坛 -- 参考消息 -- 卫星通讯社 -- 百度贴吧 -- 靠谱新闻 -- 以及更多... +- The Paper +- Baidu Hot Search +- Cailianshe +- Weibo +- Tik Tok +- Zhihu +- 36Kr +- Wall Street Journal +- IT Home +- Toutiao +- Hupu +- Bilibili +- Kuaishou +- Snowball +- Gelonghui +- Fab Finance +- Jinshi Data +- Niuke +- Minority +- Rare Earth Mining +- Phoenix.com +- Bug Tribe +- Lianhe Zaobao +- Cool Security +- Vision Forum +- Reference News +- Satellite News Agency +- Baidu Tieba +- Reliable News +- and more... -## 默认配置 +## Default Configuration -如果未配置新闻源,插件将使用以下默认配置: +If no news source is configured, the plugin will use the following default configuration: ``` -澎湃新闻;百度热搜;财联社 +The Paper; Baidu Trending Search; Cailianshe ``` -## 使用说明 +## Usage Instructions -1. **配置新闻源**:在Web界面或配置文件中设置新闻源的中文名称,用分号分隔 -2. **调用插件**:用户可以说"播报新闻"或"获取新闻" -3. **指定新闻源**:用户可以说"播报澎湃新闻"或"获取百度热搜" -4. **获取详情**:用户可以说"详细介绍这条新闻" +1. **Configure news source**: Set the Chinese name of the news source in the web interface or configuration file, separated by semicolons +2. **Call plugin**: Users can say "broadcast news" or "get news" +3. **Specify news source**: Users can say "report The Paper" or "get Baidu trending searches" +4. **Get details**: Users can say "Get more details about this news" -## 工作原理 +How it works -1. 插件接受中文名称作为参数(如"澎湃新闻") -2. 根据配置的新闻源列表,将中文名称转换为对应的英文ID(如"thepaper") -3. 使用英文ID调用API获取新闻数据 -4. 返回新闻内容给用户 +1. The plugin accepts Chinese names as parameters (e.g. "The Paper") +2. According to the configured news source list, convert the Chinese name to the corresponding English ID (such as "thepaper") +3. Use the English ID to call the API to obtain news data +4. Return news content to the user -## 注意事项 +## Notes -1. 配置的中文名称必须与 CHANNEL_MAP 中定义的名称完全一致 -2. 配置更改后需要重启服务或重新加载配置 -3. 如果配置的新闻源无效,插件会自动使用默认新闻源 -4. 多个新闻源之间使用英文分号(;)分隔,不要使用中文分号(;) \ No newline at end of file +1. The configured Chinese name must be exactly the same as the name defined in CHANNEL_MAP +2. After the configuration changes, you need to restart the service or reload the configuration +3. If the configured news source is invalid, the plugin will automatically use the default news source +4. Use English semicolons (;) to separate multiple news sources. Do not use Chinese semicolons (;).