Agentic AI Tools
Claude Code Setup Guide
Claude Code helps researchers manage files, run analyses, and automate repeatable project tasks from the terminal.
Intermediate · 45–60 min · Node.js 18+ and terminal access
Your research project lives in files. This agent lives in the terminal alongside them.
Overview
Claude Code is an agentic AI assistant that runs in your terminal. It helps researchers manage literature, analyze papers, draft sections, organize complex projects, and run project workflows through natural-language commands. Unlike traditional chat interfaces, it can read files, create folders, run analyses, and manage workflows.
Benefits for Research Memex:
- File-aware AI: Reference papers with @filename syntax
- Project memory: CLAUDE.md stores your research protocol
- Custom commands: Create slash commands for repetitive tasks
- MCP integration: Connect to Zotero, filesystems, web search
- Autonomous execution: Plan and execute multi-step workflows
- Version control: Built-in Git integration
Step 1: installation
1.1 prerequisites
System requirements:
- Node.js 18 or newer
- Terminal/command-line access
- Claude.ai account or API key
Check Node.js version:
node --versionIf you need to install Node.js, download from the Node.js website
1.2 install Claude Code
Via npm (Terminal):
npm install -g @anthropic-ai/claude-codeVerify installation:
claude --versionFirst launch:
cd ~/your-research-project
claude1.3 alternative: VS Code extension
For users who prefer a graphical interface:
- Open VS Code.
- Install the Claude Code extension from the marketplace.
- Configure your API key in the extension settings.
- Access Claude Code from the sidebar.
Step 2: core concepts
2.1 what is CLAUDE.md?
Claude automatically reads CLAUDE.md at the start of every conversation. It acts as your project's memory or constitution.
What to put in CLAUDE.md:
- Project overview and goals
- File structure explanation
- Research protocol or methodology
- Custom commands you've created
- Style guidelines (citation format, writing tone)
- Important context Claude should always know
Example CLAUDE.md for a research project:
# Research Project: AI in Education
## Project Goal
Analyze the impact of AI tools on student learning outcomes through
literature synthesis and empirical analysis.
## File Structure
- /literature/ - Curated papers in markdown format
- /analysis/ - Data files and R scripts
- /drafts/ - Paper sections and outlines
- /exports/ - Final outputs (PDF, Word)
## Research Protocol
- Citation style: APA 7th Edition
- Inclusion criteria: Peer-reviewed, 2020-2025, empirical studies
- Analysis approach: Thematic synthesis
## Custom Commands
- /summarize: Create structured summary of a paper
- /compare: Compare methodologies across papers
- /synthesize: Identify themes across multiple papersOfficial guide: CLAUDE.md Best Practices
2.2 plan mode vs act mode
Plan Mode (default - recommended):
- Claude shows you what it will do before it executes
- You approve/reject each action
- Useful for learning and complex operations
- Toggle:
Shift+Tab(Mac/Linux) orAlt+M(Windows)
Act Mode:
- Claude executes immediately
- Faster for trusted operations
- Use for simple tasks (reading files, searches)
Warning
Stay in Plan Mode when working with research data. Preview operations before they modify your files.
2.3 file references with @ syntax
Add files to context:
"Summarize the key arguments in @/literature/smith2024.md"
"Compare the methodologies in @/literature/jones2024.md
and @/literature/lee2024.md"
"Analyze all papers in @/literature/ and identify common themes"Folder references:
@/literature/- Adds entire folder to context@CLAUDE.md- Always available as project memory
Step 3: creating custom slash commands
3.1 what are slash commands?
Slash commands are reusable prompt templates you create once and run with /commandname. Use them for repetitive research tasks.
Examples for research:
/summarize- Structured paper summary/compare- Compare two papers/extract- Pull out specific information/critique- Review writing for quality
3.2 create your first command
Step 1: create the commands folder
mkdir -p .claude/commandsStep 2: create a command file
Create .claude/commands/summarize.md:
Summarize the following paper in this exact structure:
Paper: $ARGUMENTS
## Summary Template
- **Research Question**: [What problem does it address?]
- **Methodology**: [How did they study it?]
- **Key Findings**: [What did they discover?]
- **Theoretical Contribution**: [What does it add to knowledge?]
- **Limitations**: [What are the gaps?]
- **Relevance**: [How does this relate to my research?]
Be specific and cite page numbers where relevant.Step 3: use your command
claude # Launch Claude CodeThen type:
/summarize @/literature/smith2024.mdClaude executes the template, replacing $ARGUMENTS with whatever follows the slash command so the command stays flexible and reusable.
3.3 useful research commands
Create .claude/commands/compare.md:
Compare these two papers systematically:
Papers: $ARGUMENTS
## Comparison Framework
1. **Research Questions**: How do they differ?
2. **Methodologies**: Qualitative vs quantitative? Samples?
3. **Findings**: Do they agree or contradict?
4. **Theories**: What frameworks do they use?
5. **Gaps**: What does each paper miss that the other addresses?
Present in a comparison table.Create .claude/commands/gaps.md:
Analyze the following papers for research gaps:
Papers: $ARGUMENTS
## Gap Analysis
1. **Methodological Gaps**: What methods are missing?
2. **Theoretical Gaps**: What theories are underexplored?
3. **Empirical Gaps**: What contexts are understudied?
4. **Temporal Gaps**: What recent developments aren't covered?
For each gap, explain why it matters and what research it suggests.Step 4: MCP servers for research
MCP (Model Context Protocol) servers add specialized tools to Claude Code.
4.1 essential MCP servers for research
Zotero MCP:
- Search your Zotero library from terminal
- Get paper metadata instantly
- Installation: See Zotero Setup Guide
Filesystem MCP:
- Already built-in to Claude Code
- Navigate and search project files
- Create and modify documents
Sequential Thinking MCP:
- Step-by-step reasoning for complex analysis
- Useful for theoretical arguments
- Install: Smithery - Sequential Thinking
Web Search MCP:
- Real-time literature discovery
- Verify recent developments
- Fact-checking and citation validation
4.2 installing MCP servers
Via Smithery:
- Visit smithery.ai.
- Search for the MCP server you want.
- Click Install.
- Follow the guided setup.
- Restart Claude Code.
Manual configuration:
Edit ~/.config/claude-code/config.json to add MCP servers. For end-to-end installation guidance, see the MCP Explorer Guide.
Step 5: project structure for research
5.1 recommended folder structure
General research project:
/Your-Research-Project/
├── CLAUDE.md # Project memory
├── .claude/
│ └── commands/ # Custom slash commands
├── literature/ # Curated papers (markdown)
├── analysis/ # Data, scripts, results
├── notes/ # Research notes, synthesis
├── drafts/ # Paper sections
└── exports/ # Final outputs5.2 setting up a new project
Option 1: ask Claude to do it
Create a research project structure with folders for literature,
analysis, notes, drafts, and exports. Then create a CLAUDE.md file
documenting this project structure.Option 2: manual setup
mkdir -p literature analysis notes drafts exports .claude/commands
touch CLAUDE.md
claudeStep 6: common research workflows
6.1 literature analysis
Analyze a single paper:
Read @/literature/smith2024.md and create a structured summary
following the format in CLAUDE.mdCompare multiple papers:
Compare the methodologies in @/literature/smith2024.md,
@/literature/jones2024.md, and @/literature/lee2024.md.
Create a comparison table.Find themes across corpus:
Analyze all papers in @/literature/ and identify the 3 most
common themes. For each theme, list which papers discuss it
and how their perspectives differ.6.2 data management
Organize files:
Review all files in @/literature/ and organize them into
subfolders by research method (qualitative, quantitative, mixed-methods)Create synthesis tables:
Extract the following from each paper in @/literature/:
author, year, method, sample size, key finding.
Create a CSV table with this data.6.3 drafting and writing
Generate section outlines:
Based on the papers in @/literature/, create an outline for
a literature review section covering theoretical frameworks.Draft from synthesis:
Using the synthesis notes in @/notes/themes.md, draft a
2-page literature review section in academic style (APA 7th).Step 7: keyboard shortcuts & navigation
7.1 essential shortcuts
| Shortcut | Action |
|---|---|
Shift+Tab | Toggle Plan/Act mode (Mac/Linux) |
Alt+M | Toggle Plan/Act mode (Windows) |
Esc Esc | Navigate command history (double-tap) |
Ctrl+C | Cancel current operation |
Ctrl+D | Exit Claude Code |
7.2 command history
Double-tap Esc to jump back through previous commands:
- Modify and re-run analyses
- Fix typos without retyping
- Compare different approaches quickly
Step 8: learning resources
8.1 official documentation
- Claude Code Overview - Official intro
- Best Practices Guide - CLAUDE.md tips
- GitHub Repository - Source code and issues
- Latest Updates - New features
8.2 video tutorials
Beginner series:
- SeanMatthewAI YouTube Series - Claude Code essentials
- Claude Code Beginners Guide 2025 - Comprehensive walkthrough
Hands-on tutorials:
- Build a YouTube Research Agent - Slash commands in action
- Cooking with Claude Code - Complete app build
8.3 online courses
- DeepLearning.AI: Claude Code - Comprehensive course
- Anthropic Training - Official certification
- DataCamp Tutorial - Practical examples
8.4 blog posts and guides
- How I Use Claude Code - Pro tips from Builder.io
- No-BS Quick Start Guide - July 2025 guide
- ClaudeLog - Best practices collection
Step 9: integration with Research Memex
9.1 connect to Zotero
Set up Zotero MCP:
- Follow the Zotero Setup Guide.
- Install the Zotero MCP server.
- Start a new Claude Code session, or restart Claude Code if it was already open, then run
/mcpand confirmzoterois connected.
In Claude Code, search your library with natural language. Example: "Search my Zotero for papers on AI in education"
9.2 export papers for analysis
From Zotero to Claude Code:
- Export papers from Zotero as markdown (via OCR)
- Save to
/literature/folder - Reference with
@/literature/author2024.md - Claude can now analyze the full text.
9.3 workflow with Obsidian
Obsidian for synthesis, Claude Code for execution:
- Use Obsidian for literature notes
- Export synthesis to markdown
- Move to Claude Code project folder
- Claude Code automates analysis and drafting
Step 10: example research workflows
10.1 general literature analysis
Create CLAUDE.md:
# Literature Analysis Project
## Goal
Analyze papers on [TOPIC] to identify themes, methodologies, and gaps.
## File Structure
- /literature/ - Papers in markdown format
- /synthesis/ - Theme notes and comparisons
- /outputs/ - Final analysis documents
## Analysis Protocol
- Extract: Research question, method, key findings
- Compare: Methodologies and theoretical frameworks
- Synthesize: Common themes and research gapsCustom command .claude/commands/analyze.md:
Analyze this paper:
Paper: $ARGUMENTS
Extract:
1. Research question and objectives
2. Methodology (qualitative/quantitative/mixed)
3. Sample and data collection
4. Key findings (3-5 bullet points)
5. Theoretical contribution
6. Limitations and future research
Format as markdown table for easy compilation.10.2 multi-paper comparison
Workflow:
1. /analyze @/literature/paper1.md
2. /analyze @/literature/paper2.md
3. /analyze @/literature/paper3.md
Then: "Create a comparison table of the three analyses above,
focusing on methodological differences."10.3 theory building
Use Sequential Thinking MCP:
Using Sequential Thinking, analyze the papers in @/literature/
and propose a novel theoretical framework that integrates their
key findings. Work step-by-step through:
1. Identifying core constructs
2. Mapping relationships
3. Proposing mechanisms
4. Identifying testable propositionsStep 11: advanced features
11.1 parallel agents
Run multiple analyses simultaneously:
"Use 3 parallel agents to analyze @/literature/smith2024.md:
- Agent 1: Focus on methodology quality
- Agent 2: Focus on theoretical contribution
- Agent 3: Focus on practical implications
Compare their assessments."11.2 git integration
Built-in version control:
"Create a Git commit for the changes we just made with
message: 'Add literature analysis for Smith 2024'"
"Show me the diff of changes since yesterday"
"Create a new branch for the theory-building section"11.3 task tracking with TodoWrite
Claude Code has built-in task management:
"Create a todo list for analyzing these 10 papers:
- Read and summarize each
- Extract methodologies
- Identify common themes
- Map theoretical frameworks
- Draft synthesis section"Claude creates a checklist and tracks progress.
Step 12: troubleshooting
Installation issues
"npm command not found"
- Install Node.js from nodejs.org
- Restart terminal after installation
"Permission denied"
- Use:
sudo npm install -g @anthropic-ai/claude-code - Or fix npm permissions: npm docs
CLAUDE.md not loading
- Verify filename is exactly
CLAUDE.md(case-sensitive) - Must be in project root directory
- Restart Claude Code:
exitthenclaude
Slash commands not working
- Check folder exists:
.claude/commands/ - Verify file naming:
commandname.md(no slashes) - Restart Claude Code after creating commands
- Test with:
/help(built-in command)
File references failing
- Use absolute paths from project root:
@/literature/file.md - Check filename spelling and case
- Verify file exists:
ls literature/
Step 13: best practices for research
13.1 project organization
DRY Principle (Don't Repeat Yourself):
- Create slash commands for repetitive tasks
- Document protocols in CLAUDE.md once
- Reuse across multiple papers/projects
Version Everything:
- Use Git for tracking changes
- Commit after major analyses
- Branch for experimental approaches
13.2 quality control
Always verify AI outputs:
- Check citations against your Zotero library
- Validate statistical claims
- Review for coherence and logic
- See: Failure Museum
Use Plan Mode for:
- File modifications
- Data extraction
- Writing operations
- Complex multi-step tasks
13.3 ethical guidelines
Transparency:
- Document AI use in CLAUDE.md
- Track which tasks were AI-assisted
- Maintain audit trail of prompts used
Verification:
- Never trust AI-generated citations blindly
- Verify every factual claim
- Check for hallucinations and errors
Step 14: advanced use cases
14.1 for systematic literature reviews
See the Claude Code SLR Workflow for a complete SLR workflow covering screening, extraction, and PRISMA reporting.
14.2 for qualitative analysis
Coding transcripts:
/code "Analyze @/data/interview1.md using thematic analysis.
Identify codes, group into themes, provide exemplar quotes."14.3 for theory development
Build conceptual frameworks:
"Using Sequential Thinking MCP, develop a theoretical model
that integrates findings from @/synthesis/themes.md.
Work through: constructs → relationships → propositions → testable hypotheses."Checklist
By the end of this guide, you should have:
- Installed Claude Code (terminal or VS Code)
- Created a research project folder
- Written a CLAUDE.md file with project context
- Created at least one custom slash command
- Tested file references with @ syntax
- Understood Plan vs Act mode
- Installed at least one MCP server (Zotero or Sequential Thinking)
- Watched at least one tutorial video
- Tested a basic analysis workflow
What's next
Next, see the Claude Code SLR Workflow for a complete walkthrough of screening, extraction, and synthesis with Claude Code.
External references
cite this page
Lin, X. (2026). Claude Code Setup Guide. Research Memex. https://research-memex.org/docs/implementation/agentic-ai-tools/claude-code-setup-guide
@misc{docs-implementation-agentic-ai-tools-claude-code-setup-guide-2026,
author = {Xule Lin},
title = {Claude Code Setup Guide},
year = {2026},
howpublished = {\url{https://research-memex.org/docs/implementation/agentic-ai-tools/claude-code-setup-guide}},
note = {ORCID: 0000-0001-7885-4194}
}one renderingthe source remains