skills/jrc1883/research-merge/SKILL.md
Processes research branches from Claude Code Web sessions - merges content, moves docs to docs/research/, and creates GitHub issues. Use when /popkit:next detects research branches or when manually processing research from mobile sessions. Do NOT use for regular feature branches - only for branches matching claude/research-* or containing research documentation.
npx skillsauth add aiskillstore/marketplace research-mergeInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Handles the complete workflow for processing research branches created during Claude Code Web sessions:
Trigger: Called by pop-next-action skill when research branches detected, or directly via /popkit:research merge.
ALWAYS use AskUserQuestion for merge decisions:
Use AskUserQuestion tool with:
- question: "Found research branch: [topic]. How should we process it?"
- header: "Research"
- options:
- label: "Merge and create issue"
description: "Squash-merge, move docs, create GitHub issue, delete branch"
- label: "Merge only"
description: "Squash-merge content without creating issue"
- label: "Skip for now"
description: "Leave branch for later processing"
- label: "Delete branch"
description: "Discard research (cannot be undone)"
- multiSelect: false
Use the research_branch_detector.py utility:
import sys
# No longer needed - install popkit-shared instead
from research_branch_detector import (
fetch_remotes,
get_research_branches,
format_branch_table,
get_branch_content_preview,
parse_research_doc,
generate_issue_body
)
# Fetch and detect
fetch_remotes()
branches = get_research_branches()
if not branches:
print("No research branches detected.")
return
# Show table
print("## Research Branches Detected\n")
print(format_branch_table(branches))
For each branch, show a preview before prompting:
for branch in branches:
print(f"\n### {branch.short_name}")
print(f"**Topic:** {branch.topic}")
print(f"**Created:** {branch.created_ago}")
print(f"**Commits:** {branch.commit_count} ahead of master")
if branch.doc_paths:
print(f"\n**Documentation:**")
for path in branch.doc_paths:
print(f"- `{path}`")
# Show summary preview
previews = get_branch_content_preview(branch, max_lines=20)
for path, content in previews.items():
parsed = parse_research_doc(content)
if parsed.get("summary"):
print(f"\n**Summary:** {parsed['summary'][:200]}...")
Use AskUserQuestion for each branch:
Use AskUserQuestion tool with:
- question: f"Process '{branch.topic}' research? ({branch.commit_count} commits, {len(branch.doc_paths)} docs)"
- header: "Merge"
- options:
- label: "Merge + Issue"
description: "Full processing: merge, organize docs, create issue"
- label: "Merge Only"
description: "Just merge the content"
- label: "Skip"
description: "Process later"
- label: "Delete"
description: "Discard this research"
- multiSelect: false
Based on user choice:
# 1. Ensure clean working directory
git status --porcelain
# If dirty, prompt user to commit or stash first
# 2. Squash merge the research branch
git merge --squash origin/claude/research-[topic]-[session-id]
# 3. Organize docs (if not already in docs/research/)
mkdir -p docs/research
# Move any root-level research docs
git mv RESEARCH*.md docs/research/ 2>/dev/null || true
git mv *_RESEARCH.md docs/research/ 2>/dev/null || true
# 4. Commit with standard message
git commit -m "docs(research): merge [topic] research from web session
Merged from: [branch-name]
Created: [created-ago]
🤖 Generated with [Claude Code](https://claude.ai/claude-code)
Co-Authored-By: Claude Opus 4.5 <[email protected]>"
# 5. Create GitHub issue
gh issue create --title "[Research] [Topic Title]" --body "[generated-body]" --label "research,documentation"
# 6. Delete remote branch
git push origin --delete claude/research-[topic]-[session-id]
git merge --squash origin/claude/research-[topic]-[session-id]
git commit -m "docs(research): merge [topic] research
Merged from: [branch-name]
🤖 Generated with [Claude Code](https://claude.ai/claude-code)
Co-Authored-By: Claude Opus 4.5 <[email protected]>"
# Optionally delete branch
# Ask: "Delete the remote branch?"
No action - branch remains for future processing.
# Confirm deletion
# "Are you sure? This research will be permanently lost."
git push origin --delete claude/research-[topic]-[session-id]
After processing all branches:
## Research Processing Complete
| Branch | Action | Result |
|--------|--------|--------|
| research-claude-code | Merged + Issue | Issue #182 created |
| research-audio-hooks | Skipped | - |
| research-old-test | Deleted | - |
**Next Steps:**
- Review created issues
- Run `/popkit:next` to see updated recommendations
[Research] {Topic Title}
Examples:
[Research] Claude Code v2.0.65 Features Integration[Research] Audio Feedback Hooks Architecture## Summary
{Executive summary from research doc}
## Source
- **Branch:** `{full_branch_name}`
- **Created:** {created_ago}
- **Files:** {file_count} changed
## Documentation
- `docs/research/{doc_name}.md`
## Implementation Tasks
- [ ] {Task 1 from research}
- [ ] {Task 2 from research}
---
*Auto-generated from research branch by PopKit*
Automatically apply:
research - Marks as research outputdocumentation - Contains documentationOptionally detect from content:
enhancement - If implementation tasks foundP1-high / P2-medium / P3-low - From priority metadata| Situation | Response | |-----------|----------| | Dirty working directory | Prompt to commit/stash first | | Merge conflicts | Show conflicts, offer manual resolution | | gh CLI unavailable | Skip issue creation, note in output | | No doc files | Merge anyway, create minimal issue | | Branch already merged | Skip, note in output |
For best results, research docs should follow this format:
# Research: [Topic Name]
**Research Date:** YYYY-MM-DD
**Status:** Research Document
**Priority:** P1-high | P2-medium | P3-low
## Executive Summary
[Brief summary of findings - becomes issue body]
## Key Findings
[Main research content]
## Implementation Tasks
- [ ] Task 1 [becomes checklist in issue]
- [ ] Task 2
- [ ] Task 3
## References
[Links and sources]
| Component | Role |
|-----------|------|
| pop-next-action | Calls this skill when branches detected |
| research_branch_detector.py | Core detection logic |
| /popkit:next | Entry point for auto-detection |
| /popkit:routine morning | Can include in morning routine |
| GitHub Issues | Output destination for findings |
/popkit:next - Primary entry point/popkit:routine morning - Can detect in morning checkhooks/utils/research_branch_detector.py - Detection utilityoutput-styles/research-summary.md - Output formattingdevelopment
Apple Human Interface Guidelines for content display components. Use this skill when the user asks about charts component, collection view, image view, web view, color well, image well, activity view, lockup, data visualization, content display, displaying images, rendering web content, color pickers, or presenting collections of items in Apple apps. Also use when the user says how should I display charts, what's the best way to show images, should I use a web view, how do I build a grid of items, what component shows media, or how do I present a share sheet. Cross-references: hig-foundations for color/typography/accessibility, hig-patterns for data visualization patterns, hig-components-layout for structural containers, hig-platforms for platform-specific component behavior.
tools
Automate HelpDesk tasks via Rube MCP (Composio): list tickets, manage views, use canned responses, and configure custom fields. Always search tools first for current schemas.
testing
Expert Haskell engineer specializing in advanced type systems, pure functional design, and high-reliability software. Use PROACTIVELY for type-level programming, concurrency, and architecture guidance.
tools
GraphQL gives clients exactly the data they need - no more, no less. One endpoint, typed schema, introspection. But the flexibility that makes it powerful also makes it dangerous. Without proper controls, clients can craft queries that bring down your server. This skill covers schema design, resolvers, DataLoader for N+1 prevention, federation for microservices, and client integration with Apollo/urql. Key insight: GraphQL is a contract. The schema is the API documentation. Design it carefully.