{
  "schemaVersion": "1.0",
  "item": {
    "slug": "instruments-profiling",
    "name": "Instruments Profiling",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/steipete/instruments-profiling",
    "canonicalUrl": "https://clawhub.ai/steipete/instruments-profiling",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/instruments-profiling",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=instruments-profiling",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "SKILL.md"
    ],
    "primaryDoc": "SKILL.md",
    "quickSetup": [
      "Download the package from Yavira.",
      "Extract the archive and review SKILL.md first.",
      "Import or place the package into your OpenClaw setup."
    ],
    "agentAssist": {
      "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
      "steps": [
        "Download the package from Yavira.",
        "Extract it into a folder your agent can access.",
        "Paste one of the prompts below and point your agent at the extracted folder."
      ],
      "prompts": [
        {
          "label": "New install",
          "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
        },
        {
          "label": "Upgrade existing",
          "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
        }
      ]
    },
    "sourceHealth": {
      "source": "tencent",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-04-30T16:55:25.780Z",
      "expiresAt": "2026-05-07T16:55:25.780Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=network",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=network",
        "contentDisposition": "attachment; filename=\"network-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null
      },
      "scope": "source",
      "summary": "Source download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this source.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/instruments-profiling"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    },
    "downloadPageUrl": "https://openagent3.xyz/downloads/instruments-profiling",
    "agentPageUrl": "https://openagent3.xyz/skills/instruments-profiling/agent",
    "manifestUrl": "https://openagent3.xyz/skills/instruments-profiling/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/instruments-profiling/agent.md"
  },
  "agentAssist": {
    "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
    "steps": [
      "Download the package from Yavira.",
      "Extract it into a folder your agent can access.",
      "Paste one of the prompts below and point your agent at the extracted folder."
    ],
    "prompts": [
      {
        "label": "New install",
        "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
      },
      {
        "label": "Upgrade existing",
        "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
      }
    ]
  },
  "documentation": {
    "source": "clawhub",
    "primaryDoc": "SKILL.md",
    "sections": [
      {
        "title": "Instruments Profiling (macOS/iOS)",
        "body": "Use this skill when the user wants performance profiling or stack analysis for native apps.\nFocus: Time Profiler, xctrace CLI, and picking the correct binary/app instance."
      },
      {
        "title": "Quick Start (CLI)",
        "body": "List templates: xcrun xctrace list templates\nRecord Time Profiler (launch):\n\nxcrun xctrace record --template 'Time Profiler' --time-limit 60s --output /tmp/App.trace --launch -- /path/To/App.app\n\n\nRecord Time Profiler (attach):\n\nLaunch app yourself, get PID, then:\nxcrun xctrace record --template 'Time Profiler' --time-limit 60s --output /tmp/App.trace --attach <pid>\n\n\nOpen trace in Instruments:\n\nopen -a Instruments /tmp/App.trace\n\nNote: xcrun xctrace --help is not a valid subcommand. Use xcrun xctrace help record."
      },
      {
        "title": "Picking the Correct Binary (Critical)",
        "body": "Gotcha: Instruments may profile the wrong app (e.g., one in /Applications) if LaunchServices resolves a different bundle.\nUse these rules:\n\nPrefer direct binary path for deterministic launch:\n\nxcrun xctrace record ... --launch -- /path/App.app/Contents/MacOS/App\n\n\nIf launching .app, ensure it’s the intended bundle:\n\nopen -n /path/App.app\nVerify with ps -p <pid> -o comm= -o command=\n\n\nIf both /Applications/App.app and a local build exist, explicitly target the local build path.\nAfter launch, confirm the process path before trusting the trace."
      },
      {
        "title": "Command Arguments (xctrace)",
        "body": "--template 'Time Profiler': template name from xctrace list templates.\n--launch -- <cmd>: everything after -- is the target command (binary or app bundle).\n--attach <pid|name>: attach to running process.\n--output <path>: .trace output. If omitted, file saved in CWD.\n--time-limit 60s|5m: set capture duration.\n--device <name|UDID>: required for iOS device runs.\n--target-stdout -: stream launched process stdout to terminal (useful for CLI tools)."
      },
      {
        "title": "Exporting Stacks (CLI)",
        "body": "Inspect trace tables:\n\nxcrun xctrace export --input /tmp/App.trace --toc\n\n\nExport raw time-profile samples:\n\nxcrun xctrace export --input /tmp/App.trace --xpath '/trace-toc/run[@number=\"1\"]/data/table[@schema=\"time-profile\"]' --output /tmp/time-profile.xml\n\n\nPost-process in a script (Python/Rust) to aggregate stacks."
      },
      {
        "title": "Instruments UI Workflow",
        "body": "Template: Time Profiler\nUse “Record” and capture the slow path (startup vs steady-state)\nCall Tree tips:\n\nHide System Libraries\nInvert Call Tree\nSeparate by Thread\nFocus on hot frames and call counts"
      },
      {
        "title": "Gotchas & Fixes",
        "body": "Wrong app profiled: LaunchServices resolves installed app instead of local build.\n\nFix: use direct binary path or --attach with known PID.\n\n\nNo samples / empty trace: App exits quickly or never hits work.\n\nFix: longer capture, trigger workload during recording.\n\n\nPrivacy prompts: xctrace may need Developer Tools permission.\n\nFix: System Settings → Privacy & Security → Developer Tools → allow Terminal/Xcode.\n\n\nLarge XML exports: time-profile exports are huge.\n\nFix: filter with XPath and aggregate offline; don’t print to terminal."
      },
      {
        "title": "iOS Specific Notes",
        "body": "Device: use xcrun xctrace list devices and --device <UDID>.\nLaunch via Xcode if needed; attach with xctrace --attach.\nEnsure debug symbols for meaningful stacks."
      },
      {
        "title": "Verification Checklist",
        "body": "Confirm trace process path matches target build.\nConfirm stacks show expected app frames.\nCapture covers the slow operation (startup/refresh).\nExport stacks for automated diffing if optimizing."
      }
    ],
    "body": "Instruments Profiling (macOS/iOS)\n\nUse this skill when the user wants performance profiling or stack analysis for native apps. Focus: Time Profiler, xctrace CLI, and picking the correct binary/app instance.\n\nQuick Start (CLI)\nList templates: xcrun xctrace list templates\nRecord Time Profiler (launch):\nxcrun xctrace record --template 'Time Profiler' --time-limit 60s --output /tmp/App.trace --launch -- /path/To/App.app\nRecord Time Profiler (attach):\nLaunch app yourself, get PID, then:\nxcrun xctrace record --template 'Time Profiler' --time-limit 60s --output /tmp/App.trace --attach <pid>\nOpen trace in Instruments:\nopen -a Instruments /tmp/App.trace\n\nNote: xcrun xctrace --help is not a valid subcommand. Use xcrun xctrace help record.\n\nPicking the Correct Binary (Critical)\n\nGotcha: Instruments may profile the wrong app (e.g., one in /Applications) if LaunchServices resolves a different bundle. Use these rules:\n\nPrefer direct binary path for deterministic launch:\nxcrun xctrace record ... --launch -- /path/App.app/Contents/MacOS/App\nIf launching .app, ensure it’s the intended bundle:\nopen -n /path/App.app\nVerify with ps -p <pid> -o comm= -o command=\nIf both /Applications/App.app and a local build exist, explicitly target the local build path.\nAfter launch, confirm the process path before trusting the trace.\nCommand Arguments (xctrace)\n--template 'Time Profiler': template name from xctrace list templates.\n--launch -- <cmd>: everything after -- is the target command (binary or app bundle).\n--attach <pid|name>: attach to running process.\n--output <path>: .trace output. If omitted, file saved in CWD.\n--time-limit 60s|5m: set capture duration.\n--device <name|UDID>: required for iOS device runs.\n--target-stdout -: stream launched process stdout to terminal (useful for CLI tools).\nExporting Stacks (CLI)\nInspect trace tables:\nxcrun xctrace export --input /tmp/App.trace --toc\nExport raw time-profile samples:\nxcrun xctrace export --input /tmp/App.trace --xpath '/trace-toc/run[@number=\"1\"]/data/table[@schema=\"time-profile\"]' --output /tmp/time-profile.xml\nPost-process in a script (Python/Rust) to aggregate stacks.\nInstruments UI Workflow\nTemplate: Time Profiler\nUse “Record” and capture the slow path (startup vs steady-state)\nCall Tree tips:\nHide System Libraries\nInvert Call Tree\nSeparate by Thread\nFocus on hot frames and call counts\nGotchas & Fixes\nWrong app profiled: LaunchServices resolves installed app instead of local build.\nFix: use direct binary path or --attach with known PID.\nNo samples / empty trace: App exits quickly or never hits work.\nFix: longer capture, trigger workload during recording.\nPrivacy prompts: xctrace may need Developer Tools permission.\nFix: System Settings → Privacy & Security → Developer Tools → allow Terminal/Xcode.\nLarge XML exports: time-profile exports are huge.\nFix: filter with XPath and aggregate offline; don’t print to terminal.\niOS Specific Notes\nDevice: use xcrun xctrace list devices and --device <UDID>.\nLaunch via Xcode if needed; attach with xctrace --attach.\nEnsure debug symbols for meaningful stacks.\nVerification Checklist\nConfirm trace process path matches target build.\nConfirm stacks show expected app frames.\nCapture covers the slow operation (startup/refresh).\nExport stacks for automated diffing if optimizing."
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/steipete/instruments-profiling",
    "publisherUrl": "https://clawhub.ai/steipete/instruments-profiling",
    "owner": "steipete",
    "version": "1.0.0",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/instruments-profiling",
    "downloadUrl": "https://openagent3.xyz/downloads/instruments-profiling",
    "agentUrl": "https://openagent3.xyz/skills/instruments-profiling/agent",
    "manifestUrl": "https://openagent3.xyz/skills/instruments-profiling/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/instruments-profiling/agent.md"
  }
}