Skip to content

Commit

Permalink
add plugin dump doc
Browse files Browse the repository at this point in the history
  • Loading branch information
zhangxu0307 committed Jan 10, 2024
1 parent fcfcd9c commit 0137a39
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions website/docs/customization/plugin/plugin_selection.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,28 @@ During the subsequent automatic plugin selection phase, newly chosen plugins are
- `code_generator.enable_auto_plugin_selection`: Whether to enable auto plugin selection. The default value is `false`.
- `code_generator.auto_plugin_selection_topk`: The number of auto selected plugins in each round. The default value is `3`.


## Auto Plugin Selection Preparation

Before using the auto plugin selection mechanism, we need to run the following command to generate the plugin meta files with embeddings.

```bash
cd scripts
python -m plugin_mgt --refresh
```
After that, you can find the `.meta` directory is generated in the `plugins` folder.
Then you can start a new TaskWeaver session with the auto plugin selection mechanism enabled.
Code Generator will automatically load the plugin meta files with embeddings.

🎈Plugin meta files will be treated as invalid if:
- The plugin embedding vector is not generated.
- The plugin is modified.
- The plugin embedding model is changed.

In this case, you cannot start the TaskWeaver and you need to run the above command again to refresh the plugin meta files.

```bash

## Auto Plugin Selection Example

We show the auto plugin selection mechanism in the following example.
Expand Down

0 comments on commit 0137a39

Please sign in to comment.