@thuanphan2208/paper-pilot 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.
@@ -0,0 +1,125 @@
1
+ ---
2
+ name: paper-write-method
3
+ description: Write a draft Methodology section for a research paper via guided Q&A. Works across all academic majors and paper types. Use after completing paper:teach-method.
4
+ license: MIT
5
+ metadata:
6
+ author: claude-paper-skills
7
+ version: "2.0"
8
+ ---
9
+
10
+ You are helping a student write their **Methodology** section. Read context, conduct Q&A, then write a draft tailored to the paper type.
11
+
12
+ **English only** — Respond in English regardless of what language the user writes in.
13
+
14
+ ---
15
+
16
+ ## Step 1: Read Context
17
+
18
+ Check `paper/context.yaml`. If missing, ask the user to run `/paper:plan` first. Use `paper_type` and `contribution_type` to determine which Q&A path to follow.
19
+
20
+ **Format**: Read `writing_format` from context.yaml and apply throughout the draft:
21
+ - `latex` → use `\section{}`, `\subsection{}`, `\cite{ref}`, math in `$...$` or `\begin{equation}`, pseudocode in `algorithm` environment
22
+ - `word` → plain text with labelled headings, no LaTeX commands
23
+ - `markdown` → use `##`, `**bold**`, code blocks for pseudocode
24
+
25
+ - **empirical / new-method** → System design, components, algorithm
26
+ - **review** → Search strategy, inclusion/exclusion criteria, screening process
27
+ - **theoretical** → Framework components, theoretical grounding, application example
28
+
29
+ ---
30
+
31
+ ## Step 2: Q&A (one at a time, wait for each answer)
32
+
33
+ ### If empirical / new-method:
34
+
35
+ Tell the user: "I'll ask about your system or method so I can write the Methodology. More detail = more reproducible draft."
36
+
37
+ **Q1**: "Describe your system or method step by step. What is the input? What is the output? What happens in between?"
38
+ *(Example: "Input: a URL string. Step 1: extract 48 features. Step 2: pass to Random Forest classifier. Output: phishing/legitimate label + confidence score.")*
39
+
40
+ **Q2**: "How many main components or modules does your system have? What does each one do?"
41
+ *(Example: "3 components — Feature Extractor (parses URL and HTML), Classifier (Random Forest), Decision Engine (applies 0.5 threshold to confidence score).")*
42
+
43
+ **Q3**: "What algorithm, model, or technique do you use? With what configuration or parameters?"
44
+ *(Example: "Random Forest: 100 trees, max depth 10, min samples per leaf 5. Hyperparameters chosen via 5-fold cross-validation.")*
45
+
46
+ **Q4**: "Why did you choose this method/algorithm over alternatives?"
47
+ *(Example: "Random Forest over SVM because it handles non-linear interactions and provides feature importance scores, which we use for our weighting mechanism.")*
48
+
49
+ **Q5**: "Are there any formulas, pseudocode, or special technical details that need to be described?"
50
+ *(Example: "Yes — the feature weighting formula: w_i = importance_i / Σimportance. Also pseudocode for the prediction pipeline.")*
51
+
52
+ ---
53
+
54
+ ### If review:
55
+
56
+ **Q1**: "Which databases or sources did you search? (e.g., Google Scholar, Scopus, PubMed, IEEE Xplore)"
57
+
58
+ **Q2**: "What keywords or search terms did you use?"
59
+
60
+ **Q3**: "What were your inclusion and exclusion criteria? What made a paper qualify for review?"
61
+
62
+ **Q4**: "How many papers did your search return initially? How many did you end up including after screening?"
63
+
64
+ ---
65
+
66
+ ### If theoretical / framework:
67
+
68
+ **Q1**: "What existing theory, model, or principles does your framework build on?"
69
+
70
+ **Q2**: "What are the main components or dimensions of your framework? How do they relate to each other?"
71
+
72
+ **Q3**: "How would someone apply your framework? Walk me through an example."
73
+
74
+ ---
75
+
76
+ ## Step 3: Write Draft
77
+
78
+ ### If empirical / new-method:
79
+
80
+ **Opening overview paragraph:**
81
+ "Figure X illustrates the overall architecture of [system name]. Given [input] as input, the system performs [N] sequential steps: (1) [step 1], (2) [step 2], ..., producing [output] as output."
82
+
83
+ **Subsection per component:**
84
+ ```
85
+ 3.1 [Component Name]
86
+ Describe what it does, how it works, key parameters.
87
+ Justify choices: "We employ X because Y."
88
+ ```
89
+
90
+ **Algorithm / model:**
91
+ - Existing algorithm: cite it and describe your configuration.
92
+ - Novel algorithm: write numbered pseudocode steps.
93
+
94
+ ---
95
+
96
+ ### If review:
97
+
98
+ **Search Strategy:**
99
+ "We searched [databases] using the keywords [terms] for papers published between [years]. We included [criteria]. We excluded [criteria]."
100
+
101
+ **Screening:**
102
+ "An initial search returned [N] papers. After title and abstract screening, [N] papers remained. After full-text review, [N] papers were included for analysis."
103
+
104
+ ---
105
+
106
+ ### If theoretical:
107
+
108
+ **Theoretical grounding:**
109
+ "Our framework builds on [theory] [cite], which proposes [key idea]. We extend this to [domain] by [what you add or modify]."
110
+
111
+ **Framework components:**
112
+ Define each component clearly with a diagram description if applicable.
113
+
114
+ **Application example:**
115
+ Walk through how the framework applies to a concrete case.
116
+
117
+ ---
118
+
119
+ ## Step 4: Save and Recommend
120
+
121
+ Ask: "Shall I save this draft to `paper/sections/03-methodology.md`?"
122
+
123
+ Save and update context.yaml: `methodology: draft`.
124
+
125
+ "Draft saved! Continue with `/paper:teach experiment` or review this section with `/paper:review method`."
@@ -0,0 +1,74 @@
1
+ ---
2
+ name: paper-write-related
3
+ description: Write a draft Related Work section for a research paper via guided Q&A. Works across all academic majors. Use after completing paper:teach-related.
4
+ license: MIT
5
+ metadata:
6
+ author: claude-paper-skills
7
+ version: "2.0"
8
+ ---
9
+
10
+ You are helping a student write their **Related Work** section. Read context, conduct Q&A about papers they've read, then write a thematically organized draft.
11
+
12
+ **English only** — Respond in English regardless of what language the user writes in.
13
+
14
+ ---
15
+
16
+ ## Step 1: Read Context
17
+
18
+ Check `paper/context.yaml`. If missing, ask the user to run `/paper:plan` first. Use the topic and field to understand what kind of related work to expect.
19
+
20
+ **Format**: Read `writing_format` from context.yaml and apply throughout the draft:
21
+ - `latex` → use `\section{}`, `\subsection{}`, `\cite{ref}`, `\textbf{}`
22
+ - `word` → plain text with labelled headings, no LaTeX commands
23
+ - `markdown` → use `##`, `**bold**`, `-` for bullets
24
+
25
+ ---
26
+
27
+ ## Step 2: Q&A (one at a time, wait for each answer)
28
+
29
+ Tell the user: "I need to know about the papers you've read to write your Related Work. Answer as best you can — if you haven't read many papers yet, I'll help you think through what to look for."
30
+
31
+ **Q1**: "List 5–10 related papers you've read or know of. Format: [Author(s), year — brief description or method name]"
32
+ *(Example: "Zhang et al. 2020 — SVM with URL features; Google Safe Browsing 2022 — blacklist API; Li et al. 2021 — LSTM on HTML content")*
33
+ *(If few papers: "Search Google Scholar for '[your topic] survey' or '[your topic] review' filtered to last 5 years. Aim for at least 8 papers.")*
34
+
35
+ **Q2**: "How would you group those papers into 2–3 themes or categories? What patterns do you see?"
36
+ *(Example: "Group 1: blacklist-based — PhishTank, Safe Browsing. Group 2: ML with URL features — Zhang, Li, Kim. Group 3: deep learning on page content — Chen, Wang.")*
37
+ *(If stuck: "Look at the method each paper uses. Papers using similar methods belong in the same group.")*
38
+
39
+ **Q3**: "What are the main limitations of existing approaches in your area? Why don't they fully solve your problem?"
40
+ *(Example: "Blacklist methods are too slow — update takes hours. ML methods use static feature sets that don't adapt to new attack patterns. Deep learning is too slow for real-time use.")*
41
+
42
+ **Q4**: "What makes your approach different from the prior work you've reviewed?"
43
+ *(Example: "Unlike prior ML approaches that use fixed features, we dynamically weight features by predictive power. Also the first study specifically on Vietnamese phishing campaigns.")*
44
+
45
+ ---
46
+
47
+ ## Step 3: Write Draft
48
+
49
+ Structure the Related Work with 3 moves:
50
+
51
+ **Opening sentence:**
52
+ "Prior work on [topic] can be broadly categorized into [N] approaches: [theme 1], [theme 2], [and theme 3]."
53
+
54
+ **For each theme (1–2 paragraphs):**
55
+ - Name the approach and group the relevant papers together
56
+ - Describe what they do at a general level
57
+ - Critique their limitations using transition language:
58
+ - "While [these methods] achieve [result], they [limitation] because [reason]."
59
+ - "A common limitation of [theme] is [issue], which [consequence]."
60
+
61
+ **Positioning paragraph (end of section):**
62
+ "Unlike [prior approaches], our work [differentiator]. To the best of our knowledge, this is the first work to [novelty claim if applicable]."
63
+
64
+ Adapt tone and framing to the user's field. In social sciences or humanities, positioning may be more about theoretical lens than technical novelty.
65
+
66
+ ---
67
+
68
+ ## Step 4: Save and Recommend
69
+
70
+ Ask: "Shall I save this draft to `paper/sections/02-related-work.md`?"
71
+
72
+ If yes, save and update context.yaml: `related_work: draft`.
73
+
74
+ "Draft saved! Continue with `/paper:teach method` or review this section with `/paper:review related`."
@@ -0,0 +1,131 @@
1
+ ---
2
+ name: paper-write-results
3
+ description: Write a draft Results section for a research paper via guided Q&A. Works across all academic majors and paper types. Use after completing paper:teach-results.
4
+ license: MIT
5
+ metadata:
6
+ author: claude-paper-skills
7
+ version: "2.0"
8
+ ---
9
+
10
+ You are helping a student write their **Results** section. Push the user to go beyond reporting numbers — analysis and interpretation are what make results compelling.
11
+
12
+ **English only** — Respond in English regardless of what language the user writes in.
13
+
14
+ ---
15
+
16
+ ## Step 1: Read Context
17
+
18
+ Check `paper/context.yaml`. Use `paper_type` to determine the right approach.
19
+
20
+ **Format**: Read `writing_format` from context.yaml and apply throughout the draft:
21
+ - `latex` → use `\section{}`, `\subsection{}`, tables in `tabular`, bold with `\textbf{}`, `\cite{ref}`
22
+ - `word` → plain text with labelled headings, ASCII tables or described table structure
23
+ - `markdown` → use `##`, tables in Markdown pipe syntax, `**bold**`
24
+
25
+ - **empirical / new-method** → Comparison table + analysis + ablation
26
+ - **review** → Synthesis of findings + taxonomy + open challenges
27
+ - **theoretical** → Framework validation, case application, discussion of implications
28
+
29
+ Also check if `paper/sections/04-experiments.md` exists — read it if available to understand baselines and metrics already defined.
30
+
31
+ ---
32
+
33
+ ## Step 2: Q&A (one at a time, wait for each answer)
34
+
35
+ ### If empirical / new-method:
36
+
37
+ Tell the user: "I need your experimental results to write this section."
38
+
39
+ **Q1**: "What are your main results? List performance numbers for your method and all baselines across each metric."
40
+ *(Example: "PhishGuard: Acc=97.4%, P=97.1%, R=97.7%, F1=97.4%. SVM-URL: Acc=92.1%, F1=92.1%. PhishTank blacklist: Acc=78.3%, F1=76.2%.")*
41
+ *(If results are worse than baselines: "Share the numbers honestly — we'll handle how to write about it.")*
42
+
43
+ **Q2**: "Does your method outperform the baselines? By how much on the primary metric?"
44
+ *(Example: "Yes — beats SVM-URL by 5.3% F1, and blacklist by 21.2%.")*
45
+ *(If no: "By how much does it fall short? On which metric? Does it win on any specific metric or subset?")*
46
+
47
+ **Q3**: "Why do you think your method performs better? What design decision drives that improvement?"
48
+ *(Example: "The feature weighting mechanism — it assigns more importance to discriminative features like URL length, reducing noise from weaker signals.")*
49
+ *(If unsure: "Look at your ablation results — which component removal caused the biggest performance drop?")*
50
+
51
+ **Q4**: "Were there any surprising findings — a baseline that performed unexpectedly, or a metric that diverged from expectations?"
52
+ *(Example: "PhishGuard-NoWeight beat SVM-URL even without feature weighting — suggesting Random Forest's ensemble nature itself provides robustness.")*
53
+
54
+ **Q5**: "Do you have ablation study results? (performance when each component is removed)"
55
+ *(Example: "Yes — removing URL features drops F1 by 8.2%; domain features by 3.3%; HTML features by 1.2%.")*
56
+ *(If no ablation: "That's fine — we'll note it as a limitation of the study.")*
57
+
58
+ ---
59
+
60
+ ### If review:
61
+
62
+ **Q1**: "What are the main patterns or trends you found across the reviewed literature?"
63
+
64
+ **Q2**: "Were there consistent findings across papers, or significant disagreements?"
65
+
66
+ **Q3**: "What gaps or open challenges did the literature reveal?"
67
+
68
+ ---
69
+
70
+ ### If theoretical:
71
+
72
+ **Q1**: "How did you validate or demonstrate your framework? What case or example did you use?"
73
+
74
+ **Q2**: "What did the framework reveal or explain that prior work could not?"
75
+
76
+ ---
77
+
78
+ ## Step 3: Write Draft
79
+
80
+ ### If empirical / new-method:
81
+
82
+ **[Section N].1 Main Results**
83
+
84
+ Format a comparison table:
85
+ ```
86
+ Table 1: [Metric] comparison on [dataset]
87
+
88
+ Method [Metric 1] [Metric 2] [Metric 3]
89
+ ──────────────────────────────────────────────────────────
90
+ [Baseline 1] X% X% X%
91
+ [Baseline 2] X% X% X%
92
+ [Your method] **X%** **X%** **X%**
93
+ ──────────────────────────────────────────────────────────
94
+ Bold = best result
95
+ ```
96
+
97
+ Analysis paragraph (2–3 sentences — NOT just restating numbers):
98
+ "[Your method] achieves [best metric], outperforming [best baseline] by [X] points. This improvement can be attributed to [reason from Q3]. Notably, [any surprising finding from Q4]."
99
+
100
+ **[Section N].2 Ablation Study** (if the user has data):
101
+ Table with each component removed + performance delta.
102
+ "The ablation results confirm that [most impactful component] contributes most significantly, with a [X%] drop when removed."
103
+
104
+ **[Section N].3 Discussion** (optional):
105
+ Broader interpretation — what do these results mean for the field? Any limitations of the results themselves?
106
+
107
+ ---
108
+
109
+ ### If review:
110
+
111
+ **Synthesis:**
112
+ Write thematic paragraphs summarizing what the literature found across each category. Highlight agreements, disagreements, and evolving trends.
113
+
114
+ **Open Challenges:**
115
+ "Despite [progress], several challenges remain unaddressed: [challenge 1], [challenge 2], [challenge 3]."
116
+
117
+ ---
118
+
119
+ ### If theoretical:
120
+
121
+ Describe how the framework was applied, what it revealed, and how it compares to prior conceptualizations.
122
+
123
+ ---
124
+
125
+ ## Step 4: Save and Recommend
126
+
127
+ Ask: "Shall I save this draft to `paper/sections/05-results.md`?"
128
+
129
+ Save and update context.yaml: `results: draft`.
130
+
131
+ "Draft saved! Continue with `/paper:teach conclusion` or review this section with `/paper:review results`."
package/README.md ADDED
@@ -0,0 +1,2 @@
1
+ # Claude_Skills-for-Research
2
+ A collection of Claude Code skills for writing CS/IT research papers — from brainstorming to draft. Includes teach + write skills for every section (Introduction, Related Work, Methodology, Experiments, Results, Conclusion, Abstract), with a complete phishing detection demo paper.
package/bin/cli.js ADDED
@@ -0,0 +1,46 @@
1
+ #!/usr/bin/env node
2
+ 'use strict';
3
+
4
+ const { init } = require('../src/init');
5
+
6
+ const args = process.argv.slice(2);
7
+ const command = args[0];
8
+ const flags = args.slice(1);
9
+ const dryRun = flags.includes('--dry-run');
10
+
11
+ const BOLD = '\x1b[1m';
12
+ const RESET = '\x1b[0m';
13
+
14
+ switch (command) {
15
+ case 'init':
16
+ init({ dryRun });
17
+ break;
18
+
19
+ case '--version':
20
+ case '-v': {
21
+ const pkg = require('../package.json');
22
+ console.log(pkg.version);
23
+ break;
24
+ }
25
+
26
+ case '--help':
27
+ case '-h':
28
+ case undefined:
29
+ console.log(`
30
+ ${BOLD}paper-pilot${RESET} — Install Claude Code paper-writing skills into your project
31
+
32
+ Usage:
33
+ npx paper-pilot init Install skills into current directory
34
+ npx paper-pilot init --dry-run Preview what would be installed
35
+ npx paper-pilot --version Show version
36
+ npx paper-pilot --help Show this help
37
+
38
+ After init, open Claude Code and run /paper:explore to get started.
39
+ `);
40
+ break;
41
+
42
+ default:
43
+ console.error(`Unknown command: ${command}`);
44
+ console.error('Run "npx paper-pilot --help" for usage.');
45
+ process.exit(1);
46
+ }
package/package.json ADDED
@@ -0,0 +1,29 @@
1
+ {
2
+ "name": "@thuanphan2208/paper-pilot",
3
+ "version": "1.0.0",
4
+ "description": "Install Claude Code paper-writing skills into any project with one command.",
5
+ "keywords": ["claude", "claude-code", "research", "paper", "skills", "academic"],
6
+ "homepage": "https://github.com/ThuanPne/Claude_Skills-for-Research",
7
+ "repository": {
8
+ "type": "git",
9
+ "url": "https://github.com/ThuanPne/Claude_Skills-for-Research.git"
10
+ },
11
+ "license": "MIT",
12
+ "bin": {
13
+ "paper-pilot": "./bin/cli.js"
14
+ },
15
+ "files": [
16
+ "bin/",
17
+ "src/",
18
+ ".claude/"
19
+ ],
20
+ "scripts": {
21
+ "test": "node bin/cli.js init --dry-run"
22
+ },
23
+ "engines": {
24
+ "node": ">=18.0.0"
25
+ },
26
+ "publishConfig": {
27
+ "access": "public"
28
+ }
29
+ }
package/src/init.js ADDED
@@ -0,0 +1,111 @@
1
+ const fs = require('fs');
2
+ const path = require('path');
3
+
4
+ const GREEN = '\x1b[32m';
5
+ const YELLOW = '\x1b[33m';
6
+ const CYAN = '\x1b[36m';
7
+ const BOLD = '\x1b[1m';
8
+ const RESET = '\x1b[0m';
9
+
10
+ function log(msg) { process.stdout.write(msg + '\n'); }
11
+ function success(msg) { log(`${GREEN}✓${RESET} ${msg}`); }
12
+ function skip(msg) { log(`${YELLOW}─${RESET} ${msg} (already exists, skipped)`); }
13
+ function info(msg) { log(`${CYAN} ${msg}${RESET}`); }
14
+
15
+ function copyDirMerge(src, dest, dryRun = false) {
16
+ const entries = fs.readdirSync(src, { withFileTypes: true });
17
+ let copied = 0;
18
+ let skipped = 0;
19
+
20
+ for (const entry of entries) {
21
+ const srcPath = path.join(src, entry.name);
22
+ const destPath = path.join(dest, entry.name);
23
+
24
+ if (entry.isDirectory()) {
25
+ if (!dryRun && !fs.existsSync(destPath)) {
26
+ fs.mkdirSync(destPath, { recursive: true });
27
+ }
28
+ const result = copyDirMerge(srcPath, destPath, dryRun);
29
+ copied += result.copied;
30
+ skipped += result.skipped;
31
+ } else {
32
+ if (fs.existsSync(destPath)) {
33
+ skip(path.relative(process.cwd(), destPath));
34
+ skipped++;
35
+ } else {
36
+ if (!dryRun) {
37
+ fs.mkdirSync(dest, { recursive: true });
38
+ fs.copyFileSync(srcPath, destPath);
39
+ }
40
+ success(path.relative(process.cwd(), destPath));
41
+ copied++;
42
+ }
43
+ }
44
+ }
45
+
46
+ return { copied, skipped };
47
+ }
48
+
49
+ function ensureDir(dirPath, dryRun = false) {
50
+ if (fs.existsSync(dirPath)) {
51
+ skip(path.relative(process.cwd(), dirPath) + '/');
52
+ } else {
53
+ if (!dryRun) fs.mkdirSync(dirPath, { recursive: true });
54
+ success(path.relative(process.cwd(), dirPath) + '/');
55
+ }
56
+ }
57
+
58
+ function init({ dryRun = false } = {}) {
59
+ const packageRoot = path.join(__dirname, '..');
60
+ const destRoot = process.cwd();
61
+
62
+ log('');
63
+ log(`${BOLD}paper-pilot init${RESET}${dryRun ? ' (dry run)' : ''}`);
64
+ log('─'.repeat(50));
65
+
66
+ // 1. Copy .claude/ (skills + commands)
67
+ const claudeSrc = path.join(packageRoot, '.claude');
68
+ const claudeDest = path.join(destRoot, '.claude');
69
+
70
+ if (!fs.existsSync(claudeSrc)) {
71
+ log(`\x1b[31mError: .claude/ not found in package. Reinstall paper-pilot.\x1b[0m`);
72
+ process.exit(1);
73
+ }
74
+
75
+ log(`\nInstalling skills into ${CYAN}.claude/${RESET}`);
76
+ const { copied, skipped } = copyDirMerge(claudeSrc, claudeDest, dryRun);
77
+
78
+ // 2. Create paper/sections/ directory
79
+ log(`\nCreating paper workspace`);
80
+ ensureDir(path.join(destRoot, 'paper'), dryRun);
81
+ ensureDir(path.join(destRoot, 'paper', 'sections'), dryRun);
82
+
83
+ // 3. Create paper/notes/.gitkeep if not present
84
+ const notesDir = path.join(destRoot, 'paper', 'notes');
85
+ const notesKeep = path.join(notesDir, '.gitkeep');
86
+ if (!fs.existsSync(notesKeep)) {
87
+ if (!dryRun) {
88
+ fs.mkdirSync(notesDir, { recursive: true });
89
+ fs.writeFileSync(notesKeep, '');
90
+ }
91
+ success('paper/notes/');
92
+ } else {
93
+ skip('paper/notes/');
94
+ }
95
+
96
+ // 4. Summary
97
+ log('');
98
+ log('─'.repeat(50));
99
+ log(`${copied} file(s) installed, ${skipped} skipped`);
100
+ log('');
101
+ log(`${BOLD}You're ready! Open Claude Code and run:${RESET}`);
102
+ log('');
103
+ info('/paper:explore ← find your research topic');
104
+ info('/paper:plan ← plan your paper structure');
105
+ info('/paper:teach ← learn how to write each section');
106
+ info('/paper:write ← draft each section with AI guidance');
107
+ info('/paper:review ← get feedback on your drafts');
108
+ log('');
109
+ }
110
+
111
+ module.exports = { init };