A template repository implementing Boris Cherny's productivity tips for AI-assisted coding with Claude Code and Cursor.
Boris Cherny is the creator of Claude Code. This repo synthesizes his recommendations from two threads on how he and the Claude Code team use the tool, providing ready-to-use configurations for maximum productivity.
| File/Directory | Purpose | Install To |
|---|---|---|
CLAUDE.md |
Project memory for Claude Code | Project root |
AGENTS.md |
Agent instructions for Cursor | Project root |
.cursor/skills/ |
Project-specific Cursor skills | Project .cursor/skills/ |
claude_personal_skills/ |
Personal Claude Code skills | ~/.claude/skills/ |
claude_subagents/ |
Claude Code subagent definitions | ~/.claude/agents/ |
cursor_personal_skills/ |
Personal Cursor skills | ~/.cursor/skills-cursor/ |
cursor_subagents/ |
Cursor subagent definitions | ~/.cursor/agents/ |
Copy these files to your project root:
CLAUDE.md- Edit for your project's contextAGENTS.md- Edit for your project's context.cursor/skills/- Copy the skills directory
Copy these from this repo to your home directory for use across all projects:
# Create directories if they don't exist
mkdir -p ~/.claude/skills ~/.claude/agents ~/.cursor/skills-cursor ~/.cursor/agents
# Claude Code personal skills
cp -r claude_personal_skills/* ~/.claude/skills/
# Claude Code subagents
cp -r claude_subagents/* ~/.claude/agents/
# Cursor personal skills
cp -r cursor_personal_skills/* ~/.cursor/skills-cursor/
# Cursor subagents
cp -r cursor_subagents/* ~/.cursor/agents/Create a personal memory file for all projects:
# Copy the template (edit with your preferences)
cp CLAUDE.md ~/.claude/CLAUDE.mdThese files provide persistent context that the AI reads at the start of every session:
- Project-level (
./CLAUDE.md,./AGENTS.md): Shared with your team via git - Personal (
~/.claude/CLAUDE.md): Your preferences across all projects - Local (
./CLAUDE.local.md): Personal project settings, gitignored
Best Practice: After every correction, say:
"Update CLAUDE.md so you don't make that mistake again"
Claude is excellent at writing rules for itself.
Skills are reusable workflows you can invoke with /skill-name:
| Skill | Description |
|---|---|
/commit-push-pr |
Commit, push, and create a PR |
/techdebt |
Find and fix technical debt |
/code-simplifier |
Clean up code after changes |
/code-style |
Python code style guidelines |
/testing |
pytest conventions |
/git-workflow |
Git and commit conventions |
/llm-development |
LLM/ML best practices |
Subagents run specialized tasks in their own context window, enabling parallel execution and context isolation:
| Agent | Description |
|---|---|
code-reviewer |
Review code as a senior engineer (readonly) |
test-writer |
Write comprehensive tests (proactive) |
doc-generator |
Generate documentation |
verifier |
Validate completed work (fast model) |
Use subagents by:
- Slash command:
/code-reviewer review my changes - Natural language: "use the verifier agent to confirm the feature is complete"
For complex tasks, start in Plan mode:
- Cursor: Toggle plan mode in the UI
- Claude Code: Press
Shift+Tabtwice
Pour your energy into the plan. A good plan lets Claude one-shot the implementation.
Run multiple Claude sessions simultaneously:
- Use git worktrees for parallel branches
- Run 3-5 sessions on different tasks
- Hand off sessions between terminal and web
If you do something more than once a day, make it a skill:
# Create a new skill
mkdir -p ~/.claude/skills/my-skill
cat > ~/.claude/skills/my-skill/SKILL.md << 'EOF'
---
name: my-skill
description: What this skill does
---
# My Skill
Instructions for Claude...
EOFThe most important tip: Give Claude a way to verify its work.
- Run tests after changes
- Use browser testing for UI
- Check linter output
- Verify with
git diff
After every mistake or correction:
"Update CLAUDE.md so you don't make that mistake again"
Over time, Claude's error rate will measurably drop.
On macOS, press fn twice to dictate. You speak 3x faster than you type, and your prompts become more detailed.
ChernyCode/
├── README.md
├── CLAUDE.md # Project memory for Claude Code
├── AGENTS.md # Agent instructions for Cursor
├── threads.md # Source material from Boris Cherny
│
├── .cursor/skills/ # Project-specific Cursor skills
│ ├── code-style/SKILL.md
│ ├── testing/SKILL.md
│ ├── git-workflow/SKILL.md
│ └── llm-development/SKILL.md
│
├── claude_personal_skills/ # Install to ~/.claude/skills/
│ ├── commit-push-pr/SKILL.md
│ ├── techdebt/SKILL.md
│ └── code-simplifier/SKILL.md
│
├── claude_subagents/ # Install to ~/.claude/agents/
│ ├── code-reviewer.md
│ ├── test-writer.md
│ └── doc-generator.md
│
├── cursor_personal_skills/ # Install to ~/.cursor/skills-cursor/
│ ├── commit-push-pr/SKILL.md
│ ├── techdebt/SKILL.md
│ └── code-simplifier/SKILL.md
│
├── cursor_subagents/ # Install to ~/.cursor/agents/
│ ├── code-reviewer.md
│ ├── doc-generator.md
│ ├── test-writer.md
│ └── verifier.md
│
└── .cursor/agents/ # Project-specific Cursor subagents
├── code-reviewer.md
├── doc-generator.md
├── test-writer.md
└── verifier.md
After installation, your home directory will have:
~/.claude/
├── CLAUDE.md # Personal memory (all projects)
├── skills/
│ ├── commit-push-pr/SKILL.md
│ ├── techdebt/SKILL.md
│ └── code-simplifier/SKILL.md
└── agents/
├── code-reviewer.md
├── test-writer.md
└── doc-generator.md
~/.cursor/
├── skills-cursor/
│ ├── commit-push-pr/SKILL.md
│ ├── techdebt/SKILL.md
│ └── code-simplifier/SKILL.md
└── agents/
├── code-reviewer.md
├── doc-generator.md
├── test-writer.md
└── verifier.md
Update CLAUDE.md and AGENTS.md with:
- Your project's purpose and architecture
- Coding standards specific to your team
- Common commands and workflows
- Known pitfalls (add these as you encounter them)
- Create a directory:
~/.claude/skills/my-skill/ - Add
SKILL.mdwith frontmatter and instructions - Invoke with
/my-skill
For Claude Code:
- Create a file:
~/.claude/agents/my-agent.md - Add frontmatter with
name,description,allowed-tools - Add the agent's system prompt
- Use by asking Claude to "use the my-agent agent"
For Cursor:
- Create a file:
.cursor/agents/my-agent.md(project) or~/.cursor/agents/my-agent.md(global) - Add YAML frontmatter with:
name: Unique identifier (lowercase, hyphens)description: When to use (Agent reads this for auto-delegation)model:fast,inherit, or specific model IDreadonly: Set totruefor read-only operationsis_background: Set totruefor background execution
- Add the agent's prompt below the frontmatter
- Invoke with
/my-agentor mention naturally in your prompt
Based on Boris Cherny's threads:
MIT