toutiao-publisher
/toutiao-publisher
Przygotowuje i publikuje artykuły na Toutiao: sprawdza lub przywraca stan logowania, wypełnia szkice z Markdown ze zdjęciami i okładkami oraz opcjonalnie kończy publikację.
- Autor
- guanyang ↗
- Repozytorium
- super-publisher ↗
- Licencja
- MIT
- Ostatnia zmiana repozytorium
- 13.10.2026
Ocena i bezpieczeństwo
- Pliki w paczce
- 20
- Skrypty
- 17
- Komentarze HTML
- 0
- Adresy URL w SKILL.md
- 0
Brak sygnałów. Repozytorium zmienione 13.10.2026, bez odwołań do wycofanych modeli i API.
MIT, otwarta: można używać i zmieniać, z zachowaniem informacji o autorze.
- 17 skryptów w paczce. Przejrzyj je przed instalacją, bo Claude może je uruchomić.
Skrypty: scripts/auth_manager.py, scripts/browser_utils.py, scripts/cli_utils.py, scripts/config.py, scripts/md2html.py, scripts/publisher.py, scripts/run.py, scripts/setup_environment.py
Co robi i kiedy
Przygotowuje i publikuje artykuły na Toutiao: sprawdza lub przywraca stan logowania, wypełnia szkice z Markdown ze zdjęciami i okładkami oraz opcjonalnie kończy publikację.
Oryginalny opis (EN)
Publish or prepare articles for Toutiao/头条号, check or restore shared login state, fill Markdown drafts with inline images and covers, and optionally complete final publishing. Use for requests such as 发布到头条、检查头条登录、填充头条草稿、上传图文、人工审核 or explicitly authorized automatic publishing.
Jak działa
- Safety rules
- Preflight authentication
- Prepare and publish an article
- Result contract
- Session management
- Environment
Podgląd SKILL.md
--- name: toutiao-publisher description: Publish or prepare articles for Toutiao/头条号, check or restore shared login state, fill Markdown drafts with inline images and covers, and optionally complete final publishing. Use for requests such as 发布到头条、检查头条登录、填充头条草稿、上传图文、人工审核 or explicitly authorized automatic publishing. --- # Toutiao Publisher Use the scripts from this Skill directory. Resolve the directory containing this `SKILL.md` first and set its absolute path as `SKILL_DIR`; do not assume the caller's working directory is the Skill directory. ## Safety rules - Default to `--mode manual`. Leave Chrome open for the user to review and click Publish. - Use `--mode auto` only when the user explicitly authorizes final publishing. - Run `clear --yes` or `reauth --yes` only after the user confirms that all local Agents may lose the shared Toutiao session. - Do not bypass input validation or treat an unconfirmed publish click as success. ## Preflight authentication Check the protected Toutiao page before asking the user to scan a QR code: ```bash python3 "$SKILL_DIR/scripts/run.py" auth_manager.py status --verify --json ``` If the result status is `not_authenticated`, open the interactive login flow: ```bash python3 "$SKILL_DIR/scripts/run.py" auth_manager.py setup --json ``` The shared profile lives under `~/.super-publisher/toutiao-publisher/` by default. Codex, Kiro, Antigravity, and direct CLI runs by the same system user reuse it. Set `SUPER_PUBLISHER_DATA_DIR` to override the location; relative values resolve from the user home directory. ## Prepare and publish an article Validate inputs without opening Chrome: ```bash python3 "$SKILL_DIR/scripts/run.py" publisher.py \ --mode validate \ --title "AI Trends 2026" \ --content-file "/absolute/path/article.md" \ --cover "/absolute/path/cover.jpg" \ --json ``` After validation succeeds, fill the draft and wait for manual review: ```bash python3 "$SKILL_DIR/scripts/run.py" publisher.py \ --mode manual \ --title "AI Trends 2026" \ --content-file "/absolute/path/article.md" \ --cover "/absolute/path/cover.jpg" \ --json ``` Use direct text only through `--content-text`. `--content` remains an alias for `--content-file`; a missing path is an error rather than literal article text. Markdown supports headings, links, ordered and unordered lists, block quotes, tables, fenced code, inline code, emphasis, and local inline images. Resolve relative image paths from the Markdown file. If the body contains images, skip explicit cover upload. Use `--no-cover` only when the body has no image and no cover is supplied. For explicitly authorized automatic publishing: ```bash python3 "$SKILL_DIR/scripts/run.py" publisher.py \ --mode auto \ --title "AI Trends 2026" \ --content-file "/absolute/path/article.md" \ --headless \ --json ``` Automatic publishing succeeds only after Toutiao displays a recognized success indicator. A final-button click without confirmation returns `publish_unconfirmed`. ## Result contract With `--json`, authentication commands write one JSON result to stdout. Publisher commands write newline-delimited JSON events; manual mode emits `awaiting_manual_review` before waiting for the user. - Exit `0`: authenticated, input valid, manual review completed, or publish confirmed. - Exit `1`: runtime, browser interaction, draft, upload, or publish failure. - Exit `2`: invalid input, missing authentication, or clear confirmation required. Treat stderr as human-readable diagnostics. Do not parse emojis or prose to determine success. ## Session management ```bash # Read local state only python3 "$SKILL_DIR/scripts/run.py" auth_manager.py status --json # Verify against Toutiao and refresh state python3 "$SKILL_DIR/scripts/run.py" auth_manager.py validate --json # Destructive: require explicit user confirmation first python3 "$SKILL_DIR/scripts/run.py" auth_manager.py clear --yes --json ``` ## Environment Require Python 3.9+, Google Chrome, and local network access. `scripts/run.py` bootstraps `scripts/setup_environment.py`, verifies the requirements fingerprint, and executes the target with the Skill-local `.venv` Python. The shared state directory uses owner-only permissions. Avoid starting concurrent browser operations against the same persistent Chrome Profile. Enable `--debug-screenshots` only when troubleshooting. Screenshots are written under `output/toutiao-publisher-debug/` by default.
Pliki w paczce (20)
- README.md 8 KB
- SKILL.md 4 KB
- requirements.txt 1 KB
- scripts/auth_manager.py 20 KB
- scripts/browser_utils.py 3 KB
- scripts/cli_utils.py 1 KB
- scripts/config.py 1 KB
- scripts/md2html.py 3 KB
- scripts/publisher.py 44 KB
- scripts/run.py 5 KB
- scripts/setup_environment.py 8 KB
- tests/test_auth_manager.py 8 KB
- tests/test_browser_utils.py 1 KB
- tests/test_config.py 1 KB
- tests/test_md2html.py 2 KB
- tests/test_publisher_cli.py 5 KB
- tests/test_publisher_cover_policy.py 1 KB
- tests/test_publisher_debug.py 1 KB
- tests/test_run.py 5 KB
- tests/test_setup_environment.py 3 KB
Wersje
W bazie nie ma innych skilli o nazwie toutiao-publisher.
Migawka bazy z 28.10.2026 · wersja paczki 5b74e9b99012 (skrót SHA-256 całej paczki)
Pobrania w ostatnich 30 dniach: 0 · ranking
Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.
Podobne skille
- 100toutiao
Czyta i publikuje na Toutiao z własnymi ciasteczkami logowania użytkownika: lista artykułów ze statystykami, podgląd artykułu oraz publikacja nowego artykułu lub szkicu. - 100toutiao-content-research
Bada treści na Toutiao: na podstawie tematu lub linku wskazuje wzorce tytułów i kierunki do sprawdzenia. - 100md2wechat
Konwertuje Markdown na HTML dla WeChat Official Account, generuje obrazy artykułów, tworzy szkice, proponuje tytuły, usuwa ślady pisania AI i obsługuje szkice Zhihu, CSDN i Toutiao przez przeglądarkę. - 100wechatsync
Publikuje i synchronizuje artykuły Markdown lub HTML na ponad 29 platform, np. Zhihu, Juejin, CSDN, Weibo i WordPress. - 100linkedin-article-publisher
Publikuje artykuły z Markdowna w edytorze LinkedIn Articles z poprawnym formatowaniem, wgrywa grafikę okładki i konwertuje Markdown na tekst sformatowany. - 100recoup-internal-consulting-linkedin-publisher
Przygotowuje, publikuje lub planuje post LinkedIn przez wybrane konto publikacyjne workspace'u i zweryfikowany stan dostawcy.