@wentorai/research-plugins 1.2.3 → 1.3.0
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.
- package/README.md +16 -8
- package/openclaw.plugin.json +10 -3
- package/package.json +2 -5
- package/skills/analysis/dataviz/SKILL.md +25 -0
- package/skills/analysis/dataviz/chart-image-generator/SKILL.md +1 -1
- package/skills/analysis/econometrics/SKILL.md +23 -0
- package/skills/analysis/econometrics/robustness-checks/SKILL.md +1 -1
- package/skills/analysis/statistics/SKILL.md +21 -0
- package/skills/analysis/statistics/data-anomaly-detection/SKILL.md +1 -1
- package/skills/analysis/statistics/ml-experiment-tracker/SKILL.md +1 -1
- package/skills/analysis/statistics/{senior-data-scientist-guide → modeling-strategy-guide}/SKILL.md +5 -5
- package/skills/analysis/wrangling/SKILL.md +21 -0
- package/skills/analysis/wrangling/csv-data-analyzer/SKILL.md +1 -1
- package/skills/analysis/wrangling/data-cog-guide/SKILL.md +1 -1
- package/skills/domains/ai-ml/SKILL.md +37 -0
- package/skills/domains/biomedical/SKILL.md +28 -0
- package/skills/domains/biomedical/genomas-guide/SKILL.md +1 -1
- package/skills/domains/biomedical/med-researcher-guide/SKILL.md +1 -1
- package/skills/domains/biomedical/medgeclaw-guide/SKILL.md +1 -1
- package/skills/domains/business/SKILL.md +17 -0
- package/skills/domains/business/architecture-design-guide/SKILL.md +1 -1
- package/skills/domains/chemistry/SKILL.md +19 -0
- package/skills/domains/chemistry/computational-chemistry-guide/SKILL.md +1 -1
- package/skills/domains/cs/SKILL.md +21 -0
- package/skills/domains/ecology/SKILL.md +16 -0
- package/skills/domains/economics/SKILL.md +20 -0
- package/skills/domains/economics/post-labor-economics/SKILL.md +1 -1
- package/skills/domains/economics/pricing-psychology-guide/SKILL.md +1 -1
- package/skills/domains/education/SKILL.md +19 -0
- package/skills/domains/education/academic-study-methods/SKILL.md +1 -1
- package/skills/domains/education/edumcp-guide/SKILL.md +1 -1
- package/skills/domains/finance/SKILL.md +19 -0
- package/skills/domains/finance/akshare-finance-data/SKILL.md +1 -1
- package/skills/domains/finance/options-analytics-agent-guide/SKILL.md +1 -1
- package/skills/domains/finance/stata-accounting-research/SKILL.md +1 -1
- package/skills/domains/geoscience/SKILL.md +17 -0
- package/skills/domains/humanities/SKILL.md +16 -0
- package/skills/domains/humanities/history-research-guide/SKILL.md +1 -1
- package/skills/domains/humanities/political-history-guide/SKILL.md +1 -1
- package/skills/domains/law/SKILL.md +19 -0
- package/skills/domains/math/SKILL.md +17 -0
- package/skills/domains/pharma/SKILL.md +17 -0
- package/skills/domains/physics/SKILL.md +16 -0
- package/skills/domains/social-science/SKILL.md +17 -0
- package/skills/domains/social-science/sociology-research-methods/SKILL.md +1 -1
- package/skills/literature/discovery/SKILL.md +20 -0
- package/skills/literature/discovery/paper-recommendation-guide/SKILL.md +1 -1
- package/skills/literature/discovery/semantic-paper-radar/SKILL.md +1 -1
- package/skills/literature/fulltext/SKILL.md +26 -0
- package/skills/literature/metadata/SKILL.md +35 -0
- package/skills/literature/metadata/doi-content-negotiation/SKILL.md +4 -0
- package/skills/literature/metadata/doi-resolution-guide/SKILL.md +4 -0
- package/skills/literature/metadata/orcid-api/SKILL.md +4 -0
- package/skills/literature/metadata/orcid-integration-guide/SKILL.md +4 -0
- package/skills/literature/search/SKILL.md +43 -0
- package/skills/literature/search/paper-search-mcp-guide/SKILL.md +1 -1
- package/skills/research/automation/SKILL.md +21 -0
- package/skills/research/deep-research/SKILL.md +24 -0
- package/skills/research/deep-research/auto-deep-research-guide/SKILL.md +1 -1
- package/skills/research/deep-research/in-depth-research-guide/SKILL.md +1 -1
- package/skills/research/funding/SKILL.md +20 -0
- package/skills/research/methodology/SKILL.md +24 -0
- package/skills/research/paper-review/SKILL.md +19 -0
- package/skills/research/paper-review/paper-critique-framework/SKILL.md +1 -1
- package/skills/tools/code-exec/SKILL.md +18 -0
- package/skills/tools/diagram/SKILL.md +20 -0
- package/skills/tools/document/SKILL.md +21 -0
- package/skills/tools/knowledge-graph/SKILL.md +21 -0
- package/skills/tools/ocr-translate/SKILL.md +18 -0
- package/skills/tools/ocr-translate/handwriting-recognition-guide/SKILL.md +2 -0
- package/skills/tools/ocr-translate/latex-ocr-guide/SKILL.md +2 -0
- package/skills/tools/scraping/SKILL.md +17 -0
- package/skills/writing/citation/SKILL.md +33 -0
- package/skills/writing/citation/zotfile-attachment-guide/SKILL.md +2 -0
- package/skills/writing/composition/SKILL.md +22 -0
- package/skills/writing/composition/research-paper-writer/SKILL.md +1 -1
- package/skills/writing/composition/scientific-writing-wrapper/SKILL.md +1 -1
- package/skills/writing/latex/SKILL.md +22 -0
- package/skills/writing/latex/academic-writing-latex/SKILL.md +1 -1
- package/skills/writing/latex/latex-drawing-guide/SKILL.md +1 -1
- package/skills/writing/polish/SKILL.md +20 -0
- package/skills/writing/polish/chinese-text-humanizer/SKILL.md +1 -1
- package/skills/writing/templates/SKILL.md +22 -0
- package/skills/writing/templates/beamer-presentation-guide/SKILL.md +1 -1
- package/skills/writing/templates/scientific-article-pdf/SKILL.md +1 -1
- package/skills/analysis/dataviz/citation-map-guide/SKILL.md +0 -184
- package/skills/analysis/dataviz/data-visualization-principles/SKILL.md +0 -171
- package/skills/analysis/econometrics/empirical-paper-analysis/SKILL.md +0 -192
- package/skills/analysis/econometrics/panel-data-regression-workflow/SKILL.md +0 -267
- package/skills/analysis/econometrics/stata-regression/SKILL.md +0 -117
- package/skills/analysis/statistics/general-statistics-guide/SKILL.md +0 -226
- package/skills/analysis/statistics/infiagent-benchmark-guide/SKILL.md +0 -106
- package/skills/analysis/statistics/pywayne-statistics-guide/SKILL.md +0 -192
- package/skills/analysis/statistics/quantitative-methods-guide/SKILL.md +0 -193
- package/skills/analysis/wrangling/claude-data-analysis-guide/SKILL.md +0 -100
- package/skills/analysis/wrangling/open-data-scientist-guide/SKILL.md +0 -197
- package/skills/domains/ai-ml/annotated-dl-papers-guide/SKILL.md +0 -159
- package/skills/domains/humanities/digital-humanities-methods/SKILL.md +0 -232
- package/skills/domains/law/legal-research-methods/SKILL.md +0 -190
- package/skills/domains/social-science/sociology-research-guide/SKILL.md +0 -238
- package/skills/literature/discovery/arxiv-paper-monitoring/SKILL.md +0 -233
- package/skills/literature/discovery/paper-tracking-guide/SKILL.md +0 -211
- package/skills/literature/fulltext/zotero-scihub-guide/SKILL.md +0 -168
- package/skills/literature/search/arxiv-osiris/SKILL.md +0 -199
- package/skills/literature/search/deepgit-search-guide/SKILL.md +0 -147
- package/skills/literature/search/multi-database-literature-search/SKILL.md +0 -198
- package/skills/literature/search/papers-chat-guide/SKILL.md +0 -194
- package/skills/literature/search/pasa-paper-search-guide/SKILL.md +0 -138
- package/skills/literature/search/scientify-literature-survey/SKILL.md +0 -203
- package/skills/research/automation/ai-scientist-guide/SKILL.md +0 -228
- package/skills/research/automation/coexist-ai-guide/SKILL.md +0 -149
- package/skills/research/automation/foam-agent-guide/SKILL.md +0 -203
- package/skills/research/automation/research-paper-orchestrator/SKILL.md +0 -254
- package/skills/research/deep-research/academic-deep-research/SKILL.md +0 -190
- package/skills/research/deep-research/cognitive-kernel-guide/SKILL.md +0 -200
- package/skills/research/deep-research/corvus-research-guide/SKILL.md +0 -132
- package/skills/research/deep-research/deep-research-pro/SKILL.md +0 -213
- package/skills/research/deep-research/deep-research-work/SKILL.md +0 -204
- package/skills/research/deep-research/research-cog/SKILL.md +0 -153
- package/skills/research/methodology/academic-mentor-guide/SKILL.md +0 -169
- package/skills/research/methodology/deep-innovator-guide/SKILL.md +0 -242
- package/skills/research/methodology/research-pipeline-units-guide/SKILL.md +0 -169
- package/skills/research/paper-review/paper-compare-guide/SKILL.md +0 -238
- package/skills/research/paper-review/paper-digest-guide/SKILL.md +0 -240
- package/skills/research/paper-review/paper-research-assistant/SKILL.md +0 -231
- package/skills/research/paper-review/research-quality-filter/SKILL.md +0 -261
- package/skills/tools/code-exec/contextplus-mcp-guide/SKILL.md +0 -110
- package/skills/tools/diagram/clawphd-guide/SKILL.md +0 -149
- package/skills/tools/diagram/scientific-graphical-abstract/SKILL.md +0 -201
- package/skills/tools/document/md2pdf-xelatex/SKILL.md +0 -212
- package/skills/tools/document/openpaper-guide/SKILL.md +0 -232
- package/skills/tools/document/qq-connect/SKILL.md +0 -227
- package/skills/tools/document/weknora-guide/SKILL.md +0 -216
- package/skills/tools/knowledge-graph/mimir-memory-guide/SKILL.md +0 -135
- package/skills/tools/knowledge-graph/open-webui-tools-guide/SKILL.md +0 -156
- package/skills/tools/ocr-translate/formula-recognition-guide/SKILL.md +0 -367
- package/skills/tools/ocr-translate/math-equation-renderer/SKILL.md +0 -198
- package/skills/tools/scraping/api-data-collection-guide/SKILL.md +0 -301
- package/skills/writing/citation/academic-citation-manager-guide/SKILL.md +0 -182
- package/skills/writing/composition/opendraft-thesis-guide/SKILL.md +0 -200
- package/skills/writing/composition/paper-debugger-guide/SKILL.md +0 -143
- package/skills/writing/composition/paperforge-guide/SKILL.md +0 -205
|
@@ -1,232 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: openpaper-guide
|
|
3
|
-
description: "Open-source tool for organizing and annotating research papers"
|
|
4
|
-
metadata:
|
|
5
|
-
openclaw:
|
|
6
|
-
emoji: "📄"
|
|
7
|
-
category: "tools"
|
|
8
|
-
subcategory: "document"
|
|
9
|
-
keywords: ["paper management", "PDF annotation", "research organizer", "paper reader", "document viewer", "open source"]
|
|
10
|
-
source: "https://github.com/nicehash/openpaper"
|
|
11
|
-
---
|
|
12
|
-
|
|
13
|
-
# OpenPaper Guide
|
|
14
|
-
|
|
15
|
-
## Overview
|
|
16
|
-
|
|
17
|
-
OpenPaper is an open-source research paper management and annotation tool. It provides PDF viewing with inline annotations, paper organization with tags and collections, metadata extraction, full-text search across your library, and export capabilities. Designed as a lightweight, privacy-focused alternative to commercial reference managers, running entirely locally.
|
|
18
|
-
|
|
19
|
-
## Installation
|
|
20
|
-
|
|
21
|
-
```bash
|
|
22
|
-
# Install via pip
|
|
23
|
-
pip install openpaper
|
|
24
|
-
|
|
25
|
-
# Or from source
|
|
26
|
-
git clone https://github.com/nicehash/openpaper.git
|
|
27
|
-
cd openpaper && pip install -e .
|
|
28
|
-
|
|
29
|
-
# Launch
|
|
30
|
-
openpaper
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
## Library Management
|
|
34
|
-
|
|
35
|
-
```python
|
|
36
|
-
from openpaper import Library
|
|
37
|
-
|
|
38
|
-
library = Library("./my_research_library")
|
|
39
|
-
|
|
40
|
-
# Add papers
|
|
41
|
-
paper = library.add("path/to/paper.pdf")
|
|
42
|
-
print(f"Added: {paper.title}")
|
|
43
|
-
print(f"Authors: {paper.authors}")
|
|
44
|
-
print(f"Year: {paper.year}")
|
|
45
|
-
|
|
46
|
-
# Bulk import
|
|
47
|
-
added = library.import_directory(
|
|
48
|
-
"downloads/papers/",
|
|
49
|
-
recursive=True,
|
|
50
|
-
extract_metadata=True, # Auto-extract from PDF
|
|
51
|
-
deduplicate=True, # Skip duplicates by DOI/title
|
|
52
|
-
)
|
|
53
|
-
print(f"Imported {len(added)} papers, {added.duplicates} skipped")
|
|
54
|
-
```
|
|
55
|
-
|
|
56
|
-
## Organization
|
|
57
|
-
|
|
58
|
-
```python
|
|
59
|
-
# Tags
|
|
60
|
-
paper.add_tag("transformer")
|
|
61
|
-
paper.add_tag("attention")
|
|
62
|
-
paper.add_tag("priority:high")
|
|
63
|
-
|
|
64
|
-
# Collections
|
|
65
|
-
library.create_collection("thesis-chapter-2")
|
|
66
|
-
library.add_to_collection("thesis-chapter-2", paper)
|
|
67
|
-
|
|
68
|
-
# Smart collections (auto-updating filters)
|
|
69
|
-
library.create_smart_collection(
|
|
70
|
-
name="Recent NLP",
|
|
71
|
-
filters={
|
|
72
|
-
"tags": ["nlp"],
|
|
73
|
-
"year": {"gte": 2023},
|
|
74
|
-
"read_status": "unread",
|
|
75
|
-
},
|
|
76
|
-
)
|
|
77
|
-
|
|
78
|
-
# List and browse
|
|
79
|
-
for p in library.search(tags=["transformer"], year=2024):
|
|
80
|
-
print(f"{p.title} ({p.year}) - {p.read_status}")
|
|
81
|
-
```
|
|
82
|
-
|
|
83
|
-
## Annotations
|
|
84
|
-
|
|
85
|
-
```python
|
|
86
|
-
# Add annotations to papers
|
|
87
|
-
paper.annotate(
|
|
88
|
-
page=3,
|
|
89
|
-
type="highlight",
|
|
90
|
-
text="The attention mechanism allows the model to focus...",
|
|
91
|
-
color="yellow",
|
|
92
|
-
note="Key definition of attention",
|
|
93
|
-
)
|
|
94
|
-
|
|
95
|
-
paper.annotate(
|
|
96
|
-
page=5,
|
|
97
|
-
type="comment",
|
|
98
|
-
position=(100, 250), # x, y coordinates
|
|
99
|
-
note="This contradicts the claim in Smith et al. 2023",
|
|
100
|
-
)
|
|
101
|
-
|
|
102
|
-
# Export annotations
|
|
103
|
-
annotations = paper.get_annotations()
|
|
104
|
-
for ann in annotations:
|
|
105
|
-
print(f"[p.{ann.page}] {ann.type}: {ann.text[:60]}...")
|
|
106
|
-
if ann.note:
|
|
107
|
-
print(f" Note: {ann.note}")
|
|
108
|
-
|
|
109
|
-
# Export to markdown
|
|
110
|
-
paper.export_annotations("annotations.md")
|
|
111
|
-
```
|
|
112
|
-
|
|
113
|
-
## Search
|
|
114
|
-
|
|
115
|
-
```python
|
|
116
|
-
# Full-text search across library
|
|
117
|
-
results = library.search_fulltext("attention mechanism")
|
|
118
|
-
for r in results:
|
|
119
|
-
print(f"{r.title} (relevance: {r.score:.2f})")
|
|
120
|
-
for match in r.matches[:3]:
|
|
121
|
-
print(f" p.{match.page}: ...{match.context}...")
|
|
122
|
-
|
|
123
|
-
# Metadata search
|
|
124
|
-
results = library.search(
|
|
125
|
-
query="transformer", # Title/abstract search
|
|
126
|
-
authors="Vaswani",
|
|
127
|
-
year_range=(2020, 2025),
|
|
128
|
-
tags=["nlp"],
|
|
129
|
-
)
|
|
130
|
-
|
|
131
|
-
# Semantic search (if embeddings enabled)
|
|
132
|
-
results = library.semantic_search(
|
|
133
|
-
"methods for reducing quadratic complexity of attention",
|
|
134
|
-
top_k=10,
|
|
135
|
-
)
|
|
136
|
-
```
|
|
137
|
-
|
|
138
|
-
## Metadata Extraction
|
|
139
|
-
|
|
140
|
-
```python
|
|
141
|
-
# Auto-extract metadata from PDFs
|
|
142
|
-
metadata = library.extract_metadata("paper.pdf")
|
|
143
|
-
print(f"Title: {metadata.title}")
|
|
144
|
-
print(f"Authors: {metadata.authors}")
|
|
145
|
-
print(f"Abstract: {metadata.abstract[:200]}...")
|
|
146
|
-
print(f"DOI: {metadata.doi}")
|
|
147
|
-
print(f"Year: {metadata.year}")
|
|
148
|
-
print(f"References: {len(metadata.references)}")
|
|
149
|
-
|
|
150
|
-
# Enrich with external databases
|
|
151
|
-
enriched = library.enrich_metadata(
|
|
152
|
-
paper,
|
|
153
|
-
sources=["crossref", "semantic_scholar"],
|
|
154
|
-
)
|
|
155
|
-
print(f"Citations: {enriched.citation_count}")
|
|
156
|
-
print(f"Venue: {enriched.venue}")
|
|
157
|
-
```
|
|
158
|
-
|
|
159
|
-
## Export
|
|
160
|
-
|
|
161
|
-
```python
|
|
162
|
-
# Export bibliography
|
|
163
|
-
library.export_bibtex("references.bib", collection="thesis-chapter-2")
|
|
164
|
-
|
|
165
|
-
# Export reading list
|
|
166
|
-
library.export_reading_list("reading_list.md", format="markdown")
|
|
167
|
-
|
|
168
|
-
# Export annotations from all papers
|
|
169
|
-
library.export_all_annotations("all_annotations.md")
|
|
170
|
-
|
|
171
|
-
# Sync with reference manager
|
|
172
|
-
library.export_ris("export.ris") # RIS format
|
|
173
|
-
library.export_csv("export.csv") # CSV with metadata
|
|
174
|
-
```
|
|
175
|
-
|
|
176
|
-
## Configuration
|
|
177
|
-
|
|
178
|
-
```json
|
|
179
|
-
{
|
|
180
|
-
"library_path": "./research_library",
|
|
181
|
-
"pdf_viewer": "builtin",
|
|
182
|
-
"metadata": {
|
|
183
|
-
"auto_extract": true,
|
|
184
|
-
"enrich_sources": ["crossref"],
|
|
185
|
-
"language": "en"
|
|
186
|
-
},
|
|
187
|
-
"search": {
|
|
188
|
-
"fulltext_index": true,
|
|
189
|
-
"semantic_search": false,
|
|
190
|
-
"embedding_model": "all-MiniLM-L6-v2"
|
|
191
|
-
},
|
|
192
|
-
"storage": {
|
|
193
|
-
"copy_pdfs": true,
|
|
194
|
-
"organize_by": "year",
|
|
195
|
-
"max_library_size_gb": 10
|
|
196
|
-
}
|
|
197
|
-
}
|
|
198
|
-
```
|
|
199
|
-
|
|
200
|
-
## CLI Usage
|
|
201
|
-
|
|
202
|
-
```bash
|
|
203
|
-
# Add paper
|
|
204
|
-
openpaper add paper.pdf --tags "nlp,transformer"
|
|
205
|
-
|
|
206
|
-
# Search
|
|
207
|
-
openpaper search "attention mechanism" --limit 10
|
|
208
|
-
|
|
209
|
-
# List library
|
|
210
|
-
openpaper list --sort year --tags "priority:high"
|
|
211
|
-
|
|
212
|
-
# Export
|
|
213
|
-
openpaper export bibtex --collection thesis --output refs.bib
|
|
214
|
-
|
|
215
|
-
# Stats
|
|
216
|
-
openpaper stats
|
|
217
|
-
# Papers: 342, Tagged: 289, Annotated: 156, Collections: 12
|
|
218
|
-
```
|
|
219
|
-
|
|
220
|
-
## Use Cases
|
|
221
|
-
|
|
222
|
-
1. **Paper library**: Organize and search your PDF collection
|
|
223
|
-
2. **Reading workflow**: Track read status, annotate, take notes
|
|
224
|
-
3. **Reference management**: Export BibTeX for LaTeX papers
|
|
225
|
-
4. **Literature review**: Tag and categorize papers by topic
|
|
226
|
-
5. **Team sharing**: Export reading lists and annotations
|
|
227
|
-
|
|
228
|
-
## References
|
|
229
|
-
|
|
230
|
-
- [OpenPaper GitHub](https://github.com/nicehash/openpaper)
|
|
231
|
-
- [Zotero](https://www.zotero.org/) — Popular open-source alternative
|
|
232
|
-
- [Semantic Scholar API](https://api.semanticscholar.org/) — Metadata enrichment
|
|
@@ -1,227 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: qq-connect
|
|
3
|
-
description: "Connect QQ messaging to Research-Claw via QQ Bot API"
|
|
4
|
-
metadata:
|
|
5
|
-
openclaw:
|
|
6
|
-
emoji: "💬"
|
|
7
|
-
category: "tools"
|
|
8
|
-
subcategory: "document"
|
|
9
|
-
keywords: ["QQ", "QQ Bot", "messaging", "Tencent", "channel"]
|
|
10
|
-
source: "https://q.qq.com/"
|
|
11
|
-
---
|
|
12
|
-
|
|
13
|
-
# QQ 连接指南 — Research-Claw × QQ Bot
|
|
14
|
-
|
|
15
|
-
通过 QQ Bot 官方 API 将 QQ 消息通道连接到 Research-Claw,实现在 QQ 中直接与科研助手交流。
|
|
16
|
-
|
|
17
|
-
## 架构概述
|
|
18
|
-
|
|
19
|
-
```
|
|
20
|
-
QQ 用户 ⟶ QQ 开放平台 (WebSocket) ⟶ openclaw-qqbot 插件 ⟶ OpenClaw Gateway ⟶ Research-Claw Agent
|
|
21
|
-
↕
|
|
22
|
-
research-claw-core (文献/任务/工作区/雷达)
|
|
23
|
-
```
|
|
24
|
-
|
|
25
|
-
- **openclaw-qqbot** 是一个 OpenClaw channel plugin,使用腾讯 QQ Bot API v2(官方接口)
|
|
26
|
-
- 它与 research-claw-core 插件共存于同一 gateway 进程,共享 agent 上下文
|
|
27
|
-
- 安装后,QQ 用户的消息等同于 dashboard 中的对话 — agent 的全部 27 个工具均可用
|
|
28
|
-
- 附带 2 个技能:`qqbot-cron`(定时提醒)和 `qqbot-media`(图片/语音/视频/文件收发)
|
|
29
|
-
|
|
30
|
-
## 前提条件
|
|
31
|
-
|
|
32
|
-
1. **QQ 开放平台账号** — 前往 https://q.qq.com/ 注册开发者账号
|
|
33
|
-
2. **创建机器人应用** — 在开放平台创建一个机器人,获取:
|
|
34
|
-
- **AppID**(应用 ID)
|
|
35
|
-
- **AppSecret**(应用密钥)
|
|
36
|
-
3. **配置机器人权限**(在 QQ 开放平台控制台):
|
|
37
|
-
- 消息接收:开启「群聊」和/或「私聊」权限
|
|
38
|
-
- 推荐开启:`PUBLIC_GUILD_MESSAGES` + `GROUP_AND_C2C`(频道+群+私聊)
|
|
39
|
-
4. **Research-Claw 已正常运行** — gateway 可访问 (`ws://127.0.0.1:18789`)
|
|
40
|
-
|
|
41
|
-
## 安装步骤(Agent 可直接执行)
|
|
42
|
-
|
|
43
|
-
### 步骤 1:安装 QQ Bot 插件
|
|
44
|
-
|
|
45
|
-
```bash
|
|
46
|
-
openclaw plugins install @tencent-connect/openclaw-qqbot@latest
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
如果网络不通,可使用代理:
|
|
50
|
-
```bash
|
|
51
|
-
HTTPS_PROXY=http://127.0.0.1:7890 openclaw plugins install @tencent-connect/openclaw-qqbot@latest
|
|
52
|
-
```
|
|
53
|
-
|
|
54
|
-
### 步骤 2:配置凭证
|
|
55
|
-
|
|
56
|
-
**方法 A — 使用 CLI(推荐):**
|
|
57
|
-
|
|
58
|
-
> 注意:`openclaw channels add` 仅支持内置通道(Telegram、Discord 等)。
|
|
59
|
-
> qqbot 作为自定义插件,需通过 `config set` 配置。
|
|
60
|
-
|
|
61
|
-
```bash
|
|
62
|
-
openclaw config set channels.qqbot.appId "<APP_ID>"
|
|
63
|
-
openclaw config set channels.qqbot.clientSecret "<APP_SECRET>"
|
|
64
|
-
openclaw config set channels.qqbot.enabled true
|
|
65
|
-
```
|
|
66
|
-
|
|
67
|
-
**方法 B — 直接编辑配置文件:**
|
|
68
|
-
|
|
69
|
-
在 `~/.openclaw/openclaw.json` 中添加:
|
|
70
|
-
|
|
71
|
-
```jsonc
|
|
72
|
-
{
|
|
73
|
-
"channels": {
|
|
74
|
-
"qqbot": {
|
|
75
|
-
"appId": "<APP_ID>",
|
|
76
|
-
"clientSecret": "<APP_SECRET>",
|
|
77
|
-
"enabled": true
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
```
|
|
82
|
-
|
|
83
|
-
### 步骤 3:重启 Gateway
|
|
84
|
-
|
|
85
|
-
```bash
|
|
86
|
-
openclaw gateway restart
|
|
87
|
-
```
|
|
88
|
-
|
|
89
|
-
### 步骤 4:验证连接
|
|
90
|
-
|
|
91
|
-
重启后,在 QQ 中向你的机器人发送一条消息(如「你好」)。如果收到回复,连接成功。
|
|
92
|
-
|
|
93
|
-
查看 gateway 日志确认:
|
|
94
|
-
```bash
|
|
95
|
-
openclaw logs | grep -i qqbot
|
|
96
|
-
```
|
|
97
|
-
|
|
98
|
-
正常应看到类似:
|
|
99
|
-
```
|
|
100
|
-
[qqbot] Connected to QQ gateway
|
|
101
|
-
[qqbot] Session ready: sessionId=xxx
|
|
102
|
-
```
|
|
103
|
-
|
|
104
|
-
## 可选配置
|
|
105
|
-
|
|
106
|
-
```jsonc
|
|
107
|
-
{
|
|
108
|
-
"channels": {
|
|
109
|
-
"qqbot": {
|
|
110
|
-
"appId": "<APP_ID>",
|
|
111
|
-
"clientSecret": "<APP_SECRET>",
|
|
112
|
-
"enabled": true,
|
|
113
|
-
|
|
114
|
-
// 机器人显示名称(可选)
|
|
115
|
-
"name": "科研龙虾",
|
|
116
|
-
|
|
117
|
-
// 系统提示(可选,追加到 agent 默认提示之后)
|
|
118
|
-
"systemPrompt": "你现在通过 QQ 与用户交流,回复请简洁。",
|
|
119
|
-
|
|
120
|
-
// 私聊策略:open=开放 | pairing=需要用户先发消息 | allowlist=白名单
|
|
121
|
-
"dmPolicy": "open",
|
|
122
|
-
|
|
123
|
-
// 语音转文字(需要 STT 模型配置)
|
|
124
|
-
"stt": {
|
|
125
|
-
"provider": "openai",
|
|
126
|
-
"model": "whisper-1",
|
|
127
|
-
"enabled": true
|
|
128
|
-
},
|
|
129
|
-
|
|
130
|
-
// 文字转语音
|
|
131
|
-
"tts": {
|
|
132
|
-
"provider": "openai",
|
|
133
|
-
"model": "tts-1",
|
|
134
|
-
"voice": "nova",
|
|
135
|
-
"enabled": false
|
|
136
|
-
},
|
|
137
|
-
|
|
138
|
-
// 多账号(可选)
|
|
139
|
-
"accounts": {
|
|
140
|
-
"bot2": {
|
|
141
|
-
"appId": "<BOT2_APP_ID>",
|
|
142
|
-
"clientSecret": "<BOT2_APP_SECRET>",
|
|
143
|
-
"enabled": true
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
}
|
|
149
|
-
```
|
|
150
|
-
|
|
151
|
-
## Agent 自动化设置流程
|
|
152
|
-
|
|
153
|
-
当用户要求连接 QQ 时,按以下步骤操作:
|
|
154
|
-
|
|
155
|
-
1. **询问凭证**:
|
|
156
|
-
> 要连接 QQ,需要你在 QQ 开放平台(https://q.qq.com/)创建机器人后获取的 AppID 和 AppSecret。
|
|
157
|
-
> 你已经有了吗?如果没有,我可以指导你创建。
|
|
158
|
-
|
|
159
|
-
2. **获取 AppID 和 AppSecret 后,执行安装**:
|
|
160
|
-
```bash
|
|
161
|
-
openclaw plugins install @tencent-connect/openclaw-qqbot@latest
|
|
162
|
-
openclaw config set channels.qqbot.appId "<用户提供的AppID>"
|
|
163
|
-
openclaw config set channels.qqbot.clientSecret "<用户提供的Secret>"
|
|
164
|
-
openclaw config set channels.qqbot.enabled true
|
|
165
|
-
openclaw gateway restart
|
|
166
|
-
```
|
|
167
|
-
|
|
168
|
-
3. **引导测试**:
|
|
169
|
-
> 安装完成!请在 QQ 中找到你的机器人,发送一条消息试试。
|
|
170
|
-
|
|
171
|
-
4. **记录到 MEMORY.md**:
|
|
172
|
-
```markdown
|
|
173
|
-
### Environment
|
|
174
|
-
- QQ Bot: connected (AppID: <前4位>****)
|
|
175
|
-
```
|
|
176
|
-
|
|
177
|
-
## QQ Bot 注册指引(用于引导无账号的用户)
|
|
178
|
-
|
|
179
|
-
1. 访问 https://q.qq.com/,使用 QQ 账号登录
|
|
180
|
-
2. 点击「创建机器人」(或「应用管理」→「创建」)
|
|
181
|
-
3. 填写机器人基本信息(名称、头像、简介)
|
|
182
|
-
4. 在「开发设置」中获取 **AppID** 和 **AppSecret**
|
|
183
|
-
5. 在「消息」→「消息订阅」中开启消息接收权限:
|
|
184
|
-
- 群消息(推荐)
|
|
185
|
-
- 私聊消息(推荐)
|
|
186
|
-
- 频道消息(可选)
|
|
187
|
-
6. 审核通过后即可使用
|
|
188
|
-
|
|
189
|
-
> 注意:QQ 机器人需要通过腾讯审核。测试阶段可使用沙箱环境。
|
|
190
|
-
|
|
191
|
-
## 消息能力
|
|
192
|
-
|
|
193
|
-
连接 QQ 后,agent 可以:
|
|
194
|
-
|
|
195
|
-
| 能力 | 说明 |
|
|
196
|
-
|------|------|
|
|
197
|
-
| 文本对话 | QQ 消息 ↔ agent 双向交流 |
|
|
198
|
-
| 图片收发 | 用户发图自动下载,agent 用 `<qqimg>` 标签发图 |
|
|
199
|
-
| 语音处理 | STT 转文字(需配置),TTS 发语音 |
|
|
200
|
-
| 视频/文件 | `<qqvideo>` / `<qqfile>` 标签发送 |
|
|
201
|
-
| 定时提醒 | cron 工具创建一次性/周期提醒 |
|
|
202
|
-
| 群聊 | 支持群组中 @机器人 交流 |
|
|
203
|
-
| 私聊 | 支持一对一私聊 |
|
|
204
|
-
|
|
205
|
-
## 常见问题
|
|
206
|
-
|
|
207
|
-
### 连接超时
|
|
208
|
-
- 检查网络:QQ Bot API 需要能访问 `api.sgroup.qq.com` 和 `bots.qq.com`
|
|
209
|
-
- 如果在国内需要代理,在配置中不需要设置代理(QQ API 是国内服务)
|
|
210
|
-
- 如果在海外,可能需要配置代理
|
|
211
|
-
|
|
212
|
-
### 权限不足(Intent 降级)
|
|
213
|
-
- 插件会自动尝试 3 个权限级别:全功能 → 群+频道 → 仅频道
|
|
214
|
-
- 如果只能用基础功能,去 QQ 开放平台检查机器人权限配置
|
|
215
|
-
|
|
216
|
-
### 消息发不出去
|
|
217
|
-
- 确认 AppID 和 AppSecret 正确
|
|
218
|
-
- 确认机器人已通过审核(或在沙箱中测试)
|
|
219
|
-
- 检查 gateway 日志:`openclaw logs | grep qqbot`
|
|
220
|
-
|
|
221
|
-
### 语音无法转文字
|
|
222
|
-
- 需要配置 STT 提供商(如 OpenAI Whisper)
|
|
223
|
-
- 在 `channels.qqbot.stt` 中设置 provider 和 model
|
|
224
|
-
|
|
225
|
-
### 重启后断开
|
|
226
|
-
- 5 分钟内重启可自动恢复 session(session persistence)
|
|
227
|
-
- 超过 5 分钟会重新建立连接,不影响功能
|
|
@@ -1,216 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: weknora-guide
|
|
3
|
-
description: "Tencent document understanding engine with RAG capabilities"
|
|
4
|
-
metadata:
|
|
5
|
-
openclaw:
|
|
6
|
-
emoji: "📑"
|
|
7
|
-
category: "tools"
|
|
8
|
-
subcategory: "document"
|
|
9
|
-
keywords: ["WeKnora", "document understanding", "RAG", "text mining", "Tencent", "knowledge extraction"]
|
|
10
|
-
source: "https://github.com/Tencent/WeKnora"
|
|
11
|
-
---
|
|
12
|
-
|
|
13
|
-
# WeKnora Guide
|
|
14
|
-
|
|
15
|
-
## Overview
|
|
16
|
-
|
|
17
|
-
WeKnora is Tencent's open-source document understanding and retrieval-augmented generation engine. It processes complex documents (PDF, DOCX, HTML) into structured knowledge, supporting layout analysis, table extraction, formula recognition, and multi-modal content parsing. Integrates with RAG pipelines for question answering over document collections. Suited for academic paper processing, report analysis, and enterprise document intelligence.
|
|
18
|
-
|
|
19
|
-
## Installation
|
|
20
|
-
|
|
21
|
-
```bash
|
|
22
|
-
# Install WeKnora
|
|
23
|
-
pip install weknora
|
|
24
|
-
|
|
25
|
-
# With GPU support
|
|
26
|
-
pip install weknora[gpu]
|
|
27
|
-
|
|
28
|
-
# With all optional dependencies
|
|
29
|
-
pip install weknora[all]
|
|
30
|
-
```
|
|
31
|
-
|
|
32
|
-
## Document Parsing
|
|
33
|
-
|
|
34
|
-
```python
|
|
35
|
-
from weknora import DocumentParser
|
|
36
|
-
|
|
37
|
-
parser = DocumentParser()
|
|
38
|
-
|
|
39
|
-
# Parse a PDF document
|
|
40
|
-
doc = parser.parse("research_paper.pdf")
|
|
41
|
-
|
|
42
|
-
print(f"Pages: {doc.num_pages}")
|
|
43
|
-
print(f"Sections: {len(doc.sections)}")
|
|
44
|
-
print(f"Tables: {len(doc.tables)}")
|
|
45
|
-
print(f"Figures: {len(doc.figures)}")
|
|
46
|
-
print(f"Equations: {len(doc.equations)}")
|
|
47
|
-
|
|
48
|
-
# Access structured content
|
|
49
|
-
for section in doc.sections:
|
|
50
|
-
print(f"\n## {section.title}")
|
|
51
|
-
print(f" {section.text[:200]}...")
|
|
52
|
-
if section.tables:
|
|
53
|
-
print(f" Tables: {len(section.tables)}")
|
|
54
|
-
```
|
|
55
|
-
|
|
56
|
-
## Layout Analysis
|
|
57
|
-
|
|
58
|
-
```python
|
|
59
|
-
from weknora import LayoutAnalyzer
|
|
60
|
-
|
|
61
|
-
analyzer = LayoutAnalyzer(model="layoutlmv3")
|
|
62
|
-
|
|
63
|
-
# Detect document layout elements
|
|
64
|
-
layout = analyzer.analyze("paper.pdf")
|
|
65
|
-
|
|
66
|
-
for page in layout.pages:
|
|
67
|
-
print(f"\nPage {page.number}:")
|
|
68
|
-
for element in page.elements:
|
|
69
|
-
print(f" [{element.type}] ({element.bbox}) "
|
|
70
|
-
f"{element.text[:50]}...")
|
|
71
|
-
# Element types: title, text, table, figure,
|
|
72
|
-
# equation, header, footer, caption, list
|
|
73
|
-
```
|
|
74
|
-
|
|
75
|
-
## Table Extraction
|
|
76
|
-
|
|
77
|
-
```python
|
|
78
|
-
from weknora import TableExtractor
|
|
79
|
-
|
|
80
|
-
extractor = TableExtractor()
|
|
81
|
-
|
|
82
|
-
# Extract tables from document
|
|
83
|
-
tables = extractor.extract("paper.pdf")
|
|
84
|
-
|
|
85
|
-
for i, table in enumerate(tables):
|
|
86
|
-
print(f"\nTable {i+1}: {table.caption}")
|
|
87
|
-
df = table.to_dataframe()
|
|
88
|
-
print(df.head())
|
|
89
|
-
|
|
90
|
-
# Export
|
|
91
|
-
df.to_csv(f"table_{i+1}.csv")
|
|
92
|
-
|
|
93
|
-
# Extract specific table by page
|
|
94
|
-
table = extractor.extract_from_page("paper.pdf", page=5, index=0)
|
|
95
|
-
```
|
|
96
|
-
|
|
97
|
-
## Formula Recognition
|
|
98
|
-
|
|
99
|
-
```python
|
|
100
|
-
from weknora import FormulaRecognizer
|
|
101
|
-
|
|
102
|
-
recognizer = FormulaRecognizer()
|
|
103
|
-
|
|
104
|
-
# Extract formulas from document
|
|
105
|
-
formulas = recognizer.extract("paper.pdf")
|
|
106
|
-
|
|
107
|
-
for formula in formulas:
|
|
108
|
-
print(f"Page {formula.page}: {formula.latex}")
|
|
109
|
-
# Output: "\\mathcal{L} = -\\sum_{i} y_i \\log(\\hat{y}_i)"
|
|
110
|
-
print(f" Type: {formula.type}") # inline or display
|
|
111
|
-
```
|
|
112
|
-
|
|
113
|
-
## RAG Pipeline
|
|
114
|
-
|
|
115
|
-
```python
|
|
116
|
-
from weknora import RAGPipeline
|
|
117
|
-
|
|
118
|
-
# Build RAG over document collection
|
|
119
|
-
rag = RAGPipeline(
|
|
120
|
-
embedding_model="bge-large-zh-v1.5",
|
|
121
|
-
chunk_size=512,
|
|
122
|
-
chunk_overlap=64,
|
|
123
|
-
)
|
|
124
|
-
|
|
125
|
-
# Index documents
|
|
126
|
-
rag.add_documents([
|
|
127
|
-
"papers/transformer.pdf",
|
|
128
|
-
"papers/bert.pdf",
|
|
129
|
-
"papers/gpt3.pdf",
|
|
130
|
-
])
|
|
131
|
-
|
|
132
|
-
# Query
|
|
133
|
-
result = rag.query(
|
|
134
|
-
"What is the computational complexity of self-attention?"
|
|
135
|
-
)
|
|
136
|
-
print(result.answer)
|
|
137
|
-
for source in result.sources:
|
|
138
|
-
print(f" [{source.document}] p.{source.page}: "
|
|
139
|
-
f"{source.text[:80]}...")
|
|
140
|
-
```
|
|
141
|
-
|
|
142
|
-
## Multi-Modal Processing
|
|
143
|
-
|
|
144
|
-
```python
|
|
145
|
-
from weknora import MultiModalParser
|
|
146
|
-
|
|
147
|
-
parser = MultiModalParser()
|
|
148
|
-
|
|
149
|
-
# Process document with figures and tables
|
|
150
|
-
doc = parser.parse("paper.pdf", extract_all=True)
|
|
151
|
-
|
|
152
|
-
# Access figure descriptions
|
|
153
|
-
for fig in doc.figures:
|
|
154
|
-
print(f"Figure {fig.number}: {fig.caption}")
|
|
155
|
-
fig.save_image(f"figures/fig_{fig.number}.png")
|
|
156
|
-
|
|
157
|
-
# Cross-reference tables and text
|
|
158
|
-
for ref in doc.cross_references:
|
|
159
|
-
print(f"'{ref.text}' → {ref.target_type} {ref.target_id}")
|
|
160
|
-
```
|
|
161
|
-
|
|
162
|
-
## Batch Processing
|
|
163
|
-
|
|
164
|
-
```python
|
|
165
|
-
from weknora import BatchProcessor
|
|
166
|
-
|
|
167
|
-
processor = BatchProcessor(
|
|
168
|
-
workers=4,
|
|
169
|
-
output_dir="./parsed_docs",
|
|
170
|
-
)
|
|
171
|
-
|
|
172
|
-
# Process directory of documents
|
|
173
|
-
results = processor.process_directory(
|
|
174
|
-
"papers/",
|
|
175
|
-
formats=["pdf", "docx"],
|
|
176
|
-
output_format="json", # or "markdown"
|
|
177
|
-
)
|
|
178
|
-
|
|
179
|
-
print(f"Processed: {results.success}/{results.total}")
|
|
180
|
-
print(f"Failed: {results.failures}")
|
|
181
|
-
```
|
|
182
|
-
|
|
183
|
-
## Configuration
|
|
184
|
-
|
|
185
|
-
```python
|
|
186
|
-
from weknora import Config
|
|
187
|
-
|
|
188
|
-
config = Config(
|
|
189
|
-
parser={
|
|
190
|
-
"layout_model": "layoutlmv3",
|
|
191
|
-
"ocr_engine": "paddleocr",
|
|
192
|
-
"formula_engine": "latex_ocr",
|
|
193
|
-
"language": "en", # or "zh", "multi"
|
|
194
|
-
},
|
|
195
|
-
rag={
|
|
196
|
-
"embedding_model": "bge-large-zh-v1.5",
|
|
197
|
-
"reranker": "bge-reranker-large",
|
|
198
|
-
"chunk_strategy": "semantic",
|
|
199
|
-
"vector_store": "faiss",
|
|
200
|
-
},
|
|
201
|
-
)
|
|
202
|
-
```
|
|
203
|
-
|
|
204
|
-
## Use Cases
|
|
205
|
-
|
|
206
|
-
1. **Paper parsing**: Extract structured content from academic PDFs
|
|
207
|
-
2. **Table digitization**: Convert paper tables to spreadsheets
|
|
208
|
-
3. **Document QA**: RAG-based question answering over papers
|
|
209
|
-
4. **Knowledge extraction**: Build knowledge bases from documents
|
|
210
|
-
5. **Report analysis**: Process and compare technical reports
|
|
211
|
-
|
|
212
|
-
## References
|
|
213
|
-
|
|
214
|
-
- [WeKnora GitHub](https://github.com/Tencent/WeKnora)
|
|
215
|
-
- [LayoutLMv3](https://arxiv.org/abs/2204.08387)
|
|
216
|
-
- [PaddleOCR](https://github.com/PaddlePaddle/PaddleOCR)
|