Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions packages/document/docs/en/guide/start/ai.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,21 @@ In the [rstackjs/agent-skills](https://github.com/rstackjs/agent-skills) reposit

- [rsdoctor-analysis](https://github.com/rstackjs/agent-skills#rsdoctor-skills): Use Rsdoctor for build analysis and provide optimization recommendations.

The `rsdoctor-analysis` skill analyzes the data in `rsdoctor-data.json`. You can generate this file by setting `output.mode` to `'brief'` and `output.options.type` to `['json']`:
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this mean we need to manually adjust the configuration before using the skill? This seems not user friendly.


```js
new RsdoctorRspackPlugin({
output: {
mode: 'brief',
options: {
type: ['json'],
},
},
});
```

You can also set the `RSDOCTOR_OUTPUT='json'` environment variable to output the analysis data as a JSON file. This environment configuration requires `@rsdoctor/*-plugin` version `>= 1.5.11`.
Comment thread
yifancong marked this conversation as resolved.
Comment thread
yifancong marked this conversation as resolved.

In Coding Agents that support skills, you can use the [skills](https://www.npmjs.com/package/skills) package to install a specific skill with the following command:

<PackageManagerTabs
Expand Down
15 changes: 15 additions & 0 deletions packages/document/docs/zh/guide/start/ai.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,21 @@ Agent Skills 是可安装到 Agent 中的领域知识包,能够让 Agent 在

- [rsdoctor-analysis](https://github.com/rstackjs/agent-skills#rsdoctor-skills):使用 Rsdoctor 进行构建分析并提供优化建议。

`rsdoctor-analysis` Skill 分析的是 `rsdoctor-data.json` 中的数据。你可以通过将 `output.mode` 设置为 `'brief'`,并将 `output.options.type` 设置为 `['json']` 来生成该文件:

```js
new RsdoctorRspackPlugin({
output: {
mode: 'brief',
options: {
type: ['json'],
},
},
});
```

也可以通过设置 `RSDOCTOR_OUTPUT='json'` 环境变量,将分析数据输出为 JSON 文件。这个环境配置需要 `@rsdoctor/*-plugin` `>= 1.5.11`。

Comment thread
yifancong marked this conversation as resolved.
在支持 Skills 的 Coding Agent 中,可以通过以下命令使用 [skills](https://www.npmjs.com/package/skills) 包安装指定的 Skill:

<PackageManagerTabs
Expand Down
Loading