scientify 1.11.0 → 1.12.1

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.
Files changed (72) hide show
  1. package/README.md +2 -2
  2. package/README.zh.md +2 -2
  3. package/dist/index.d.ts.map +1 -1
  4. package/dist/index.js +16 -1
  5. package/dist/index.js.map +1 -1
  6. package/dist/src/cli/research.d.ts +10 -0
  7. package/dist/src/cli/research.d.ts.map +1 -0
  8. package/dist/src/cli/research.js +283 -0
  9. package/dist/src/cli/research.js.map +1 -0
  10. package/dist/src/commands/metabolism-status.d.ts +6 -0
  11. package/dist/src/commands/metabolism-status.d.ts.map +1 -0
  12. package/dist/src/commands/metabolism-status.js +100 -0
  13. package/dist/src/commands/metabolism-status.js.map +1 -0
  14. package/dist/src/hooks/cron-skill-inject.d.ts +21 -0
  15. package/dist/src/hooks/cron-skill-inject.d.ts.map +1 -0
  16. package/dist/src/hooks/cron-skill-inject.js +53 -0
  17. package/dist/src/hooks/cron-skill-inject.js.map +1 -0
  18. package/dist/src/hooks/research-mode.d.ts +1 -1
  19. package/dist/src/hooks/research-mode.d.ts.map +1 -1
  20. package/dist/src/hooks/research-mode.js +28 -2
  21. package/dist/src/hooks/research-mode.js.map +1 -1
  22. package/dist/src/knowledge-state/render.d.ts +8 -1
  23. package/dist/src/knowledge-state/render.d.ts.map +1 -1
  24. package/dist/src/knowledge-state/render.js +31 -0
  25. package/dist/src/knowledge-state/render.js.map +1 -1
  26. package/dist/src/knowledge-state/store.d.ts.map +1 -1
  27. package/dist/src/knowledge-state/store.js +340 -6
  28. package/dist/src/knowledge-state/store.js.map +1 -1
  29. package/dist/src/knowledge-state/types.d.ts +19 -0
  30. package/dist/src/knowledge-state/types.d.ts.map +1 -1
  31. package/dist/src/literature/subscription-state.d.ts +2 -0
  32. package/dist/src/literature/subscription-state.d.ts.map +1 -1
  33. package/dist/src/literature/subscription-state.js +7 -0
  34. package/dist/src/literature/subscription-state.js.map +1 -1
  35. package/dist/src/research-subscriptions/prompt.d.ts.map +1 -1
  36. package/dist/src/research-subscriptions/prompt.js +44 -16
  37. package/dist/src/research-subscriptions/prompt.js.map +1 -1
  38. package/dist/src/templates/bootstrap.d.ts +8 -0
  39. package/dist/src/templates/bootstrap.d.ts.map +1 -0
  40. package/dist/src/templates/bootstrap.js +153 -0
  41. package/dist/src/templates/bootstrap.js.map +1 -0
  42. package/dist/src/tools/arxiv-download.d.ts +2 -2
  43. package/dist/src/tools/arxiv-download.d.ts.map +1 -1
  44. package/dist/src/tools/arxiv-download.js +9 -11
  45. package/dist/src/tools/arxiv-download.js.map +1 -1
  46. package/dist/src/tools/scientify-cron.d.ts +2 -0
  47. package/dist/src/tools/scientify-cron.d.ts.map +1 -1
  48. package/dist/src/tools/scientify-cron.js +33 -1
  49. package/dist/src/tools/scientify-cron.js.map +1 -1
  50. package/dist/src/tools/scientify-literature-state.d.ts +4 -0
  51. package/dist/src/tools/scientify-literature-state.d.ts.map +1 -1
  52. package/dist/src/tools/scientify-literature-state.js +45 -0
  53. package/dist/src/tools/scientify-literature-state.js.map +1 -1
  54. package/dist/src/tools/unpaywall-download.d.ts +2 -2
  55. package/dist/src/tools/unpaywall-download.js +4 -4
  56. package/dist/src/tools/unpaywall-download.js.map +1 -1
  57. package/openclaw.plugin.json +4 -2
  58. package/package.json +1 -1
  59. package/skills/idea-generation/SKILL.md +24 -29
  60. package/skills/metabolism/SKILL.md +118 -0
  61. package/skills/metabolism-init/SKILL.md +80 -0
  62. package/skills/{literature-survey → research-collect}/SKILL.md +23 -33
  63. package/skills/research-experiment/SKILL.md +1 -1
  64. package/skills/research-implement/SKILL.md +1 -1
  65. package/skills/research-pipeline/SKILL.md +6 -11
  66. package/skills/research-plan/SKILL.md +3 -3
  67. package/skills/research-review/SKILL.md +1 -1
  68. package/skills/research-subscription/SKILL.md +16 -0
  69. package/skills/research-survey/SKILL.md +6 -6
  70. package/skills/write-review-paper/SKILL.md +14 -14
  71. package/skills/_shared/workspace-spec.md +0 -164
  72. package/skills/install-scientify/SKILL.md +0 -106
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: write-review-paper
3
- description: "Use this when the user wants to write a literature review, survey paper, or thesis chapter from existing papers. Guides reading strategy, note-taking, synthesis, and academic writing. NOT for searching new papers (/literature-survey) or generating ideas (/idea-generation)."
3
+ description: "Use this when the user wants to write a literature review, survey paper, or thesis chapter from existing papers. Guides reading strategy, note-taking, synthesis, and academic writing. NOT for searching new papers (/research-collect) or generating ideas (/idea-generation)."
4
4
  metadata:
5
5
  {
6
6
  "openclaw":
@@ -16,18 +16,18 @@ metadata:
16
16
 
17
17
  Guide for writing a structured literature review or survey paper from papers you've already collected. This skill helps with reading strategy, note organization, and academic writing.
18
18
 
19
- **Workspace:** See `../_shared/workspace-spec.md` for directory structure. Outputs go to `$WORKSPACE/review/`.
19
+ **Workspace:** `$W` = working directory provided in task parameter. Outputs go to `$W/review/`.
20
20
 
21
21
  ## Prerequisites
22
22
 
23
23
  Before starting, ensure you have:
24
- 1. Papers collected in `$WORKSPACE/papers/`
25
- 2. Ideally, clustering done by `/literature-survey` in `$WORKSPACE/survey/clusters.json`
24
+ 1. Papers collected in `$W/papers/`
25
+ 2. Ideally, clustering done by `/research-collect` in `$W/survey/clusters.json`
26
26
 
27
- Check active project:
27
+ Check workspace:
28
28
  ```bash
29
- cat ~/.openclaw/workspace/projects/.active 2>/dev/null
30
- ls $WORKSPACE/papers/
29
+ ls $W/papers/
30
+ ls $W/survey/ 2>/dev/null
31
31
  ```
32
32
 
33
33
  ---
@@ -44,7 +44,7 @@ Based on clusters from survey, prioritize reading:
44
44
  | P2 (重要) | 主要方法论、重要实验结果 | 读摘要+方法+实验 |
45
45
  | P3 (参考) | 辅助材料、边缘相关 | 仅读摘要 |
46
46
 
47
- Create `$WORKSPACE/review/reading_plan.md`:
47
+ Create `$W/review/reading_plan.md`:
48
48
 
49
49
  ```markdown
50
50
  # Reading Plan
@@ -62,7 +62,7 @@ Create `$WORKSPACE/review/reading_plan.md`:
62
62
 
63
63
  ### 1.2 Reading Notes Template
64
64
 
65
- For each paper, create `$WORKSPACE/review/notes/{paper_id}.md` using template in `references/note-template.md`.
65
+ For each paper, create `$W/review/notes/{paper_id}.md` using template in `references/note-template.md`.
66
66
 
67
67
  ---
68
68
 
@@ -70,7 +70,7 @@ For each paper, create `$WORKSPACE/review/notes/{paper_id}.md` using template in
70
70
 
71
71
  ### 2.1 Build Comparison Table
72
72
 
73
- Create `$WORKSPACE/review/comparison.md`:
73
+ Create `$W/review/comparison.md`:
74
74
 
75
75
  ```markdown
76
76
  # Method Comparison
@@ -83,7 +83,7 @@ Create `$WORKSPACE/review/comparison.md`:
83
83
 
84
84
  ### 2.2 Timeline Analysis
85
85
 
86
- Create `$WORKSPACE/review/timeline.md`:
86
+ Create `$W/review/timeline.md`:
87
87
 
88
88
  ```markdown
89
89
  # Research Timeline
@@ -106,7 +106,7 @@ Create `$WORKSPACE/review/timeline.md`:
106
106
 
107
107
  ### 2.3 Taxonomy Design
108
108
 
109
- Create `$WORKSPACE/review/taxonomy.md`:
109
+ Create `$W/review/taxonomy.md`:
110
110
 
111
111
  ```markdown
112
112
  # Taxonomy of Approaches
@@ -140,7 +140,7 @@ Create `$WORKSPACE/review/taxonomy.md`:
140
140
 
141
141
  ### 3.1 Survey Paper Template
142
142
 
143
- Create `$WORKSPACE/review/draft.md` using template in `references/survey-template.md`.
143
+ Create `$W/review/draft.md` using template in `references/survey-template.md`.
144
144
 
145
145
  Key sections: Abstract → Introduction → Background → Taxonomy → Comparison → Datasets → Future Directions → Conclusion
146
146
 
@@ -198,7 +198,7 @@ For a thesis chapter:
198
198
  ## Output Files
199
199
 
200
200
  ```
201
- $WORKSPACE/review/
201
+ $W/review/
202
202
  ├── reading_plan.md # 阅读计划
203
203
  ├── notes/ # 阅读笔记
204
204
  │ ├── {paper_id}.md
@@ -1,164 +0,0 @@
1
- # Workspace Directory Specification
2
-
3
- All Scientify skills share a unified project-based workspace structure.
4
-
5
- ## Base Path
6
-
7
- ```
8
- ~/.openclaw/workspace/projects/
9
- ├── .active # Current project ID (plain text)
10
- ├── {project-id}/ # Each research topic has its own project
11
- │ └── ...
12
- └── {another-project}/
13
- ```
14
-
15
- ## Project Structure
16
-
17
- ```
18
- ~/.openclaw/workspace/projects/{project-id}/
19
- ├── project.json # Project metadata
20
- ├── task.json # Research task definition
21
-
22
- ├── survey/ # /literature-survey outputs
23
- │ ├── search_terms.json # Generated search keywords
24
- │ ├── raw_results.json # All search results
25
- │ ├── filtered_papers.json # Papers with relevance scores
26
- │ ├── clusters.json # Clustered by research direction
27
- │ └── report.md # Final survey report
28
-
29
- ├── papers/ # Downloaded paper sources
30
- │ ├── {direction-1}/ # Organized by cluster
31
- │ │ ├── paper_list.md
32
- │ │ └── {arxiv_id}/ # .tex source files
33
- │ ├── {direction-2}/
34
- │ └── uncategorized/
35
-
36
- ├── repos/ # Cloned reference repositories
37
- │ ├── {repo-name-1}/
38
- │ └── {repo-name-2}/
39
-
40
- ├── ideas/ # /idea-generation outputs
41
- │ ├── gaps.md # Identified research gaps
42
- │ ├── idea_1.md ... idea_5.md # Generated ideas
43
- │ ├── selected_idea.md # Enhanced best idea
44
- │ ├── implementation_report.md # Code mapping
45
- │ └── summary.md # Final summary
46
-
47
- ├── review/ # /write-review-paper outputs
48
- │ ├── reading_plan.md # Prioritized reading list
49
- │ ├── notes/ # Per-paper reading notes
50
- │ │ └── {paper_id}.md
51
- │ ├── comparison.md # Method comparison table
52
- │ ├── timeline.md # Research timeline
53
- │ ├── taxonomy.md # Classification system
54
- │ ├── draft.md # Survey paper draft
55
- │ └── bibliography.bib # References
56
-
57
- ├── notes/ # /research-survey: per-paper deep notes
58
- │ └── paper_{arxiv_id}.md
59
- ├── survey_res.md # /research-survey: deep analysis + method comparison
60
- ├── plan_res.md # /research-plan: 4-part implementation plan
61
- ├── project/ # /research-implement: code implementation
62
- │ ├── model/
63
- │ ├── data/
64
- │ ├── training/
65
- │ ├── testing/
66
- │ ├── utils/
67
- │ ├── run.py
68
- │ └── requirements.txt
69
- ├── ml_res.md # /research-implement: execution report with [RESULT] lines
70
- ├── iterations/ # /research-review: judge iterations
71
- │ ├── judge_v1.md
72
- │ └── judge_v2.md
73
- ├── experiment_res.md # /research-experiment: full training + ablation results
74
- └── knowledge_state/ # scheduled research state artifacts
75
- ├── knowledge/
76
- ├── paper_notes/
77
- ├── daily_changes/
78
- ├── hypotheses/
79
- ├── logs/
80
- ├── state.json
81
- └── events.jsonl
82
- ```
83
-
84
- ## Conventions
85
-
86
- ### File Existence = Step Completion
87
-
88
- Check output file before executing any step. If exists, skip.
89
-
90
- Enables:
91
- - **Crash recovery**: resume from last completed step
92
- - **Incremental progress**: rerunning skips completed work
93
- - **Transparency**: inspect progress by listing directory
94
-
95
- ### Project Metadata
96
-
97
- **project.json:**
98
- ```json
99
- {
100
- "id": "battery-rul-prediction",
101
- "name": "Battery RUL Prediction",
102
- "created": "2024-01-15T10:00:00Z",
103
- "topics": ["battery", "remaining useful life", "prediction"]
104
- }
105
- ```
106
-
107
- **task.json:**
108
- ```json
109
- {
110
- "domain": "battery health",
111
- "focus": "RUL prediction using transformer",
112
- "date_limit": "2024-01-01",
113
- "created": "2024-01-15"
114
- }
115
- ```
116
-
117
- ### Immutability
118
-
119
- Once written, do NOT modify outputs unless user explicitly asks.
120
- Exception: `project/` is mutable during implement-review-iterate loop.
121
-
122
- ### Active Project
123
-
124
- ```bash
125
- # Read active project
126
- cat ~/.openclaw/workspace/projects/.active
127
-
128
- # Set active project
129
- echo "battery-rul-prediction" > ~/.openclaw/workspace/projects/.active
130
-
131
- # Set $WORKSPACE variable
132
- WORKSPACE=~/.openclaw/workspace/projects/$(cat ~/.openclaw/workspace/projects/.active)
133
- ```
134
-
135
- ### Scheduled Subscription Storage
136
-
137
- `research-subscription` writes both global incremental state and project-level knowledge_state files.
138
-
139
- - Scheduled jobs are stored in OpenClaw cron storage.
140
- - Incremental dedupe state/logs are stored under `~/.openclaw/workspace/scientify/`:
141
- - `literature-state.json`
142
- - `literature-push-log.jsonl`
143
- - Project-level research state is stored under:
144
- - `~/.openclaw/workspace/projects/{project-id}/knowledge_state/`
145
- - Includes `knowledge/`, `paper_notes/`, `daily_changes/`, `hypotheses/`, `logs/`, `state.json`, `events.jsonl`
146
- - `paper_notes/` stores per-paper deep-reading records (domain/subdomains/cross-domain links/research goal/approach/design/contributions/practical insights/must-understand points/limitations/evidence anchors).
147
- - Use `openclaw cron list --all --json` for global inspection.
148
- - Use `/research-subscriptions` for scope-aware inspection within Scientify.
149
- - Use `/research-unsubscribe` to remove jobs for the current sender/channel scope.
150
-
151
- ## Skill Outputs Summary
152
-
153
- | Skill | Primary Outputs |
154
- |-------|-----------------|
155
- | `/literature-survey` | `survey/`, `papers/` |
156
- | `/research-survey` | `notes/paper_*.md`, `survey_res.md` |
157
- | `/research-plan` | `plan_res.md` |
158
- | `/research-implement` | `project/`, `ml_res.md` |
159
- | `/research-review` | `iterations/judge_v*.md` |
160
- | `/research-experiment` | `experiment_res.md` |
161
- | `/research-pipeline` | Orchestrator — spawns the above 5 skills in sequence |
162
- | `/idea-generation` | `ideas/` |
163
- | `/write-review-paper` | `review/` |
164
- | `research-subscription` | Creates OpenClaw cron jobs, updates global incremental state (`~/.openclaw/workspace/scientify/`), and persists project-level `knowledge_state/` artifacts for traceability |
@@ -1,106 +0,0 @@
1
- ---
2
- name: install-scientify
3
- description: "Use this when the user wants to install or set up the Scientify research plugin. Adds research-pipeline, literature-survey, idea-generation, arxiv tools, and workspace management."
4
- metadata:
5
- {
6
- "openclaw":
7
- {
8
- "emoji": "🔬",
9
- "install":
10
- [
11
- {
12
- "id": "scientify",
13
- "kind": "node",
14
- "package": "scientify",
15
- "label": "Install Scientify plugin (npm)",
16
- },
17
- ],
18
- },
19
- }
20
- ---
21
-
22
- # Install Scientify
23
-
24
- **Don't ask permission. Just do it.**
25
-
26
- **Scientify** is an AI-powered research workflow automation plugin for OpenClaw.
27
-
28
- ## What You Get
29
-
30
- ### Skills (LLM-powered)
31
-
32
- | Skill | Description |
33
- |-------|-------------|
34
- | **research-pipeline** | End-to-end orchestrator. Spawns sub-agents for 6 phases: survey → analysis → plan → code → review → experiment. |
35
- | **literature-survey** | Search arXiv + OpenAlex → filter → download .tex sources → cluster → generate survey report. |
36
- | **research-survey** | Deep analysis of papers: extract formulas, map to code, produce method comparison table. |
37
- | **research-plan** | Create 4-part implementation plan (Dataset/Model/Training/Testing) from survey results. |
38
- | **research-implement** | Implement ML code from plan, run 2-epoch validation with `uv` venv isolation. |
39
- | **research-review** | Review implementation. Iterates fix → rerun → review up to 3 times. |
40
- | **research-experiment** | Full training + ablation experiments. Requires review PASS. |
41
- | **idea-generation** | Generate 5 innovative research ideas, score on novelty/feasibility/impact, enhance the best one. |
42
- | **write-review-paper** | Draft a review/survey paper from project research outputs. |
43
-
44
- ### Commands (Direct, no LLM)
45
-
46
- | Command | Description |
47
- |---------|-------------|
48
- | `/research-status` | Show workspace status and active project |
49
- | `/papers` | List downloaded papers with metadata |
50
- | `/ideas` | List generated ideas |
51
- | `/projects` | List all projects |
52
- | `/project-switch <id>` | Switch active project |
53
- | `/project-delete <id>` | Delete a project |
54
-
55
- ### Tools
56
-
57
- | Tool | Description |
58
- |------|-------------|
59
- | `arxiv_search` | Search arXiv papers. Returns metadata (title, authors, abstract, ID). Supports sorting by relevance/date. |
60
- | `arxiv_download` | Batch download papers by arXiv ID. Prefers .tex source (PDF fallback). |
61
- | `openalex_search` | Search cross-disciplinary papers via OpenAlex API. Returns DOI, authors, citation count, OA status. |
62
- | `unpaywall_download` | Download open access PDFs by DOI via Unpaywall. Non-OA papers silently skipped. |
63
- | `github_search` | Search GitHub repositories. Returns name, description, stars, URL. Supports language filtering. |
64
- | `paper_browser` | Paginated browsing of large paper files (.tex/.md) to avoid context overflow. |
65
-
66
- ## Installation
67
-
68
- ```bash
69
- openclaw plugins install scientify
70
- ```
71
-
72
- Or let OpenClaw install it automatically when you use this skill.
73
-
74
- > **Note:** Do NOT use `npm install scientify`. OpenClaw plugins must be installed via `openclaw plugins install` to be properly discovered.
75
-
76
- ## Usage Examples
77
-
78
- ### End-to-End Research
79
-
80
- ```
81
- Research scaling laws for classical ML classifiers on Fashion-MNIST
82
- ```
83
-
84
- ### Generate Research Ideas
85
-
86
- ```
87
- Explore recent advances in protein folding and generate innovative research ideas
88
- ```
89
-
90
- ### Literature Survey Only
91
-
92
- ```
93
- Survey the latest papers on vision-language models for medical imaging
94
- ```
95
-
96
- ### Check Workspace
97
-
98
- ```
99
- /research-status
100
- ```
101
-
102
- ## Links
103
-
104
- - npm: https://www.npmjs.com/package/scientify
105
- - GitHub: https://github.com/tsingyuai/scientify
106
- - Author: tsingyuai