scientify 1.0.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 ADDED
@@ -0,0 +1,243 @@
1
+ # Scientify
2
+
3
+ **AI-powered research workflow automation for OpenClaw.**
4
+
5
+ [中文文档](./README.zh.md)
6
+
7
+ ---
8
+
9
+ ## Features
10
+
11
+ ### Skills (LLM-powered)
12
+
13
+ | Skill | Description |
14
+ |-------|-------------|
15
+ | **idea-generation** | Generate innovative research ideas from a topic. Searches arXiv/GitHub, downloads papers, analyzes literature, outputs 5 ideas with citations. |
16
+ | **research-pipeline** | End-to-end ML research workflow: idea → literature → survey → plan → implement → review → iterate. |
17
+ | **literature-review** | Generate structured notes and synthesis from papers you've collected. |
18
+ | **arxiv** | Search arXiv.org for papers and download .tex sources. |
19
+
20
+ ### Commands (Direct, no LLM)
21
+
22
+ | Command | Description |
23
+ |---------|-------------|
24
+ | `/research-status` | Show workspace status |
25
+ | `/papers` | List downloaded papers |
26
+ | `/ideas` | List generated ideas |
27
+ | `/projects` | List all projects |
28
+ | `/project-switch <id>` | Switch project |
29
+ | `/project-delete <id>` | Delete project |
30
+
31
+ ### Tool
32
+
33
+ - **arxiv** - Search arXiv.org API with keyword search, date filtering, automatic .tex download
34
+
35
+ ---
36
+
37
+ ## Installation
38
+
39
+ ```bash
40
+ npm install scientify
41
+ ```
42
+
43
+ Add to OpenClaw config:
44
+
45
+ ```json
46
+ {
47
+ "plugins": ["scientify"]
48
+ }
49
+ ```
50
+
51
+ ---
52
+
53
+ ## Usage Scenarios
54
+
55
+ ### 1. One-shot Idea Generation
56
+
57
+ ```
58
+ You: Research "long document summarization" and generate some innovative ideas
59
+
60
+ Agent: [Auto-executes]
61
+ 1. Search arXiv papers
62
+ 2. Search GitHub repositories
63
+ 3. Download and analyze .tex sources
64
+ 4. Generate 5 innovative ideas
65
+ 5. Select and enhance the best idea
66
+ 6. Map to code implementations
67
+ ```
68
+
69
+ ### 2. Daily Literature Tracking
70
+
71
+ ```
72
+ You: Set up a daily task at 9am to check arXiv for new papers on
73
+ "transformer efficiency", summarize relevant ones and send to Feishu
74
+
75
+ Agent: Setting up:
76
+ 1. Create scheduled Hook (cron: "0 9 * * *")
77
+ 2. Daily arxiv search for papers from last 24h
78
+ 3. Compare against your idea (selected_idea.md)
79
+ 4. Filter relevant papers, generate summary
80
+ 5. Push via Feishu webhook
81
+
82
+ [Example push]
83
+ 📚 Today's Relevant Papers (3)
84
+ • "FlashAttention-3: Fast Attention with ..." - Highly relevant to your idea
85
+ • "Efficient Long-Context Transformers" - Medium relevance
86
+ • "..."
87
+ ```
88
+
89
+ ### 3. Research Progress Reporter
90
+
91
+ ```
92
+ You: Generate weekly research progress report every Friday and send to Slack
93
+
94
+ Agent: [Auto-executes every Friday]
95
+ 1. Read $WORKSPACE changes
96
+ 2. Stats: X new papers, Y new ideas, Z code commits
97
+ 3. Generate weekly report markdown
98
+ 4. Push to Slack #research channel
99
+ ```
100
+
101
+ ### 4. Competitive Paper Monitor
102
+
103
+ ```
104
+ You: Monitor new papers from "Yann LeCun" and "Meta AI"
105
+
106
+ Agent: Setting up monitoring:
107
+ - Daily check arxiv author "Yann LeCun"
108
+ - Check arxiv affiliation "Meta AI"
109
+ - Push notification when new papers appear
110
+ ```
111
+
112
+ ### 5. Paper Reading Assistant
113
+
114
+ ```
115
+ You: Read papers/2401.12345/ and compare its method with my idea
116
+
117
+ Agent: [Reading paper .tex files]
118
+
119
+ 📄 Paper: "Efficient Attention for Long Documents"
120
+
121
+ ## Comparison with Your Idea
122
+
123
+ | Aspect | Paper Method | Your Method |
124
+ |--------|-------------|-------------|
125
+ | Attention | Sparse Attention | Hierarchical Attention |
126
+ | Complexity | O(n√n) | O(n log n) |
127
+ | Advantage | Simple implementation | Preserves more info |
128
+
129
+ ## Suggestions
130
+ Consider combining both approaches...
131
+ ```
132
+
133
+ ### 6. Related Work Writer
134
+
135
+ ```
136
+ You: Write Related Work section based on papers in my project
137
+
138
+ Agent: [Reading papers/ and literature/notes/]
139
+
140
+ Generating related_work.tex:
141
+
142
+ \section{Related Work}
143
+
144
+ \subsection{Long Document Summarization}
145
+ Recent works have explored various approaches...
146
+ \cite{paper1} proposed...
147
+ \cite{paper2} extended this by...
148
+
149
+ \subsection{Efficient Transformers}
150
+ ...
151
+ ```
152
+
153
+ ### 7. Idea Mashup
154
+
155
+ ```
156
+ You: Combine "reinforcement learning" and "text summarization" to spark new ideas
157
+
158
+ Agent: [Searching papers from both fields]
159
+
160
+ 🔥 Mashup Results:
161
+
162
+ 1. **RL-guided Summarization**
163
+ Use RL to optimize readability and information coverage
164
+ References: [2301.xxx], [2302.xxx]
165
+
166
+ 2. **Interactive Summarization Agent**
167
+ User feedback as reward signal for iterative optimization
168
+
169
+ 3. ...
170
+ ```
171
+
172
+ ### 8. Experiment Design Helper
173
+
174
+ ```
175
+ You: My idea is xxx, help me design experiments
176
+
177
+ Agent: [Reading selected_idea.md and related papers]
178
+
179
+ ## Experiment Design
180
+
181
+ ### Datasets
182
+ 1. CNN/DailyMail - Standard news summarization (287k samples)
183
+ 2. arXiv - Long scientific papers (215k samples)
184
+ 3. ...
185
+
186
+ ### Baselines
187
+ 1. BART-large (ref: paper_001.md)
188
+ 2. LED (ref: paper_003.md)
189
+
190
+ ### Metrics
191
+ - ROUGE-1/2/L
192
+ - BERTScore
193
+ - Human evaluation: fluency, information coverage
194
+
195
+ ### Ablation Studies
196
+ 1. Remove xxx module
197
+ 2. ...
198
+ ```
199
+
200
+ ---
201
+
202
+ ## Workspace Structure
203
+
204
+ ```
205
+ ~/.openclaw/workspace/projects/
206
+ ├── .active # Current project ID
207
+ ├── nlp-summarization/ # Project A
208
+ │ ├── project.json # Metadata
209
+ │ ├── task.json # Task definition
210
+ │ ├── search_results.md # Search results
211
+ │ ├── papers/ # Downloaded papers
212
+ │ ├── repos/ # Cloned repos
213
+ │ └── ideas/ # Generated ideas
214
+ │ ├── idea_1.md
215
+ │ ├── idea_2.md
216
+ │ └── selected_idea.md # Best idea
217
+ └── another-project/
218
+ ```
219
+
220
+ ---
221
+
222
+ ## Configuration
223
+
224
+ ```json
225
+ {
226
+ "plugins": {
227
+ "scientify": {
228
+ "workspaceRoot": "~/my-research",
229
+ "defaultMaxPapers": 15
230
+ }
231
+ }
232
+ }
233
+ ```
234
+
235
+ ---
236
+
237
+ ## License
238
+
239
+ MIT
240
+
241
+ ## Author
242
+
243
+ tsingyuai
package/README.zh.md ADDED
@@ -0,0 +1,244 @@
1
+ # Scientify
2
+
3
+ **为 OpenClaw 打造的 AI 驱动研究工作流自动化插件。**
4
+
5
+ [English](./README.md)
6
+
7
+ ---
8
+
9
+ ## 功能
10
+
11
+ ### Skills (通过 LLM)
12
+
13
+ | Skill | 描述 |
14
+ |-------|------|
15
+ | **idea-generation** | 从研究主题生成创新想法。自动搜索 arXiv/GitHub、下载论文、分析文献,输出 5 个带引用的研究想法。 |
16
+ | **research-pipeline** | 端到端 ML 研究流程:想法 → 文献 → 综述 → 计划 → 实现 → 评审 → 迭代。 |
17
+ | **literature-review** | 从已收集的论文生成结构化笔记和综述。 |
18
+ | **arxiv** | 搜索 arXiv 论文并下载 .tex 源文件。 |
19
+
20
+ ### Commands (直接执行,不经 LLM)
21
+
22
+ | 命令 | 描述 |
23
+ |------|------|
24
+ | `/research-status` | 显示工作空间状态 |
25
+ | `/papers` | 列出已下载论文 |
26
+ | `/ideas` | 列出已生成想法 |
27
+ | `/projects` | 列出所有项目 |
28
+ | `/project-switch <id>` | 切换项目 |
29
+ | `/project-delete <id>` | 删除项目 |
30
+
31
+ ### Tool
32
+
33
+ - **arxiv** - 搜索 arXiv API,支持关键词搜索、日期过滤、自动下载 .tex 源文件
34
+
35
+ ---
36
+
37
+ ## 安装
38
+
39
+ ```bash
40
+ npm install scientify
41
+ ```
42
+
43
+ 添加到 OpenClaw 配置:
44
+
45
+ ```json
46
+ {
47
+ "plugins": ["scientify"]
48
+ }
49
+ ```
50
+
51
+ ---
52
+
53
+ ## 使用场景
54
+
55
+ ### 1. 一键生成研究想法
56
+
57
+ ```
58
+ 你: 帮我调研 "长文档摘要" 领域,生成一些创新的研究想法
59
+
60
+ Agent: [自动执行]
61
+ 1. 搜索 arXiv 论文
62
+ 2. 搜索 GitHub 仓库
63
+ 3. 下载并分析 .tex 源文件
64
+ 4. 生成 5 个创新想法
65
+ 5. 选出最佳想法并增强
66
+ 6. 映射到代码实现
67
+ ```
68
+
69
+ ### 2. 每日文献追踪
70
+
71
+ ```
72
+ 你: 帮我设置一个定时任务,每天早上 9 点检查 arXiv 上关于
73
+ "transformer efficiency" 的新论文,如果有相关的就总结后发到飞书
74
+
75
+ Agent: 好的,我来设置:
76
+ 1. 创建定时 Hook (cron: "0 9 * * *")
77
+ 2. 每天调用 arxiv 工具搜索最近 24h 的论文
78
+ 3. 用你的 idea (selected_idea.md) 作为对比基准
79
+ 4. 筛选相关论文,生成摘要
80
+ 5. 通过飞书 webhook 推送
81
+
82
+ [示例推送]
83
+ 📚 今日相关论文 (3篇)
84
+ • "FlashAttention-3: Fast Attention with ..." - 与你的 idea 高度相关,建议精读
85
+ • "Efficient Long-Context Transformers" - 中等相关
86
+ • "..."
87
+ ```
88
+
89
+ ### 3. 研究进展汇报
90
+
91
+ ```
92
+ 你: 每周五下午帮我生成本周研究进展报告,发到 Slack
93
+
94
+ Agent: [每周五自动执行]
95
+ 1. 读取 $WORKSPACE 变化
96
+ 2. 统计: 新增论文 X 篇,新想法 Y 个,代码提交 Z 次
97
+ 3. 生成周报 markdown
98
+ 4. 推送到 Slack #research 频道
99
+ ```
100
+
101
+ ### 4. 竞品论文监控
102
+
103
+ ```
104
+ 你: 监控 "Yann LeCun" 和 "Meta AI" 的新论文,有新发布就提醒我
105
+
106
+ Agent: 设置监控:
107
+ - 每日检查 arxiv 作者 "Yann LeCun"
108
+ - 检查 arxiv 机构 "Meta AI"
109
+ - 新论文出现时推送通知
110
+ ```
111
+
112
+ ### 5. 论文阅读助手
113
+
114
+ ```
115
+ 你: 帮我读一下 papers/2401.12345/ 这篇论文,
116
+ 重点关注它的方法和我的 idea 有什么异同
117
+
118
+ Agent: [读取论文 .tex 文件]
119
+
120
+ 📄 论文: "Efficient Attention for Long Documents"
121
+
122
+ ## 与你的 idea 对比
123
+
124
+ | 方面 | 论文方法 | 你的方法 |
125
+ |------|---------|---------|
126
+ | 注意力机制 | Sparse Attention | Hierarchical Attention |
127
+ | 复杂度 | O(n√n) | O(n log n) |
128
+ | 优势 | 实现简单 | 保留更多信息 |
129
+
130
+ ## 建议
131
+ 可以考虑结合两者...
132
+ ```
133
+
134
+ ### 6. Related Work 写作助手
135
+
136
+ ```
137
+ 你: 基于我项目里的论文,帮我写 Related Work 章节
138
+
139
+ Agent: [读取 papers/ 和 literature/notes/]
140
+
141
+ 生成 related_work.tex:
142
+
143
+ \section{Related Work}
144
+
145
+ \subsection{Long Document Summarization}
146
+ Recent works have explored various approaches...
147
+ \cite{paper1} proposed...
148
+ \cite{paper2} extended this by...
149
+
150
+ \subsection{Efficient Transformers}
151
+ ...
152
+ ```
153
+
154
+ ### 7. 想法碰撞
155
+
156
+ ```
157
+ 你: 把 "强化学习" 和 "文本摘要" 两个领域结合,看能不能碰撞出新想法
158
+
159
+ Agent: [搜索两个领域的论文]
160
+
161
+ 🔥 碰撞结果:
162
+
163
+ 1. **RL-guided Summarization**
164
+ 用 RL 优化摘要的可读性和信息覆盖
165
+ 参考: [2301.xxx], [2302.xxx]
166
+
167
+ 2. **Interactive Summarization Agent**
168
+ 用户反馈作为 reward 信号迭代优化摘要
169
+
170
+ 3. ...
171
+ ```
172
+
173
+ ### 8. 实验设计助手
174
+
175
+ ```
176
+ 你: 我的 idea 是 xxx,帮我设计实验方案
177
+
178
+ Agent: [读取 selected_idea.md 和相关论文]
179
+
180
+ ## 实验设计
181
+
182
+ ### Datasets
183
+ 1. CNN/DailyMail - 标准新闻摘要 (287k samples)
184
+ 2. arXiv - 长文档科学论文 (215k samples)
185
+ 3. ...
186
+
187
+ ### Baselines
188
+ 1. BART-large (参考: paper_001.md)
189
+ 2. LED (参考: paper_003.md)
190
+
191
+ ### Metrics
192
+ - ROUGE-1/2/L
193
+ - BERTScore
194
+ - 人工评估: 流畅度、信息覆盖
195
+
196
+ ### Ablation Studies
197
+ 1. 去掉 xxx 模块
198
+ 2. ...
199
+ ```
200
+
201
+ ---
202
+
203
+ ## 工作空间结构
204
+
205
+ ```
206
+ ~/.openclaw/workspace/projects/
207
+ ├── .active # 当前项目 ID
208
+ ├── nlp-summarization/ # 项目 A
209
+ │ ├── project.json # 元数据
210
+ │ ├── task.json # 任务定义
211
+ │ ├── search_results.md # 搜索结果
212
+ │ ├── papers/ # 下载的论文
213
+ │ ├── repos/ # 克隆的仓库
214
+ │ └── ideas/ # 生成的想法
215
+ │ ├── idea_1.md
216
+ │ ├── idea_2.md
217
+ │ └── selected_idea.md # 最佳想法
218
+ └── another-project/
219
+ ```
220
+
221
+ ---
222
+
223
+ ## 配置
224
+
225
+ ```json
226
+ {
227
+ "plugins": {
228
+ "scientify": {
229
+ "workspaceRoot": "~/my-research",
230
+ "defaultMaxPapers": 15
231
+ }
232
+ }
233
+ }
234
+ ```
235
+
236
+ ---
237
+
238
+ ## License
239
+
240
+ MIT
241
+
242
+ ## Author
243
+
244
+ tsingyuai
@@ -0,0 +1,3 @@
1
+ import type { OpenClawPluginApi } from "openclaw";
2
+ export default function register(api: OpenClawPluginApi): void;
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAWlD,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,GAAG,EAAE,iBAAiB,QAsDtD"}
package/dist/index.js ADDED
@@ -0,0 +1,51 @@
1
+ import { handleResearchStatus, handlePapers, handleIdeas, handleProjects, handleProjectSwitch, handleProjectDelete, } from "./src/commands.js";
2
+ import { createArxivTool } from "./src/tools/arxiv-tool.js";
3
+ export default function register(api) {
4
+ // Register the arxiv tool
5
+ api.registerTool(createArxivTool());
6
+ // Register chat commands (bypass LLM)
7
+ api.registerCommand({
8
+ name: "research-status",
9
+ description: "Show research workspace status (active project, papers, ideas)",
10
+ acceptsArgs: false,
11
+ requireAuth: false,
12
+ handler: handleResearchStatus,
13
+ });
14
+ api.registerCommand({
15
+ name: "papers",
16
+ description: "List downloaded papers in active project",
17
+ acceptsArgs: true,
18
+ requireAuth: false,
19
+ handler: handlePapers,
20
+ });
21
+ api.registerCommand({
22
+ name: "ideas",
23
+ description: "List generated ideas in active project",
24
+ acceptsArgs: true,
25
+ requireAuth: false,
26
+ handler: handleIdeas,
27
+ });
28
+ api.registerCommand({
29
+ name: "projects",
30
+ description: "List all research projects",
31
+ acceptsArgs: false,
32
+ requireAuth: false,
33
+ handler: handleProjects,
34
+ });
35
+ api.registerCommand({
36
+ name: "project-switch",
37
+ description: "Switch to a different research project",
38
+ acceptsArgs: true,
39
+ requireAuth: false,
40
+ handler: handleProjectSwitch,
41
+ });
42
+ api.registerCommand({
43
+ name: "project-delete",
44
+ description: "Delete a research project (use --force to confirm)",
45
+ acceptsArgs: true,
46
+ requireAuth: true, // Require auth for destructive operation
47
+ handler: handleProjectDelete,
48
+ });
49
+ api.logger.info("Scientify plugin loaded successfully");
50
+ }
51
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AACA,OAAO,EACL,oBAAoB,EACpB,YAAY,EACZ,WAAW,EACX,cAAc,EACd,mBAAmB,EACnB,mBAAmB,GACpB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAE5D,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,GAAsB;IACrD,0BAA0B;IAC1B,GAAG,CAAC,YAAY,CAAC,eAAe,EAAE,CAAC,C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research-status - Show workspace status
4
+ */
5
+ export declare function handleResearchStatus(_ctx: PluginCommandContext): PluginCommandResult;
6
+ /**
7
+ * /papers - List downloaded papers
8
+ */
9
+ export declare function handlePapers(ctx: PluginCommandContext): PluginCommandResult;
10
+ /**
11
+ * /ideas - List generated ideas
12
+ */
13
+ export declare function handleIdeas(ctx: PluginCommandContext): PluginCommandResult;
14
+ /**
15
+ * /projects - List all research projects
16
+ */
17
+ export declare function handleProjects(_ctx: PluginCommandContext): PluginCommandResult;
18
+ /**
19
+ * /project-switch <project-id> - Switch to a different project
20
+ */
21
+ export declare function handleProjectSwitch(ctx: PluginCommandContext): PluginCommandResult;
22
+ /**
23
+ * /project-delete <project-id> - Delete a research project
24
+ */
25
+ export declare function handleProjectDelete(ctx: PluginCommandContext): PluginCommandResult;
26
+ //# sourceMappingURL=commands.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"commands.d.ts","sourceRoot":"","sources":["../../src/commands.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAkF1E;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,oBAAoB,GAAG,mBAAmB,CAkCpF;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,GAAG,EAAE,oBAAoB,GAAG,mBAAmB,CAiC3E;AAED;;GAEG;AACH,wBAAgB,WAAW,CAAC,GAAG,EAAE,oBAAoB,GAAG,mBAAmB,CA4B1E;AAED;;GAEG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,oBAAoB,GAAG,mBAAmB,CAqB9E;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,GAAG,EAAE,oBAAoB,GAAG,mBAAmB,CAclF;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,GAAG,EAAE,oBAAoB,GAAG,mBAAmB,CA2ClF"}