fp-review
Review code, create stories, and ensure commits are assigned to issues. Use when user asks to "review code", "assign commits", "check commits are assigned", "prepare for review", "create a story", or "write a story".
What this skill does
# FP Review Skill
**Ensure commits are properly linked to issues and provide review feedback.**
## Prerequisites
Before using fp commands, check setup:
```bash
# Check if fp is installed
fp --version
```
**If fp is not installed**, tell the user:
> The `fp` CLI is not installed. Install it with:
> ```bash
> curl -fsSL https://setup.fp.dev/install.sh | sh -s
> ```
```bash
# Check if project is initialized
fp tree
```
**If project is not initialized**, ask the user if they want to initialize:
> This project hasn't been initialized with fp. Would you like to initialize it?
If yes:
```bash
fp init
```
---
## Core Purpose
1. Verify commits are assigned to the correct issues
2. Leave review comments on issues
3. Open interactive review in the desktop app
4. Create stories — narrative documents that walk through code changes
---
## Assigning Commits to Issues
### Check Current Assignments
```bash
fp issue files <PREFIX>-X
```
If empty, the issue has no commits assigned.
### Find Relevant Commits
```bash
jj log --limit 20 # Jujutsu
git log --oneline -20 # Git
```
### View Commit Details
```bash
jj show <commit-id> # Jujutsu
git show <hash> --stat # Git
```
### Match Commits to Issues
Compare:
- Files changed in commit vs issue description
- Commit message content vs issue title
- Code changes vs issue requirements
### Assign Commits
**Before assigning commits, confirm with the user.** Some users prefer to work without committing until they're done, or may not want commits linked to issues.
Use `AskUserTool` to ask:
> I found these commits that appear related to `<PREFIX>-X`:
> - `abc123` - Add user model
> - `def456` - Implement auth middleware
>
> Would you like me to assign them to the issue? (If you prefer to review uncommitted changes instead, you can run `fp review` for the working copy.)
If confirmed:
```bash
# Single commit
fp issue assign <PREFIX>-X --rev abc123
# Multiple commits
fp issue assign <PREFIX>-X --rev abc123,def456,ghi789
# Current HEAD
fp issue assign <PREFIX>-X
# Reset and reassign
fp issue assign <PREFIX>-X --reset
fp issue assign <PREFIX>-X --rev abc123,def456
```
### Verify Assignment
```bash
fp issue files <PREFIX>-X
fp issue diff <PREFIX>-X --stat
```
---
## Leaving Review Comments
Use `fp comment` for review feedback. Reference files and lines for specificity.
### File-Specific Comments
```bash
fp comment <PREFIX>-X "**src/utils/parser.ts**: Consider extracting the validation logic into a separate function for testability."
fp comment <PREFIX>-X "**src/api/handler.ts:45-60**: This error handling could swallow important exceptions. Suggest re-throwing after logging."
```
### Severity Prefixes
Use prefixes to indicate importance:
```bash
fp comment <PREFIX>-X "[blocker] **src/auth.ts**: Missing input sanitization creates SQL injection risk."
fp comment <PREFIX>-X "[suggestion] **src/utils.ts:23**: Could use optional chaining here for cleaner code."
fp comment <PREFIX>-X "[nit] **README.md**: Typo in setup instructions."
```
- `[blocker]` - Must fix before merging
- `[suggestion]` - Recommended improvement
- `[nit]` - Minor/cosmetic issue
### General Comments
```bash
fp comment <PREFIX>-X "Overall looks good. Main concern is the error handling in the API layer - see specific comments above."
```
---
## Interactive Review (Desktop App)
`fp review` opens the Fiberplane desktop app for interactive diff review.
**Requires the desktop app.** If not installed: https://setup.fp.dev/desktop/latest/
### Review Working Copy (No Commits Needed)
If the user hasn't committed yet (or prefers not to commit while work is in progress):
```bash
fp review
```
This shows all uncommitted changes in the working directory. No commit assignment required.
### Review by Issue
```bash
fp review <PREFIX>-X
```
**Note:** For issue-based review to work, the issue must have commits assigned. If no commits are assigned, either:
1. Assign commits first with `fp issue assign`, OR
2. Use `fp review` to review the working copy instead
### Review with Story
```bash
fp review <PREFIX>-X --with-story
```
Opens the review with the story panel visible alongside the diff. The issue must have a story created for it.
### Other Review Targets
```bash
fp review git:abc123 # Specific git commit
fp review jj:abc123 # Specific jj revision
fp review git:abc123..def456 # Range of commits
```
---
## Review Workflow
### Step 1: Check Assignments
```bash
fp issue files <PREFIX>-X
```
### Step 2: Assign Missing Commits
```bash
jj log --limit 20
fp issue assign <PREFIX>-X --rev abc,def
```
### Step 3: View the Diff
```bash
fp issue diff <PREFIX>-X --stat # Overview
fp issue diff <PREFIX>-X # Full diff
fp review <PREFIX>-X # Open in desktop app
```
### Step 4: Leave Comments
```bash
fp comment <PREFIX>-X "**file.ts:line**: feedback"
```
---
## Stories
Stories are narrative documents that walk a reviewer through code changes. They combine markdown prose with embedded diffs, file excerpts, and chat transcripts.
**Requires the `experimental_story` feature flag:**
```bash
fp feature enable experimental_story
```
### Creating a Story
```bash
# From a file
fp story create <PREFIX>-X --file story.md
# From stdin
cat story.md | fp story create <PREFIX>-X
```
The first `## ` heading in the markdown becomes the story title.
### Story Format
Stories are markdown documents that use directives to embed code artifacts:
#### Diff Directive
Shows file changes from the issue's assigned commits:
```markdown
## Moved validation to a shared module
The old approach duplicated validation in each handler.
:::diff{file="src/validation.ts"}
Extracted from handler.ts and api.ts into a single module.
:::
```
- `file` (required): relative path to the changed file
- The text between `:::diff` and `:::` is the annotation — keep it to 1-2 sentences
#### File Directive
Shows file content (or a slice of it):
```markdown
:::file{path="src/config.ts" lines="10-25"}
The new defaults that drive the behavior change.
:::
```
- `path` (required): relative path to file
- `lines` (optional): line range, e.g. `"10-25"`
#### Chat Directive
Embeds excerpts from an AI coding session:
```markdown
:::chat{source="claude" session="/path/to/session.jsonl" messages="msg1,msg2"}
The key design discussion that led to this approach.
:::
```
- `source`: `"claude"`, `"pi"`, or `"opencode"`
- `session`: full path to session file
- `messages`: comma-separated message IDs
### Writing Guidelines
- **Headings are past-tense verbs** — describe what was done, not what to do (e.g. "Moved validation to a shared module")
- **Start with the user problem** — the opening prose should explain why the change exists
- **Show diff, then explain** — lead with the `:::diff` directive, follow with the annotation
- **Annotations are 1-2 sentences** — brief context, not a full explanation
### UI Support
Only `:::diff` is fully rendered in the desktop app right now. `:::file` works but the `collapsed` attribute is ignored. The `hunks` attribute on `:::diff` is also ignored.
### Managing Stories
```bash
fp story list # List all stories in the project
fp story get <story-id> # Get story details (supports ID prefix)
fp story get <PREFIX>-X # Get story by issue ID
fp story delete <story-id> # Delete a story (supports ID prefix)
fp story delete <story-id> --yes # Skip confirmation
```
One story per issue. Creating a new story for an issue replaces the previous one.
---
## Quick Reference
### Commands
```bash
# Check assignments
fp issue files <PREFIX>-X
# Assign commits
fp issue assign <PREFIX>-X --rev <commits>
# View changes
fp issue diff <PREFIX>-X --stat
fp issue diff <PREFIX>-X
# Leave comments
fp comment <PREFIX>-X "message"
# Interactive review (desktop app)
fp review <PREFIX>-X
# Stories
fp story create <PREFIX>-X --file story.md
fp story list
fpRelated in Code Review
gstack
IncludedFast headless browser for QA testing and site dogfooding. Navigate pages, interact with elements, verify state, diff before/after, take annotated screenshots, test responsive layouts, forms, uploads, dialogs, and capture bug evidence. Use when asked to open or test a site, verify a deployment, dogfood a user flow, or file a bug with screenshots. (gstack)
startup-due-diligence
IncludedLegal due diligence review for seed-stage and Series A startups (US, Delaware C-Corp focus). Supports both investor and founder perspectives. Capabilities include: (1) Interactive document review and issue spotting; (2) Document request list generation; (3) Cap table and SAFE/convertible note analysis; (4) Red flag identification with severity ratings; (5) Diligence report generation. TRIGGERS: due diligence, DD, startup investment, cap table review, Series A, seed round, investor diligence, legal review startup, SAFE analysis, convertible note, 409A, founder vesting.
interview-master
IncludedThis skill should be used when the user asks to "generate interview questions", "prepare for interview", "optimize resume", "conduct mock interview", "analyze git commits for resume", "generate resume from code", "review my resume", or mentions interview preparation, career assistance, or extracting project experience from git history. Provides comprehensive interview and career development guidance for both job seekers and interviewers.
fix-issue
IncludedFixes GitHub issues using parallel analysis agents for root cause investigation, code exploration, and regression detection. Reads issue context from gh CLI, searches codebase and memory for related patterns, generates a fix with tests, and links the resolution back to the issue via PR. Includes prevention analysis to avoid recurrence. Use when debugging errors, resolving regressions, fixing bugs, or triaging issues.
sf-apex
IncludedGenerates and reviews Salesforce Apex code with 150-point scoring. TRIGGER when: user writes, reviews, or fixes Apex classes, triggers, test classes, batch/queueable/schedulable jobs, or touches .cls/.trigger files. DO NOT TRIGGER when: LWC JavaScript (use sf-lwc), Flow XML (use sf-flow), SOQL-only queries (use sf-soql), or non-Salesforce code.
swift-development
IncludedComprehensive Swift development for building, testing, and deploying iOS/macOS applications. Use when Claude needs to: (1) Build Swift packages or Xcode projects from command line, (2) Run tests with XCTest or Swift Testing framework, (3) Manage iOS simulators with simctl, (4) Handle code signing, provisioning profiles, and app distribution, (5) Format or lint Swift code with SwiftFormat/SwiftLint, (6) Work with Swift Package Manager (SPM), (7) Implement Swift 6 concurrency patterns (async/await, actors, Sendable), (8) Create SwiftUI views with MVVM architecture, (9) Set up Core Data or SwiftData persistence, or any other Swift/iOS/macOS development tasks.