Compare commits
55 Commits
v2026.01.1
...
v2026.01.1
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f650c64ffe | ||
|
|
6000c880de | ||
|
|
048fbb26d7 | ||
|
|
a88eda62cc | ||
|
|
957fb2dfb7 | ||
|
|
d2be5109ad | ||
|
|
80fdc52598 | ||
|
|
2b90ead3cf | ||
|
|
2aa5d77586 | ||
|
|
2b1b1ef939 | ||
|
|
4e21e06617 | ||
|
|
82ce1cef29 | ||
|
|
533eace74e | ||
|
|
83b3dcda65 | ||
|
|
e89373e0ed | ||
|
|
4b66a2bb1c | ||
|
|
59ba23da63 | ||
|
|
f8a89e222c | ||
|
|
096568f3e6 | ||
|
|
e10e12ebc9 | ||
|
|
c4df5eba47 | ||
|
|
0da3d3d881 | ||
|
|
6f4a62d1bc | ||
|
|
5d71c2a4d3 | ||
|
|
097707c168 | ||
|
|
8f4cfceb50 | ||
|
|
4ab5fab7d0 | ||
|
|
0e293be8bc | ||
|
|
182c12f81a | ||
|
|
1337a90911 | ||
|
|
2f0a347ab3 | ||
|
|
4eda286512 | ||
|
|
0fead8158d | ||
|
|
031bef563a | ||
|
|
04c3fd2bf9 | ||
|
|
cbbf6118b5 | ||
|
|
4c529369ce | ||
|
|
797dea0d77 | ||
|
|
a91aee31de | ||
|
|
8511b7df80 | ||
|
|
afd1e7a444 | ||
|
|
34b2c3d6cf | ||
|
|
d5c099dd15 | ||
|
|
8810223693 | ||
|
|
84974a2fb9 | ||
|
|
af847293af | ||
|
|
a44e80ce5b | ||
|
|
c2815e13e9 | ||
|
|
56bfa3a3ef | ||
|
|
a13c915f27 | ||
|
|
fb2d35237e | ||
|
|
3f19ecfd20 | ||
|
|
2fd96f07aa | ||
|
|
a1c1ed9840 | ||
|
|
c63701d05f |
47
.all-contributorsrc
Normal file
47
.all-contributorsrc
Normal file
@@ -0,0 +1,47 @@
|
||||
{
|
||||
"files": [
|
||||
"README.md"
|
||||
],
|
||||
"imageSize": 100,
|
||||
"commit": false,
|
||||
"commitType": "docs",
|
||||
"commitConvention": "angular",
|
||||
"contributors": [
|
||||
{
|
||||
"login": "rbb-dev",
|
||||
"name": "rbb-dev",
|
||||
"avatar_url": "https://avatars.githubusercontent.com/u/37469229?v=4",
|
||||
"profile": "https://github.com/rbb-dev",
|
||||
"contributions": [
|
||||
"ideas",
|
||||
"code"
|
||||
]
|
||||
},
|
||||
{
|
||||
"login": "dhaern",
|
||||
"name": "Raxxoor",
|
||||
"avatar_url": "https://avatars.githubusercontent.com/u/7317522?v=4",
|
||||
"profile": "https://trade.xyz/?ref=BZ1RJRXWO",
|
||||
"contributions": [
|
||||
"bug",
|
||||
"ideas"
|
||||
]
|
||||
},
|
||||
{
|
||||
"login": "i-iooi-i",
|
||||
"name": "ZOLO",
|
||||
"avatar_url": "https://avatars.githubusercontent.com/u/1827701?v=4",
|
||||
"profile": "https://github.com/i-iooi-i",
|
||||
"contributions": [
|
||||
"bug",
|
||||
"ideas"
|
||||
]
|
||||
}
|
||||
],
|
||||
"contributorsPerLine": 7,
|
||||
"skipCi": true,
|
||||
"repoType": "github",
|
||||
"repoHost": "https://github.com",
|
||||
"projectName": "awesome-openwebui",
|
||||
"projectOwner": "Fu-Jie"
|
||||
}
|
||||
79
.github/copilot-instructions.md
vendored
79
.github/copilot-instructions.md
vendored
@@ -320,6 +320,43 @@ logger.error(f"Processing failed: {e}", exc_info=True)
|
||||
|
||||
---
|
||||
|
||||
## 🛡️ Filter 插件开发规范 (Filter Plugin Standards)
|
||||
|
||||
### 1. 状态管理 (State Management) - **关键 (Critical)**
|
||||
|
||||
Filter 实例在 OpenWebUI 生命周期中是**单例 (Singleton)**。这意味着同一个 Filter 实例会处理所有并发请求。
|
||||
|
||||
- **❌ 禁止 (Prohibited)**: 使用 `self` 存储请求级别的临时状态(如 `self.temp_state`)。这会导致严重的**竞态条件 (Race Conditions)**,即一个请求的数据被另一个请求覆盖。
|
||||
- **✅ 推荐 (Recommended)**:
|
||||
- **无状态设计**: `inlet` 和 `outlet` 应该尽可能独立。
|
||||
- **重新计算**: 在 `outlet` 中根据 `body['messages']` 重新计算所需的状态,而不是依赖 `inlet` 传递。
|
||||
- **元数据传递**: 如果必须传递状态,尝试使用 `body` 中的临时字段(需谨慎处理清理)或 `__metadata__`(如果可写)。
|
||||
|
||||
### 2. 摘要注入角色 (Summary Injection Role)
|
||||
|
||||
当注入历史摘要或上下文时:
|
||||
|
||||
- **❌ 避免 (Avoid)**: 使用 `system` 角色(部分模型对 system prompt 位置敏感或不支持中间插入)。
|
||||
- **❌ 避免 (Avoid)**: 使用 `user` 角色(容易混淆用户真实意图)。
|
||||
- **✅ 推荐 (Recommended)**: 使用 **`assistant`** 角色。这通常被模型视为上下文历史的一部分,兼容性最好。
|
||||
|
||||
### 3. 模型默认值 (Model Defaults)
|
||||
|
||||
- **❌ 禁止 (Prohibited)**: 硬编码特定模型 ID(如 `gpt-3.5-turbo`)作为默认值。这会导致非 OpenAI 用户出错。
|
||||
- **✅ 推荐 (Recommended)**:
|
||||
- 默认值设为 `None` 或空字符串。
|
||||
- 优先使用当前对话的模型 (`body.get("model")`)。
|
||||
- 如果必须指定,通过 `Valves` 让用户配置。
|
||||
|
||||
### 4. 异步处理 (Async Processing)
|
||||
|
||||
对于耗时的后台任务(如摘要生成、日志记录):
|
||||
|
||||
- **✅ 推荐 (Recommended)**: 在 `outlet` 中使用 `asyncio.create_task()` 启动后台任务,确保不阻塞用户响应。
|
||||
- **✅ 推荐 (Recommended)**: 在后台任务中捕获所有异常,防止崩溃影响主进程。
|
||||
|
||||
---
|
||||
|
||||
## 🎨 HTML 注入规范 (HTML Injection)
|
||||
|
||||
使用统一的标记和结构:
|
||||
@@ -1550,6 +1587,48 @@ feat(flash-card): add _get_user_context for safer user info retrieval
|
||||
|
||||
---
|
||||
|
||||
## 🤝 贡献者认可规范 (Contributor Recognition Standards)
|
||||
|
||||
本项目使用 [All Contributors](https://allcontributors.org/) 规范来认可所有形式的贡献。
|
||||
|
||||
### 1. 如何添加贡献者 (How to Add)
|
||||
|
||||
在 GitHub 的 **Issue** 或 **Pull Request** 评论区发送以下指令,Bot 会自动创建 PR 更新 README:
|
||||
|
||||
```text
|
||||
@all-contributors please add @username for <contribution-type>
|
||||
```
|
||||
|
||||
### 2. 常用贡献类型 (Common Contribution Types)
|
||||
|
||||
| 类型 (Type) | 含义 (Meaning) | 图标 (Icon) |
|
||||
| :--- | :--- | :---: |
|
||||
| **`ideas`** | 提供想法、功能建议或改进思路 | 🤔 |
|
||||
| **`code`** | 编写并提交代码实现 | 💻 |
|
||||
| **`bug`** | 报告 Bug 或发现逻辑缺陷 | 🐛 |
|
||||
| **`doc`** | 改进文档、README 或注释 | 📖 |
|
||||
| **`translation`** | 提供多语言翻译支持 | 🌍 |
|
||||
| **`review`** | 进行代码审查 (Code Review) | 👀 |
|
||||
| **`design`** | 提供 UI/UX 设计或图标 | 🎨 |
|
||||
| **`question`** | 在讨论区回答用户问题 | 💬 |
|
||||
| **`tutorial`** | 编写教程或使用指南 | ✅ |
|
||||
|
||||
### 3. 核心区别:`ideas` vs `code`
|
||||
|
||||
- **`ideas`**: 贡献者提供了核心思路、逻辑优化方案或功能需求,但未直接编写代码。
|
||||
- **`code`**: 贡献者直接编写并提交了 Pull Request。
|
||||
- **组合使用**: 如果贡献者既提出了方案又完成了实现,应同时添加:`for ideas, code`。
|
||||
|
||||
### 4. 多次贡献处理 (Multiple Contributions)
|
||||
|
||||
All Contributors 支持勋章累加,无需担心重复添加:
|
||||
|
||||
- **累加勋章**: 如果贡献者已在列表中,再次发送指令指定新类型(如 `@all-contributors please add @user for doc`),Bot 会自动将新勋章追加到该用户头像下方。
|
||||
- **一次性添加**: 支持在单条指令中列出所有类型:`for code, doc, ideas`。
|
||||
- **手动修正**: 若需删除或修正勋章,需手动编辑 `.all-contributorsrc` 文件中的 `contributions` 数组。
|
||||
|
||||
---
|
||||
|
||||
## <20>📚 参考资源 (Reference Resources)
|
||||
|
||||
- [Action 插件模板 (英文)](plugins/actions/ACTION_PLUGIN_TEMPLATE.py)
|
||||
|
||||
32
.github/workflows/community-stats.yml
vendored
32
.github/workflows/community-stats.yml
vendored
@@ -32,16 +32,7 @@ jobs:
|
||||
run: |
|
||||
pip install requests python-dotenv
|
||||
|
||||
- name: Get previous stats
|
||||
id: prev_stats
|
||||
run: |
|
||||
# 获取当前的 points 用于比较
|
||||
if [ -f docs/community-stats.json ]; then
|
||||
OLD_POINTS=$(jq -r '.user.total_points' docs/community-stats.json 2>/dev/null || echo "0")
|
||||
echo "old_points=$OLD_POINTS" >> $GITHUB_OUTPUT
|
||||
else
|
||||
echo "old_points=0" >> $GITHUB_OUTPUT
|
||||
fi
|
||||
|
||||
|
||||
- name: Generate stats report
|
||||
env:
|
||||
@@ -49,27 +40,8 @@ jobs:
|
||||
OPENWEBUI_USER_ID: ${{ secrets.OPENWEBUI_USER_ID }}
|
||||
run: |
|
||||
python scripts/openwebui_stats.py
|
||||
|
||||
- name: Check for significant changes
|
||||
id: check_changes
|
||||
run: |
|
||||
# 获取新的 points
|
||||
NEW_POINTS=$(jq -r '.user.total_points' docs/community-stats.json 2>/dev/null || echo "0")
|
||||
|
||||
echo "📊 Previous points: ${{ steps.prev_stats.outputs.old_points }}"
|
||||
echo "📊 Current points: $NEW_POINTS"
|
||||
|
||||
# 只在 points 变化时才 commit
|
||||
if [ "$NEW_POINTS" != "${{ steps.prev_stats.outputs.old_points }}" ]; then
|
||||
echo "changed=true" >> $GITHUB_OUTPUT
|
||||
echo "✅ Points changed (${{ steps.prev_stats.outputs.old_points }} → $NEW_POINTS), will commit"
|
||||
else
|
||||
echo "changed=false" >> $GITHUB_OUTPUT
|
||||
echo "⏭️ Points unchanged, skipping commit"
|
||||
fi
|
||||
|
||||
|
||||
- name: Commit and push changes
|
||||
if: steps.check_changes.outputs.changed == 'true'
|
||||
run: |
|
||||
git config --local user.email "github-actions[bot]@users.noreply.github.com"
|
||||
git config --local user.name "github-actions[bot]"
|
||||
|
||||
57
README.md
57
README.md
@@ -1,4 +1,7 @@
|
||||
# OpenWebUI Extras
|
||||
<!-- ALL-CONTRIBUTORS-BADGE:START - Do not remove or modify this section -->
|
||||
[](#contributors-)
|
||||
<!-- ALL-CONTRIBUTORS-BADGE:END -->
|
||||
|
||||
English | [中文](./README_CN.md)
|
||||
|
||||
@@ -7,28 +10,28 @@ A collection of enhancements, plugins, and prompts for [OpenWebUI](https://githu
|
||||
<!-- STATS_START -->
|
||||
## 📊 Community Stats
|
||||
|
||||
> 🕐 Auto-updated: 2026-01-11 19:06
|
||||
> 🕐 Auto-updated: 2026-01-12 23:10
|
||||
|
||||
| 👤 Author | 👥 Followers | ⭐ Points | 🏆 Contributions |
|
||||
|:---:|:---:|:---:|:---:|
|
||||
| [Fu-Jie](https://openwebui.com/u/Fu-Jie) | **78** | **79** | **22** |
|
||||
| [Fu-Jie](https://openwebui.com/u/Fu-Jie) | **88** | **91** | **22** |
|
||||
|
||||
| 📝 Posts | ⬇️ Downloads | 👁️ Views | 👍 Upvotes | 💾 Saves |
|
||||
|:---:|:---:|:---:|:---:|:---:|
|
||||
| **14** | **1134** | **12338** | **69** | **68** |
|
||||
| **14** | **1230** | **13650** | **80** | **79** |
|
||||
|
||||
### 🔥 Top 6 Popular Plugins
|
||||
|
||||
> 🕐 Auto-updated: 2026-01-11 19:06
|
||||
> 🕐 Auto-updated: 2026-01-12 23:10
|
||||
|
||||
| Rank | Plugin | Downloads | Views | Updated |
|
||||
|:---:|------|:---:|:---:|:---:|
|
||||
| 🥇 | [Smart Mind Map](https://openwebui.com/posts/turn_any_text_into_beautiful_mind_maps_3094c59a) | 363 | 3289 | 2026-01-07 |
|
||||
| 🥈 | [Export to Excel](https://openwebui.com/posts/export_mulit_table_to_excel_244b8f9d) | 183 | 568 | 2026-01-07 |
|
||||
| 🥉 | [Async Context Compression](https://openwebui.com/posts/async_context_compression_b1655bc8) | 132 | 1475 | 2026-01-11 |
|
||||
| 4️⃣ | [📊 Smart Infographic (AntV)](https://openwebui.com/posts/smart_infographic_ad6f0c7f) | 129 | 1437 | 2026-01-07 |
|
||||
| 5️⃣ | [Flash Card](https://openwebui.com/posts/flash_card_65a2ea8f) | 99 | 1812 | 2026-01-07 |
|
||||
| 6️⃣ | [Export to Word (Enhanced)](https://openwebui.com/posts/export_to_word_enhanced_formatting_fca6a315) | 89 | 834 | 2026-01-07 |
|
||||
| Rank | Plugin | Version | Downloads | Views | Updated |
|
||||
|:---:|------|:---:|:---:|:---:|:---:|
|
||||
| 🥇 | [Smart Mind Map](https://openwebui.com/posts/turn_any_text_into_beautiful_mind_maps_3094c59a) | 0.9.1 | 392 | 3535 | 2026-01-07 |
|
||||
| 🥈 | [Export to Excel](https://openwebui.com/posts/export_mulit_table_to_excel_244b8f9d) | 0.3.7 | 187 | 604 | 2026-01-07 |
|
||||
| 🥉 | [📊 Smart Infographic (AntV)](https://openwebui.com/posts/smart_infographic_ad6f0c7f) | 1.4.9 | 145 | 1594 | 2026-01-11 |
|
||||
| 4️⃣ | [Async Context Compression](https://openwebui.com/posts/async_context_compression_b1655bc8) | 1.1.3 | 144 | 1596 | 2026-01-11 |
|
||||
| 5️⃣ | [Export to Word (Enhanced)](https://openwebui.com/posts/export_to_word_enhanced_formatting_fca6a315) | 0.4.3 | 104 | 938 | 2026-01-07 |
|
||||
| 6️⃣ | [Flash Card](https://openwebui.com/posts/flash_card_65a2ea8f) | 0.2.4 | 101 | 1881 | 2026-01-07 |
|
||||
|
||||
*See full stats in [Community Stats Report](./docs/community-stats.md)*
|
||||
<!-- STATS_END -->
|
||||
@@ -42,16 +45,18 @@ Located in the `plugins/` directory, containing Python-based enhancements:
|
||||
#### Actions
|
||||
- **Smart Mind Map** (`smart-mind-map`): Generates interactive mind maps from text.
|
||||
- **Smart Infographic** (`infographic`): Transforms text into professional infographics using AntV.
|
||||
- **Knowledge Card** (`knowledge-card`): Creates beautiful flashcards for learning.
|
||||
- **Flash Card** (`flash-card`): Quickly generates beautiful flashcards for learning.
|
||||
- **Deep Dive** (`deep-dive`): A comprehensive thinking lens that dives deep into any content.
|
||||
- **Export to Excel** (`export_to_excel`): Exports chat history to Excel files.
|
||||
- **Export to Word** (`export_to_docx`): Exports chat history to Word documents.
|
||||
- **Summary** (`summary`): Text summarization tool.
|
||||
|
||||
#### Filters
|
||||
- **Async Context Compression** (`async-context-compression`): Optimizes token usage via context compression.
|
||||
- **Context Enhancement** (`context_enhancement_filter`): Enhances chat context.
|
||||
- **Gemini Manifold Companion** (`gemini_manifold_companion`): Companion filter for Gemini Manifold.
|
||||
- **Gemini Multimodal Filter** (`web_gemini_multimodel_filter`): Provides multimodal capabilities (PDF, Office, Video) for any model via Gemini.
|
||||
- **Markdown Normalizer** (`markdown_normalizer`): Fixes common Markdown formatting issues in LLM outputs.
|
||||
- **Multi-Model Context Merger** (`multi_model_context_merger`): Automatically merges and injects context from multiple model responses.
|
||||
|
||||
|
||||
#### Pipes
|
||||
@@ -107,3 +112,27 @@ If you have great prompts or plugins to share:
|
||||
3. Submit a Pull Request.
|
||||
|
||||
[Contributing](./CONTRIBUTING.md)
|
||||
|
||||
## Contributors ✨
|
||||
|
||||
Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):
|
||||
|
||||
<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
|
||||
<!-- prettier-ignore-start -->
|
||||
<!-- markdownlint-disable -->
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td align="center" valign="top" width="14.28%"><a href="https://github.com/rbb-dev"><img src="https://avatars.githubusercontent.com/u/37469229?v=4?s=100" width="100px;" alt="rbb-dev"/><br /><sub><b>rbb-dev</b></sub></a><br /><a href="#ideas-rbb-dev" title="Ideas, Planning, & Feedback">🤔</a> <a href="https://github.com/Fu-Jie/awesome-openwebui/commits?author=rbb-dev" title="Code">💻</a></td>
|
||||
<td align="center" valign="top" width="14.28%"><a href="https://trade.xyz/?ref=BZ1RJRXWO"><img src="https://avatars.githubusercontent.com/u/7317522?v=4?s=100" width="100px;" alt="Raxxoor"/><br /><sub><b>Raxxoor</b></sub></a><br /><a href="https://github.com/Fu-Jie/awesome-openwebui/issues?q=author%3Adhaern" title="Bug reports">🐛</a> <a href="#ideas-dhaern" title="Ideas, Planning, & Feedback">🤔</a></td>
|
||||
<td align="center" valign="top" width="14.28%"><a href="https://github.com/i-iooi-i"><img src="https://avatars.githubusercontent.com/u/1827701?v=4?s=100" width="100px;" alt="ZOLO"/><br /><sub><b>ZOLO</b></sub></a><br /><a href="https://github.com/Fu-Jie/awesome-openwebui/issues?q=author%3Ai-iooi-i" title="Bug reports">🐛</a> <a href="#ideas-i-iooi-i" title="Ideas, Planning, & Feedback">🤔</a></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<!-- markdownlint-restore -->
|
||||
<!-- prettier-ignore-end -->
|
||||
|
||||
<!-- ALL-CONTRIBUTORS-LIST:END -->
|
||||
|
||||
This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!
|
||||
|
||||
30
README_CN.md
30
README_CN.md
@@ -7,28 +7,28 @@ OpenWebUI 增强功能集合。包含个人开发与收集的插件、提示词
|
||||
<!-- STATS_START -->
|
||||
## 📊 社区统计
|
||||
|
||||
> 🕐 自动更新于 2026-01-11 19:06
|
||||
> 🕐 自动更新于 2026-01-12 23:10
|
||||
|
||||
| 👤 作者 | 👥 粉丝 | ⭐ 积分 | 🏆 贡献 |
|
||||
|:---:|:---:|:---:|:---:|
|
||||
| [Fu-Jie](https://openwebui.com/u/Fu-Jie) | **78** | **79** | **22** |
|
||||
| [Fu-Jie](https://openwebui.com/u/Fu-Jie) | **88** | **91** | **22** |
|
||||
|
||||
| 📝 发布 | ⬇️ 下载 | 👁️ 浏览 | 👍 点赞 | 💾 收藏 |
|
||||
|:---:|:---:|:---:|:---:|:---:|
|
||||
| **14** | **1134** | **12338** | **69** | **68** |
|
||||
| **14** | **1230** | **13650** | **80** | **79** |
|
||||
|
||||
### 🔥 热门插件 Top 6
|
||||
|
||||
> 🕐 自动更新于 2026-01-11 19:06
|
||||
> 🕐 自动更新于 2026-01-12 23:10
|
||||
|
||||
| 排名 | 插件 | 下载 | 浏览 | 更新日期 |
|
||||
|:---:|------|:---:|:---:|:---:|
|
||||
| 🥇 | [Smart Mind Map](https://openwebui.com/posts/turn_any_text_into_beautiful_mind_maps_3094c59a) | 363 | 3289 | 2026-01-07 |
|
||||
| 🥈 | [Export to Excel](https://openwebui.com/posts/export_mulit_table_to_excel_244b8f9d) | 183 | 568 | 2026-01-07 |
|
||||
| 🥉 | [Async Context Compression](https://openwebui.com/posts/async_context_compression_b1655bc8) | 132 | 1475 | 2026-01-11 |
|
||||
| 4️⃣ | [📊 Smart Infographic (AntV)](https://openwebui.com/posts/smart_infographic_ad6f0c7f) | 129 | 1437 | 2026-01-07 |
|
||||
| 5️⃣ | [Flash Card](https://openwebui.com/posts/flash_card_65a2ea8f) | 99 | 1812 | 2026-01-07 |
|
||||
| 6️⃣ | [Export to Word (Enhanced)](https://openwebui.com/posts/export_to_word_enhanced_formatting_fca6a315) | 89 | 834 | 2026-01-07 |
|
||||
| 排名 | 插件 | 版本 | 下载 | 浏览 | 更新日期 |
|
||||
|:---:|------|:---:|:---:|:---:|:---:|
|
||||
| 🥇 | [Smart Mind Map](https://openwebui.com/posts/turn_any_text_into_beautiful_mind_maps_3094c59a) | 0.9.1 | 392 | 3535 | 2026-01-07 |
|
||||
| 🥈 | [Export to Excel](https://openwebui.com/posts/export_mulit_table_to_excel_244b8f9d) | 0.3.7 | 187 | 604 | 2026-01-07 |
|
||||
| 🥉 | [📊 Smart Infographic (AntV)](https://openwebui.com/posts/smart_infographic_ad6f0c7f) | 1.4.9 | 145 | 1594 | 2026-01-11 |
|
||||
| 4️⃣ | [Async Context Compression](https://openwebui.com/posts/async_context_compression_b1655bc8) | 1.1.3 | 144 | 1596 | 2026-01-11 |
|
||||
| 5️⃣ | [Export to Word (Enhanced)](https://openwebui.com/posts/export_to_word_enhanced_formatting_fca6a315) | 0.4.3 | 104 | 938 | 2026-01-07 |
|
||||
| 6️⃣ | [Flash Card](https://openwebui.com/posts/flash_card_65a2ea8f) | 0.2.4 | 101 | 1881 | 2026-01-07 |
|
||||
|
||||
*完整统计请查看 [社区统计报告](./docs/community-stats.zh.md)*
|
||||
<!-- STATS_END -->
|
||||
@@ -42,16 +42,18 @@ OpenWebUI 增强功能集合。包含个人开发与收集的插件、提示词
|
||||
#### Actions (交互增强)
|
||||
- **Smart Mind Map** (`smart-mind-map`): 智能分析文本并生成交互式思维导图。
|
||||
- **Smart Infographic** (`infographic`): 基于 AntV 的智能信息图生成工具。
|
||||
- **Knowledge Card** (`knowledge-card`): 快速生成精美的学习记忆卡片。
|
||||
- **Flash Card** (`flash-card`): 快速生成精美的学习记忆卡片。
|
||||
- **Deep Dive** (`deep-dive`): 深度思考透镜,从背景、逻辑、洞察到行动路径的全方位分析。
|
||||
- **Export to Excel** (`export_to_excel`): 将对话内容导出为 Excel 文件。
|
||||
- **Export to Word** (`export_to_docx`): 将对话内容导出为 Word 文档。
|
||||
- **Summary** (`summary`): 文本摘要生成工具。
|
||||
|
||||
#### Filters (消息处理)
|
||||
- **Async Context Compression** (`async-context-compression`): 异步上下文压缩,优化 Token 使用。
|
||||
- **Context Enhancement** (`context_enhancement_filter`): 上下文增强过滤器。
|
||||
- **Gemini Manifold Companion** (`gemini_manifold_companion`): Gemini Manifold 配套增强。
|
||||
- **Gemini Multimodal Filter** (`web_gemini_multimodel_filter`): 为任意模型提供多模态能力(PDF、Office、视频等),支持智能路由和字幕精修。
|
||||
- **Markdown Normalizer** (`markdown_normalizer`): 修复 LLM 输出中常见的 Markdown 格式问题。
|
||||
- **Multi-Model Context Merger** (`multi_model_context_merger`): 自动合并并注入多模型回答的上下文。
|
||||
|
||||
#### Pipes (模型管道)
|
||||
- **Gemini Manifold** (`gemini_mainfold`): 集成 Gemini 模型的管道。
|
||||
|
||||
@@ -1,15 +1,14 @@
|
||||
{
|
||||
"total_posts": 14,
|
||||
"total_downloads": 1134,
|
||||
"total_views": 12338,
|
||||
"total_upvotes": 69,
|
||||
"total_downloads": 1230,
|
||||
"total_views": 13650,
|
||||
"total_upvotes": 80,
|
||||
"total_downvotes": 2,
|
||||
"total_saves": 68,
|
||||
"total_comments": 17,
|
||||
"total_saves": 79,
|
||||
"total_comments": 18,
|
||||
"by_type": {
|
||||
"filter": 2,
|
||||
"unknown": 1,
|
||||
"action": 11
|
||||
"action": 13,
|
||||
"unknown": 1
|
||||
},
|
||||
"posts": [
|
||||
{
|
||||
@@ -19,11 +18,11 @@
|
||||
"version": "0.9.1",
|
||||
"author": "Fu-Jie",
|
||||
"description": "Intelligently analyzes text content and generates interactive mind maps to help users structure and visualize knowledge.",
|
||||
"downloads": 363,
|
||||
"views": 3289,
|
||||
"upvotes": 10,
|
||||
"saves": 21,
|
||||
"comments": 10,
|
||||
"downloads": 392,
|
||||
"views": 3535,
|
||||
"upvotes": 11,
|
||||
"saves": 22,
|
||||
"comments": 11,
|
||||
"created_at": "2025-12-30",
|
||||
"updated_at": "2026-01-07",
|
||||
"url": "https://openwebui.com/posts/turn_any_text_into_beautiful_mind_maps_3094c59a"
|
||||
@@ -35,8 +34,8 @@
|
||||
"version": "0.3.7",
|
||||
"author": "Fu-Jie",
|
||||
"description": "Extracts tables from chat messages and exports them to Excel (.xlsx) files with smart formatting.",
|
||||
"downloads": 183,
|
||||
"views": 568,
|
||||
"downloads": 187,
|
||||
"views": 604,
|
||||
"upvotes": 3,
|
||||
"saves": 4,
|
||||
"comments": 0,
|
||||
@@ -44,54 +43,38 @@
|
||||
"updated_at": "2026-01-07",
|
||||
"url": "https://openwebui.com/posts/export_mulit_table_to_excel_244b8f9d"
|
||||
},
|
||||
{
|
||||
"title": "📊 Smart Infographic (AntV)",
|
||||
"slug": "smart_infographic_ad6f0c7f",
|
||||
"type": "action",
|
||||
"version": "1.4.9",
|
||||
"author": "Fu-Jie",
|
||||
"description": "AI-powered infographic generator based on AntV Infographic. Supports professional templates, auto-icon matching, and SVG/PNG downloads.",
|
||||
"downloads": 145,
|
||||
"views": 1594,
|
||||
"upvotes": 8,
|
||||
"saves": 10,
|
||||
"comments": 2,
|
||||
"created_at": "2025-12-28",
|
||||
"updated_at": "2026-01-11",
|
||||
"url": "https://openwebui.com/posts/smart_infographic_ad6f0c7f"
|
||||
},
|
||||
{
|
||||
"title": "Async Context Compression",
|
||||
"slug": "async_context_compression_b1655bc8",
|
||||
"type": "filter",
|
||||
"version": "1.1.2",
|
||||
"type": "action",
|
||||
"version": "1.1.3",
|
||||
"author": "Fu-Jie",
|
||||
"description": "Reduces token consumption in long conversations while maintaining coherence through intelligent summarization and message compression.",
|
||||
"downloads": 132,
|
||||
"views": 1475,
|
||||
"upvotes": 5,
|
||||
"saves": 9,
|
||||
"downloads": 144,
|
||||
"views": 1596,
|
||||
"upvotes": 7,
|
||||
"saves": 11,
|
||||
"comments": 0,
|
||||
"created_at": "2025-11-08",
|
||||
"updated_at": "2026-01-11",
|
||||
"url": "https://openwebui.com/posts/async_context_compression_b1655bc8"
|
||||
},
|
||||
{
|
||||
"title": "📊 Smart Infographic (AntV)",
|
||||
"slug": "smart_infographic_ad6f0c7f",
|
||||
"type": "action",
|
||||
"version": "1.4.1",
|
||||
"author": "jeff",
|
||||
"description": "AI-powered infographic generator based on AntV Infographic. Supports professional templates, auto-icon matching, and SVG/PNG downloads.",
|
||||
"downloads": 129,
|
||||
"views": 1437,
|
||||
"upvotes": 7,
|
||||
"saves": 9,
|
||||
"comments": 2,
|
||||
"created_at": "2025-12-28",
|
||||
"updated_at": "2026-01-07",
|
||||
"url": "https://openwebui.com/posts/smart_infographic_ad6f0c7f"
|
||||
},
|
||||
{
|
||||
"title": "Flash Card",
|
||||
"slug": "flash_card_65a2ea8f",
|
||||
"type": "action",
|
||||
"version": "0.2.4",
|
||||
"author": "Fu-Jie",
|
||||
"description": "Quickly generates beautiful flashcards from text, extracting key points and categories.",
|
||||
"downloads": 99,
|
||||
"views": 1812,
|
||||
"upvotes": 8,
|
||||
"saves": 6,
|
||||
"comments": 2,
|
||||
"created_at": "2025-12-30",
|
||||
"updated_at": "2026-01-07",
|
||||
"url": "https://openwebui.com/posts/flash_card_65a2ea8f"
|
||||
},
|
||||
{
|
||||
"title": "Export to Word (Enhanced)",
|
||||
"slug": "export_to_word_enhanced_formatting_fca6a315",
|
||||
@@ -99,15 +82,31 @@
|
||||
"version": "0.4.3",
|
||||
"author": "Fu-Jie",
|
||||
"description": "Export current conversation from Markdown to Word (.docx) with Mermaid diagrams rendered client-side (Mermaid.js, SVG+PNG), LaTeX math, real hyperlinks, improved tables, syntax highlighting, and blockquote support.",
|
||||
"downloads": 89,
|
||||
"views": 834,
|
||||
"upvotes": 5,
|
||||
"saves": 8,
|
||||
"downloads": 104,
|
||||
"views": 938,
|
||||
"upvotes": 6,
|
||||
"saves": 10,
|
||||
"comments": 0,
|
||||
"created_at": "2026-01-03",
|
||||
"updated_at": "2026-01-07",
|
||||
"url": "https://openwebui.com/posts/export_to_word_enhanced_formatting_fca6a315"
|
||||
},
|
||||
{
|
||||
"title": "Flash Card",
|
||||
"slug": "flash_card_65a2ea8f",
|
||||
"type": "action",
|
||||
"version": "0.2.4",
|
||||
"author": "Fu-Jie",
|
||||
"description": "Quickly generates beautiful flashcards from text, extracting key points and categories.",
|
||||
"downloads": 101,
|
||||
"views": 1881,
|
||||
"upvotes": 8,
|
||||
"saves": 6,
|
||||
"comments": 2,
|
||||
"created_at": "2025-12-30",
|
||||
"updated_at": "2026-01-07",
|
||||
"url": "https://openwebui.com/posts/flash_card_65a2ea8f"
|
||||
},
|
||||
{
|
||||
"title": "导出为 Word (增强版)",
|
||||
"slug": "导出为_word_支持公式流程图表格和代码块_8a6306c0",
|
||||
@@ -115,9 +114,9 @@
|
||||
"version": "0.4.3",
|
||||
"author": "Fu-Jie",
|
||||
"description": "将对话导出为 Word (.docx),支持 Mermaid 图表 (客户端渲染 SVG+PNG)、LaTeX 数学公式、真实超链接、增强表格格式、代码高亮和引用块。",
|
||||
"downloads": 35,
|
||||
"views": 979,
|
||||
"upvotes": 8,
|
||||
"downloads": 40,
|
||||
"views": 1038,
|
||||
"upvotes": 9,
|
||||
"saves": 2,
|
||||
"comments": 1,
|
||||
"created_at": "2026-01-04",
|
||||
@@ -128,16 +127,16 @@
|
||||
"title": "📊 智能信息图 (AntV Infographic)",
|
||||
"slug": "智能信息图_e04a48ff",
|
||||
"type": "action",
|
||||
"version": "1.4.1",
|
||||
"author": "jeff",
|
||||
"version": "1.4.9",
|
||||
"author": "Fu-Jie",
|
||||
"description": "基于 AntV Infographic 的智能信息图生成插件。支持多种专业模板,自动图标匹配,并提供 SVG/PNG 下载功能。",
|
||||
"downloads": 35,
|
||||
"views": 492,
|
||||
"views": 525,
|
||||
"upvotes": 3,
|
||||
"saves": 0,
|
||||
"comments": 0,
|
||||
"created_at": "2025-12-28",
|
||||
"updated_at": "2026-01-07",
|
||||
"updated_at": "2026-01-11",
|
||||
"url": "https://openwebui.com/posts/智能信息图_e04a48ff"
|
||||
},
|
||||
{
|
||||
@@ -147,8 +146,8 @@
|
||||
"version": "1.0.0",
|
||||
"author": "Fu-Jie",
|
||||
"description": "A comprehensive thinking lens that dives deep into any content - from context to logic, insights, and action paths.",
|
||||
"downloads": 28,
|
||||
"views": 298,
|
||||
"downloads": 35,
|
||||
"views": 351,
|
||||
"upvotes": 3,
|
||||
"saves": 4,
|
||||
"comments": 0,
|
||||
@@ -163,8 +162,8 @@
|
||||
"version": "0.9.1",
|
||||
"author": "Fu-Jie",
|
||||
"description": "智能分析文本内容,生成交互式思维导图,帮助用户结构化和可视化知识。",
|
||||
"downloads": 18,
|
||||
"views": 320,
|
||||
"downloads": 19,
|
||||
"views": 339,
|
||||
"upvotes": 2,
|
||||
"saves": 1,
|
||||
"comments": 0,
|
||||
@@ -172,6 +171,22 @@
|
||||
"updated_at": "2026-01-07",
|
||||
"url": "https://openwebui.com/posts/智能生成交互式思维导图帮助用户可视化知识_8d4b097b"
|
||||
},
|
||||
{
|
||||
"title": "异步上下文压缩",
|
||||
"slug": "异步上下文压缩_5c0617cb",
|
||||
"type": "action",
|
||||
"version": "1.1.3",
|
||||
"author": "Fu-Jie",
|
||||
"description": "通过智能摘要和消息压缩,降低长对话的 token 消耗,同时保持对话连贯性。",
|
||||
"downloads": 12,
|
||||
"views": 254,
|
||||
"upvotes": 4,
|
||||
"saves": 1,
|
||||
"comments": 0,
|
||||
"created_at": "2025-11-08",
|
||||
"updated_at": "2026-01-11",
|
||||
"url": "https://openwebui.com/posts/异步上下文压缩_5c0617cb"
|
||||
},
|
||||
{
|
||||
"title": "闪记卡 (Flash Card)",
|
||||
"slug": "闪记卡生成插件_4a31eac3",
|
||||
@@ -180,7 +195,7 @@
|
||||
"author": "Fu-Jie",
|
||||
"description": "快速将文本提炼为精美的学习记忆卡片,支持核心要点提取与分类。",
|
||||
"downloads": 12,
|
||||
"views": 353,
|
||||
"views": 376,
|
||||
"upvotes": 4,
|
||||
"saves": 1,
|
||||
"comments": 0,
|
||||
@@ -188,22 +203,6 @@
|
||||
"updated_at": "2026-01-07",
|
||||
"url": "https://openwebui.com/posts/闪记卡生成插件_4a31eac3"
|
||||
},
|
||||
{
|
||||
"title": "异步上下文压缩",
|
||||
"slug": "异步上下文压缩_5c0617cb",
|
||||
"type": "filter",
|
||||
"version": "1.1.2",
|
||||
"author": "Fu-Jie",
|
||||
"description": "通过智能摘要和消息压缩,降低长对话的 token 消耗,同时保持对话连贯性。",
|
||||
"downloads": 8,
|
||||
"views": 196,
|
||||
"upvotes": 4,
|
||||
"saves": 1,
|
||||
"comments": 0,
|
||||
"created_at": "2025-11-08",
|
||||
"updated_at": "2026-01-11",
|
||||
"url": "https://openwebui.com/posts/异步上下文压缩_5c0617cb"
|
||||
},
|
||||
{
|
||||
"title": "精读",
|
||||
"slug": "精读_99830b0f",
|
||||
@@ -211,8 +210,8 @@
|
||||
"version": "1.0.0",
|
||||
"author": "Fu-Jie",
|
||||
"description": "全方位的思维透镜 —— 从背景全景到逻辑脉络,从深度洞察到行动路径。",
|
||||
"downloads": 3,
|
||||
"views": 108,
|
||||
"downloads": 4,
|
||||
"views": 131,
|
||||
"upvotes": 2,
|
||||
"saves": 1,
|
||||
"comments": 0,
|
||||
@@ -228,9 +227,9 @@
|
||||
"author": "",
|
||||
"description": "",
|
||||
"downloads": 0,
|
||||
"views": 177,
|
||||
"upvotes": 5,
|
||||
"saves": 1,
|
||||
"views": 488,
|
||||
"upvotes": 10,
|
||||
"saves": 6,
|
||||
"comments": 2,
|
||||
"created_at": "2026-01-10",
|
||||
"updated_at": "2026-01-10",
|
||||
@@ -242,11 +241,11 @@
|
||||
"name": "Fu-Jie",
|
||||
"profile_url": "https://openwebui.com/u/Fu-Jie",
|
||||
"profile_image": "https://community.s3.openwebui.com/uploads/users/b15d1348-4347-42b4-b815-e053342d6cb0/profile_d9510745-4bd4-4f8f-a997-4a21847d9300.webp",
|
||||
"followers": 78,
|
||||
"followers": 88,
|
||||
"following": 2,
|
||||
"total_points": 79,
|
||||
"post_points": 67,
|
||||
"comment_points": 12,
|
||||
"total_points": 91,
|
||||
"post_points": 78,
|
||||
"comment_points": 13,
|
||||
"contributions": 22
|
||||
}
|
||||
}
|
||||
@@ -1,39 +1,38 @@
|
||||
# 📊 OpenWebUI Community Stats Report
|
||||
|
||||
> 📅 Updated: 2026-01-11 19:06
|
||||
> 📅 Updated: 2026-01-12 23:10
|
||||
|
||||
## 📈 Overview
|
||||
|
||||
| Metric | Value |
|
||||
|------|------|
|
||||
| 📝 Total Posts | 14 |
|
||||
| ⬇️ Total Downloads | 1134 |
|
||||
| 👁️ Total Views | 12338 |
|
||||
| 👍 Total Upvotes | 69 |
|
||||
| 💾 Total Saves | 68 |
|
||||
| 💬 Total Comments | 17 |
|
||||
| ⬇️ Total Downloads | 1230 |
|
||||
| 👁️ Total Views | 13650 |
|
||||
| 👍 Total Upvotes | 80 |
|
||||
| 💾 Total Saves | 79 |
|
||||
| 💬 Total Comments | 18 |
|
||||
|
||||
## 📂 By Type
|
||||
|
||||
- **filter**: 2
|
||||
- **action**: 13
|
||||
- **unknown**: 1
|
||||
- **action**: 11
|
||||
|
||||
## 📋 Posts List
|
||||
|
||||
| Rank | Title | Type | Version | Downloads | Views | Upvotes | Saves | Updated |
|
||||
|:---:|------|:---:|:---:|:---:|:---:|:---:|:---:|:---:|
|
||||
| 1 | [Smart Mind Map](https://openwebui.com/posts/turn_any_text_into_beautiful_mind_maps_3094c59a) | action | 0.9.1 | 363 | 3289 | 10 | 21 | 2026-01-07 |
|
||||
| 2 | [Export to Excel](https://openwebui.com/posts/export_mulit_table_to_excel_244b8f9d) | action | 0.3.7 | 183 | 568 | 3 | 4 | 2026-01-07 |
|
||||
| 3 | [Async Context Compression](https://openwebui.com/posts/async_context_compression_b1655bc8) | filter | 1.1.2 | 132 | 1475 | 5 | 9 | 2026-01-11 |
|
||||
| 4 | [📊 Smart Infographic (AntV)](https://openwebui.com/posts/smart_infographic_ad6f0c7f) | action | 1.4.1 | 129 | 1437 | 7 | 9 | 2026-01-07 |
|
||||
| 5 | [Flash Card](https://openwebui.com/posts/flash_card_65a2ea8f) | action | 0.2.4 | 99 | 1812 | 8 | 6 | 2026-01-07 |
|
||||
| 6 | [Export to Word (Enhanced)](https://openwebui.com/posts/export_to_word_enhanced_formatting_fca6a315) | action | 0.4.3 | 89 | 834 | 5 | 8 | 2026-01-07 |
|
||||
| 7 | [导出为 Word (增强版)](https://openwebui.com/posts/导出为_word_支持公式流程图表格和代码块_8a6306c0) | action | 0.4.3 | 35 | 979 | 8 | 2 | 2026-01-07 |
|
||||
| 8 | [📊 智能信息图 (AntV Infographic)](https://openwebui.com/posts/智能信息图_e04a48ff) | action | 1.4.1 | 35 | 492 | 3 | 0 | 2026-01-07 |
|
||||
| 9 | [Deep Dive](https://openwebui.com/posts/deep_dive_c0b846e4) | action | 1.0.0 | 28 | 298 | 3 | 4 | 2026-01-08 |
|
||||
| 10 | [思维导图](https://openwebui.com/posts/智能生成交互式思维导图帮助用户可视化知识_8d4b097b) | action | 0.9.1 | 18 | 320 | 2 | 1 | 2026-01-07 |
|
||||
| 11 | [闪记卡 (Flash Card)](https://openwebui.com/posts/闪记卡生成插件_4a31eac3) | action | 0.2.4 | 12 | 353 | 4 | 1 | 2026-01-07 |
|
||||
| 12 | [异步上下文压缩](https://openwebui.com/posts/异步上下文压缩_5c0617cb) | filter | 1.1.2 | 8 | 196 | 4 | 1 | 2026-01-11 |
|
||||
| 13 | [精读](https://openwebui.com/posts/精读_99830b0f) | action | 1.0.0 | 3 | 108 | 2 | 1 | 2026-01-08 |
|
||||
| 14 | [ 🛠️ Debug Open WebUI Plugins in Your Browser](https://openwebui.com/posts/debug_open_webui_plugins_in_your_browser_81bf7960) | unknown | | 0 | 177 | 5 | 1 | 2026-01-10 |
|
||||
| 1 | [Smart Mind Map](https://openwebui.com/posts/turn_any_text_into_beautiful_mind_maps_3094c59a) | action | 0.9.1 | 392 | 3535 | 11 | 22 | 2026-01-07 |
|
||||
| 2 | [Export to Excel](https://openwebui.com/posts/export_mulit_table_to_excel_244b8f9d) | action | 0.3.7 | 187 | 604 | 3 | 4 | 2026-01-07 |
|
||||
| 3 | [📊 Smart Infographic (AntV)](https://openwebui.com/posts/smart_infographic_ad6f0c7f) | action | 1.4.9 | 145 | 1594 | 8 | 10 | 2026-01-11 |
|
||||
| 4 | [Async Context Compression](https://openwebui.com/posts/async_context_compression_b1655bc8) | action | 1.1.3 | 144 | 1596 | 7 | 11 | 2026-01-11 |
|
||||
| 5 | [Export to Word (Enhanced)](https://openwebui.com/posts/export_to_word_enhanced_formatting_fca6a315) | action | 0.4.3 | 104 | 938 | 6 | 10 | 2026-01-07 |
|
||||
| 6 | [Flash Card](https://openwebui.com/posts/flash_card_65a2ea8f) | action | 0.2.4 | 101 | 1881 | 8 | 6 | 2026-01-07 |
|
||||
| 7 | [导出为 Word (增强版)](https://openwebui.com/posts/导出为_word_支持公式流程图表格和代码块_8a6306c0) | action | 0.4.3 | 40 | 1038 | 9 | 2 | 2026-01-07 |
|
||||
| 8 | [📊 智能信息图 (AntV Infographic)](https://openwebui.com/posts/智能信息图_e04a48ff) | action | 1.4.9 | 35 | 525 | 3 | 0 | 2026-01-11 |
|
||||
| 9 | [Deep Dive](https://openwebui.com/posts/deep_dive_c0b846e4) | action | 1.0.0 | 35 | 351 | 3 | 4 | 2026-01-08 |
|
||||
| 10 | [思维导图](https://openwebui.com/posts/智能生成交互式思维导图帮助用户可视化知识_8d4b097b) | action | 0.9.1 | 19 | 339 | 2 | 1 | 2026-01-07 |
|
||||
| 11 | [异步上下文压缩](https://openwebui.com/posts/异步上下文压缩_5c0617cb) | action | 1.1.3 | 12 | 254 | 4 | 1 | 2026-01-11 |
|
||||
| 12 | [闪记卡 (Flash Card)](https://openwebui.com/posts/闪记卡生成插件_4a31eac3) | action | 0.2.4 | 12 | 376 | 4 | 1 | 2026-01-07 |
|
||||
| 13 | [精读](https://openwebui.com/posts/精读_99830b0f) | action | 1.0.0 | 4 | 131 | 2 | 1 | 2026-01-08 |
|
||||
| 14 | [ 🛠️ Debug Open WebUI Plugins in Your Browser](https://openwebui.com/posts/debug_open_webui_plugins_in_your_browser_81bf7960) | unknown | | 0 | 488 | 10 | 6 | 2026-01-10 |
|
||||
|
||||
@@ -1,39 +1,38 @@
|
||||
# 📊 OpenWebUI 社区统计报告
|
||||
|
||||
> 📅 更新时间: 2026-01-11 19:06
|
||||
> 📅 更新时间: 2026-01-12 23:10
|
||||
|
||||
## 📈 总览
|
||||
|
||||
| 指标 | 数值 |
|
||||
|------|------|
|
||||
| 📝 发布数量 | 14 |
|
||||
| ⬇️ 总下载量 | 1134 |
|
||||
| 👁️ 总浏览量 | 12338 |
|
||||
| 👍 总点赞数 | 69 |
|
||||
| 💾 总收藏数 | 68 |
|
||||
| 💬 总评论数 | 17 |
|
||||
| ⬇️ 总下载量 | 1230 |
|
||||
| 👁️ 总浏览量 | 13650 |
|
||||
| 👍 总点赞数 | 80 |
|
||||
| 💾 总收藏数 | 79 |
|
||||
| 💬 总评论数 | 18 |
|
||||
|
||||
## 📂 按类型分类
|
||||
|
||||
- **filter**: 2
|
||||
- **action**: 13
|
||||
- **unknown**: 1
|
||||
- **action**: 11
|
||||
|
||||
## 📋 发布列表
|
||||
|
||||
| 排名 | 标题 | 类型 | 版本 | 下载 | 浏览 | 点赞 | 收藏 | 更新日期 |
|
||||
|:---:|------|:---:|:---:|:---:|:---:|:---:|:---:|:---:|
|
||||
| 1 | [Smart Mind Map](https://openwebui.com/posts/turn_any_text_into_beautiful_mind_maps_3094c59a) | action | 0.9.1 | 363 | 3289 | 10 | 21 | 2026-01-07 |
|
||||
| 2 | [Export to Excel](https://openwebui.com/posts/export_mulit_table_to_excel_244b8f9d) | action | 0.3.7 | 183 | 568 | 3 | 4 | 2026-01-07 |
|
||||
| 3 | [Async Context Compression](https://openwebui.com/posts/async_context_compression_b1655bc8) | filter | 1.1.2 | 132 | 1475 | 5 | 9 | 2026-01-11 |
|
||||
| 4 | [📊 Smart Infographic (AntV)](https://openwebui.com/posts/smart_infographic_ad6f0c7f) | action | 1.4.1 | 129 | 1437 | 7 | 9 | 2026-01-07 |
|
||||
| 5 | [Flash Card](https://openwebui.com/posts/flash_card_65a2ea8f) | action | 0.2.4 | 99 | 1812 | 8 | 6 | 2026-01-07 |
|
||||
| 6 | [Export to Word (Enhanced)](https://openwebui.com/posts/export_to_word_enhanced_formatting_fca6a315) | action | 0.4.3 | 89 | 834 | 5 | 8 | 2026-01-07 |
|
||||
| 7 | [导出为 Word (增强版)](https://openwebui.com/posts/导出为_word_支持公式流程图表格和代码块_8a6306c0) | action | 0.4.3 | 35 | 979 | 8 | 2 | 2026-01-07 |
|
||||
| 8 | [📊 智能信息图 (AntV Infographic)](https://openwebui.com/posts/智能信息图_e04a48ff) | action | 1.4.1 | 35 | 492 | 3 | 0 | 2026-01-07 |
|
||||
| 9 | [Deep Dive](https://openwebui.com/posts/deep_dive_c0b846e4) | action | 1.0.0 | 28 | 298 | 3 | 4 | 2026-01-08 |
|
||||
| 10 | [思维导图](https://openwebui.com/posts/智能生成交互式思维导图帮助用户可视化知识_8d4b097b) | action | 0.9.1 | 18 | 320 | 2 | 1 | 2026-01-07 |
|
||||
| 11 | [闪记卡 (Flash Card)](https://openwebui.com/posts/闪记卡生成插件_4a31eac3) | action | 0.2.4 | 12 | 353 | 4 | 1 | 2026-01-07 |
|
||||
| 12 | [异步上下文压缩](https://openwebui.com/posts/异步上下文压缩_5c0617cb) | filter | 1.1.2 | 8 | 196 | 4 | 1 | 2026-01-11 |
|
||||
| 13 | [精读](https://openwebui.com/posts/精读_99830b0f) | action | 1.0.0 | 3 | 108 | 2 | 1 | 2026-01-08 |
|
||||
| 14 | [ 🛠️ Debug Open WebUI Plugins in Your Browser](https://openwebui.com/posts/debug_open_webui_plugins_in_your_browser_81bf7960) | unknown | | 0 | 177 | 5 | 1 | 2026-01-10 |
|
||||
| 1 | [Smart Mind Map](https://openwebui.com/posts/turn_any_text_into_beautiful_mind_maps_3094c59a) | action | 0.9.1 | 392 | 3535 | 11 | 22 | 2026-01-07 |
|
||||
| 2 | [Export to Excel](https://openwebui.com/posts/export_mulit_table_to_excel_244b8f9d) | action | 0.3.7 | 187 | 604 | 3 | 4 | 2026-01-07 |
|
||||
| 3 | [📊 Smart Infographic (AntV)](https://openwebui.com/posts/smart_infographic_ad6f0c7f) | action | 1.4.9 | 145 | 1594 | 8 | 10 | 2026-01-11 |
|
||||
| 4 | [Async Context Compression](https://openwebui.com/posts/async_context_compression_b1655bc8) | action | 1.1.3 | 144 | 1596 | 7 | 11 | 2026-01-11 |
|
||||
| 5 | [Export to Word (Enhanced)](https://openwebui.com/posts/export_to_word_enhanced_formatting_fca6a315) | action | 0.4.3 | 104 | 938 | 6 | 10 | 2026-01-07 |
|
||||
| 6 | [Flash Card](https://openwebui.com/posts/flash_card_65a2ea8f) | action | 0.2.4 | 101 | 1881 | 8 | 6 | 2026-01-07 |
|
||||
| 7 | [导出为 Word (增强版)](https://openwebui.com/posts/导出为_word_支持公式流程图表格和代码块_8a6306c0) | action | 0.4.3 | 40 | 1038 | 9 | 2 | 2026-01-07 |
|
||||
| 8 | [📊 智能信息图 (AntV Infographic)](https://openwebui.com/posts/智能信息图_e04a48ff) | action | 1.4.9 | 35 | 525 | 3 | 0 | 2026-01-11 |
|
||||
| 9 | [Deep Dive](https://openwebui.com/posts/deep_dive_c0b846e4) | action | 1.0.0 | 35 | 351 | 3 | 4 | 2026-01-08 |
|
||||
| 10 | [思维导图](https://openwebui.com/posts/智能生成交互式思维导图帮助用户可视化知识_8d4b097b) | action | 0.9.1 | 19 | 339 | 2 | 1 | 2026-01-07 |
|
||||
| 11 | [异步上下文压缩](https://openwebui.com/posts/异步上下文压缩_5c0617cb) | action | 1.1.3 | 12 | 254 | 4 | 1 | 2026-01-11 |
|
||||
| 12 | [闪记卡 (Flash Card)](https://openwebui.com/posts/闪记卡生成插件_4a31eac3) | action | 0.2.4 | 12 | 376 | 4 | 1 | 2026-01-07 |
|
||||
| 13 | [精读](https://openwebui.com/posts/精读_99830b0f) | action | 1.0.0 | 4 | 131 | 2 | 1 | 2026-01-08 |
|
||||
| 14 | [ 🛠️ Debug Open WebUI Plugins in Your Browser](https://openwebui.com/posts/debug_open_webui_plugins_in_your_browser_81bf7960) | unknown | | 0 | 488 | 10 | 6 | 2026-01-10 |
|
||||
|
||||
@@ -33,7 +33,7 @@ Actions are interactive plugins that:
|
||||
|
||||
Transform text into professional infographics using AntV visualization engine with various templates.
|
||||
|
||||
**Version:** 1.4.1
|
||||
**Version:** 1.4.9
|
||||
|
||||
[:octicons-arrow-right-24: Documentation](smart-infographic.md)
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@ Actions 是交互式插件,能够:
|
||||
|
||||
使用 AntV 可视化引擎,将文本转成专业的信息图。
|
||||
|
||||
**版本:** 1.4.1
|
||||
**版本:** 1.4.9
|
||||
|
||||
[:octicons-arrow-right-24: 查看文档](smart-infographic.md)
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Smart Infographic
|
||||
|
||||
<span class="category-badge action">Action</span>
|
||||
<span class="version-badge">v1.4.0</span>
|
||||
<span class="version-badge">v1.4.9</span>
|
||||
|
||||
An AntV Infographic engine powered plugin that transforms long text into professional, beautiful infographics with a single click.
|
||||
|
||||
@@ -14,8 +14,8 @@ The Smart Infographic plugin uses AI to analyze text content and generate profes
|
||||
## Features
|
||||
|
||||
- :material-robot: **AI-Powered Transformation**: Automatically analyzes text logic, extracts key points, and generates structured charts
|
||||
- :material-palette: **Professional Templates**: Includes various AntV official templates: Lists, Trees, Mindmaps, Comparison Tables, Flowcharts, and Statistical Charts
|
||||
- :material-magnify: **Auto-Icon Matching**: Built-in logic to search and match the most relevant Material Design Icons based on content
|
||||
- :material-palette: **70+ Professional Templates**: Includes various AntV official templates: Lists, Trees, Roadmaps, Timelines, Comparison Tables, SWOT, Quadrants, and Statistical Charts
|
||||
- :material-magnify: **Auto-Icon Matching**: Built-in logic to search and match the most relevant icons (Iconify) and illustrations (unDraw)
|
||||
- :material-download: **Multi-Format Export**: Download your infographics as **SVG**, **PNG**, or **Standalone HTML** file
|
||||
- :material-theme-light-dark: **Theme Support**: Supports Dark/Light modes, auto-adapts theme colors
|
||||
- :material-cellphone-link: **Responsive Design**: Generated charts look great on both desktop and mobile devices
|
||||
@@ -37,10 +37,11 @@ The Smart Infographic plugin uses AI to analyze text content and generate profes
|
||||
|
||||
| Category | Template Name | Use Case |
|
||||
|:---------|:--------------|:---------|
|
||||
| **Lists & Hierarchy** | `list-grid`, `tree-vertical`, `mindmap` | Features, Org Charts, Brainstorming |
|
||||
| **Sequence & Relation** | `sequence-roadmap`, `relation-circle` | Roadmaps, Circular Flows, Steps |
|
||||
| **Comparison & Analysis** | `compare-binary`, `compare-swot`, `quadrant-quarter` | Pros/Cons, SWOT, Quadrants |
|
||||
| **Charts & Data** | `chart-bar`, `chart-line`, `chart-pie` | Trends, Distributions, Metrics |
|
||||
| **Sequence** | `sequence-timeline-simple`, `sequence-roadmap-vertical-simple`, `sequence-snake-steps-compact-card` | Timelines, Roadmaps, Processes |
|
||||
| **Lists** | `list-grid-candy-card-lite`, `list-row-horizontal-icon-arrow`, `list-column-simple-vertical-arrow` | Features, Bullet Points, Lists |
|
||||
| **Comparison** | `compare-binary-horizontal-underline-text-vs`, `compare-swot`, `quadrant-quarter-simple-card` | Pros/Cons, SWOT, Quadrants |
|
||||
| **Hierarchy** | `hierarchy-tree-tech-style-capsule-item`, `hierarchy-structure` | Org Charts, Structures |
|
||||
| **Charts** | `chart-column-simple`, `chart-bar-plain-text`, `chart-line-plain-text`, `chart-wordcloud` | Trends, Distributions, Metrics |
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Smart Infographic(智能信息图)
|
||||
|
||||
<span class="category-badge action">Action</span>
|
||||
<span class="version-badge">v1.4.0</span>
|
||||
<span class="version-badge">v1.4.9</span>
|
||||
|
||||
基于 AntV 信息图引擎,将长文本一键转成专业、美观的信息图。
|
||||
|
||||
@@ -14,8 +14,8 @@ Smart Infographic 使用 AI 分析文本,并基于 AntV 可视化引擎生成
|
||||
## 功能特性
|
||||
|
||||
- :material-robot: **AI 转换**:自动分析文本逻辑,提取要点并生成结构化图表
|
||||
- :material-palette: **专业模板**:内置 AntV 官方模板:列表、树、思维导图、对比表、流程图、统计图等
|
||||
- :material-magnify: **自动匹配图标**:根据内容自动选择最合适的 Material Design Icons
|
||||
- :material-palette: **70+ 专业模板**:内置多种 AntV 官方模板,包括列表、树图、路线图、时间线、对比图、SWOT、象限图及统计图表等
|
||||
- :material-magnify: **自动匹配图标**:内置图标搜索逻辑,支持 Iconify 图标和 unDraw 插图自动匹配
|
||||
- :material-download: **多格式导出**:支持下载 **SVG**、**PNG**、**独立 HTML**
|
||||
- :material-theme-light-dark: **主题支持**:适配深色/浅色模式
|
||||
- :material-cellphone-link: **响应式**:桌面与移动端都能良好展示
|
||||
@@ -37,10 +37,11 @@ Smart Infographic 使用 AI 分析文本,并基于 AntV 可视化引擎生成
|
||||
|
||||
| 分类 | 模板名称 | 典型场景 |
|
||||
|:---------|:--------------|:---------|
|
||||
| **列表与层级** | `list-grid`, `tree-vertical`, `mindmap` | 特性列表、组织结构、头脑风暴 |
|
||||
| **序列与关系** | `sequence-roadmap`, `relation-circle` | 路线图、循环流程、步骤拆解 |
|
||||
| **对比与分析** | `compare-binary`, `compare-swot`, `quadrant-quarter` | 优劣势、SWOT、象限分析 |
|
||||
| **图表与数据** | `chart-bar`, `chart-line`, `chart-pie` | 趋势、分布、指标对比 |
|
||||
| **时序与流程** | `sequence-timeline-simple`, `sequence-roadmap-vertical-simple`, `sequence-snake-steps-compact-card` | 时间线、路线图、步骤说明 |
|
||||
| **列表与网格** | `list-grid-candy-card-lite`, `list-row-horizontal-icon-arrow`, `list-column-simple-vertical-arrow` | 功能亮点、要点列举、清单 |
|
||||
| **对比与分析** | `compare-binary-horizontal-underline-text-vs`, `compare-swot`, `quadrant-quarter-simple-card` | 优劣势对比、SWOT 分析、象限图 |
|
||||
| **层级与结构** | `hierarchy-tree-tech-style-capsule-item`, `hierarchy-structure` | 组织架构、层级关系 |
|
||||
| **图表与数据** | `chart-column-simple`, `chart-bar-plain-text`, `chart-line-plain-text`, `chart-wordcloud` | 数据趋势、比例分布、数值对比 |
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Async Context Compression
|
||||
|
||||
<span class="category-badge filter">Filter</span>
|
||||
<span class="version-badge">v1.1.2</span>
|
||||
<span class="version-badge">v1.1.3</span>
|
||||
|
||||
Reduces token consumption in long conversations through intelligent summarization while maintaining conversational coherence.
|
||||
|
||||
@@ -32,6 +32,8 @@ This is especially useful for:
|
||||
- :material-console: **Frontend Debugging**: Debug logs in browser console
|
||||
- :material-alert-circle-check: **Enhanced Error Reporting**: Clear error status notifications
|
||||
- :material-check-all: **Open WebUI v0.7.x Compatibility**: Dynamic DB session handling
|
||||
- :material-account-convert: **Improved Compatibility**: Summary role changed to `assistant`
|
||||
- :material-shield-check: **Enhanced Stability**: Resolved race conditions in state management
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Async Context Compression(异步上下文压缩)
|
||||
|
||||
<span class="category-badge filter">Filter</span>
|
||||
<span class="version-badge">v1.1.2</span>
|
||||
<span class="version-badge">v1.1.3</span>
|
||||
|
||||
通过智能摘要减少长对话的 token 消耗,同时保持对话连贯。
|
||||
|
||||
@@ -32,6 +32,8 @@ Async Context Compression 过滤器通过以下方式帮助管理长对话的 to
|
||||
- :material-console: **前端调试**:支持浏览器控制台日志
|
||||
- :material-alert-circle-check: **增强错误报告**:清晰的错误状态通知
|
||||
- :material-check-all: **Open WebUI v0.7.x 兼容性**:动态数据库会话处理
|
||||
- :material-account-convert: **兼容性提升**:摘要角色改为 `assistant`
|
||||
- :material-shield-check: **稳定性增强**:解决状态管理竞态条件
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@ Filters act as middleware in the message pipeline:
|
||||
|
||||
Reduces token consumption in long conversations through intelligent summarization while maintaining coherence.
|
||||
|
||||
**Version:** 1.1.2
|
||||
**Version:** 1.1.3
|
||||
|
||||
[:octicons-arrow-right-24: Documentation](async-context-compression.md)
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@ Filter 充当消息管线中的中间件:
|
||||
|
||||
通过智能总结减少长对话的 token 消耗,同时保持连贯性。
|
||||
|
||||
**版本:** 1.1.0
|
||||
**版本:** 1.1.3
|
||||
|
||||
[:octicons-arrow-right-24: 查看文档](async-context-compression.md)
|
||||
|
||||
|
||||
@@ -1,11 +1,14 @@
|
||||
# 📊 Smart Infographic (AntV)
|
||||
|
||||
**Author:** [Fu-Jie](https://github.com/Fu-Jie) | **Version:** 1.4.1 | **Project:** [Awesome OpenWebUI](https://github.com/Fu-Jie/awesome-openwebui)
|
||||
**Author:** [Fu-Jie](https://github.com/Fu-Jie) | **Version:** 1.4.9 | **Project:** [Awesome OpenWebUI](https://github.com/Fu-Jie/awesome-openwebui)
|
||||
|
||||
An Open WebUI plugin powered by the AntV Infographic engine. It transforms long text into professional, beautiful infographics with a single click.
|
||||
|
||||
## 🔥 What's New in v1.4.1
|
||||
## 🔥 What's New in v1.4.9
|
||||
|
||||
- 🎨 **70+ Official Templates**: Integrated comprehensive AntV infographic template library.
|
||||
- 🖼️ **Iconify & unDraw Support**: Richer visuals with official icons and illustrations.
|
||||
- 📏 **Visual Optimization**: Improved text wrapping, adaptive sizing, and layout refinement.
|
||||
- ✨ **PNG Upload**: Infographics now upload as PNG format for better Word export compatibility.
|
||||
- 🔧 **Canvas Conversion**: Uses browser canvas for high-quality SVG to PNG conversion (2x scale).
|
||||
|
||||
@@ -17,8 +20,8 @@ An Open WebUI plugin powered by the AntV Infographic engine. It transforms long
|
||||
## ✨ Key Features
|
||||
|
||||
- 🚀 **AI-Powered Transformation**: Automatically analyzes text logic, extracts key points, and generates structured charts.
|
||||
- 🎨 **Professional Templates**: Includes various AntV official templates: Lists, Trees, Mindmaps, Comparison Tables, Flowcharts, and Statistical Charts.
|
||||
- 🔍 **Auto-Icon Matching**: Built-in logic to search and match the most relevant Material Design Icons based on content.
|
||||
- 🎨 **70+ Professional Templates**: Includes various AntV official templates: Lists, Trees, Roadmaps, Timelines, Comparison Tables, SWOT, Quadrants, and Statistical Charts.
|
||||
- 🔍 **Auto-Icon Matching**: Built-in logic to search and match the most relevant icons (Iconify) and illustrations (unDraw).
|
||||
- 📥 **Multi-Format Export**: Download your infographics as **SVG**, **PNG**, or a **Standalone HTML** file.
|
||||
- 🌈 **Highly Customizable**: Supports Dark/Light modes, auto-adapts theme colors, with bold titles and refined card layouts.
|
||||
- 📱 **Responsive Design**: Generated charts look great on both desktop and mobile devices.
|
||||
@@ -47,10 +50,11 @@ You can adjust the following parameters in the plugin settings to optimize the g
|
||||
|
||||
| Category | Template Name | Use Case |
|
||||
| :--- | :--- | :--- |
|
||||
| **Lists & Hierarchy** | `list-grid`, `tree-vertical`, `mindmap` | Features, Org Charts, Brainstorming |
|
||||
| **Sequence & Relation** | `sequence-roadmap`, `relation-circle` | Roadmaps, Circular Flows, Steps |
|
||||
| **Comparison & Analysis** | `compare-binary`, `compare-swot`, `quadrant-quarter` | Pros/Cons, SWOT, Quadrants |
|
||||
| **Charts & Data** | `chart-bar`, `chart-line`, `chart-pie` | Trends, Distributions, Metrics |
|
||||
| **Sequence** | `sequence-timeline-simple`, `sequence-roadmap-vertical-simple`, `sequence-snake-steps-compact-card` | Timelines, Roadmaps, Processes |
|
||||
| **Lists** | `list-grid-candy-card-lite`, `list-row-horizontal-icon-arrow`, `list-column-simple-vertical-arrow` | Features, Bullet Points, Lists |
|
||||
| **Comparison** | `compare-binary-horizontal-underline-text-vs`, `compare-swot`, `quadrant-quarter-simple-card` | Pros/Cons, SWOT, Quadrants |
|
||||
| **Hierarchy** | `hierarchy-tree-tech-style-capsule-item`, `hierarchy-structure` | Org Charts, Structures |
|
||||
| **Charts** | `chart-column-simple`, `chart-bar-plain-text`, `chart-line-plain-text`, `chart-wordcloud` | Trends, Distributions, Metrics |
|
||||
|
||||
## 📝 Syntax Example (For Advanced Users)
|
||||
|
||||
|
||||
@@ -1,11 +1,14 @@
|
||||
# 📊 智能信息图 (AntV Infographic)
|
||||
|
||||
**Author:** [Fu-Jie](https://github.com/Fu-Jie) | **Version:** 1.4.1 | **Project:** [Awesome OpenWebUI](https://github.com/Fu-Jie/awesome-openwebui)
|
||||
**Author:** [Fu-Jie](https://github.com/Fu-Jie) | **Version:** 1.4.9 | **Project:** [Awesome OpenWebUI](https://github.com/Fu-Jie/awesome-openwebui)
|
||||
|
||||
基于 AntV Infographic 引擎的 Open WebUI 插件,能够将长文本内容一键转换为专业、美观的信息图表。
|
||||
|
||||
## 🔥 v1.4.1 更新日志
|
||||
## 🔥 v1.4.9 更新日志
|
||||
|
||||
- 🎨 **70+ 官方模板**:全面集成 AntV 官方信息图模板库。
|
||||
- 🖼️ **图标与插图支持**:支持 Iconify 图标库与 unDraw 插图库,视觉效果更丰富。
|
||||
- 📏 **视觉优化**:改进文本换行逻辑,优化自适应尺寸,提升卡片布局精细度。
|
||||
- ✨ **PNG 上传**:信息图现在以 PNG 格式上传,与 Word 导出完美兼容。
|
||||
- 🔧 **Canvas 转换**:使用浏览器 Canvas 高质量转换 SVG 为 PNG(2倍缩放)。
|
||||
|
||||
@@ -17,8 +20,8 @@
|
||||
## ✨ 核心特性
|
||||
|
||||
- 🚀 **智能转换**:自动分析文本核心逻辑,提取关键点并生成结构化图表。
|
||||
- 🎨 **专业模板**:内置多种 AntV 官方模板,包括列表、树图、思维导图、对比图、流程图及统计图表等。
|
||||
- 🔍 **自动图标匹配**:内置图标搜索逻辑,根据内容自动匹配最相关的 Material Design Icons。
|
||||
- 🎨 **70+ 专业模板**:内置多种 AntV 官方模板,包括列表、树图、路线图、时间线、对比图、SWOT、象限图及统计图表等。
|
||||
- 🔍 **自动图标匹配**:内置图标搜索逻辑,支持 Iconify 图标和 unDraw 插图自动匹配。
|
||||
- 📥 **多格式导出**:支持一键下载为 **SVG**、**PNG** 或 **独立 HTML** 文件。
|
||||
- 🌈 **高度自定义**:支持深色/浅色模式,自动适配主题颜色,主标题加粗突出,卡片布局精美。
|
||||
- 📱 **响应式设计**:生成的图表在桌面端和移动端均有良好的展示效果。
|
||||
@@ -47,10 +50,11 @@
|
||||
|
||||
| 分类 | 模板名称 | 适用场景 |
|
||||
| :--- | :--- | :--- |
|
||||
| **列表与层级** | `list-grid`, `tree-vertical`, `mindmap` | 功能亮点、组织架构、思维导图 |
|
||||
| **顺序与关系** | `sequence-roadmap`, `relation-circle` | 发展历程、循环关系、步骤说明 |
|
||||
| **对比与分析** | `compare-binary`, `compare-swot`, `quadrant-quarter` | 优劣势对比、SWOT 分析、象限图 |
|
||||
| **图表与数据** | `chart-bar`, `chart-line`, `chart-pie` | 数据趋势、比例分布、数值对比 |
|
||||
| **时序与流程** | `sequence-timeline-simple`, `sequence-roadmap-vertical-simple`, `sequence-snake-steps-compact-card` | 时间线、路线图、步骤说明 |
|
||||
| **列表与网格** | `list-grid-candy-card-lite`, `list-row-horizontal-icon-arrow`, `list-column-simple-vertical-arrow` | 功能亮点、要点列举、清单 |
|
||||
| **对比与分析** | `compare-binary-horizontal-underline-text-vs`, `compare-swot`, `quadrant-quarter-simple-card` | 优劣势对比、SWOT 分析、象限图 |
|
||||
| **层级与结构** | `hierarchy-tree-tech-style-capsule-item`, `hierarchy-structure` | 组织架构、层级关系 |
|
||||
| **图表与数据** | `chart-column-simple`, `chart-bar-plain-text`, `chart-line-plain-text`, `chart-wordcloud` | 数据趋势、比例分布、数值对比 |
|
||||
|
||||
## 📝 语法示例 (高级用户)
|
||||
|
||||
|
||||
@@ -1,9 +1,14 @@
|
||||
# Async Context Compression Filter
|
||||
|
||||
**Author:** [Fu-Jie](https://github.com/Fu-Jie) | **Version:** 1.1.2 | **License:** MIT
|
||||
**Author:** [Fu-Jie](https://github.com/Fu-Jie) | **Version:** 1.1.3 | **License:** MIT
|
||||
|
||||
This filter reduces token consumption in long conversations through intelligent summarization and message compression while keeping conversations coherent.
|
||||
|
||||
## What's new in 1.1.3
|
||||
- **Improved Compatibility**: Changed summary injection role from `user` to `assistant` for better compatibility across different LLMs.
|
||||
- **Enhanced Stability**: Fixed a race condition in state management that could cause "inlet state not found" warnings in high-concurrency scenarios.
|
||||
- **Bug Fixes**: Corrected default model handling to prevent misleading logs when no model is specified.
|
||||
|
||||
## What's new in 1.1.2
|
||||
|
||||
- **Open WebUI v0.7.x Compatibility**: Resolved a critical database session binding error affecting Open WebUI v0.7.x users. The plugin now dynamically discovers the database engine and session context, ensuring compatibility across versions.
|
||||
@@ -15,12 +20,7 @@ This filter reduces token consumption in long conversations through intelligent
|
||||
- **Frontend Debugging**: Added `show_debug_log` option to print debug info to the browser console (F12).
|
||||
- **Optimized Compression**: Improved token calculation logic to prevent aggressive truncation of history, ensuring more context is retained.
|
||||
|
||||
## What's new in 1.1.0
|
||||
|
||||
- Reuses Open WebUI's shared database connection by default (no custom engine or env vars required).
|
||||
- Token-based thresholds (`compression_threshold_tokens`, `max_context_tokens`) for safer long-context handling.
|
||||
- Per-model overrides via `model_thresholds` for mixed-model workflows.
|
||||
- Documentation now mirrors the latest async workflow and retention-first injection.
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -1,11 +1,16 @@
|
||||
# 异步上下文压缩过滤器
|
||||
|
||||
**作者:** [Fu-Jie](https://github.com/Fu-Jie) | **版本:** 1.1.2 | **许可证:** MIT
|
||||
**作者:** [Fu-Jie](https://github.com/Fu-Jie) | **版本:** 1.1.3 | **许可证:** MIT
|
||||
|
||||
> **重要提示**:为了确保所有过滤器的可维护性和易用性,每个过滤器都应附带清晰、完整的文档,以确保其功能、配置和使用方法得到充分说明。
|
||||
|
||||
本过滤器通过智能摘要和消息压缩技术,在保持对话连贯性的同时,显著降低长对话的 Token 消耗。
|
||||
|
||||
## 1.1.3 版本更新
|
||||
- **兼容性提升**: 将摘要注入角色从 `user` 改为 `assistant`,以提高在不同 LLM 之间的兼容性。
|
||||
- **稳定性增强**: 修复了状态管理中的竞态条件,解决了高并发场景下可能出现的“无法获取 inlet 状态”警告。
|
||||
- **Bug 修复**: 修正了默认模型处理逻辑,防止在未指定模型时产生误导性日志。
|
||||
|
||||
## 1.1.2 版本更新
|
||||
|
||||
- **Open WebUI v0.7.x 兼容性**: 修复了影响 Open WebUI v0.7.x 用户的严重数据库会话绑定错误。插件现在动态发现数据库引擎和会话上下文,确保跨版本兼容性。
|
||||
@@ -17,12 +22,7 @@
|
||||
- **前端调试**: 新增 `show_debug_log` 选项,支持在浏览器控制台 (F12) 打印调试信息。
|
||||
- **压缩优化**: 优化 Token 计算逻辑,防止历史记录被过度截断,保留更多上下文。
|
||||
|
||||
## 1.1.0 版本更新
|
||||
|
||||
- 默认复用 OpenWebUI 内置数据库连接,无需自建引擎、无需配置 `DATABASE_URL`。
|
||||
- 基于 Token 的阈值控制(`compression_threshold_tokens`、`max_context_tokens`),长上下文更安全。
|
||||
- 支持 `model_thresholds` 为不同模型设置专属阈值,适合混用多模型场景。
|
||||
- 文档同步最新异步工作流与“先保留再注入”策略。
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ author: Fu-Jie
|
||||
author_url: https://github.com/Fu-Jie
|
||||
funding_url: https://github.com/Fu-Jie/awesome-openwebui
|
||||
description: Reduces token consumption in long conversations while maintaining coherence through intelligent summarization and message compression.
|
||||
version: 1.1.2
|
||||
version: 1.1.3
|
||||
openwebui_id: b1655bc8-6de9-4cad-8cb5-a6f7829a02ce
|
||||
license: MIT
|
||||
|
||||
@@ -370,7 +370,10 @@ class Filter:
|
||||
self.valves = self.Valves()
|
||||
self._owui_db = owui_db
|
||||
self._db_engine = owui_engine
|
||||
self.temp_state = {} # Used to pass temporary data between inlet and outlet
|
||||
self._db_engine = owui_engine
|
||||
self._fallback_session_factory = (
|
||||
sessionmaker(bind=self._db_engine) if self._db_engine else None
|
||||
)
|
||||
self._fallback_session_factory = (
|
||||
sessionmaker(bind=self._db_engine) if self._db_engine else None
|
||||
)
|
||||
@@ -638,42 +641,6 @@ class Filter:
|
||||
|
||||
return ""
|
||||
|
||||
def _inject_summary_to_first_message(self, message: dict, summary: str) -> dict:
|
||||
"""Injects the summary into the first message (prepended to content)."""
|
||||
content = message.get("content", "")
|
||||
summary_block = f"【Historical Conversation Summary】\n{summary}\n\n---\nBelow is the recent conversation:\n\n"
|
||||
|
||||
# Handle different content types
|
||||
if isinstance(content, list): # Multimodal content
|
||||
# Find the first text part and insert the summary before it
|
||||
new_content = []
|
||||
summary_inserted = False
|
||||
|
||||
for part in content:
|
||||
if (
|
||||
isinstance(part, dict)
|
||||
and part.get("type") == "text"
|
||||
and not summary_inserted
|
||||
):
|
||||
# Prepend summary to the first text part
|
||||
new_content.append(
|
||||
{"type": "text", "text": summary_block + part.get("text", "")}
|
||||
)
|
||||
summary_inserted = True
|
||||
else:
|
||||
new_content.append(part)
|
||||
|
||||
# If no text part, insert at the beginning
|
||||
if not summary_inserted:
|
||||
new_content.insert(0, {"type": "text", "text": summary_block})
|
||||
|
||||
message["content"] = new_content
|
||||
|
||||
elif isinstance(content, str): # Plain text
|
||||
message["content"] = summary_block + content
|
||||
|
||||
return message
|
||||
|
||||
async def _emit_debug_log(
|
||||
self,
|
||||
__event_call__,
|
||||
@@ -803,15 +770,9 @@ class Filter:
|
||||
# Target is to compress up to the (total - keep_last) message
|
||||
target_compressed_count = max(0, len(messages) - self.valves.keep_last)
|
||||
|
||||
# [Optimization] Simple state cleanup check
|
||||
if chat_id in self.temp_state:
|
||||
await self._log(
|
||||
f"[Inlet] ⚠️ Overwriting unconsumed old state (Chat ID: {chat_id})",
|
||||
type="warning",
|
||||
event_call=__event_call__,
|
||||
)
|
||||
|
||||
self.temp_state[chat_id] = target_compressed_count
|
||||
# Record the target compression progress for the original messages, for use in outlet
|
||||
# Target is to compress up to the (total - keep_last) message
|
||||
target_compressed_count = max(0, len(messages) - self.valves.keep_last)
|
||||
|
||||
await self._log(
|
||||
f"[Inlet] Recorded target compression progress: {target_compressed_count}",
|
||||
@@ -844,7 +805,7 @@ class Filter:
|
||||
f"---\n"
|
||||
f"Below is the recent conversation:"
|
||||
)
|
||||
summary_msg = {"role": "user", "content": summary_content}
|
||||
summary_msg = {"role": "assistant", "content": summary_content}
|
||||
|
||||
# 3. Tail messages (Tail) - All messages starting from the last compression point
|
||||
# Note: Must ensure head messages are not duplicated
|
||||
@@ -914,18 +875,29 @@ class Filter:
|
||||
event_call=__event_call__,
|
||||
)
|
||||
return body
|
||||
model = body.get("model", "gpt-3.5-turbo")
|
||||
model = body.get("model") or ""
|
||||
|
||||
# Calculate target compression progress directly
|
||||
# Assuming body['messages'] in outlet contains the full history (including new response)
|
||||
messages = body.get("messages", [])
|
||||
target_compressed_count = max(0, len(messages) - self.valves.keep_last)
|
||||
|
||||
if self.valves.debug_mode or self.valves.show_debug_log:
|
||||
await self._log(
|
||||
f"\n{'='*60}\n[Outlet] Chat ID: {chat_id}\n[Outlet] Response complete",
|
||||
f"\n{'='*60}\n[Outlet] Chat ID: {chat_id}\n[Outlet] Response complete\n[Outlet] Calculated target compression progress: {target_compressed_count} (Messages: {len(messages)})",
|
||||
event_call=__event_call__,
|
||||
)
|
||||
|
||||
# Process Token calculation and summary generation asynchronously in the background (do not wait for completion, do not affect output)
|
||||
asyncio.create_task(
|
||||
self._check_and_generate_summary_async(
|
||||
chat_id, model, body, __user__, __event_emitter__, __event_call__
|
||||
chat_id,
|
||||
model,
|
||||
body,
|
||||
__user__,
|
||||
target_compressed_count,
|
||||
__event_emitter__,
|
||||
__event_call__,
|
||||
)
|
||||
)
|
||||
|
||||
@@ -942,6 +914,7 @@ class Filter:
|
||||
model: str,
|
||||
body: dict,
|
||||
user_data: Optional[dict],
|
||||
target_compressed_count: Optional[int],
|
||||
__event_emitter__: Callable[[Any], Awaitable[None]] = None,
|
||||
__event_call__: Callable[[Any], Awaitable[None]] = None,
|
||||
):
|
||||
@@ -986,6 +959,7 @@ class Filter:
|
||||
chat_id,
|
||||
body,
|
||||
user_data,
|
||||
target_compressed_count,
|
||||
__event_emitter__,
|
||||
__event_call__,
|
||||
)
|
||||
@@ -1015,6 +989,7 @@ class Filter:
|
||||
chat_id: str,
|
||||
body: dict,
|
||||
user_data: Optional[dict],
|
||||
target_compressed_count: Optional[int],
|
||||
__event_emitter__: Callable[[Any], Awaitable[None]] = None,
|
||||
__event_call__: Callable[[Any], Awaitable[None]] = None,
|
||||
):
|
||||
@@ -1031,12 +1006,11 @@ class Filter:
|
||||
)
|
||||
|
||||
# 1. Get target compression progress
|
||||
# Prioritize getting from temp_state (calculated by inlet). If unavailable (e.g., after restart), assume current is full history.
|
||||
target_compressed_count = self.temp_state.pop(chat_id, None)
|
||||
# If target_compressed_count is not passed (should not happen with new logic), estimate it
|
||||
if target_compressed_count is None:
|
||||
target_compressed_count = max(0, len(messages) - self.valves.keep_last)
|
||||
await self._log(
|
||||
f"[🤖 Async Summary Task] ⚠️ Could not get inlet state, estimating progress using current message count: {target_compressed_count}",
|
||||
f"[🤖 Async Summary Task] ⚠️ target_compressed_count is None, estimating: {target_compressed_count}",
|
||||
type="warning",
|
||||
event_call=__event_call__,
|
||||
)
|
||||
|
||||
@@ -5,7 +5,7 @@ author: Fu-Jie
|
||||
author_url: https://github.com/Fu-Jie
|
||||
funding_url: https://github.com/Fu-Jie/awesome-openwebui
|
||||
description: 通过智能摘要和消息压缩,降低长对话的 token 消耗,同时保持对话连贯性。
|
||||
version: 1.1.2
|
||||
version: 1.1.3
|
||||
openwebui_id: 5c0617cb-a9e4-4bd6-a440-d276534ebd18
|
||||
license: MIT
|
||||
|
||||
@@ -290,7 +290,8 @@ class Filter:
|
||||
self.valves = self.Valves()
|
||||
self._db_engine = owui_engine
|
||||
self._SessionLocal = owui_Session
|
||||
self.temp_state = {} # 用于在 inlet 和 outlet 之间传递临时数据
|
||||
self._SessionLocal = owui_Session
|
||||
self._init_database()
|
||||
self._init_database()
|
||||
|
||||
def _init_database(self):
|
||||
@@ -471,42 +472,6 @@ class Filter:
|
||||
"max_context_tokens": self.valves.max_context_tokens,
|
||||
}
|
||||
|
||||
def _inject_summary_to_first_message(self, message: dict, summary: str) -> dict:
|
||||
"""将摘要注入到第一条消息中(追加到内容前面)"""
|
||||
content = message.get("content", "")
|
||||
summary_block = f"【历史对话摘要】\n{summary}\n\n---\n以下是最近的对话:\n\n"
|
||||
|
||||
# 处理不同内容类型
|
||||
if isinstance(content, list): # 多模态内容
|
||||
# 查找第一个文本部分并在其前面插入摘要
|
||||
new_content = []
|
||||
summary_inserted = False
|
||||
|
||||
for part in content:
|
||||
if (
|
||||
isinstance(part, dict)
|
||||
and part.get("type") == "text"
|
||||
and not summary_inserted
|
||||
):
|
||||
# 在第一个文本部分前插入摘要
|
||||
new_content.append(
|
||||
{"type": "text", "text": summary_block + part.get("text", "")}
|
||||
)
|
||||
summary_inserted = True
|
||||
else:
|
||||
new_content.append(part)
|
||||
|
||||
# 如果没有文本部分,在开头插入
|
||||
if not summary_inserted:
|
||||
new_content.insert(0, {"type": "text", "text": summary_block})
|
||||
|
||||
message["content"] = new_content
|
||||
|
||||
elif isinstance(content, str): # 纯文本
|
||||
message["content"] = summary_block + content
|
||||
|
||||
return message
|
||||
|
||||
async def _emit_debug_log(
|
||||
self,
|
||||
__event_call__,
|
||||
@@ -628,15 +593,9 @@ class Filter:
|
||||
# 目标是压缩到倒数第 keep_last 条之前
|
||||
target_compressed_count = max(0, len(messages) - self.valves.keep_last)
|
||||
|
||||
# [优化] 简单的状态清理检查
|
||||
if chat_id in self.temp_state:
|
||||
await self._log(
|
||||
f"[Inlet] ⚠️ 覆盖未消费的旧状态 (Chat ID: {chat_id})",
|
||||
type="warning",
|
||||
event_call=__event_call__,
|
||||
)
|
||||
|
||||
self.temp_state[chat_id] = target_compressed_count
|
||||
# 记录原始消息的目标压缩进度,供 outlet 使用
|
||||
# 目标是压缩到倒数第 keep_last 条之前
|
||||
target_compressed_count = max(0, len(messages) - self.valves.keep_last)
|
||||
|
||||
await self._log(
|
||||
f"[Inlet] 记录目标压缩进度: {target_compressed_count}",
|
||||
@@ -669,7 +628,7 @@ class Filter:
|
||||
f"---\n"
|
||||
f"以下是最近的对话:"
|
||||
)
|
||||
summary_msg = {"role": "user", "content": summary_content}
|
||||
summary_msg = {"role": "assistant", "content": summary_content}
|
||||
|
||||
# 3. 尾部消息 (Tail) - 从上次压缩点开始的所有消息
|
||||
# 注意:这里必须确保不重复包含头部消息
|
||||
@@ -732,18 +691,29 @@ class Filter:
|
||||
在后台计算 Token 数并触发摘要生成(不阻塞当前响应,不影响内容输出)
|
||||
"""
|
||||
chat_id = __metadata__["chat_id"]
|
||||
model = body.get("model", "gpt-3.5-turbo")
|
||||
model = body.get("model") or ""
|
||||
|
||||
# 直接计算目标压缩进度
|
||||
# 假设 outlet 中的 body['messages'] 包含完整历史(包括新响应)
|
||||
messages = body.get("messages", [])
|
||||
target_compressed_count = max(0, len(messages) - self.valves.keep_last)
|
||||
|
||||
if self.valves.debug_mode or self.valves.show_debug_log:
|
||||
await self._log(
|
||||
f"\n{'='*60}\n[Outlet] Chat ID: {chat_id}\n[Outlet] 响应完成",
|
||||
f"\n{'='*60}\n[Outlet] Chat ID: {chat_id}\n[Outlet] 响应完成\n[Outlet] 计算目标压缩进度: {target_compressed_count} (消息数: {len(messages)})",
|
||||
event_call=__event_call__,
|
||||
)
|
||||
|
||||
# 在后台异步处理 Token 计算和摘要生成(不等待完成,不影响输出)
|
||||
asyncio.create_task(
|
||||
self._check_and_generate_summary_async(
|
||||
chat_id, model, body, __user__, __event_emitter__, __event_call__
|
||||
chat_id,
|
||||
model,
|
||||
body,
|
||||
__user__,
|
||||
target_compressed_count,
|
||||
__event_emitter__,
|
||||
__event_call__,
|
||||
)
|
||||
)
|
||||
|
||||
@@ -760,6 +730,7 @@ class Filter:
|
||||
model: str,
|
||||
body: dict,
|
||||
user_data: Optional[dict],
|
||||
target_compressed_count: Optional[int],
|
||||
__event_emitter__: Callable[[Any], Awaitable[None]] = None,
|
||||
__event_call__: Callable[[Any], Awaitable[None]] = None,
|
||||
):
|
||||
@@ -804,6 +775,7 @@ class Filter:
|
||||
chat_id,
|
||||
body,
|
||||
user_data,
|
||||
target_compressed_count,
|
||||
__event_emitter__,
|
||||
__event_call__,
|
||||
)
|
||||
@@ -833,6 +805,7 @@ class Filter:
|
||||
chat_id: str,
|
||||
body: dict,
|
||||
user_data: Optional[dict],
|
||||
target_compressed_count: Optional[int],
|
||||
__event_emitter__: Callable[[Any], Awaitable[None]] = None,
|
||||
__event_call__: Callable[[Any], Awaitable[None]] = None,
|
||||
):
|
||||
@@ -847,12 +820,11 @@ class Filter:
|
||||
await self._log(f"\n[🤖 异步摘要任务] 开始...", event_call=__event_call__)
|
||||
|
||||
# 1. 获取目标压缩进度
|
||||
# 优先从 temp_state 获取(由 inlet 计算),如果获取不到(例如重启后),则假设当前是完整历史
|
||||
target_compressed_count = self.temp_state.pop(chat_id, None)
|
||||
# 如果未传递 target_compressed_count(新逻辑下不应发生),则进行估算
|
||||
if target_compressed_count is None:
|
||||
target_compressed_count = max(0, len(messages) - self.valves.keep_last)
|
||||
await self._log(
|
||||
f"[🤖 异步摘要任务] ⚠️ 无法获取 inlet 状态,使用当前消息数估算进度: {target_compressed_count}",
|
||||
f"[🤖 异步摘要任务] ⚠️ target_compressed_count 为 None,进行估算: {target_compressed_count}",
|
||||
type="warning",
|
||||
event_call=__event_call__,
|
||||
)
|
||||
|
||||
@@ -125,19 +125,45 @@ if x == 1:
|
||||
```
|
||||
|
||||
## 7. Mermaid 语法修复 (Mermaid Syntax Fix)
|
||||
**功能**: 修复 Mermaid 图表中常见的语法错误,特别是未加引号的标签包含特殊字符的情况。
|
||||
**功能**: 修复 Mermaid 图表中常见的语法错误,特别是未加引号的标签包含特殊字符、嵌套括号或 HTML 标签的情况。
|
||||
**默认**: 开启 (`enable_mermaid_fix = True`)
|
||||
**示例**:
|
||||
* **Before**:
|
||||
```mermaid
|
||||
graph TD
|
||||
A[Label with (parens)] --> B(Label with [brackets])
|
||||
```
|
||||
* **After**:
|
||||
```mermaid
|
||||
graph TD
|
||||
A["Label with (parens)"] --> B("Label with [brackets]")
|
||||
```
|
||||
|
||||
### 7.1 基础特殊字符
|
||||
**Before**:
|
||||
```mermaid
|
||||
graph TD
|
||||
A[Label with (parens)] --> B(Label with [brackets])
|
||||
```
|
||||
**After**:
|
||||
```mermaid
|
||||
graph TD
|
||||
A["Label with (parens)"] --> B("Label with [brackets]")
|
||||
```
|
||||
|
||||
### 7.2 嵌套括号修复 (v1.1.0+)
|
||||
**Before**:
|
||||
```mermaid
|
||||
graph TD
|
||||
A((开始: 发现可疑快照)) --> B[物理损坏(Allocation Errors)]
|
||||
```
|
||||
**After**:
|
||||
```mermaid
|
||||
graph TD
|
||||
A(("开始: 发现可疑快照")) --> B["物理损坏(Allocation Errors)"]
|
||||
```
|
||||
|
||||
### 7.3 包含 HTML 标签 (v1.1.0+)
|
||||
**Before**:
|
||||
```mermaid
|
||||
graph TD
|
||||
A[第一步<br/>环境隔离] --> B{状态?}
|
||||
```
|
||||
**After**:
|
||||
```mermaid
|
||||
graph TD
|
||||
A["第一步<br/>环境隔离"] --> B{"状态?"}
|
||||
```
|
||||
*注:插件已优化 HTML 保护机制,允许包含 `<br/>` 等标签的 Mermaid 图表正常触发修复。*
|
||||
|
||||
## 8. XML 标签清理 (XML Cleanup)
|
||||
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
# Markdown Normalizer Filter
|
||||
|
||||
A production-grade content normalizer filter for Open WebUI that fixes common Markdown formatting issues in LLM outputs. It ensures that code blocks, LaTeX formulas, Mermaid diagrams, and other Markdown elements are rendered correctly.
|
||||
**Author:** [Fu-Jie](https://github.com/Fu-Jie)
|
||||
**Version:** 1.1.0
|
||||
|
||||
A content normalizer filter for Open WebUI that fixes common Markdown formatting issues in LLM outputs. It ensures that code blocks, LaTeX formulas, Mermaid diagrams, and other Markdown elements are rendered correctly.
|
||||
|
||||
## Features
|
||||
|
||||
@@ -41,6 +44,14 @@ A production-grade content normalizer filter for Open WebUI that fixes common Ma
|
||||
* `show_status`: Show status notification when fixes are applied.
|
||||
* `show_debug_log`: Print debug logs to browser console.
|
||||
|
||||
## Changelog
|
||||
|
||||
### v1.1.0
|
||||
* **Mermaid Fix Refinement**: Improved regex to handle nested parentheses in node labels (e.g., `ID("Label (text)")`) and avoided matching connection labels.
|
||||
* **HTML Safeguard Optimization**: Refined `_contains_html` to allow common tags like `<br/>`, `<b>`, `<i>`, etc., ensuring Mermaid diagrams with these tags are still normalized.
|
||||
* **Full-width Symbol Cleanup**: Fixed duplicate keys and incorrect quote mapping in `FULLWIDTH_MAP`.
|
||||
* **Bug Fixes**: Fixed missing `Dict` import in Python files.
|
||||
|
||||
## License
|
||||
|
||||
MIT
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
# Markdown 格式化过滤器 (Markdown Normalizer)
|
||||
|
||||
这是一个用于 Open WebUI 的生产级内容格式化过滤器,旨在修复 LLM 输出中常见的 Markdown 格式问题。它能确保代码块、LaTeX 公式、Mermaid 图表和其他 Markdown 元素被正确渲染。
|
||||
**作者:** [Fu-Jie](https://github.com/Fu-Jie)
|
||||
**版本:** 1.1.0
|
||||
|
||||
这是一个用于 Open WebUI 的内容格式化过滤器,旨在修复 LLM 输出中常见的 Markdown 格式问题。它能确保代码块、LaTeX 公式、Mermaid 图表和其他 Markdown 元素被正确渲染。
|
||||
|
||||
## 功能特性
|
||||
|
||||
@@ -41,6 +44,14 @@
|
||||
* `show_status`: 应用修复时显示状态通知。
|
||||
* `show_debug_log`: 在浏览器控制台打印调试日志。
|
||||
|
||||
## 更新日志
|
||||
|
||||
### v1.1.0
|
||||
* **Mermaid 修复优化**: 改进了正则表达式以处理节点标签中的嵌套括号(如 `ID("标签 (文本)")`),并避免误匹配连接线上的文字。
|
||||
* **HTML 保护机制优化**: 优化了 `_contains_html` 检测,允许 `<br/>`, `<b>`, `<i>` 等常见标签,确保包含这些标签的 Mermaid 图表能被正常规范化。
|
||||
* **全角符号清理**: 修复了 `FULLWIDTH_MAP` 中的重复键名和错误的引号映射。
|
||||
* **Bug 修复**: 修复了 Python 文件中缺失的 `Dict` 类型导入。
|
||||
|
||||
## 许可证
|
||||
|
||||
MIT
|
||||
|
||||
BIN
plugins/filters/markdown_normalizer/markdown_normalizer.png
Normal file
BIN
plugins/filters/markdown_normalizer/markdown_normalizer.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 472 KiB |
@@ -1,14 +1,14 @@
|
||||
"""
|
||||
title: Markdown Normalizer
|
||||
author: Fu-Jie
|
||||
author_url: https://github.com/Fu-Jie
|
||||
funding_url: https://github.com/Fu-Jie/awesome-openwebui
|
||||
version: 1.0.1
|
||||
description: A production-grade content normalizer filter that fixes common Markdown formatting issues in LLM outputs, such as broken code blocks, LaTeX formulas, and list formatting.
|
||||
author_url: https://github.com/Fu-Jie/awesome-openwebui
|
||||
funding_url: https://github.com/open-webui
|
||||
version: 1.1.0
|
||||
description: A content normalizer filter that fixes common Markdown formatting issues in LLM outputs, such as broken code blocks, LaTeX formulas, and list formatting.
|
||||
"""
|
||||
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Optional, List, Callable
|
||||
from typing import Optional, List, Callable, Dict
|
||||
import re
|
||||
import logging
|
||||
import logging
|
||||
@@ -75,7 +75,7 @@ class ContentNormalizer:
|
||||
# Priority: Longer delimiters match first
|
||||
"mermaid_node": re.compile(
|
||||
r'("[^"\\]*(?:\\.[^"\\]*)*")|' # Match quoted strings first (Group 1)
|
||||
r"(\w+)\s*(?:"
|
||||
r"(\w+)(?:"
|
||||
r"(\(\(\()(?![\"])(.*?)(?<![\"])(\)\)\))|" # (((...))) Double Circle
|
||||
r"(\(\()(?![\"])(.*?)(?<![\"])(\)\))|" # ((...)) Circle
|
||||
r"(\(\[)(?![\"])(.*?)(?<![\"])(\]\))|" # ([...]) Stadium
|
||||
@@ -86,7 +86,7 @@ class ContentNormalizer:
|
||||
r"(\[\\)(?![\"])(.*?)(?<![\"])(\\\])|" # [\...\] Parallelogram Alt
|
||||
r"(\[/)(?![\"])(.*?)(?<![\"])(\\\])|" # [/...\] Trapezoid
|
||||
r"(\[\\)(?![\"])(.*?)(?<![\"])(/\])|" # [\.../] Trapezoid Alt
|
||||
r"(\()(?![\"])(.*?)(?<![\"])(\))|" # (...) Round
|
||||
r"(\()(?![\"])([^)]*?)(?<![\"])(\))|" # (...) Round - Modified to be safer
|
||||
r"(\[)(?![\"])(.*?)(?<![\"])(\])|" # [...] Square
|
||||
r"(\{)(?![\"])(.*?)(?<![\"])(\})|" # {...} Rhombus
|
||||
r"(>)(?![\"])(.*?)(?<![\"])(\])" # >...] Asymmetric
|
||||
@@ -267,9 +267,10 @@ class ContentNormalizer:
|
||||
":": ":",
|
||||
"?": "?",
|
||||
"!": "!",
|
||||
'"': '"',
|
||||
'"': '"',
|
||||
""": "'", """: "'",
|
||||
"“": '"',
|
||||
"”": '"',
|
||||
"‘": "'",
|
||||
"’": "'",
|
||||
}
|
||||
|
||||
parts = content.split("```")
|
||||
@@ -410,9 +411,46 @@ class Filter:
|
||||
def __init__(self):
|
||||
self.valves = self.Valves()
|
||||
|
||||
def _get_chat_context(
|
||||
self, body: dict, __metadata__: Optional[dict] = None
|
||||
) -> Dict[str, str]:
|
||||
"""
|
||||
Unified extraction of chat context information (chat_id, message_id).
|
||||
Prioritizes extraction from body, then metadata.
|
||||
"""
|
||||
chat_id = ""
|
||||
message_id = ""
|
||||
|
||||
# 1. Try to get from body
|
||||
if isinstance(body, dict):
|
||||
chat_id = body.get("chat_id", "")
|
||||
message_id = body.get("id", "") # message_id is usually 'id' in body
|
||||
|
||||
# Check body.metadata as fallback
|
||||
if not chat_id or not message_id:
|
||||
body_metadata = body.get("metadata", {})
|
||||
if isinstance(body_metadata, dict):
|
||||
if not chat_id:
|
||||
chat_id = body_metadata.get("chat_id", "")
|
||||
if not message_id:
|
||||
message_id = body_metadata.get("message_id", "")
|
||||
|
||||
# 2. Try to get from __metadata__ (as supplement)
|
||||
if __metadata__ and isinstance(__metadata__, dict):
|
||||
if not chat_id:
|
||||
chat_id = __metadata__.get("chat_id", "")
|
||||
if not message_id:
|
||||
message_id = __metadata__.get("message_id", "")
|
||||
|
||||
return {
|
||||
"chat_id": str(chat_id).strip(),
|
||||
"message_id": str(message_id).strip(),
|
||||
}
|
||||
|
||||
def _contains_html(self, content: str) -> bool:
|
||||
"""Check if content contains HTML tags (to avoid breaking HTML output)"""
|
||||
pattern = r"<\s*/?\s*(?:html|head|body|div|span|p|br|hr|ul|ol|li|table|thead|tbody|tfoot|tr|td|th|img|a|b|i|strong|em|code|pre|blockquote|h[1-6]|script|style|form|input|button|label|select|option|iframe|link|meta|title)\b"
|
||||
# Removed common Mermaid-compatible tags like br, b, i, strong, em, span
|
||||
pattern = r"<\s*/?\s*(?:html|head|body|div|p|hr|ul|ol|li|table|thead|tbody|tfoot|tr|td|th|img|a|code|pre|blockquote|h[1-6]|script|style|form|input|button|label|select|option|iframe|link|meta|title)\b"
|
||||
return bool(re.search(pattern, content, re.IGNORECASE))
|
||||
|
||||
async def _emit_status(self, __event_emitter__, applied_fixes: List[str]):
|
||||
@@ -438,24 +476,23 @@ class Filter:
|
||||
print(f"Error emitting status: {e}")
|
||||
|
||||
async def _emit_debug_log(
|
||||
self, __event_call__, applied_fixes: List[str], original: str, normalized: str
|
||||
self,
|
||||
__event_call__,
|
||||
applied_fixes: List[str],
|
||||
original: str,
|
||||
normalized: str,
|
||||
chat_id: str = "",
|
||||
):
|
||||
"""Emit debug log to browser console via JS execution"""
|
||||
if not self.valves.show_debug_log or not __event_call__:
|
||||
return
|
||||
|
||||
try:
|
||||
# Prepare data for JS
|
||||
log_data = {
|
||||
"fixes": applied_fixes,
|
||||
"original": original,
|
||||
"normalized": normalized,
|
||||
}
|
||||
|
||||
# Construct JS code
|
||||
js_code = f"""
|
||||
(async function() {{
|
||||
console.group("🛠️ Markdown Normalizer Debug");
|
||||
console.log("Chat ID:", {json.dumps(chat_id)});
|
||||
console.log("Applied Fixes:", {json.dumps(applied_fixes, ensure_ascii=False)});
|
||||
console.log("Original Content:", {json.dumps(original, ensure_ascii=False)});
|
||||
console.log("Normalized Content:", {json.dumps(normalized, ensure_ascii=False)});
|
||||
@@ -521,11 +558,13 @@ class Filter:
|
||||
await self._emit_status(
|
||||
__event_emitter__, normalizer.applied_fixes
|
||||
)
|
||||
chat_ctx = self._get_chat_context(body, __metadata__)
|
||||
await self._emit_debug_log(
|
||||
__event_call__,
|
||||
normalizer.applied_fixes,
|
||||
content,
|
||||
new_content,
|
||||
chat_id=chat_ctx["chat_id"],
|
||||
)
|
||||
|
||||
return body
|
||||
|
||||
BIN
plugins/filters/markdown_normalizer/markdown_normalizer_cn.png
Normal file
BIN
plugins/filters/markdown_normalizer/markdown_normalizer_cn.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 472 KiB |
@@ -1,14 +1,14 @@
|
||||
"""
|
||||
title: Markdown 格式修复器 (Markdown Normalizer)
|
||||
author: Fu-Jie
|
||||
author_url: https://github.com/Fu-Jie
|
||||
funding_url: https://github.com/Fu-Jie/awesome-openwebui
|
||||
version: 1.0.1
|
||||
description: 生产级内容规范化过滤器,修复 LLM 输出中常见的 Markdown 格式问题,如损坏的代码块、LaTeX 公式、Mermaid 图表和列表格式。
|
||||
author_url: https://github.com/Fu-Jie/awesome-openwebui
|
||||
funding_url: https://github.com/open-webui
|
||||
version: 1.1.0
|
||||
description: 内容规范化过滤器,修复 LLM 输出中常见的 Markdown 格式问题,如损坏的代码块、LaTeX 公式、Mermaid 图表和列表格式。
|
||||
"""
|
||||
|
||||
from pydantic import BaseModel, Field
|
||||
from typing import Optional, List, Callable
|
||||
from typing import Optional, List, Callable, Dict
|
||||
import re
|
||||
import logging
|
||||
import asyncio
|
||||
@@ -70,7 +70,7 @@ class ContentNormalizer:
|
||||
# 优先级:长定界符优先匹配
|
||||
"mermaid_node": re.compile(
|
||||
r'("[^"\\]*(?:\\.[^"\\]*)*")|' # Match quoted strings first (Group 1)
|
||||
r"(\w+)\s*(?:"
|
||||
r"(\w+)(?:"
|
||||
r"(\(\(\()(?![\"])(.*?)(?<![\"])(\)\)\))|" # (((...))) Double Circle
|
||||
r"(\(\()(?![\"])(.*?)(?<![\"])(\)\))|" # ((...)) Circle
|
||||
r"(\(\[)(?![\"])(.*?)(?<![\"])(\]\))|" # ([...]) Stadium
|
||||
@@ -81,7 +81,7 @@ class ContentNormalizer:
|
||||
r"(\[\\)(?![\"])(.*?)(?<![\"])(\\\])|" # [\...\] Parallelogram Alt
|
||||
r"(\[/)(?![\"])(.*?)(?<![\"])(\\\])|" # [/...\] Trapezoid
|
||||
r"(\[\\)(?![\"])(.*?)(?<![\"])(/\])|" # [\.../] Trapezoid Alt
|
||||
r"(\()(?![\"])(.*?)(?<![\"])(\))|" # (...) Round
|
||||
r"(\()(?![\"])([^)]*?)(?<![\"])(\))|" # (...) Round - Modified to be safer
|
||||
r"(\[)(?![\"])(.*?)(?<![\"])(\])|" # [...] Square
|
||||
r"(\{)(?![\"])(.*?)(?<![\"])(\})|" # {...} Rhombus
|
||||
r"(>)(?![\"])(.*?)(?<![\"])(\])" # >...] Asymmetric
|
||||
@@ -262,9 +262,10 @@ class ContentNormalizer:
|
||||
":": ":",
|
||||
"?": "?",
|
||||
"!": "!",
|
||||
'"': '"',
|
||||
'"': '"',
|
||||
""": "'", """: "'",
|
||||
"“": '"',
|
||||
"”": '"',
|
||||
"‘": "'",
|
||||
"’": "'",
|
||||
}
|
||||
|
||||
parts = content.split("```")
|
||||
@@ -410,9 +411,46 @@ class Filter:
|
||||
def __init__(self):
|
||||
self.valves = self.Valves()
|
||||
|
||||
def _get_chat_context(
|
||||
self, body: dict, __metadata__: Optional[dict] = None
|
||||
) -> Dict[str, str]:
|
||||
"""
|
||||
统一提取聊天上下文信息 (chat_id, message_id)。
|
||||
优先从 body 中提取,其次从 metadata 中提取。
|
||||
"""
|
||||
chat_id = ""
|
||||
message_id = ""
|
||||
|
||||
# 1. 尝试从 body 获取
|
||||
if isinstance(body, dict):
|
||||
chat_id = body.get("chat_id", "")
|
||||
message_id = body.get("id", "") # message_id 在 body 中通常是 id
|
||||
|
||||
# 再次检查 body.metadata
|
||||
if not chat_id or not message_id:
|
||||
body_metadata = body.get("metadata", {})
|
||||
if isinstance(body_metadata, dict):
|
||||
if not chat_id:
|
||||
chat_id = body_metadata.get("chat_id", "")
|
||||
if not message_id:
|
||||
message_id = body_metadata.get("message_id", "")
|
||||
|
||||
# 2. 尝试从 __metadata__ 获取 (作为补充)
|
||||
if __metadata__ and isinstance(__metadata__, dict):
|
||||
if not chat_id:
|
||||
chat_id = __metadata__.get("chat_id", "")
|
||||
if not message_id:
|
||||
message_id = __metadata__.get("message_id", "")
|
||||
|
||||
return {
|
||||
"chat_id": str(chat_id).strip(),
|
||||
"message_id": str(message_id).strip(),
|
||||
}
|
||||
|
||||
def _contains_html(self, content: str) -> bool:
|
||||
"""Check if content contains HTML tags (to avoid breaking HTML output)"""
|
||||
pattern = r"<\s*/?\s*(?:html|head|body|div|span|p|br|hr|ul|ol|li|table|thead|tbody|tfoot|tr|td|th|img|a|b|i|strong|em|code|pre|blockquote|h[1-6]|script|style|form|input|button|label|select|option|iframe|link|meta|title)\b"
|
||||
# Removed common Mermaid-compatible tags like br, b, i, strong, em, span
|
||||
pattern = r"<\s*/?\s*(?:html|head|body|div|p|hr|ul|ol|li|table|thead|tbody|tfoot|tr|td|th|img|a|code|pre|blockquote|h[1-6]|script|style|form|input|button|label|select|option|iframe|link|meta|title)\b"
|
||||
return bool(re.search(pattern, content, re.IGNORECASE))
|
||||
|
||||
async def _emit_status(self, __event_emitter__, applied_fixes: List[str]):
|
||||
@@ -463,24 +501,23 @@ class Filter:
|
||||
"""Emit debug log to browser console via JS execution"""
|
||||
|
||||
async def _emit_debug_log(
|
||||
self, __event_call__, applied_fixes: List[str], original: str, normalized: str
|
||||
self,
|
||||
__event_call__,
|
||||
applied_fixes: List[str],
|
||||
original: str,
|
||||
normalized: str,
|
||||
chat_id: str = "",
|
||||
):
|
||||
"""Emit debug log to browser console via JS execution"""
|
||||
if not self.valves.show_debug_log or not __event_call__:
|
||||
return
|
||||
|
||||
try:
|
||||
# Prepare data for JS
|
||||
log_data = {
|
||||
"fixes": applied_fixes,
|
||||
"original": original,
|
||||
"normalized": normalized,
|
||||
}
|
||||
|
||||
# Construct JS code
|
||||
js_code = f"""
|
||||
(async function() {{
|
||||
console.group("🛠️ Markdown Normalizer Debug");
|
||||
console.log("Chat ID:", {json.dumps(chat_id)});
|
||||
console.log("Applied Fixes:", {json.dumps(applied_fixes, ensure_ascii=False)});
|
||||
console.log("Original Content:", {json.dumps(original, ensure_ascii=False)});
|
||||
console.log("Normalized Content:", {json.dumps(normalized, ensure_ascii=False)});
|
||||
@@ -546,11 +583,13 @@ class Filter:
|
||||
await self._emit_status(
|
||||
__event_emitter__, normalizer.applied_fixes
|
||||
)
|
||||
chat_ctx = self._get_chat_context(body, __metadata__)
|
||||
await self._emit_debug_log(
|
||||
__event_call__,
|
||||
normalizer.applied_fixes,
|
||||
content,
|
||||
new_content,
|
||||
chat_id=chat_ctx["chat_id"],
|
||||
)
|
||||
|
||||
return body
|
||||
|
||||
@@ -253,7 +253,24 @@ class OpenWebUICommunityClient:
|
||||
是否成功
|
||||
"""
|
||||
url = f"{self.BASE_URL}/posts/{post_id}/update"
|
||||
response = requests.post(url, headers=self.headers, json=post_data)
|
||||
|
||||
# 仅发送允许更新的字段,避免 422 错误
|
||||
allowed_keys = ["title", "content", "type", "data", "media"]
|
||||
payload = {k: v for k, v in post_data.items() if k in allowed_keys}
|
||||
|
||||
response = requests.post(url, headers=self.headers, json=payload)
|
||||
|
||||
if response.status_code != 200:
|
||||
try:
|
||||
error_detail = response.json()
|
||||
print(
|
||||
f" Error: Update failed ({response.status_code}): {json.dumps(error_detail, indent=2)}"
|
||||
)
|
||||
except Exception:
|
||||
print(
|
||||
f" Error: Update failed ({response.status_code}): {response.text[:500]}"
|
||||
)
|
||||
|
||||
response.raise_for_status()
|
||||
return True
|
||||
|
||||
@@ -282,37 +299,54 @@ class OpenWebUICommunityClient:
|
||||
if not post_data:
|
||||
return False
|
||||
|
||||
# 确保结构存在
|
||||
if "data" not in post_data:
|
||||
post_data["data"] = {}
|
||||
if "function" not in post_data["data"]:
|
||||
post_data["data"]["function"] = {}
|
||||
if "meta" not in post_data["data"]["function"]:
|
||||
post_data["data"]["function"]["meta"] = {}
|
||||
if "manifest" not in post_data["data"]["function"]["meta"]:
|
||||
post_data["data"]["function"]["meta"]["manifest"] = {}
|
||||
# 严格重建 data 结构,避免包含只读字段(如 data.function.id)
|
||||
current_function = post_data.get("data", {}).get("function", {})
|
||||
|
||||
# 更新源代码
|
||||
post_data["data"]["function"]["content"] = source_code
|
||||
# 过滤 metadata,移除 openwebui_id 等系统字段
|
||||
clean_metadata = {
|
||||
k: v
|
||||
for k, v in (metadata or {}).items()
|
||||
if k not in ["openwebui_id", "post_id"]
|
||||
}
|
||||
|
||||
function_data = {
|
||||
"id": current_function.get("id", ""),
|
||||
"name": metadata.get("title", current_function.get("name", "Plugin")),
|
||||
"type": current_function.get("type", "action"),
|
||||
"content": source_code,
|
||||
"meta": {
|
||||
"description": metadata.get(
|
||||
"description",
|
||||
current_function.get("meta", {}).get("description", ""),
|
||||
),
|
||||
"manifest": clean_metadata,
|
||||
},
|
||||
}
|
||||
|
||||
post_data["data"] = {"function": function_data}
|
||||
post_data["type"] = "function"
|
||||
|
||||
# 更新 README(社区页面展示内容)
|
||||
if readme_content:
|
||||
post_data["content"] = readme_content
|
||||
|
||||
# 更新元数据
|
||||
if metadata:
|
||||
post_data["data"]["function"]["meta"]["manifest"].update(metadata)
|
||||
if "title" in metadata:
|
||||
post_data["title"] = metadata["title"]
|
||||
post_data["data"]["function"]["name"] = metadata["title"]
|
||||
if "description" in metadata:
|
||||
post_data["data"]["function"]["meta"]["description"] = metadata[
|
||||
"description"
|
||||
]
|
||||
# 更新标题
|
||||
if metadata and "title" in metadata:
|
||||
post_data["title"] = metadata["title"]
|
||||
|
||||
# 更新图片
|
||||
if media_urls:
|
||||
post_data["media"] = media_urls
|
||||
# 将字符串 URL 转换为字典格式 (API 要求)
|
||||
media_list = []
|
||||
for item in media_urls:
|
||||
if isinstance(item, str):
|
||||
media_list.append({"url": item})
|
||||
elif isinstance(item, dict):
|
||||
media_list.append(item)
|
||||
post_data["media"] = media_list
|
||||
else:
|
||||
# 如果没有新图片,保留原有的(如果有)
|
||||
pass
|
||||
|
||||
return self.update_post(post_id, post_data)
|
||||
|
||||
|
||||
@@ -415,7 +415,7 @@ class OpenWebUIStats:
|
||||
"header": "| 📝 发布 | ⬇️ 下载 | 👁️ 浏览 | 👍 点赞 | 💾 收藏 |",
|
||||
"top6_title": "### 🔥 热门插件 Top 6",
|
||||
"top6_updated": f"> 🕐 自动更新于 {get_beijing_time().strftime('%Y-%m-%d %H:%M')}",
|
||||
"top6_header": "| 排名 | 插件 | 下载 | 浏览 | 更新日期 |",
|
||||
"top6_header": "| 排名 | 插件 | 版本 | 下载 | 浏览 | 更新日期 |",
|
||||
"full_stats": "*完整统计请查看 [社区统计报告](./docs/community-stats.zh.md)*",
|
||||
},
|
||||
"en": {
|
||||
@@ -425,7 +425,7 @@ class OpenWebUIStats:
|
||||
"header": "| 📝 Posts | ⬇️ Downloads | 👁️ Views | 👍 Upvotes | 💾 Saves |",
|
||||
"top6_title": "### 🔥 Top 6 Popular Plugins",
|
||||
"top6_updated": f"> 🕐 Auto-updated: {get_beijing_time().strftime('%Y-%m-%d %H:%M')}",
|
||||
"top6_header": "| Rank | Plugin | Downloads | Views | Updated |",
|
||||
"top6_header": "| Rank | Plugin | Version | Downloads | Views | Updated |",
|
||||
"full_stats": "*See full stats in [Community Stats Report](./docs/community-stats.md)*",
|
||||
},
|
||||
}
|
||||
@@ -467,13 +467,13 @@ class OpenWebUIStats:
|
||||
lines.append(t["top6_updated"])
|
||||
lines.append("")
|
||||
lines.append(t["top6_header"])
|
||||
lines.append("|:---:|------|:---:|:---:|:---:|")
|
||||
lines.append("|:---:|------|:---:|:---:|:---:|:---:|")
|
||||
|
||||
medals = ["🥇", "🥈", "🥉", "4️⃣", "5️⃣", "6️⃣"]
|
||||
for i, post in enumerate(top_plugins):
|
||||
medal = medals[i] if i < len(medals) else str(i + 1)
|
||||
lines.append(
|
||||
f"| {medal} | [{post['title']}]({post['url']}) | {post['downloads']} | {post['views']} | {post['updated_at']} |"
|
||||
f"| {medal} | [{post['title']}]({post['url']}) | {post['version']} | {post['downloads']} | {post['views']} | {post['updated_at']} |"
|
||||
)
|
||||
|
||||
lines.append("")
|
||||
|
||||
Reference in New Issue
Block a user