feat(skill/playwright): unify shared-session CLI flow for web skills

This commit is contained in:
2026-03-04 12:19:57 +08:00
parent aa72b570e1
commit 8fc5c6e128
12 changed files with 411 additions and 236 deletions
+7
View File
@@ -16,6 +16,13 @@ description: "Execute XiaoHongShu (小红书) image-note publishing workflow in
7. Execute publish behavior according to publish mode.
8. Save publish evidence and return summary.
## Shared Session Policy
- Reuse a single Playwright CLI session across all web-automation skills:
- `export PLAYWRIGHT_SHARED_SESSION=codex-shared`
- Use `/Users/xd/java/xhs/tools/pw` as the only Playwright CLI entrypoint.
- Do not pass `--session` directly in skill-specific commands.
## 1) Enter Creator Publish Page
- From web homepage, click left sidebar `发布`.
@@ -1,4 +1,4 @@
interface:
display_name: "XHS Publish Note"
short_description: "Publish XHS image notes with manifest image linkage, hard gates, and publish modes"
default_prompt: "Use $xiaohongshu-publish-note to publish XiaoHongShu image notes: prefer user image paths, otherwise generate via $gemini-image-web and use manifest target paths, enforce hard gates (images>=1, topics>=5, no location), and run in safe_mode by default unless live_mode is explicitly requested."
default_prompt: "Use $xiaohongshu-publish-note with PLAYWRIGHT_SHARED_SESSION=codex-shared and run all browser steps via /Users/xd/java/xhs/tools/pw; publish XiaoHongShu image notes by preferring user image paths, otherwise generate via $gemini-image-web and use manifest target paths, enforce hard gates (images>=1, topics>=5, no location), and run in safe_mode by default unless live_mode is explicitly requested."