[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7EWEE6C91ZX8GPZXSZA6QVW":3,"skill-same:01M7EWEE6C91ZX8GPZXSZA6QVW":46},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":6,"ownerHtmlUrl":29,"ownerBlogUrl":6,"ownerDescription":30,"updatedAt":31,"install":32,"resources":45},"01M7EWEE6C91ZX8GPZXSZA6QVW","agent-swarm-pr",null,"Agent skill for swarm-pr - invoke with $agent-swarm-pr","lza6\u002FArmor-piercing-system-prompts","lza6","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F128880206?v=4","01M7EB3K7WPX5T28EJ2NVHE6EG","Chinese-tingfeng","01M7EB3K97E1KQ16QWKJMFNGX8",11,"MIT","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F05-技能与代理开发\u002Fagent-swarm-pr\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: agent-swarm-pr\ndescription: Agent skill for swarm-pr - invoke with $agent-swarm-pr\n---\n\n---\nname: swarm-pr\ndescription: Pull request swarm management agent that coordinates multi-agent code review, validation, and integration workflows with automated PR lifecycle management\ntype: development\ncolor: \"#4ECDC4\"\ntools:\n  - mcp__github__get_pull_request\n  - mcp__github__create_pull_request\n  - mcp__github__update_pull_request\n  - mcp__github__list_pull_requests\n  - mcp__github__create_pr_comment\n  - mcp__github__get_pr_diff\n  - mcp__github__merge_pull_request\n  - mcp__claude-flow__swarm_init\n  - mcp__claude-flow__agent_spawn\n  - mcp__claude-flow__task_orchestrate\n  - mcp__claude-flow__memory_usage\n  - mcp__claude-flow__coordination_sync\n  - TodoWrite\n  - TodoRead\n  - Bash\n  - Grep\n  - Read\n  - Write\n  - Edit\nhooks:\n  pre:\n    - \"Initialize PR-specific swarm with diff analysis and impact assessment\"\n    - \"Analyze PR complexity and assign optimal agent topology\"\n    - \"Store PR metadata and diff context in swarm memory\"\n  post:\n    - \"Update PR with comprehensive swarm review results\"\n    - \"Coordinate merge decisions based on swarm analysis\"\n    - \"Generate PR completion metrics and learnings\"\n---\n\n# Swarm PR - Managing Swarms through Pull Requests\n\n## Overview\nCreate and manage AI swarms directly from GitHub Pull Requests, enabling seamless integration with your development workflow through intelligent multi-agent coordination.\n\n## Core Features\n\n### 1. PR-Based Swarm Creation\n```bash\n# Create swarm from PR description using gh CLI\ngh pr view 123 --json body,title,labels,files | npx ruv-swarm swarm create-from-pr\n\n# Auto-spawn agents based on PR labels\ngh pr view 123 --json labels | npx ruv-swarm swarm auto-spawn\n\n# Create swarm with PR context\ngh pr view 123 --json body,labels,author,assignees | \\\n  npx ruv-swarm swarm init --from-pr-data\n```\n\n### 2. PR Comment Commands\nExecute swarm commands via PR comments:\n\n```markdown\n\u003C!-- In PR comment -->\n$swarm init mesh 6\n$swarm spawn coder \"Implement authentication\"\n$swarm spawn tester \"Write unit tests\"\n$swarm status\n```\n\n### 3. Automated PR Workflows\n\n```yaml\n# .github$workflows$swarm-pr.yml\nname: Swarm PR Handler\non:\n  pull_request:\n    types: [opened, labeled]\n  issue_comment:\n    types: [created]\n\njobs:\n  swarm-handler:\n    runs-on: ubuntu-latest\n    steps:\n      - uses: actions$checkout@v3\n      - name: Handle Swarm Command\n        run: |\n          if [[ \"${{ github.event.comment.body }}\" == $swarm* ]]; then\n            npx ruv-swarm github handle-comment \\\n              --pr ${{ github.event.pull_request.number }} \\\n              --comment \"${{ github.event.comment.body }}\"\n          fi\n```\n\n## PR Label Integration\n\n### Automatic Agent Assignment\nMap PR labels to agent types:\n\n```json\n{\n  \"label-mapping\": {\n    \"bug\": [\"debugger\", \"tester\"],\n    \"feature\": [\"architect\", \"coder\", \"tester\"],\n    \"refactor\": [\"analyst\", \"coder\"],\n    \"docs\": [\"researcher\", \"writer\"],\n    \"performance\": [\"analyst\", \"optimizer\"]\n  }\n}\n```\n\n### Label-Based Topology\n```bash\n# Small PR (\u003C 100 lines): ring topology\n# Medium PR (100-500 lines): mesh topology  \n# Large PR (> 500 lines): hierarchical topology\nnpx ruv-swarm github pr-topology --pr 123\n```\n\n## PR Swarm Commands\n\n### Initialize from PR\n```bash\n# Create swarm with PR context using gh CLI\nPR_DIFF=$(gh pr diff 123)\nPR_INFO=$(gh pr view 123 --json title,body,labels,files,reviews)\n\nnpx ruv-swarm github pr-init 123 \\\n  --auto-agents \\\n  --pr-data \"$PR_INFO\" \\\n  --diff \"$PR_DIFF\" \\\n  --analyze-impact\n```\n\n### Progress Updates\n```bash\n# Post swarm progress to PR using gh CLI\nPROGRESS=$(npx ruv-swarm github pr-progress 123 --format markdown)\n\ngh pr comment 123 --body \"$PROGRESS\"\n\n# Update PR labels based on progress\nif [[ $(echo \"$PROGRESS\" | grep -o '[0-9]\\+%' | sed 's\u002F%\u002F\u002F') -gt 90 ]]; then\n  gh pr edit 123 --add-label \"ready-for-review\"\nfi\n```\n\n### Code Review Integration\n```bash\n# Create review agents with gh CLI integration\nPR_FILES=$(gh pr view 123 --json files --jq '.files[].path')\n\n# Run swarm review\nREVIEW_RESULTS=$(npx ruv-swarm github pr-review 123 \\\n  --agents \"security,performance,style\" \\\n  --files \"$PR_FILES\")\n\n# Post review comments using gh CLI\necho \"$REVIEW_RESULTS\" | jq -r '.comments[]' | while read -r comment; do\n  FILE=$(echo \"$comment\" | jq -r '.file')\n  LINE=$(echo \"$comment\" | jq -r '.line')\n  BODY=$(echo \"$comment\" | jq -r '.body')\n  \n  gh pr review 123 --comment --body \"$BODY\"\ndone\n```\n\n## Advanced Features\n\n### 1. Multi-PR Swarm Coordination\n```bash\n# Coordinate swarms across related PRs\nnpx ruv-swarm github multi-pr \\\n  --prs \"123,124,125\" \\\n  --strategy \"parallel\" \\\n  --share-memory\n```\n\n### 2. PR Dependency Analysis\n```bash\n# Analyze PR dependencies\nnpx ruv-swarm github pr-deps 123 \\\n  --spawn-agents \\\n  --resolve-conflicts\n```\n\n### 3. Automated PR Fixes\n```bash\n# Auto-fix PR issues\nnpx ruv-swarm github pr-fix 123 \\\n  --issues \"lint,test-failures\" \\\n  --commit-fixes\n```\n\n## Best Practices\n\n### 1. PR Templates\n```markdown\n\u003C!-- .github$pull_request_template.md -->\n## Swarm Configuration\n- Topology: [mesh$hierarchical$ring$star]\n- Max Agents: [number]\n- Auto-spawn: [yes$no]\n- Priority: [high$medium$low]\n\n## Tasks for Swarm\n- [ ] Task 1 description\n- [ ] Task 2 description\n```\n\n### 2. Status Checks\n```yaml\n# Require swarm completion before merge\nrequired_status_checks:\n  contexts:\n    - \"swarm$tasks-complete\"\n    - \"swarm$tests-pass\"\n    - \"swarm$review-approved\"\n```\n\n### 3. PR Merge Automation\n```bash\n# Auto-merge when swarm completes using gh CLI\n# Check swarm completion status\nSWARM_STATUS=$(npx ruv-swarm github pr-status 123)\n\nif [[ \"$SWARM_STATUS\" == \"complete\" ]]; then\n  # Check review requirements\n  REVIEWS=$(gh pr view 123 --json reviews --jq '.reviews | length')\n  \n  if [[ $REVIEWS -ge 2 ]]; then\n    # Enable auto-merge\n    gh pr merge 123 --auto --squash\n  fi\nfi\n```\n\n## Webhook Integration\n\n### Setup Webhook Handler\n```javascript\n\u002F\u002F webhook-handler.js\nconst { createServer } = require('http');\nconst { execSync } = require('child_process');\n\ncreateServer((req, res) => {\n  if (req.url === '$github-webhook') {\n    const event = JSON.parse(body);\n    \n    if (event.action === 'opened' && event.pull_request) {\n      execSync(`npx ruv-swarm github pr-init ${event.pull_request.number}`);\n    }\n    \n    res.writeHead(200);\n    res.end('OK');\n  }\n}).listen(3000);\n```\n\n## Examples\n\n### Feature Development PR\n```bash\n# PR #456: Add user authentication\nnpx ruv-swarm github pr-init 456 \\\n  --topology hierarchical \\\n  --agents \"architect,coder,tester,security\" \\\n  --auto-assign-tasks\n```\n\n### Bug Fix PR\n```bash\n# PR #789: Fix memory leak\nnpx ruv-swarm github pr-init 789 \\\n  --topology mesh \\\n  --agents \"debugger,analyst,tester\" \\\n  --priority high\n```\n\n### Documentation PR\n```bash\n# PR #321: Update API docs\nnpx ruv-swarm github pr-init 321 \\\n  --topology ring \\\n  --agents \"researcher,writer,reviewer\" \\\n  --validate-links\n```\n\n## Metrics & Reporting\n\n### PR Swarm Analytics\n```bash\n# Generate PR swarm report\nnpx ruv-swarm github pr-report 123 \\\n  --metrics \"completion-time,agent-efficiency,token-usage\" \\\n  --format markdown\n```\n\n### Dashboard Integration\n```bash\n# Export to GitHub Insights\nnpx ruv-swarm github export-metrics \\\n  --pr 123 \\\n  --to-insights\n```\n\n## Security Considerations\n\n1. **Token Permissions**: Ensure GitHub tokens have appropriate scopes\n2. **Command Validation**: Validate all PR comments before execution\n3. **Rate Limiting**: Implement rate limits for PR operations\n4. **Audit Trail**: Log all swarm operations for compliance\n\n## Integration with Claude Code\n\nWhen using with Claude Code:\n1. Claude Code reads PR diff and context\n2. Swarm coordinates approach based on PR type\n3. Agents work in parallel on different aspects\n4. Progress updates posted to PR automatically\n5. Final review performed before marking ready\n\n## Advanced Swarm PR Coordination\n\n### Multi-Agent PR Analysis\n```bash\n# Initialize PR-specific swarm with intelligent topology selection\nmcp__claude-flow__swarm_init { topology: \"mesh\", maxAgents: 8 }\nmcp__claude-flow__agent_spawn { type: \"coordinator\", name: \"PR Coordinator\" }\nmcp__claude-flow__agent_spawn { type: \"reviewer\", name: \"Code Reviewer\" }\nmcp__claude-flow__agent_spawn { type: \"tester\", name: \"Test Engineer\" }\nmcp__claude-flow__agent_spawn { type: \"analyst\", name: \"Impact Analyzer\" }\nmcp__claude-flow__agent_spawn { type: \"optimizer\", name: \"Performance Optimizer\" }\n\n# Store PR context for swarm coordination\nmcp__claude-flow__memory_usage {\n  action: \"store\",\n  key: \"pr\u002F#{pr_number}$analysis\",\n  value: { \n    diff: \"pr_diff_content\", \n    files_changed: [\"file1.js\", \"file2.py\"],\n    complexity_score: 8.5,\n    risk_assessment: \"medium\"\n  }\n}\n\n# Orchestrate comprehensive PR workflow\nmcp__claude-flow__task_orchestrate {\n  task: \"Execute multi-agent PR review and validation workflow\",\n  strategy: \"parallel\",\n  priority: \"high\",\n  dependencies: [\"diff_analysis\", \"test_validation\", \"security_review\"]\n}\n```\n\n### Swarm-Coordinated PR Lifecycle\n```javascript\n\u002F\u002F Pre-hook: PR Initialization and Swarm Setup\nconst prPreHook = async (prData) => {\n  \u002F\u002F Analyze PR complexity for optimal swarm configuration\n  const complexity = await analyzePRComplexity(prData);\n  const topology = complexity > 7 ? \"hierarchical\" : \"mesh\";\n  \n  \u002F\u002F Initialize swarm with PR-specific configuration\n  await mcp__claude_flow__swarm_init({ topology, maxAgents: 8 });\n  \n  \u002F\u002F Store comprehensive PR context\n  await mcp__claude_flow__memory_usage({\n    action: \"store\",\n    key: `pr\u002F${prData.number}$context`,\n    value: {\n      pr: prData,\n      complexity,\n      agents_assigned: await getOptimalAgents(prData),\n      timeline: generateTimeline(prData)\n    }\n  });\n  \n  \u002F\u002F Coordinate initial agent synchronization\n  await mcp__claude_flow__coordination_sync({ swarmId: \"current\" });\n};\n\n\u002F\u002F Post-hook: PR Completion and Metrics\nconst prPostHook = async (results) => {\n  \u002F\u002F Generate comprehensive PR completion report\n  const report = await generatePRReport(results);\n  \n  \u002F\u002F Update PR with final swarm analysis\n  await updatePRWithResults(report);\n  \n  \u002F\u002F Store completion metrics for future optimization\n  await mcp__claude_flow__memory_usage({\n    action: \"store\",\n    key: `pr\u002F${results.number}$completion`,\n    value: {\n      completion_time: results.duration,\n      agent_efficiency: results.agentMetrics,\n      quality_score: results.qualityAssessment,\n      lessons_learned: results.insights\n    }\n  });\n};\n```\n\n### Intelligent PR Merge Coordination\n```bash\n# Coordinate merge decision with swarm consensus\nmcp__claude-flow__coordination_sync { swarmId: \"pr-review-swarm\" }\n\n# Analyze merge readiness with multiple agents\nmcp__claude-flow__task_orchestrate {\n  task: \"Evaluate PR merge readiness with comprehensive validation\",\n  strategy: \"sequential\",\n  priority: \"critical\"\n}\n\n# Store merge decision context\nmcp__claude-flow__memory_usage {\n  action: \"store\",\n  key: \"pr$merge_decisions\u002F#{pr_number}\",\n  value: {\n    ready_to_merge: true,\n    validation_passed: true,\n    agent_consensus: \"approved\",\n    final_review_score: 9.2\n  }\n}\n```\n\nSee also: [swarm-issue.md](.$swarm-issue.md), [sync-coordinator.md](.$sync-coordinator.md), [workflow-automation.md](.$workflow-automation.md)","---\nname: swarm-pr\ndescription: Pull request swarm management agent that coordinates multi-agent code review, validation, and integration workflows with automated PR lifecycle management\ntype: development\ncolor: \"#4ECDC4\"\ntools:\n  - mcp__github__get_pull_request\n  - mcp__github__create_pull_request\n  - mcp__github__update_pull_request\n  - mcp__github__list_pull_requests\n  - mcp__github__create_pr_comment\n  - mcp__github__get_pr_diff\n  - mcp__github__merge_pull_request\n  - mcp__claude-flow__swarm_init\n  - mcp__claude-flow__agent_spawn\n  - mcp__claude-flow__task_orchestrate\n  - mcp__claude-flow__memory_usage\n  - mcp__claude-flow__coordination_sync\n  - TodoWrite\n  - TodoRead\n  - Bash\n  - Grep\n  - Read\n  - Write\n  - Edit\nhooks:\n  pre:\n    - \"Initialize PR-specific swarm with diff analysis and impact assessment\"\n    - \"Analyze PR complexity and assign optimal agent topology\"\n    - \"Store PR metadata and diff context in swarm memory\"\n  post:\n    - \"Update PR with comprehensive swarm review results\"\n    - \"Coordinate merge decisions based on swarm analysis\"\n    - \"Generate PR completion metrics and learnings\"\n---\n\n# Swarm PR - Managing Swarms through Pull Requests\n\n## Overview\nCreate and manage AI swarms directly from GitHub Pull Requests, enabling seamless integration with your development workflow through intelligent multi-agent coordination.\n\n## Core Features\n\n### 1. PR-Based Swarm Creation\n```bash\n# Create swarm from PR description using gh CLI\ngh pr view 123 --json body,title,labels,files | npx ruv-swarm swarm create-from-pr\n\n# Auto-spawn agents based on PR labels\ngh pr view 123 --json labels | npx ruv-swarm swarm auto-spawn\n\n# Create swarm with PR context\ngh pr view 123 --json body,labels,author,assignees | \\\n  npx ruv-swarm swarm init --from-pr-data\n```\n\n### 2. PR Comment Commands\nExecute swarm commands via PR comments:\n\n```markdown\n\u003C!-- In PR comment -->\n$swarm init mesh 6\n$swarm spawn coder \"Implement authentication\"\n$swarm spawn tester \"Write unit tests\"\n$swarm status\n```\n\n### 3. Automated PR Workflows\n\n```yaml\n# .github$workflows$swarm-pr.yml\nname: Swarm PR Handler\non:\n  pull_request:\n    types: [opened, labeled]\n  issue_comment:\n    types: [created]\n\njobs:\n  swarm-handler:\n    runs-on: ubuntu-latest\n    steps:\n      - uses: actions$checkout@v3\n      - name: Handle Swarm Command\n        run: |\n          if [[ \"${{ github.event.comment.body }}\" == $swarm* ]]; then\n            npx ruv-swarm github handle-comment \\\n              --pr ${{ github.event.pull_request.number }} \\\n              --comment \"${{ github.event.comment.body }}\"\n          fi\n```\n\n## PR Label Integration\n\n### Automatic Agent Assignment\nMap PR labels to agent types:\n\n```json\n{\n  \"label-mapping\": {\n    \"bug\": [\"debugger\", \"tester\"],\n    \"feature\": [\"architect\", \"coder\", \"tester\"],\n    \"refactor\": [\"analyst\", \"coder\"],\n    \"docs\": [\"researcher\", \"writer\"],\n    \"performance\": [\"analyst\", \"optimizer\"]\n  }\n}\n```\n\n### Label-Based Topology\n```bash\n# Small PR (\u003C 100 lines): ring topology\n# Medium PR (100-500 lines): mesh topology  \n# Large PR (> 500 lines): hierarchical topology\nnpx ruv-swarm github pr-topology --pr 123\n```\n\n## PR Swarm Commands\n\n### Initialize from PR\n```bash\n# Create swarm with PR context using gh CLI\nPR_DIFF=$(gh pr diff 123)\nPR_INFO=$(gh pr view 123 --json title,body,labels,files,reviews)\n\nnpx ruv-swarm github pr-init 123 \\\n  --auto-agents \\\n  --pr-data \"$PR_INFO\" \\\n  --diff \"$PR_DIFF\" \\\n  --analyze-impact\n```\n\n### Progress Updates\n```bash\n# Post swarm progress to PR using gh CLI\nPROGRESS=$(npx ruv-swarm github pr-progress 123 --format markdown)\n\ngh pr comment 123 --body \"$PROGRESS\"\n\n# Update PR labels based on progress\nif [[ $(echo \"$PROGRESS\" | grep -o '[0-9]\\+%' | sed 's\u002F%\u002F\u002F') -gt 90 ]]; then\n  gh pr edit 123 --add-label \"ready-for-review\"\nfi\n```\n\n### Code Review Integration\n```bash\n# Create review agents with gh CLI integration\nPR_FILES=$(gh pr view 123 --json files --jq '.files[].path')\n\n# Run swarm review\nREVIEW_RESULTS=$(npx ruv-swarm github pr-review 123 \\\n  --agents \"security,performance,style\" \\\n  --files \"$PR_FILES\")\n\n# Post review comments using gh CLI\necho \"$REVIEW_RESULTS\" | jq -r '.comments[]' | while read -r comment; do\n  FILE=$(echo \"$comment\" | jq -r '.file')\n  LINE=$(echo \"$comment\" | jq -r '.line')\n  BODY=$(echo \"$comment\" | jq -r '.body')\n  \n  gh pr review 123 --comment --body \"$BODY\"\ndone\n```\n\n## Advanced Features\n\n### 1. Multi-PR Swarm Coordination\n```bash\n# Coordinate swarms across related PRs\nnpx ruv-swarm github multi-pr \\\n  --prs \"123,124,125\" \\\n  --strategy \"parallel\" \\\n  --share-memory\n```\n\n### 2. PR Dependency Analysis\n```bash\n# Analyze PR dependencies\nnpx ruv-swarm github pr-deps 123 \\\n  --spawn-agents \\\n  --resolve-conflicts\n```\n\n### 3. Automated PR Fixes\n```bash\n# Auto-fix PR issues\nnpx ruv-swarm github pr-fix 123 \\\n  --issues \"lint,test-failures\" \\\n  --commit-fixes\n```\n\n## Best Practices\n\n### 1. PR Templates\n```markdown\n\u003C!-- .github$pull_request_template.md -->\n## Swarm Configuration\n- Topology: [mesh$hierarchical$ring$star]\n- Max Agents: [number]\n- Auto-spawn: [yes$no]\n- Priority: [high$medium$low]\n\n## Tasks for Swarm\n- [ ] Task 1 description\n- [ ] Task 2 description\n```\n\n### 2. Status Checks\n```yaml\n# Require swarm completion before merge\nrequired_status_checks:\n  contexts:\n    - \"swarm$tasks-complete\"\n    - \"swarm$tests-pass\"\n    - \"swarm$review-approved\"\n```\n\n### 3. PR Merge Automation\n```bash\n# Auto-merge when swarm completes using gh CLI\n# Check swarm completion status\nSWARM_STATUS=$(npx ruv-swarm github pr-status 123)\n\nif [[ \"$SWARM_STATUS\" == \"complete\" ]]; then\n  # Check review requirements\n  REVIEWS=$(gh pr view 123 --json reviews --jq '.reviews | length')\n  \n  if [[ $REVIEWS -ge 2 ]]; then\n    # Enable auto-merge\n    gh pr merge 123 --auto --squash\n  fi\nfi\n```\n\n## Webhook Integration\n\n### Setup Webhook Handler\n```javascript\n\u002F\u002F webhook-handler.js\nconst { createServer } = require('http');\nconst { execSync } = require('child_process');\n\ncreateServer((req, res) => {\n  if (req.url === '$github-webhook') {\n    const event = JSON.parse(body);\n    \n    if (event.action === 'opened' && event.pull_request) {\n      execSync(`npx ruv-swarm github pr-init ${event.pull_request.number}`);\n    }\n    \n    res.writeHead(200);\n    res.end('OK');\n  }\n}).listen(3000);\n```\n\n## Examples\n\n### Feature Development PR\n```bash\n# PR #456: Add user authentication\nnpx ruv-swarm github pr-init 456 \\\n  --topology hierarchical \\\n  --agents \"architect,coder,tester,security\" \\\n  --auto-assign-tasks\n```\n\n### Bug Fix PR\n```bash\n# PR #789: Fix memory leak\nnpx ruv-swarm github pr-init 789 \\\n  --topology mesh \\\n  --agents \"debugger,analyst,tester\" \\\n  --priority high\n```\n\n### Documentation PR\n```bash\n# PR #321: Update API docs\nnpx ruv-swarm github pr-init 321 \\\n  --topology ring \\\n  --agents \"researcher,writer,reviewer\" \\\n  --validate-links\n```\n\n## Metrics & Reporting\n\n### PR Swarm Analytics\n```bash\n# Generate PR swarm report\nnpx ruv-swarm github pr-report 123 \\\n  --metrics \"completion-time,agent-efficiency,token-usage\" \\\n  --format markdown\n```\n\n### Dashboard Integration\n```bash\n# Export to GitHub Insights\nnpx ruv-swarm github export-metrics \\\n  --pr 123 \\\n  --to-insights\n```\n\n## Security Considerations\n\n1. **Token Permissions**: Ensure GitHub tokens have appropriate scopes\n2. **Command Validation**: Validate all PR comments before execution\n3. **Rate Limiting**: Implement rate limits for PR operations\n4. **Audit Trail**: Log all swarm operations for compliance\n\n## Integration with Claude Code\n\nWhen using with Claude Code:\n1. Claude Code reads PR diff and context\n2. Swarm coordinates approach based on PR type\n3. Agents work in parallel on different aspects\n4. Progress updates posted to PR automatically\n5. Final review performed before marking ready\n\n## Advanced Swarm PR Coordination\n\n### Multi-Agent PR Analysis\n```bash\n# Initialize PR-specific swarm with intelligent topology selection\nmcp__claude-flow__swarm_init { topology: \"mesh\", maxAgents: 8 }\nmcp__claude-flow__agent_spawn { type: \"coordinator\", name: \"PR Coordinator\" }\nmcp__claude-flow__agent_spawn { type: \"reviewer\", name: \"Code Reviewer\" }\nmcp__claude-flow__agent_spawn { type: \"tester\", name: \"Test Engineer\" }\nmcp__claude-flow__agent_spawn { type: \"analyst\", name: \"Impact Analyzer\" }\nmcp__claude-flow__agent_spawn { type: \"optimizer\", name: \"Performance Optimizer\" }\n\n# Store PR context for swarm coordination\nmcp__claude-flow__memory_usage {\n  action: \"store\",\n  key: \"pr\u002F#{pr_number}$analysis\",\n  value: { \n    diff: \"pr_diff_content\", \n    files_changed: [\"file1.js\", \"file2.py\"],\n    complexity_score: 8.5,\n    risk_assessment: \"medium\"\n  }\n}\n\n# Orchestrate comprehensive PR workflow\nmcp__claude-flow__task_orchestrate {\n  task: \"Execute multi-agent PR review and validation workflow\",\n  strategy: \"parallel\",\n  priority: \"high\",\n  dependencies: [\"diff_analysis\", \"test_validation\", \"security_review\"]\n}\n```\n\n### Swarm-Coordinated PR Lifecycle\n```javascript\n\u002F\u002F Pre-hook: PR Initialization and Swarm Setup\nconst prPreHook = async (prData) => {\n  \u002F\u002F Analyze PR complexity for optimal swarm configuration\n  const complexity = await analyzePRComplexity(prData);\n  const topology = complexity > 7 ? \"hierarchical\" : \"mesh\";\n  \n  \u002F\u002F Initialize swarm with PR-specific configuration\n  await mcp__claude_flow__swarm_init({ topology, maxAgents: 8 });\n  \n  \u002F\u002F Store comprehensive PR context\n  await mcp__claude_flow__memory_usage({\n    action: \"store\",\n    key: `pr\u002F${prData.number}$context`,\n    value: {\n      pr: prData,\n      complexity,\n      agents_assigned: await getOptimalAgents(prData),\n      timeline: generateTimeline(prData)\n    }\n  });\n  \n  \u002F\u002F Coordinate initial agent synchronization\n  await mcp__claude_flow__coordination_sync({ swarmId: \"current\" });\n};\n\n\u002F\u002F Post-hook: PR Completion and Metrics\nconst prPostHook = async (results) => {\n  \u002F\u002F Generate comprehensive PR completion report\n  const report = await generatePRReport(results);\n  \n  \u002F\u002F Update PR with final swarm analysis\n  await updatePRWithResults(report);\n  \n  \u002F\u002F Store completion metrics for future optimization\n  await mcp__claude_flow__memory_usage({\n    action: \"store\",\n    key: `pr\u002F${results.number}$completion`,\n    value: {\n      completion_time: results.duration,\n      agent_efficiency: results.agentMetrics,\n      quality_score: results.qualityAssessment,\n      lessons_learned: results.insights\n    }\n  });\n};\n```\n\n### Intelligent PR Merge Coordination\n```bash\n# Coordinate merge decision with swarm consensus\nmcp__claude-flow__coordination_sync { swarmId: \"pr-review-swarm\" }\n\n# Analyze merge readiness with multiple agents\nmcp__claude-flow__task_orchestrate {\n  task: \"Evaluate PR merge readiness with comprehensive validation\",\n  strategy: \"sequential\",\n  priority: \"critical\"\n}\n\n# Store merge decision context\nmcp__claude-flow__memory_usage {\n  action: \"store\",\n  key: \"pr$merge_decisions\u002F#{pr_number}\",\n  value: {\n    ready_to_merge: true,\n    validation_passed: true,\n    agent_consensus: \"approved\",\n    final_review_score: 9.2\n  }\n}\n```\n\nSee also: [swarm-issue.md](.$swarm-issue.md), [sync-coordinator.md](.$sync-coordinator.md), [workflow-automation.md](.$workflow-automation.md)",{"name":5,"description":7},"main","d69096e239f2a89aabc2cd078c47664a9d3b1e11","05-技能与代理开发\u002Fagent-swarm-pr",3,"https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts","https:\u002F\u002Fgithub.com\u002Flza6","个人vx：Tf00798\r\n个人✈：@TFGY999","2026-10-08 14:29:22",{"source":8,"skillName":5,"commands":33,"prompt":43,"zipAvailable":44},[34,37,40],{"tool":35,"command":36},"npx","npx skills add lza6\u002FArmor-piercing-system-prompts --skill agent-swarm-pr",{"tool":38,"command":39},"bunx","bunx skills add lza6\u002FArmor-piercing-system-prompts --skill agent-swarm-pr",{"tool":41,"command":42},"pnpm","pnpm dlx skills add lza6\u002FArmor-piercing-system-prompts --skill agent-swarm-pr","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F05-技能与代理开发\u002Fagent-swarm-pr\u002FSKILL.md",true,[],[47,55,60,67,74,81],{"skillNo":48,"name":49,"nameZh":6,"description":50,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":51,"categories":52,"keywords":53,"publishedAt":54},"01M7FFG485KY83TD6HSC4YPCMC","obsidian-clipper-template-creator","Guide for creating templates for the Obsidian Web Clipper. Use when you want to create a new clipping template, understand available variables, or format clipped content.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobsidian-clipper-template-creator\u002FSKILL.md",[],[],"2026-11-16 10:05:34",{"skillNo":56,"name":49,"nameZh":6,"description":50,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":57,"categories":58,"keywords":59,"publishedAt":54},"01M7FFG0T6AZ0STEJPSB3CX84K","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobsidian-clipper-template-creator-antigravity-awesome-skills-main\u002FSKILL.md",[],[],{"skillNo":61,"name":62,"nameZh":6,"description":63,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":64,"categories":65,"keywords":66,"publishedAt":54},"01M7FFFY0QEM14SKWPDYGMXM2P","python-api","Programmatic Object-Detection-Metrics API guidance for BoundingBox, BoundingBoxes, Evaluator, enums, coordinate conversion, AP\u002FmAP semantics, and source-style import diagnostics.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobject-detection-metrics\u002Fsub-skills\u002Fpython-api\u002FSKILL.md",[],[],{"skillNo":68,"name":69,"nameZh":6,"description":70,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":71,"categories":72,"keywords":73,"publishedAt":54},"01M7FFFVZQZ2GJ0C0TGP7JHD20","file-evaluation","Folder-based PASCAL VOC AP\u002FmAP evaluation from ground-truth and detection text files.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobject-detection-metrics\u002Fsub-skills\u002Ffile-evaluation\u002FSKILL.md",[],[],{"skillNo":75,"name":76,"nameZh":6,"description":77,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":78,"categories":79,"keywords":80,"publishedAt":54},"01M7FFFSFNYSE77SJ6PE1CK2DA","object-detection-metrics","Guides legacy Object-Detection-Metrics PASCAL VOC AP\u002FmAP evaluation from detection text folders and direct Python API classes.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobject-detection-metrics\u002FSKILL.md",[],[],{"skillNo":82,"name":83,"nameZh":6,"description":84,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":54},"01M7FFFP0GCK1RVXBCPQ8APBMT","nx-workspace-patterns","Configure and optimize Nx monorepo workspaces. Use when setting up Nx, configuring project boundaries, optimizing build caching, or implementing affected commands.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fnx-workspace-patterns\u002FSKILL.md",[],[]]