mcpField
S
sosumi

sosumi

github.com/nshipster开发4802.1k 次安装1 周前更新
代码仓库

关于 sosumi

sosumi 是供编码 Agent 查询 Apple API、设计指南或 WWDC 内容的技能,提供搜索和抓取流程,将文档作为 Markdown 获取,也支持外部 Swift-DocC 页面。

主要功能

  1. 01搜索 Apple 文档
  2. 02以 Markdown 获取 API 页面
  3. 03获取人机界面指南内容
  4. 04获取 WWDC 字幕
  5. 05获取外部 Swift-DocC

适用场景

  1. 01核对 Swift API 签名与可用性
  2. 02解答人机界面指南问题
  3. 03查找 WWDC 会议字幕

MCP 相关

配置为 https://sosumi.ai/mcp 上的 MCP 服务后,它提供搜索和获取 Apple 文档、人机界面指南页面、视频字幕及外部 Swift-DocC 页面等工具。

安装

复制下面的命令,在终端中运行。

$npx skills add https://github.com/nshipster/sosumi.ai --skill sosumi

安装后在 Claude Code 中输入/sosumi确认已加载。

包含的文件

除 SKILL.md 外,安装时一起下载的参考资料和脚本。

_headers
favicon.svg
index.html
llms.txt
robots.txt
sitemap.xml
sosumi.m4a
webmcp.js
icons/
square.and.pencil.svg

详细介绍

Sosumi 技能

当编码 Agent 需要精确的 API 详情时,使用此技能以可靠地获取 Apple 文档的 Markdown 内容。

适用场景

当请求涉及以下任一内容时,请使用 Sosumi:

  • Apple 平台 API(Swift、SwiftUI、UIKit、AppKit、Foundation 等)
  • API 签名、可用性、参数行为或返回语义
  • Human Interface Guidelines 相关问题
  • 查询 WWDC 会议字幕
  • 外部 Swift-DocC 文档(例如,GitHub Pages 或 Swift Package Index 托管的文档)

核心工作流

  1. 如果已有 developer.apple.com URL,请将主机名替换为 sosumi.ai,并保留相同的路径。
  2. 如果不知道确切的页面路径,请先搜索,再获取最匹配的页面。
  3. 回答实现问题时,优先选择具体的符号页面,而不是宽泛的顶层页面。
可选的 CLI 预检

如果 Sosumi CLI 可用,请先快速确认本地访问正常,再进行深入调试:

  • sosumi --version 可确认 CLI 已安装且位于 PATH 中。
  • sosumi --help 可查看顶层用法。
  • sosumi <command> --help 是特定命令行为的手册。

HTTP 用法

将 developer.apple.com 替换为 sosumi.ai:

  • 原始地址:https://developer.apple.com/documentation/swift/array
  • AI 可读地址:https://sosumi.ai/documentation/swift/array

内容类型

Apple API 参考
  • 模式:https://sosumi.ai/documentation/{framework}/{symbol}
  • 示例:
    • https://sosumi.ai/documentation/swift/array
    • https://sosumi.ai/documentation/swiftui/view
Human Interface Guidelines
  • 模式:https://sosumi.ai/design/human-interface-guidelines/{topic}
  • 示例:
    • https://sosumi.ai/design/human-interface-guidelines
    • https://sosumi.ai/design/human-interface-guidelines/foundations/color
Apple 视频字幕
  • 模式:https://sosumi.ai/videos/play/{collection}/{id}
  • 示例:
    • https://sosumi.ai/videos/play/wwdc2021/10133
    • https://sosumi.ai/videos/play/meet-with-apple/208
外部 Swift-DocC
  • 模式:https://sosumi.ai/external/{full-https-url}
  • 示例:
    • https://sosumi.ai/external/https://apple.github.io/swift-argument-parser/documentation/argumentparser/
    • https://sosumi.ai/external/https://swiftpackageindex.com/pointfreeco/swift-composable-architecture/1.23.1/documentation/composablearchitecture

MCP 工具速查

当 Sosumi 配置为 MCP 服务(https://sosumi.ai/mcp)时,请使用以下工具:

工具参数用途
searchAppleDocumentationquery: string搜索 Apple 文档并返回结构化结果
fetchAppleDocumentationpath: string按路径获取 Apple 文档或 HIG 内容,格式为 Markdown
fetchAppleVideoTranscriptpath: string按 /videos/play/... 路径获取 Apple 视频字幕
fetchExternalDocumentationurl: string按绝对 HTTPS URL 获取外部 Swift-DocC 页面

最佳实践

  • 如果不知道确切路径,请先搜索。
  • 对于编码问题,请获取目标明确的符号页面。
  • 在回答中保留来源链接,方便用户快速验证详情。
  • 引用 Apple 文档页面时,直接在回复中使用 Sosumi 路径。
  • 不要依赖一致性条件,例如“当 Element 遵循 Hashable 时遵循该协议”。Apple 文档数据可能会遗漏部分条件,也可能存在错误。当条件很重要时,请查看 SDK 中模块的 .swiftinterface 文件里的声明。

故障排除

404 或输出内容过少
  • 路径可能不正确,或范围过宽。
  • 先运行搜索查询,再获取具体结果路径。
无法获取外部页面
  • 主机可能通过 robots.txt 或 X-Robots-Tag 指令阻止访问。
  • 请尝试同一符号的其他规范页面 URL。

评论

支持 Markdown