nonebot-plugin-copywrite 0.2.3__tar.gz → 0.3.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- nonebot_plugin_copywrite-0.3.1/.github/workflows/workflow.yml +85 -0
- nonebot_plugin_copywrite-0.3.1/.gitignore +176 -0
- nonebot_plugin_copywrite-0.2.3/README.md → nonebot_plugin_copywrite-0.3.1/PKG-INFO +104 -13
- nonebot_plugin_copywrite-0.2.3/PKG-INFO → nonebot_plugin_copywrite-0.3.1/README.md +90 -34
- {nonebot_plugin_copywrite-0.2.3 → nonebot_plugin_copywrite-0.3.1}/nonebot_plugin_copywrite/__init__.py +135 -229
- {nonebot_plugin_copywrite-0.2.3 → nonebot_plugin_copywrite-0.3.1}/nonebot_plugin_copywrite/chat.py +1 -9
- nonebot_plugin_copywrite-0.3.1/nonebot_plugin_copywrite/config.py +14 -0
- {nonebot_plugin_copywrite-0.2.3 → nonebot_plugin_copywrite-0.3.1}/nonebot_plugin_copywrite/copywrite/__init__.py +16 -5
- {nonebot_plugin_copywrite-0.2.3 → nonebot_plugin_copywrite-0.3.1}/nonebot_plugin_copywrite/copywrite/default.long.yaml +34 -11
- nonebot_plugin_copywrite-0.3.1/nonebot_plugin_copywrite/copywrite/default.short.yaml +80 -0
- nonebot_plugin_copywrite-0.3.1/nonebot_plugin_copywrite/copywrite/fran.long.yaml +29 -0
- nonebot_plugin_copywrite-0.3.1/nonebot_plugin_copywrite/copywrite/fran.short.yaml +31 -0
- {nonebot_plugin_copywrite-0.2.3 → nonebot_plugin_copywrite-0.3.1}/nonebot_plugin_copywrite/copywrite/life.checkpoint.long.yaml +19 -3
- nonebot_plugin_copywrite-0.3.1/nonebot_plugin_copywrite/copywrite/sujoke.short.yaml +8 -0
- nonebot_plugin_copywrite-0.3.1/nonebot_plugin_copywrite/models.py +61 -0
- nonebot_plugin_copywrite-0.3.1/pyproject.toml +19 -0
- nonebot_plugin_copywrite-0.3.1/uv.lock +786 -0
- nonebot_plugin_copywrite-0.2.3/nonebot_plugin_copywrite/config.py +0 -8
- nonebot_plugin_copywrite-0.2.3/nonebot_plugin_copywrite/copywrite/default.delete.yaml +0 -13
- nonebot_plugin_copywrite-0.2.3/nonebot_plugin_copywrite/copywrite/default.short.yaml +0 -43
- nonebot_plugin_copywrite-0.2.3/nonebot_plugin_copywrite/utils.py +0 -9
- nonebot_plugin_copywrite-0.2.3/pyproject.toml +0 -20
- {nonebot_plugin_copywrite-0.2.3 → nonebot_plugin_copywrite-0.3.1}/LICENSE +0 -0
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
# 推送到 main 时检测 pyproject.toml 中的版本号,若对应的 v<version> tag 不存在,
|
|
4
|
+
# 则构建并通过 OIDC (Trusted Publisher) 发布到 PyPI,然后打 tag 并创建 GitHub Release。
|
|
5
|
+
|
|
6
|
+
on:
|
|
7
|
+
push:
|
|
8
|
+
branches: [main]
|
|
9
|
+
workflow_dispatch:
|
|
10
|
+
|
|
11
|
+
concurrency:
|
|
12
|
+
group: release
|
|
13
|
+
cancel-in-progress: false
|
|
14
|
+
|
|
15
|
+
jobs:
|
|
16
|
+
check:
|
|
17
|
+
runs-on: ubuntu-latest
|
|
18
|
+
outputs:
|
|
19
|
+
version: ${{ steps.version.outputs.version }}
|
|
20
|
+
release: ${{ steps.version.outputs.release }}
|
|
21
|
+
steps:
|
|
22
|
+
- uses: actions/checkout@v7
|
|
23
|
+
with:
|
|
24
|
+
fetch-depth: 0
|
|
25
|
+
- id: version
|
|
26
|
+
run: |
|
|
27
|
+
version=$(python3 -c 'import tomllib; print(tomllib.load(open("pyproject.toml", "rb"))["project"]["version"])')
|
|
28
|
+
echo "version=$version" >> "$GITHUB_OUTPUT"
|
|
29
|
+
if git rev-parse -q --verify "refs/tags/v$version" > /dev/null; then
|
|
30
|
+
echo "v$version 已存在,跳过发布"
|
|
31
|
+
echo "release=false" >> "$GITHUB_OUTPUT"
|
|
32
|
+
else
|
|
33
|
+
echo "检测到新版本 v$version"
|
|
34
|
+
echo "release=true" >> "$GITHUB_OUTPUT"
|
|
35
|
+
fi
|
|
36
|
+
|
|
37
|
+
build:
|
|
38
|
+
needs: check
|
|
39
|
+
if: needs.check.outputs.release == 'true'
|
|
40
|
+
runs-on: ubuntu-latest
|
|
41
|
+
steps:
|
|
42
|
+
- uses: actions/checkout@v7
|
|
43
|
+
- uses: astral-sh/setup-uv@v10.3.0
|
|
44
|
+
- run: uv build
|
|
45
|
+
- uses: actions/upload-artifact@v7
|
|
46
|
+
with:
|
|
47
|
+
name: dist
|
|
48
|
+
path: dist/
|
|
49
|
+
|
|
50
|
+
publish:
|
|
51
|
+
needs: [check, build]
|
|
52
|
+
runs-on: ubuntu-latest
|
|
53
|
+
environment:
|
|
54
|
+
name: pypi
|
|
55
|
+
url: https://pypi.org/project/${{ github.event.repository.name }}/${{ needs.check.outputs.version }}/
|
|
56
|
+
permissions:
|
|
57
|
+
id-token: write
|
|
58
|
+
steps:
|
|
59
|
+
- uses: actions/download-artifact@v8
|
|
60
|
+
with:
|
|
61
|
+
name: dist
|
|
62
|
+
path: dist/
|
|
63
|
+
- uses: pypa/gh-action-pypi-publish@release/v1
|
|
64
|
+
with:
|
|
65
|
+
skip-existing: true
|
|
66
|
+
|
|
67
|
+
release:
|
|
68
|
+
needs: [check, publish]
|
|
69
|
+
runs-on: ubuntu-latest
|
|
70
|
+
permissions:
|
|
71
|
+
contents: write
|
|
72
|
+
steps:
|
|
73
|
+
- uses: actions/download-artifact@v8
|
|
74
|
+
with:
|
|
75
|
+
name: dist
|
|
76
|
+
path: dist/
|
|
77
|
+
- env:
|
|
78
|
+
GH_TOKEN: ${{ github.token }}
|
|
79
|
+
TAG: v${{ needs.check.outputs.version }}
|
|
80
|
+
run: |
|
|
81
|
+
gh release create "$TAG" dist/* \
|
|
82
|
+
--repo "$GITHUB_REPOSITORY" \
|
|
83
|
+
--target "$GITHUB_SHA" \
|
|
84
|
+
--title "$TAG" \
|
|
85
|
+
--generate-notes
|
|
@@ -0,0 +1,176 @@
|
|
|
1
|
+
# Byte-compiled / optimized / DLL files
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*$py.class
|
|
5
|
+
|
|
6
|
+
# C extensions
|
|
7
|
+
*.so
|
|
8
|
+
|
|
9
|
+
# Distribution / packaging
|
|
10
|
+
.Python
|
|
11
|
+
build/
|
|
12
|
+
develop-eggs/
|
|
13
|
+
dist/
|
|
14
|
+
downloads/
|
|
15
|
+
eggs/
|
|
16
|
+
.eggs/
|
|
17
|
+
lib/
|
|
18
|
+
lib64/
|
|
19
|
+
parts/
|
|
20
|
+
sdist/
|
|
21
|
+
var/
|
|
22
|
+
wheels/
|
|
23
|
+
share/python-wheels/
|
|
24
|
+
*.egg-info/
|
|
25
|
+
.installed.cfg
|
|
26
|
+
*.egg
|
|
27
|
+
MANIFEST
|
|
28
|
+
|
|
29
|
+
# PyInstaller
|
|
30
|
+
# Usually these files are written by a python script from a template
|
|
31
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
32
|
+
*.manifest
|
|
33
|
+
*.spec
|
|
34
|
+
|
|
35
|
+
# Installer logs
|
|
36
|
+
pip-log.txt
|
|
37
|
+
pip-delete-this-directory.txt
|
|
38
|
+
|
|
39
|
+
# Unit test / coverage reports
|
|
40
|
+
htmlcov/
|
|
41
|
+
.tox/
|
|
42
|
+
.nox/
|
|
43
|
+
.coverage
|
|
44
|
+
.coverage.*
|
|
45
|
+
.cache
|
|
46
|
+
nosetests.xml
|
|
47
|
+
coverage.xml
|
|
48
|
+
*.cover
|
|
49
|
+
*.py,cover
|
|
50
|
+
.hypothesis/
|
|
51
|
+
.pytest_cache/
|
|
52
|
+
cover/
|
|
53
|
+
|
|
54
|
+
# Translations
|
|
55
|
+
*.mo
|
|
56
|
+
*.pot
|
|
57
|
+
|
|
58
|
+
# Django stuff:
|
|
59
|
+
*.log
|
|
60
|
+
local_settings.py
|
|
61
|
+
db.sqlite3
|
|
62
|
+
db.sqlite3-journal
|
|
63
|
+
|
|
64
|
+
# Flask stuff:
|
|
65
|
+
instance/
|
|
66
|
+
.webassets-cache
|
|
67
|
+
|
|
68
|
+
# Scrapy stuff:
|
|
69
|
+
.scrapy
|
|
70
|
+
|
|
71
|
+
# Sphinx documentation
|
|
72
|
+
docs/_build/
|
|
73
|
+
|
|
74
|
+
# PyBuilder
|
|
75
|
+
.pybuilder/
|
|
76
|
+
target/
|
|
77
|
+
|
|
78
|
+
# Jupyter Notebook
|
|
79
|
+
.ipynb_checkpoints
|
|
80
|
+
|
|
81
|
+
# IPython
|
|
82
|
+
profile_default/
|
|
83
|
+
ipython_config.py
|
|
84
|
+
|
|
85
|
+
# pyenv
|
|
86
|
+
# For a library or package, you might want to ignore these files since the code is
|
|
87
|
+
# intended to run in multiple environments; otherwise, check them in:
|
|
88
|
+
# .python-version
|
|
89
|
+
|
|
90
|
+
# pipenv
|
|
91
|
+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
92
|
+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
93
|
+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
94
|
+
# install all needed dependencies.
|
|
95
|
+
#Pipfile.lock
|
|
96
|
+
|
|
97
|
+
# poetry
|
|
98
|
+
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
|
99
|
+
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
|
100
|
+
# commonly ignored for libraries.
|
|
101
|
+
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
|
102
|
+
#poetry.lock
|
|
103
|
+
# Poetry local configuration file - https://python-poetry.org/docs/configuration/#local-configuration
|
|
104
|
+
poetry.toml
|
|
105
|
+
|
|
106
|
+
# pdm
|
|
107
|
+
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
|
108
|
+
#pdm.lock
|
|
109
|
+
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
|
|
110
|
+
# in version control.
|
|
111
|
+
# https://pdm.fming.dev/#use-with-ide
|
|
112
|
+
.pdm-python
|
|
113
|
+
|
|
114
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
|
115
|
+
__pypackages__/
|
|
116
|
+
|
|
117
|
+
# Celery stuff
|
|
118
|
+
celerybeat-schedule
|
|
119
|
+
celerybeat.pid
|
|
120
|
+
|
|
121
|
+
# SageMath parsed files
|
|
122
|
+
*.sage.py
|
|
123
|
+
|
|
124
|
+
# Environments
|
|
125
|
+
.env
|
|
126
|
+
.venv
|
|
127
|
+
env/
|
|
128
|
+
venv/
|
|
129
|
+
ENV/
|
|
130
|
+
env.bak/
|
|
131
|
+
venv.bak/
|
|
132
|
+
|
|
133
|
+
# Spyder project settings
|
|
134
|
+
.spyderproject
|
|
135
|
+
.spyproject
|
|
136
|
+
|
|
137
|
+
# Rope project settings
|
|
138
|
+
.ropeproject
|
|
139
|
+
|
|
140
|
+
# mkdocs documentation
|
|
141
|
+
/site
|
|
142
|
+
|
|
143
|
+
# mypy
|
|
144
|
+
.mypy_cache/
|
|
145
|
+
.dmypy.json
|
|
146
|
+
dmypy.json
|
|
147
|
+
|
|
148
|
+
# Pyre type checker
|
|
149
|
+
.pyre/
|
|
150
|
+
|
|
151
|
+
# pytype static type analyzer
|
|
152
|
+
.pytype/
|
|
153
|
+
|
|
154
|
+
# Cython debug symbols
|
|
155
|
+
cython_debug/
|
|
156
|
+
|
|
157
|
+
# ruff
|
|
158
|
+
.ruff_cache/
|
|
159
|
+
|
|
160
|
+
# LSP config files
|
|
161
|
+
pyrightconfig.json
|
|
162
|
+
|
|
163
|
+
# PyCharm
|
|
164
|
+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
|
165
|
+
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
|
166
|
+
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
167
|
+
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
168
|
+
#.idea/
|
|
169
|
+
|
|
170
|
+
# VisualStudioCode
|
|
171
|
+
.vscode/*
|
|
172
|
+
!.vscode/settings.json
|
|
173
|
+
!.vscode/tasks.json
|
|
174
|
+
!.vscode/launch.json
|
|
175
|
+
!.vscode/extensions.json
|
|
176
|
+
!.vscode/*.code-snippets
|
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: nonebot-plugin-copywrite
|
|
3
|
+
Version: 0.3.1
|
|
4
|
+
Author-email: Yan <1964649083@qq.com>
|
|
5
|
+
License-Expression: Apache-2.0
|
|
6
|
+
License-File: LICENSE
|
|
7
|
+
Requires-Python: <4.0,>=3.11
|
|
8
|
+
Requires-Dist: cairosvg<3,>=2.7.1
|
|
9
|
+
Requires-Dist: nonebot-adapter-onebot<3,>=2.4.6
|
|
10
|
+
Requires-Dist: nonebot2<3,>=2.4.0
|
|
11
|
+
Requires-Dist: openai<2,>=1.54.3
|
|
12
|
+
Requires-Dist: pyyaml<7,>=6.0.1
|
|
13
|
+
Description-Content-Type: text/markdown
|
|
14
|
+
|
|
1
15
|
<div align="center">
|
|
2
16
|
<a href="https://v2.nonebot.dev/store"><img src="https://raw.githubusercontent.com/tkgs0/nbpt/resources/nbp_logo.png" width="180" height="180" alt="NoneBotPluginLogo"></a>
|
|
3
17
|
<br>
|
|
@@ -25,9 +39,9 @@ _✨ NoneBot 定型文生成器 ✨_
|
|
|
25
39
|
<a href="https://onebot.adapters.nonebot.dev">
|
|
26
40
|
<img src="https://img.shields.io/badge/OneBot-11-black?logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHAAAABwCAMAAADxPgR5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAxQTFRF////29vbr6+vAAAAk1hCcwAAAAR0Uk5T////AEAqqfQAAAKcSURBVHja7NrbctswDATQXfD//zlpO7FlmwAWIOnOtNaTM5JwDMa8E+PNFz7g3waJ24fviyDPgfhz8fHP39cBcBL9KoJbQUxjA2iYqHL3FAnvzhL4GtVNUcoSZe6eSHizBcK5LL7dBr2AUZlev1ARRHCljzRALIEog6H3U6bCIyqIZdAT0eBuJYaGiJaHSjmkYIZd+qSGWAQnIaz2OArVnX6vrItQvbhZJtVGB5qX9wKqCMkb9W7aexfCO/rwQRBzsDIsYx4AOz0nhAtWu7bqkEQBO0Pr+Ftjt5fFCUEbm0Sbgdu8WSgJ5NgH2iu46R/o1UcBXJsFusWF/QUaz3RwJMEgngfaGGdSxJkE/Yg4lOBryBiMwvAhZrVMUUvwqU7F05b5WLaUIN4M4hRocQQRnEedgsn7TZB3UCpRrIJwQfqvGwsg18EnI2uSVNC8t+0QmMXogvbPg/xk+Mnw/6kW/rraUlvqgmFreAA09xW5t0AFlHrQZ3CsgvZm0FbHNKyBmheBKIF2cCA8A600aHPmFtRB1XvMsJAiza7LpPog0UJwccKdzw8rdf8MyN2ePYF896LC5hTzdZqxb6VNXInaupARLDNBWgI8spq4T0Qb5H4vWfPmHo8OyB1ito+AysNNz0oglj1U955sjUN9d41LnrX2D/u7eRwxyOaOpfyevCWbTgDEoilsOnu7zsKhjRCsnD/QzhdkYLBLXjiK4f3UWmcx2M7PO21CKVTH84638NTplt6JIQH0ZwCNuiWAfvuLhdrcOYPVO9eW3A67l7hZtgaY9GZo9AFc6cryjoeFBIWeU+npnk/nLE0OxCHL1eQsc1IciehjpJv5mqCsjeopaH6r15/MrxNnVhu7tmcslay2gO2Z1QfcfX0JMACG41/u0RrI9QAAAABJRU5ErkJggg==" alt="onebot">
|
|
27
41
|
</a>
|
|
28
|
-
|
|
42
|
+
<a href="https://pypi.python.org/pypi/nonebot-plugin-copywrite" rel="nofollow">
|
|
29
43
|
<img alt="pypi download" src="https://img.shields.io/pypi/dm/nonebot-plugin-copywrite" style="max-width: 100%;">
|
|
30
|
-
</a>
|
|
44
|
+
</a>
|
|
31
45
|
|
|
32
46
|
</div>
|
|
33
47
|
|
|
@@ -45,6 +59,7 @@ _✨ NoneBot 定型文生成器 ✨_
|
|
|
45
59
|
|
|
46
60
|
```yaml
|
|
47
61
|
__category__: 114514
|
|
62
|
+
__model__: sol
|
|
48
63
|
|
|
49
64
|
鸣潮:
|
|
50
65
|
examples:
|
|
@@ -52,33 +67,98 @@ __category__: 114514
|
|
|
52
67
|
- 儿童节是这样的,大哥哥只需要在家等着被抓就行了,而小萝莉要考虑的事情就很多了,什么时候喊杂鱼杂鱼,什么时候掀裙子露内裤,什么时候拉响警报器,都需要经过深思熟虑
|
|
53
68
|
- 企业家是这样的,员工只需要完成工作任务就行了,而老板要考虑的事情就很多了,什么时候拖欠工资,什么时候增加工作时间,员工绩效怎么压,都需要深思熟虑
|
|
54
69
|
addition: "你回复的文案应该是辛辣讽刺的,例如老板考虑如何拖欠工资,学生考虑低分怎么辩解,游戏玩家考虑如何开挂。"
|
|
55
|
-
|
|
70
|
+
|
|
71
|
+
紧缩术:
|
|
72
|
+
examples:
|
|
73
|
+
- 你的太阳系舰队比较松弛……
|
|
74
|
+
model: luna
|
|
56
75
|
```
|
|
57
76
|
|
|
58
77
|
#### 解释
|
|
59
78
|
|
|
60
|
-
-
|
|
79
|
+
- \_\_category\_\_: 定型文的分类
|
|
80
|
+
- \_\_model\_\_: 本文件所有文案默认使用的模型代号
|
|
61
81
|
- examples: 例子
|
|
62
82
|
- addition: 附加内容,用以约束 LLM 可能的输出
|
|
63
|
-
- model:
|
|
83
|
+
- model: 模型代号,覆盖 \_\_model\_\_
|
|
84
|
+
|
|
85
|
+
#### 模型代号
|
|
86
|
+
|
|
87
|
+
模型代号只表示「档位」,具体调用哪个模型由配置决定。每档两个代号可以混用:
|
|
88
|
+
|
|
89
|
+
| 代号 | 同档代号 | 档位 | 配置项 |
|
|
90
|
+
| ---- | -------- | ---- | ------ |
|
|
91
|
+
| luna | haiku | 小杯 | `COPYWRITE_MODEL_LUNA` |
|
|
92
|
+
| terra | sonnet | 中杯 | `COPYWRITE_MODEL_TERRA` |
|
|
93
|
+
| sol | opus | 大杯 | `COPYWRITE_MODEL_SOL` |
|
|
94
|
+
| astra | fable | 超大杯 | `COPYWRITE_MODEL_ASTRA` |
|
|
95
|
+
|
|
96
|
+
在 `.env` 里按档位填模型名即可,例如:
|
|
97
|
+
|
|
98
|
+
```dotenv
|
|
99
|
+
COPYWRITE_MODEL_LUNA=gemini-2.5-flash-lite
|
|
100
|
+
COPYWRITE_MODEL_TERRA=gemini-2.5-flash
|
|
101
|
+
COPYWRITE_MODEL_SOL=gemini-3-flash-preview
|
|
102
|
+
COPYWRITE_MODEL_ASTRA=gemini-3-pro-preview
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
没写 `model` 的文案使用 `__model__`,没写 `__model__` 的文件默认 `luna`。配置项未填写时四档均为 `gpt-6-luna`;模型名必须在 `configs/chatgpt-vision/keys.yaml` 里配置过才能调用。
|
|
64
106
|
|
|
65
107
|
## 💬 指令
|
|
66
108
|
|
|
67
109
|
### 文案
|
|
68
110
|
|
|
69
|
-
> /文案 [
|
|
70
|
-
|
|
111
|
+
> /文案 [Type] (Keywords)* [Topic]
|
|
112
|
+
|
|
113
|
+
生产电子垃圾。
|
|
114
|
+
|
|
115
|
+
| 参数 | 说明 |
|
|
116
|
+
| ---- | ---- |
|
|
117
|
+
| Type | 文案名字 |
|
|
118
|
+
| Topic | 文案的主题 |
|
|
119
|
+
| Keywords | 文案的关键词 |
|
|
71
120
|
|
|
72
|
-
查看可用文案:
|
|
73
121
|
> /文案
|
|
74
122
|
|
|
75
|
-
|
|
76
|
-
|
|
123
|
+
查看可用文案.
|
|
124
|
+
|
|
125
|
+
> /文案 [Type]
|
|
126
|
+
|
|
127
|
+
查看帮助,如果有的话。
|
|
77
128
|
|
|
78
129
|
#### 保留关键字
|
|
79
130
|
|
|
131
|
+
只有 SuperAdmin 才能使用。
|
|
132
|
+
|
|
80
133
|
1. reload: 重新加载定型文数据
|
|
81
|
-
2. fetch
|
|
134
|
+
2. **fetch**: !!慎用!! 调用 pip 更新 nonebot-plugin-copywrite,由于依赖问题,可能下一次bot就无法启动了。
|
|
135
|
+
|
|
136
|
+
#### 文案 示例
|
|
137
|
+
|
|
138
|
+
> /文案
|
|
139
|
+
|
|
140
|
+
```yaml
|
|
141
|
+
Yan:
|
|
142
|
+
不是高三生, 乙游大世界, 两种可能, 你说得对, 女性凝视, 二次元, 四不吃, 回来吧, 带节奏, 慢就业, 紧缩术, 恩情, 意林, 饭局, 鸣潮
|
|
143
|
+
Life.Checkpoint:
|
|
144
|
+
第一个被抓, 求真学生, 表白
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
---
|
|
148
|
+
|
|
149
|
+
> /copywrite reload
|
|
150
|
+
|
|
151
|
+
```yaml
|
|
152
|
+
重新加载完成。
|
|
153
|
+
```
|
|
154
|
+
|
|
155
|
+
---
|
|
156
|
+
|
|
157
|
+
> /文案 鸣潮 造新梗,套公式
|
|
158
|
+
|
|
159
|
+
```yaml
|
|
160
|
+
造新梗是这样的,网友们只需要动动手指发个帖就行了,而梗创作者要考虑的事情就很多了,什么时候抓住热点,怎么巧妙结合时事,如何让梗迅速传播,都需要深思熟虑。
|
|
161
|
+
```
|
|
82
162
|
|
|
83
163
|
#### 文案 Alias
|
|
84
164
|
|
|
@@ -86,10 +166,21 @@ __category__: 114514
|
|
|
86
166
|
|
|
87
167
|
### 汉语新解
|
|
88
168
|
|
|
169
|
+
Prompt 原作者:[李继刚](https://web.okjike.com/u/752D3103-1107-43A0-BA49-20EC29D09E36)
|
|
170
|
+
|
|
89
171
|
> /汉语新解 [Word]
|
|
90
|
-
> /汉语新解 求真书院
|
|
91
172
|
|
|
92
|
-
|
|
173
|
+
将一个汉语词汇进行全新角度的解释。(看模型,GPT-4o 多正能量,Claude 多讽刺,Gemini 比较中庸)
|
|
174
|
+
|
|
175
|
+
| 参数 | 说明 |
|
|
176
|
+
| ---- | ---- |
|
|
177
|
+
| Word | 词汇,其实不仅限于汉语。 |
|
|
178
|
+
|
|
179
|
+
#### 汉语新解 示例
|
|
180
|
+
|
|
181
|
+
> /汉语新解 调休
|
|
182
|
+
|
|
183
|
+

|
|
93
184
|
|
|
94
185
|
#### 汉语新解 Alias
|
|
95
186
|
|
|
@@ -1,23 +1,3 @@
|
|
|
1
|
-
Metadata-Version: 2.1
|
|
2
|
-
Name: nonebot-plugin-copywrite
|
|
3
|
-
Version: 0.2.3
|
|
4
|
-
Summary:
|
|
5
|
-
License: Apache-2.0
|
|
6
|
-
Author: Yan
|
|
7
|
-
Author-email: 1964649083@qq.com
|
|
8
|
-
Requires-Python: >=3.11,<4.0
|
|
9
|
-
Classifier: License :: OSI Approved :: Apache Software License
|
|
10
|
-
Classifier: Programming Language :: Python :: 3
|
|
11
|
-
Classifier: Programming Language :: Python :: 3.11
|
|
12
|
-
Classifier: Programming Language :: Python :: 3.12
|
|
13
|
-
Classifier: Programming Language :: Python :: 3.13
|
|
14
|
-
Requires-Dist: cairosvg (>=2.7.1,<3.0.0)
|
|
15
|
-
Requires-Dist: nonebot-adapter-onebot (>=2.4.6,<3.0.0)
|
|
16
|
-
Requires-Dist: nonebot2 (>=2.4.0,<3.0.0)
|
|
17
|
-
Requires-Dist: openai (>=1.54.3,<2.0.0)
|
|
18
|
-
Requires-Dist: pyyaml (>=6.0.1,<7.0.0)
|
|
19
|
-
Description-Content-Type: text/markdown
|
|
20
|
-
|
|
21
1
|
<div align="center">
|
|
22
2
|
<a href="https://v2.nonebot.dev/store"><img src="https://raw.githubusercontent.com/tkgs0/nbpt/resources/nbp_logo.png" width="180" height="180" alt="NoneBotPluginLogo"></a>
|
|
23
3
|
<br>
|
|
@@ -45,9 +25,9 @@ _✨ NoneBot 定型文生成器 ✨_
|
|
|
45
25
|
<a href="https://onebot.adapters.nonebot.dev">
|
|
46
26
|
<img src="https://img.shields.io/badge/OneBot-11-black?logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHAAAABwCAMAAADxPgR5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAxQTFRF////29vbr6+vAAAAk1hCcwAAAAR0Uk5T////AEAqqfQAAAKcSURBVHja7NrbctswDATQXfD//zlpO7FlmwAWIOnOtNaTM5JwDMa8E+PNFz7g3waJ24fviyDPgfhz8fHP39cBcBL9KoJbQUxjA2iYqHL3FAnvzhL4GtVNUcoSZe6eSHizBcK5LL7dBr2AUZlev1ARRHCljzRALIEog6H3U6bCIyqIZdAT0eBuJYaGiJaHSjmkYIZd+qSGWAQnIaz2OArVnX6vrItQvbhZJtVGB5qX9wKqCMkb9W7aexfCO/rwQRBzsDIsYx4AOz0nhAtWu7bqkEQBO0Pr+Ftjt5fFCUEbm0Sbgdu8WSgJ5NgH2iu46R/o1UcBXJsFusWF/QUaz3RwJMEgngfaGGdSxJkE/Yg4lOBryBiMwvAhZrVMUUvwqU7F05b5WLaUIN4M4hRocQQRnEedgsn7TZB3UCpRrIJwQfqvGwsg18EnI2uSVNC8t+0QmMXogvbPg/xk+Mnw/6kW/rraUlvqgmFreAA09xW5t0AFlHrQZ3CsgvZm0FbHNKyBmheBKIF2cCA8A600aHPmFtRB1XvMsJAiza7LpPog0UJwccKdzw8rdf8MyN2ePYF896LC5hTzdZqxb6VNXInaupARLDNBWgI8spq4T0Qb5H4vWfPmHo8OyB1ito+AysNNz0oglj1U955sjUN9d41LnrX2D/u7eRwxyOaOpfyevCWbTgDEoilsOnu7zsKhjRCsnD/QzhdkYLBLXjiK4f3UWmcx2M7PO21CKVTH84638NTplt6JIQH0ZwCNuiWAfvuLhdrcOYPVO9eW3A67l7hZtgaY9GZo9AFc6cryjoeFBIWeU+npnk/nLE0OxCHL1eQsc1IciehjpJv5mqCsjeopaH6r15/MrxNnVhu7tmcslay2gO2Z1QfcfX0JMACG41/u0RrI9QAAAABJRU5ErkJggg==" alt="onebot">
|
|
47
27
|
</a>
|
|
48
|
-
|
|
28
|
+
<a href="https://pypi.python.org/pypi/nonebot-plugin-copywrite" rel="nofollow">
|
|
49
29
|
<img alt="pypi download" src="https://img.shields.io/pypi/dm/nonebot-plugin-copywrite" style="max-width: 100%;">
|
|
50
|
-
</a>
|
|
30
|
+
</a>
|
|
51
31
|
|
|
52
32
|
</div>
|
|
53
33
|
|
|
@@ -65,6 +45,7 @@ _✨ NoneBot 定型文生成器 ✨_
|
|
|
65
45
|
|
|
66
46
|
```yaml
|
|
67
47
|
__category__: 114514
|
|
48
|
+
__model__: sol
|
|
68
49
|
|
|
69
50
|
鸣潮:
|
|
70
51
|
examples:
|
|
@@ -72,33 +53,98 @@ __category__: 114514
|
|
|
72
53
|
- 儿童节是这样的,大哥哥只需要在家等着被抓就行了,而小萝莉要考虑的事情就很多了,什么时候喊杂鱼杂鱼,什么时候掀裙子露内裤,什么时候拉响警报器,都需要经过深思熟虑
|
|
73
54
|
- 企业家是这样的,员工只需要完成工作任务就行了,而老板要考虑的事情就很多了,什么时候拖欠工资,什么时候增加工作时间,员工绩效怎么压,都需要深思熟虑
|
|
74
55
|
addition: "你回复的文案应该是辛辣讽刺的,例如老板考虑如何拖欠工资,学生考虑低分怎么辩解,游戏玩家考虑如何开挂。"
|
|
75
|
-
|
|
56
|
+
|
|
57
|
+
紧缩术:
|
|
58
|
+
examples:
|
|
59
|
+
- 你的太阳系舰队比较松弛……
|
|
60
|
+
model: luna
|
|
76
61
|
```
|
|
77
62
|
|
|
78
63
|
#### 解释
|
|
79
64
|
|
|
80
|
-
-
|
|
65
|
+
- \_\_category\_\_: 定型文的分类
|
|
66
|
+
- \_\_model\_\_: 本文件所有文案默认使用的模型代号
|
|
81
67
|
- examples: 例子
|
|
82
68
|
- addition: 附加内容,用以约束 LLM 可能的输出
|
|
83
|
-
- model:
|
|
69
|
+
- model: 模型代号,覆盖 \_\_model\_\_
|
|
70
|
+
|
|
71
|
+
#### 模型代号
|
|
72
|
+
|
|
73
|
+
模型代号只表示「档位」,具体调用哪个模型由配置决定。每档两个代号可以混用:
|
|
74
|
+
|
|
75
|
+
| 代号 | 同档代号 | 档位 | 配置项 |
|
|
76
|
+
| ---- | -------- | ---- | ------ |
|
|
77
|
+
| luna | haiku | 小杯 | `COPYWRITE_MODEL_LUNA` |
|
|
78
|
+
| terra | sonnet | 中杯 | `COPYWRITE_MODEL_TERRA` |
|
|
79
|
+
| sol | opus | 大杯 | `COPYWRITE_MODEL_SOL` |
|
|
80
|
+
| astra | fable | 超大杯 | `COPYWRITE_MODEL_ASTRA` |
|
|
81
|
+
|
|
82
|
+
在 `.env` 里按档位填模型名即可,例如:
|
|
83
|
+
|
|
84
|
+
```dotenv
|
|
85
|
+
COPYWRITE_MODEL_LUNA=gemini-2.5-flash-lite
|
|
86
|
+
COPYWRITE_MODEL_TERRA=gemini-2.5-flash
|
|
87
|
+
COPYWRITE_MODEL_SOL=gemini-3-flash-preview
|
|
88
|
+
COPYWRITE_MODEL_ASTRA=gemini-3-pro-preview
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
没写 `model` 的文案使用 `__model__`,没写 `__model__` 的文件默认 `luna`。配置项未填写时四档均为 `gpt-6-luna`;模型名必须在 `configs/chatgpt-vision/keys.yaml` 里配置过才能调用。
|
|
84
92
|
|
|
85
93
|
## 💬 指令
|
|
86
94
|
|
|
87
95
|
### 文案
|
|
88
96
|
|
|
89
|
-
> /文案 [
|
|
90
|
-
|
|
97
|
+
> /文案 [Type] (Keywords)* [Topic]
|
|
98
|
+
|
|
99
|
+
生产电子垃圾。
|
|
100
|
+
|
|
101
|
+
| 参数 | 说明 |
|
|
102
|
+
| ---- | ---- |
|
|
103
|
+
| Type | 文案名字 |
|
|
104
|
+
| Topic | 文案的主题 |
|
|
105
|
+
| Keywords | 文案的关键词 |
|
|
91
106
|
|
|
92
|
-
查看可用文案:
|
|
93
107
|
> /文案
|
|
94
108
|
|
|
95
|
-
|
|
96
|
-
|
|
109
|
+
查看可用文案.
|
|
110
|
+
|
|
111
|
+
> /文案 [Type]
|
|
112
|
+
|
|
113
|
+
查看帮助,如果有的话。
|
|
97
114
|
|
|
98
115
|
#### 保留关键字
|
|
99
116
|
|
|
117
|
+
只有 SuperAdmin 才能使用。
|
|
118
|
+
|
|
100
119
|
1. reload: 重新加载定型文数据
|
|
101
|
-
2. fetch
|
|
120
|
+
2. **fetch**: !!慎用!! 调用 pip 更新 nonebot-plugin-copywrite,由于依赖问题,可能下一次bot就无法启动了。
|
|
121
|
+
|
|
122
|
+
#### 文案 示例
|
|
123
|
+
|
|
124
|
+
> /文案
|
|
125
|
+
|
|
126
|
+
```yaml
|
|
127
|
+
Yan:
|
|
128
|
+
不是高三生, 乙游大世界, 两种可能, 你说得对, 女性凝视, 二次元, 四不吃, 回来吧, 带节奏, 慢就业, 紧缩术, 恩情, 意林, 饭局, 鸣潮
|
|
129
|
+
Life.Checkpoint:
|
|
130
|
+
第一个被抓, 求真学生, 表白
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
---
|
|
134
|
+
|
|
135
|
+
> /copywrite reload
|
|
136
|
+
|
|
137
|
+
```yaml
|
|
138
|
+
重新加载完成。
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
---
|
|
142
|
+
|
|
143
|
+
> /文案 鸣潮 造新梗,套公式
|
|
144
|
+
|
|
145
|
+
```yaml
|
|
146
|
+
造新梗是这样的,网友们只需要动动手指发个帖就行了,而梗创作者要考虑的事情就很多了,什么时候抓住热点,怎么巧妙结合时事,如何让梗迅速传播,都需要深思熟虑。
|
|
147
|
+
```
|
|
102
148
|
|
|
103
149
|
#### 文案 Alias
|
|
104
150
|
|
|
@@ -106,12 +152,22 @@ __category__: 114514
|
|
|
106
152
|
|
|
107
153
|
### 汉语新解
|
|
108
154
|
|
|
155
|
+
Prompt 原作者:[李继刚](https://web.okjike.com/u/752D3103-1107-43A0-BA49-20EC29D09E36)
|
|
156
|
+
|
|
109
157
|
> /汉语新解 [Word]
|
|
110
|
-
> /汉语新解 求真书院
|
|
111
158
|
|
|
112
|
-
|
|
159
|
+
将一个汉语词汇进行全新角度的解释。(看模型,GPT-4o 多正能量,Claude 多讽刺,Gemini 比较中庸)
|
|
160
|
+
|
|
161
|
+
| 参数 | 说明 |
|
|
162
|
+
| ---- | ---- |
|
|
163
|
+
| Word | 词汇,其实不仅限于汉语。 |
|
|
164
|
+
|
|
165
|
+
#### 汉语新解 示例
|
|
166
|
+
|
|
167
|
+
> /汉语新解 调休
|
|
168
|
+
|
|
169
|
+

|
|
113
170
|
|
|
114
171
|
#### 汉语新解 Alias
|
|
115
172
|
|
|
116
173
|
- new-meaning
|
|
117
|
-
|