
wewrite
PopularMain entry point for WeChat Official Account content: completes topic selection, material research, writing, and editorial review, and independently handles image generation, layout design, or publishing to draft box upon user request. Also responsible for routing style settings, edit learning, data retrospectives, and multi-platform rewriting to the corresponding wewrite-* modules. Trigger keywords: WeChat Official Account, WeChat article, WeChat post, draft box, WeChat layout, write Official Account article, write a post. Does not trigger for general articles, blogs, emails, short video scripts, or website SEO.
Related Skills
Main entry point for WeChat Official Account content: completes topic selection, material research, writing, and editorial review, and independently handles image generation, layout design, or publishing to draft box upon user request. Also responsible for routing style settings, edit learning, data retrospectives, and multi-platform rewriting to the corresponding wewrite-* modules. Trigger keywords: WeChat Official Account, WeChat article, WeChat post, draft box, WeChat layout, write Official Account article, write a post. Does not trigger for general articles, blogs, emails, short video scripts, or website SEO.
WeWrite — Main WeChat Official Account Content Entry Point
Operational Principles
- Run through the content pipeline continuously by default without pausing at every step. Confirm at the topic and outline stages only when the user explicitly requests "interactive mode".
- Each article must use an independent task directory; never overwrite another article.
- "Write a post" defaults to delivering only the reviewed local draft; generating images and publishing are not default actions.
- Image generation, layout formatting, and publishing are independent actions after the main text is completed; never trigger image generation automatically for formatting or publishing.
- "Full production" is a shortcut combining main text generation, image creation, and local preview; calling the publish command is allowed only when explicitly requested (e.g., "push to draft box/publish").
- When web searches fail, you may continue writing based on analysis and professional reasoning, but never package model memory as verified facts.
{home} is the status directory returned by wewrite home. {skill_dir} is the current skill directory. Deterministic operations are executed via wewrite commands.
Routing
| User Intent | Module |
|---|---|
| Reset style | wewrite-style |
| Topic selection only | wewrite-topic |
| Review article | wewrite-review |
| Cover or illustrations | wewrite-visual |
| Layout, preview, draft box, image posts | wewrite-publish |
| Learn from edits, reference samples, topics | wewrite-learn |
| Data retrospective | wewrite-stats |
| Multi-platform rewriting | wewrite-rewrite |
Activate the skill with the matching name if present in the environment; otherwise, fully read SKILL.md in the sibling directory before executing.
Content Pipeline
1. Initialize or Resume Task
First run wewrite diagnose --json. Guide installation only if commands are missing or dependencies fail; a missing style file is normal for first-time setup, so route to wewrite-style.
Select mode based on the user's exact wording:
# Default "write a post": no image generation, no publishing
wewrite run start --topic "{topic, optional}" --mode draft --visual-mode none
# "Full production": complete main text first; generate images and preview independently after archiving main text
wewrite run start --topic "{topic, optional}" --mode complete --visual-mode none
# "Push to draft box": user explicitly authorized publishing, but do not automatically generate images for this reason
wewrite run start --topic "{topic, optional}" --mode publish --visual-mode none
Write the diagnose flags and current date to the task:
wewrite run update --patch '{"flags": {"skip_publish": false, "skip_image_gen": false, "use_writer_model": false, "needs_onboard": false, "diagnosed_at": "YYYY-MM-DD"}}'
If the user says "continue previous task", first execute wewrite run list, identify the unique task, and run wewrite run resume <run_id>; do not create a new task.
2. Topic Selection
If the user provided a topic, record it and skip selection; otherwise execute wewrite-topic. Upon completion:
wewrite run step topic completed
3-4. Article Task, Evidence, and First Draft
Execute wewrite-write. First save artifacts.brief and artifacts.claims, then save the initial draft to artifacts.draft; sync all web sources to sources.yaml for this task. The initial draft is not the final article.
5. Editorial Review
Execute wewrite-review. Facts, arguments, practical value, account tone, and readability are the primary standards; directly revise the draft and re-review upon finding fixable issues. Write the final text to artifacts.article only when the editor decision is pass and artifacts.review_report shows publishable=true. Tool scores are merely hints for potential issues.
6. Archive Main Text
Once the article exists, editorial review has passed, and report is saved, immediately execute:
wewrite run finish
This command archives the main text and sources into history. After archiving, you can still append images, previews, and publishing results to the current article, but you must not rewrite the original main text.
Optional Follow-up Actions
A. Image Generation
- When the user asks to "add a cover", set
visual.modetocover. - When the user asks for "full illustrations" or "full production", set
visual.modetofull. - Set to
promptsif the user only requests image prompts; automatically fallback to prompts if image configurations are missing. - Execute
wewrite-visual. It can only generate standalone images and an illustrated copy; it must not overwriteartifacts.article.
If the article is already finished, use the current task directly without creating a new writing task. Strictly abide by max_images and max_cost.
B. Layout Formatting and Publishing
Execute wewrite-publish. It prioritizes formatting the illustrated copy (falls back to the original main text if unavailable) and does not call wewrite-visual automatically. If the user explicitly requests publishing in the current round, run wewrite run permission publish allow first; if the user revokes it, run wewrite run permission publish deny. Push to the draft box only when permissions.publish=true, publishing config is available, and cover image exists; generate local preview in all other cases.
C. "Full Production" Shortcut
First run through the complete content pipeline and archive the main text, then sequentially execute wewrite-visual in full mode and wewrite-publish local preview. It is a continuous execution of three independent actions and does not grant publishing permission.
Finally, inform the user about the title, original article path, illustrated copy path, source count, image/preview results, whether it entered the draft box, and any fallbacks that occurred.
Failure and Recovery
Record when a step fails:
wewrite run step <topic|write|review|visual|publish> failed --error "brief reason"
When a content step fails, retain the current task; upon resuming next time, rerun only failed or uncompleted steps. If the main text has been archived, failure in image generation or publishing will not alter the completed status of the article; publishing failures fall back to local previews, and image failures retain prompts. When web searches fail, remove unverified specific numbers and quotes.





