3.9 KiB
3.9 KiB
name, description, version, author, tags
| name | description | version | author | tags | |||
|---|---|---|---|---|---|---|---|
| zhihu-write | Use when the user wants to draft, fill, or publish a Zhihu article through browser actions in the Zhihu editor or creator center. | 0.1.0 | sgclaw |
|
Zhihu Write
Draft or publish a Zhihu article through the creator center and editor flow. Use this skill for filling article title and body, entering the Zhihu editor, and confirming the publish sequence. Do not use it for generic page navigation or hotlist extraction.
When to Use
- The user asks to write, draft, fill, edit, or publish a Zhihu article.
- The task requires entering the Zhihu editor from creator center or the direct write page.
- The task requires browser-side verification that the article title or publish URL is correct.
Do not use this skill for:
- opening ordinary Zhihu pages without editing content
- collecting hotlist or comment metrics
- bulk content generation without a clear article title and body
Workflow
- Confirm the article inputs exist and are non-empty: title and body are both required.
- Decide whether the run is draft-only or publish mode.
- In the SuperRPA browser host, call the packaged browser-script tools before any generic browser probing:
zhihu-write.prepare_article_editorzhihu-write.fill_article_draft
- Enter the editor flow described in editor-flow.md.
- Fill the title first, then the body.
- If the task is publish mode, require explicit human confirmation before clicking publish.
- After publish, verify the final state using title text and published URL when available.
- If a brittle selector is involved, revalidate it using publish-safety.md before acting.
- If the editor is blocked by login, verification, or missing permissions, report that explicit state instead of continuing generic probing.
- Once draft or publish verification succeeds, stop exploratory browser work.
SuperRPA Interface Contract
- Inside the sgClaw browser host, prefer
superrpa_browserfor Zhihu editor actions.browser_actionis only the compatibility alias. - Always pass
expected_domainas the bare hostname only, for examplewww.zhihu.com. - All selectors must be valid CSS selectors because the host executes
document.querySelector(...). - Never use XPath or jQuery-style pseudo-selectors such as
:contains(...). - Prefer the packaged browser-script tools over ad-hoc
getTextorclickprobing. - In the BrowserAttached host, use canonical
www.zhihu.comcreator routes first. - Do not navigate to
zhuanlan.zhihu.comunless the host policy explicitly allows that domain. - Do not retry multiple weak editor selectors when a canonical creator/editor route is available.
Confirmation Rule
- Draft-only mode does not require a publish confirmation gate.
- Publish mode always requires an explicit confirmation from the human operator in the current session.
- If the user’s wording is ambiguous between draft and publish, default to draft and ask before publishing.
Output
Return a concise result with:
- article title
- mode:
draftorpublish - editor entry path used
- final URL if one was captured
- verification result
- unresolved issues or brittle points encountered
- whether login/verification/permission state blocked the requested action
References
- Use editor-flow.md for the action sequence and verification steps.
- Use publish-safety.md before any live publish click.
- Use
assets/zhihu_write_flow.source.jsonwhen the references need exact selector or step names from the source flow.
Common Mistakes
- Publishing when the user only asked for a draft.
- Treating a captured edit URL as proof of successful publication.
- Ignoring title verification after the publish confirmation flow.
- Reusing brittle selectors without checking whether a better semantic selector now exists.