| name | linear-agent |
| description | Intelligent, conversational interface for managing Linear workspace operations (issues, projects, teams, reporting) |
| allowed-tools | * |
Linear Agent Skill
Purpose
Intelligent, conversational interface for managing Linear workspace operations. This skill provides comprehensive issue management, project planning, team coordination, and reporting capabilities through natural language interaction.
Core Capabilities:
- Issue Management: Create, retrieve, update, and search issues with smart defaults
- Project Planning: Bulk operations for epics, milestones, and feature sets
- Team Coordination: Assign work, track progress, manage workloads
- Reporting: Generate team summaries, sprint reports, and activity metrics
- Templates: Pre-configured patterns for bugs, features, and tasks
Architecture
This skill wraps the MCP Linear tools and provides helper utilities that add:
- Retry logic and error handling
- Smart defaults and validation
- Template-based issue creation
- Batch operations
- Natural language → Linear API translation
Helper Scripts:
linear_client.py: Unified API client with retry logiccreate_issue.py: Template-based issue creationupdate_issue.py: Issue updates with validationquery_issues.py: Advanced querying and filteringbulk_operations.py: Batch create/update operationsreporting.py: Team and sprint reports
Templates:
bug_report.yaml: Bug issue templatefeature_request.yaml: Feature request templatetask.yaml: Generic task template
Workflows
Workflow 1: Create Issue
Trigger: User wants to create a new Linear issue
Steps:
Understand Requirements
- Extract issue details from user's natural language request
- Identify: title, description, type (bug/feature/task), priority, labels
- Ask clarifying questions if needed
Select Team
- If team not specified, list available teams using
linear_client.py - Ask user to select team or infer from context
- If team not specified, list available teams using
Choose Template (Optional)
- For bugs: Use
bug_report.yamltemplate - For features: Use
feature_request.yamltemplate - For tasks: Use
task.yamltemplate - For simple issues: Skip template
- For bugs: Use
Populate Fields
- If using template, gather template variables
- Apply smart defaults:
- Priority: 3 (Normal) unless specified
- Labels: Infer from issue type and content
- Estimate: Leave empty unless specified
Create Issue
- Use
helpers/create_issue.pywith gathered information - Example:
python helpers/create_issue.py \ --team "Backend Team" \ --title "Fix authentication timeout" \ --description "Users report 30s timeout on login" \ --labels "bug,p1" \ --priority 2 \ --verbose
- Use
Return Results
- Show created issue ID, title, and URL
- Confirm status and next steps
Example Interaction:
User: "Create a bug issue for authentication timeout in the backend team"
Skill: "I'll create a bug issue for the Backend Team. Let me gather some details:
- What steps reproduce the issue?
- What's the expected vs actual behavior?
- What environment (OS, version)?"
User: "Login page → 30s timeout. Should login in <3s. Chrome on Mac."
Skill: *Creates issue using bug template with details*
Result: "✅ Created ISS-456: [BUG] Authentication timeout - https://linear.app/..."
Workflow 2: Query & Retrieve Issues
Trigger: User wants to find or list issues with specific criteria
Steps:
Parse Query
- Extract filters: team, state, assignee, priority, labels, keywords
- Identify search mode: list all, filter by criteria, search by keyword
Execute Query
- Use
helpers/query_issues.pywith parsed filters - Example:
python helpers/query_issues.py \ --team "Backend Team" \ --state "In Progress" \ --labels "bug" \ --verbose
- Use
Format Results
- For small result sets (<10): Show full details
- For larger sets: Show summary table with ID, title, state, priority
- Offer to export as CSV/JSON if many results
Follow-up Actions
- Ask if user wants to update any of the found issues
- Offer to generate report from results
Example Interaction:
User: "Show me all in-progress bugs for the backend team"
Skill: *Executes query with filters*
Result: "Found 8 in-progress bugs:
ISS-123: Login timeout
ISS-124: API rate limit error
...
Would you like to update any of these?"
Workflow 3: Update Issue
Trigger: User wants to modify an existing issue
Steps:
Identify Issue
- Get issue ID from user (e.g., "ISS-123")
- OR find issue by title/description if ID not provided
Fetch Current State
- Retrieve current issue using
linear_client.py - Show current values for fields being updated
- Retrieve current issue using
Determine Updates
- Extract fields to update from user request
- Supported: title, description, priority, state, assignee, labels, estimate
Apply Updates
- Use
helpers/update_issue.pywith changes - Example:
python helpers/update_issue.py \ --issue-id ISS-123 \ --state "In Progress" \ --assignee "user_abc123" \ --comment "Starting work on this" \ --verbose
- Use
Confirm Changes
- Show before/after snapshot
- Display updated issue URL
Example Interaction:
User: "Move ISS-123 to In Progress and assign to me"
Skill: *Fetches current state, applies updates*
Result: "✅ Updated ISS-123:
State: Backlog → In Progress
Assignee: Unassigned → John Doe
Added comment explaining changes"
Workflow 4: Bulk Operations
Trigger: User wants to create/update multiple issues at once
Steps:
Understand Scope
- Determine operation type: create or update
- Identify source: YAML file, CSV, or manual list
Prepare Batch File (if needed)
- If user provides data directly, create temporary batch file
- Format:
team: "Backend Team" issues: - title: "Issue 1" description: "Description 1" labels: ["bug", "p1"] - title: "Issue 2" priority: 2
Validate Batch
- Check all required fields present
- Warn about missing optional fields
- Confirm with user before executing
Execute Batch
- Use
helpers/bulk_operations.py - Show progress for each issue
- Example:
python helpers/bulk_operations.py \ --action create \ --input batch.yaml \ --verbose
- Use
Report Results
- Summary: X/Y issues created/updated successfully
- List any failures with error messages
- Offer to save results to file
Example Interaction:
User: "Create issues from roadmap.yaml"
Skill: *Loads file, validates, executes batch*
Result: "✅ Created 25/25 issues successfully:
- 10 features
- 8 tasks
- 7 bugs
All issues added to Q1 Roadmap project"
Workflow 5: Generate Report
Trigger: User wants team/sprint metrics or status summary
Steps:
Determine Report Type
- Team Summary: Overall team metrics (by state, priority, assignee)
- Sprint Report: Activity over time period (created, completed, velocity)
Set Parameters
- Team name
- Time period (for sprint reports)
- Output format (markdown or JSON)
Generate Report
- Use
helpers/reporting.py - Example:
python helpers/reporting.py \ --team "Backend Team" \ --report sprint \ --period 7 \ --format markdown
- Use
Format Output
- Display report in readable format
- Highlight key metrics
- Offer to save to file
Example Interaction:
User: "Show me the backend team's sprint summary for the last week"
Skill: *Generates sprint report*
Result: "# Sprint Report: Backend Team
Period: Last 7 days
Activity:
- Issues Created: 12
- Issues Completed: 8
- Velocity: 8 issues/week
By State:
- In Progress: 15
- Done: 42
- Backlog: 23
Would you like me to save this report?"
Helper Script Usage
Create Issue
cd /home/user/writing_ecosystem/.claude/skills/linear-agent
# Simple issue
python helpers/create_issue.py \
--team "Backend Team" \
--title "Add rate limiting"
# With template
python helpers/create_issue.py \
--team "Backend" \
--template bug_report \
--var short_description="Login timeout" \
--var detailed_description="Users report 30s timeout" \
--var expected="Login within 3s" \
--var actual="30s timeout"
Update Issue
# Change status
python helpers/update_issue.py \
--issue-id ISS-123 \
--state "In Progress" \
--comment "Starting work"
# Update multiple fields
python helpers/update_issue.py \
--issue-id ISS-124 \
--priority 1 \
--assignee "user_xyz" \
--labels "urgent,bug"
Query Issues
# Filter by team and state
python helpers/query_issues.py \
--team "Backend Team" \
--state "In Progress"
# Search by keyword
python helpers/query_issues.py \
--search "authentication" \
--limit 20
# Export to CSV
python helpers/query_issues.py \
--team "Backend" \
--output issues.csv \
--format csv
Bulk Operations
# Create from YAML
python helpers/bulk_operations.py \
--action create \
--input batch.yaml
# Update from JSON
python helpers/bulk_operations.py \
--action update \
--input updates.json
Reporting
# Team summary
python helpers/reporting.py \
--team "Backend Team" \
--report summary
# Sprint report
python helpers/reporting.py \
--team "Backend" \
--report sprint \
--period 7 \
--output sprint_report.md
Environment Setup
Required Environment Variables:
LINEAR_API_KEY=lin_api_... # Your Linear API key
Optional:
LINEAR_WORKSPACE_ID=... # Default workspace (if multiple)
Get API Key:
- Go to Linear Settings → API
- Create new personal API key
- Set as environment variable
Templates
Bug Report Template Variables
short_description: Brief bug summarydetailed_description: Detailed explanationsteps: Steps to reproduceexpected: Expected behavioractual: Actual behavioros: Operating systemversion: Software version
Feature Request Template Variables
short_description: Brief feature summaryproblem: Problem statementsolution: Proposed solutionalternatives: Alternative approachessuccess_criteria: Definition of done
Task Template Variables
short_description: Task titledetailed_description: Task detailsacceptance_criteria: Completion criteria
Best Practices
Creating Issues
- Use templates for bugs and features (ensures consistency)
- Set priority based on urgency and impact
- Add labels for categorization and filtering
- Include estimates to track effort
- Assign to team members with capacity
Updating Issues
- Add comments when making significant changes
- Validate state transitions (don't skip states)
- Update estimates as work progresses
- Keep descriptions current with new information
Bulk Operations
- Validate batch files before executing
- Use dry-run mode for large batches
- Monitor progress during execution
- Save results for audit trail
Reporting
- Generate weekly sprint reports for team visibility
- Track velocity trends over time
- Monitor workload distribution to prevent burnout
- Review label usage to ensure proper categorization
Troubleshooting
"Team not found"
- Verify team name matches exactly (case-sensitive)
- List all teams:
python helpers/linear_client.py
"Label not found"
- Check label exists for that team
- List labels: Use Linear client to query labels
"Rate limit exceeded"
- Client automatically throttles at 1400 requests/hour
- Wait for rate limit window to reset
- Consider batching operations
Authentication errors
- Verify LINEAR_API_KEY is set correctly
- Check API key hasn't expired
- Ensure key has necessary permissions
Reference Documentation
See reference/ directory for:
linear_api_schema.md: GraphQL schema referencefield_mappings.md: Field mapping guide
See learnings/ directory for:
pitfalls.md: Common mistakes and how to avoid them