sf-docs by jaganpro/sf-skills
npx skills add https://github.com/jaganpro/sf-skills --skill sf-docs使用此技能来检索并基于公共网络上的官方 Salesforce 文档提供有根据的答案。
此技能设计上保持简单:
它的任务是提供一个可靠的在线检索方案,用于获取难以抓取的 Salesforce 文档,特别是 help.salesforce.com、JS 密集的 developer.salesforce.com、lightningdesignsystem.com 上的 Lightning Design System 文档,以及其他 Salesforce 官方拥有的文档页面,如 architect.salesforce.com 和 admin.salesforce.com。
一个可选的包装脚本位于:
skills/sf-docs/scripts/extract_salesforce_doc.py广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
它会自动将 help.salesforce.com 的 URL 路由到专用的 Help 提取器,并通过通用的浏览器渲染路径支持其他官方文档页面,如 *.salesforce.com 和 lightningdesignsystem.com。对于反机器人敏感的页面,当安装了 playwright-stealth 时,它还支持通过 --stealth 参数启用尽力而为的可选隐身模式。
专用的 Help 提取器也可直接通过以下路径使用:
skills/sf-docs/scripts/extract_help_salesforce.py找到最佳的官方 Salesforce HTML 在线页面,并提取足够的实际内容以自信地回答。
如果证据不足,请明确说明,而不是强行给出一个无力的答案。
当用户询问以下内容时,使用 sf-docs:
developer.salesforce.com 的文档help.salesforce.com 的文档优先使用 Salesforce 拥有的文档来源:
developer.salesforce.comhelp.salesforce.comarchitect.salesforce.comadmin.salesforce.comlightningdesignsystem.com避免第三方博客、视频或摘要文章,除非用户明确要求。
不要回退到 PDF。
在抓取任何内容之前,先确定可能的文档系列。
| 系列 | 典型来源 | 用于 |
|---|---|---|
| 开发者文档 | developer.salesforce.com/docs/... | Apex、API、LWC、元数据、Agentforce 开发者文档 |
| 帮助文档 | help.salesforce.com/... | 设置、管理、产品配置 |
| 架构师/管理员文档 | architect.salesforce.com/..., admin.salesforce.com/... | 最佳实践、模式、架构良好指南、管理员赋能 |
| 设计系统文档 | lightningdesignsystem.com/... | SLDS、Cosmos、设计令牌、组件和样式指南 |
| 旧版 atlas 文档 | developer.salesforce.com/docs/atlas.en-us.* | 较旧的官方指南和参考文档 |
在搜索之前提取真正的目标:
示例:
Lightning Message ServiceWire ServiceSystem.StubProviderAgentforce ActionsMessaging for In-App and Web allowed domains不要对 Salesforce 文档进行广泛爬取。
而是:
指南着陆页不够充分,除非它明确包含所请求的确切概念。
这对于以下情况尤其重要:
developer.salesforce.com使用此方案:
help.salesforce.com帮助页面通常无法通过简单的抓取获取。
使用此方案:
articleView?id=... URL(如果可用)Loading、Sorry to interrupt、CSS Error 或主要是 chrome/导航文本的输出视为提取失败,而非证据一个页面足以从中回答,仅当至少满足以下条件之一时:
一个页面不足够好,当:
拒绝将这些作为最终证据:
回答时,请包含:
如果证据薄弱,请明确说明。
不要停留在通用的 LWC 指南根目录。找到 Lightning Message Service 的确切 LWC 页面,或者从 LWC 文档中跟踪最相关的子链接,直到出现确切概念。
不要从 LWC 主页回答,除非 Wire Service 实际出现在那里。跟踪 wire service 或 wire adapters 的相关子文档页面。
不要从广泛的 Agentforce 着陆页或博客文章回答。找到 actions 的官方 Agentforce 开发者页面,或者从官方 Agentforce 文档中跟踪最匹配的子页面。
优先使用官方帮助文章和浏览器渲染提取。拒绝通用的帮助 shell。如果需要,从附近的官方消息传递文档跟踪链接的帮助文章。
优先选择确切标识符出现的官方 Salesforce 参考/开发者页面。如果标识符缺失,不要用更广泛的 Apex 着陆页替代。
此技能不应:
其他 sf-* 技能在需要权威的 Salesforce 文档时,应使用 sf-docs,而不是仅仅依赖通用搜索。
每周安装数
91
仓库
GitHub 星标数
219
首次出现
10 天前
安全审计
安装于
cursor90
gemini-cli88
codex88
opencode88
github-copilot87
amp87
Use this skill to retrieve and ground answers in official Salesforce documentation on the public web.
This skill is intentionally simple:
Its job is to provide a reliable online retrieval playbook for Salesforce docs that are hard to fetch, especially help.salesforce.com, JS-heavy developer.salesforce.com, Lightning Design System docs on lightningdesignsystem.com, and other official Salesforce-owned doc pages such as architect.salesforce.com and admin.salesforce.com.
An optional wrapper script is available at:
skills/sf-docs/scripts/extract_salesforce_doc.pyIt automatically routes help.salesforce.com URLs into the dedicated Help extractor and supports other official documentation pages such as *.salesforce.com and lightningdesignsystem.com through a generic browser-rendered path. For bot-sensitive pages, it also supports best-effort optional stealth mode via --stealth when playwright-stealth is installed.
The dedicated Help extractor is also available directly at:
skills/sf-docs/scripts/extract_help_salesforce.pyFind the best official Salesforce HTML page online and extract enough real content to answer confidently.
If the evidence is weak, say so clearly instead of forcing a weak answer.
Use sf-docs when a user asks for:
developer.salesforce.comhelp.salesforce.comPrefer Salesforce-owned documentation sources:
developer.salesforce.comhelp.salesforce.comarchitect.salesforce.comadmin.salesforce.comlightningdesignsystem.comAvoid third-party blogs, videos, or summary articles unless the user explicitly asks for them.
Do not fall back to PDFs.
Before fetching anything, identify the likely doc family.
| Family | Typical Source | Use For |
|---|---|---|
| Developer docs | developer.salesforce.com/docs/... | Apex, APIs, LWC, metadata, Agentforce developer docs |
| Help docs | help.salesforce.com/... | setup, admin, product configuration |
| Architect/Admin docs | architect.salesforce.com/..., admin.salesforce.com/... | best practices, patterns, well-architected guidance, admin enablement |
| Design system docs | lightningdesignsystem.com/... | SLDS, Cosmos, design tokens, component and styling guidance |
Extract the real target before you search:
Examples:
Lightning Message ServiceWire ServiceSystem.StubProviderAgentforce ActionsMessaging for In-App and Web allowed domainsDo not broad-crawl Salesforce docs.
Instead:
A guide landing page is not enough unless it clearly contains the exact requested concept.
This is especially important for:
developer.salesforce.comUse this playbook:
help.salesforce.comHelp pages often fail with naive fetching.
Use this playbook:
articleView?id=... URLs when availableLoading, Sorry to interrupt, CSS Error, or mostly chrome/navigation text as failed extraction , not evidenceA page is good enough to answer from only when at least one of these is true:
A page is not good enough when:
Reject these as final evidence:
When answering, include:
If evidence is weak, say so plainly.
Do not stop at the general LWC guide root. Find the exact LWC page for Lightning Message Service or follow the most relevant child links from the LWC docs until the exact concept appears.
Do not answer from the LWC homepage unless Wire Service is actually present there. Follow the relevant child doc page for wire service or wire adapters.
Do not answer from a broad Agentforce landing page or a blog post. Find the official Agentforce developer page for actions, or follow the best matching child pages from the official Agentforce docs.
Prefer official Help articles and browser-rendered extraction. Reject generic help shells. Follow linked Help articles from nearby official messaging docs if needed.
Prefer the official Salesforce reference/developer page where the exact identifier appears. Do not substitute a broader Apex landing page if the identifier is absent.
This skill should not :
Other sf-* skills should use sf-docs when they need authoritative Salesforce documentation instead of relying on generic search alone.
Weekly Installs
91
Repository
GitHub Stars
219
First Seen
10 days ago
Security Audits
Gen Agent Trust HubPassSocketPassSnykWarn
Installed on
cursor90
gemini-cli88
codex88
opencode88
github-copilot87
amp87
React 组合模式指南:Vercel 组件架构最佳实践,提升代码可维护性
118,000 周安装
| Legacy atlas docs | developer.salesforce.com/docs/atlas.en-us.* | older official guide and reference docs |