SuperAPI AI Directory

writing-style-coach

Writing & research

View repository

Updated 10-15 22:13

About this skill

Writing Style Learning Tool

An AI-based writing style learning tool that can analyze a user's historical articles, extract writing style features, and generate new content based on the style.

Core Features

  1. Style Analysis - 5-dimension analysis (title, opening, content structure, language style, ending)
  2. Style Description Generation - Structured description, Prompt template, style tags
  3. Style-based Generation - Title generation, content polishing, article creation
  4. Style Library Management - Style saving, style comparison, style fusion

Workflow

Process 1: Analyze writing style

输入:10-50篇历史文章(纯文本)

Steps:

  1. Tokenization and part-of-speech tagging
  2. Extract features across 5 dimensions
  3. Calculate statistical metrics (average sentence length, vocabulary diversity)
  4. Identify commonly used patterns and sentence structures
  5. Generate style score

Output: Style analysis JSON + style description + style tags


### 流程2:生成风格Prompt

Input: Style analysis JSON

Steps:

  1. Read style features
  2. Organize descriptions by dimension
  3. Generate reusable Prompt templates
  4. Add examples and notes

Output: Style Prompt MD file


### 流程3:基于风格生成标题

Input: Topic + style Prompt

Steps:

  1. Analyze title style patterns
  2. Extract keywords and sentence structures
  3. Generate multiple candidate titles
  4. Sort by style match score

Output: Candidate title list + match scores


### 流程4:基于风格润色内容

Input: Original text + style Prompt

Steps:

  1. Analyze the structure and content of the original text
  2. Adjust vocabulary and sentence structures according to the style
  3. Preserve the core information of the original text
  4. Generate polished text

Output: Polished text + change notes


## 5个分析维度

### 1. 标题风格
- **模式识别**:数字+亮点、悬念+结果、对比+反差
- **长度分析**:平均字数、最短/最长
- **关键词提取**:高频词、行业术语

### 2. 开头风格
- **模式识别**:热点引入、痛点提问、数据震撼
- **长度分析**:平均字数
- **基调分析**:专业/轻松/幽默

### 3. 内容结构
- **整体结构**:总分总、逐步深入、并列式
- **段落组织**:段落数量、段落长度
- **内容要素**:案例数量、数据支撑、技巧数量

### 4. 语言风格
- **词汇选择**:专业术语、通俗程度、形象比喻
- **句式特点**:平均句长、句式类型
- **基调风格**:理性/感性、正式/口语

### 5. 结尾风格
- **模式识别**:总结提升、行动号召、福利引导
- **长度分析**:平均字数
- **行动号召**:关注/点赞/分享/评论

详见:references/analysis-dimensions.md

## API 使用

### handler(args) 主函数

```python
from style_learner import handler

# 分析写作风格
args = {
    "action": "analyze_style",
    "articles": "文章1内容\n\n文章2内容...",
    "output_file": "style_analysis.json"
}
result = handler(args)

# 生成风格Prompt
args = {
    "action": "generate_style_prompt",
    "style_file": "style_analysis.json",
    "output_file": "style_prompt.md"
}
result = handler(args)

# 基于风格生成标题
args = {
    "action": "generate_title_from_style",
    "topic": "AI写作工具",
    "style_prompt_file": "style_prompt.md",
    "count": 5
}
result = handler(args)

# 基于风格润色内容
args = {
    "action": "polish_with_style",
    "text": "待润色的文本",
    "style_prompt_file": "style_prompt.md"
}
result = handler(args)

See: references/api-reference.md

Design Trade-off Explanation

Why is a minimum of 10 articles recommended?

Answer: To ensure analysis accuracy

Data Support:

  • <5 articles: Feature extraction is unstable, accuracy 50-60%
  • 5-9 articles: Basically usable, accuracy 65-75%
  • 10-20 articles: Recommended range, accuracy 80-90%
  • 20-50 articles: Optimal range, accuracy 90-95%
  • 50 articles: Diminishing marginal returns

Trade-off Analysis:

  • Too few(<10 articles): Insufficient samples, unstable features
  • Too many(>50 articles): High computational cost, low marginal returns
  • Moderate(10-50 articles): Balances accuracy and efficiency

Flexible Application:

  • Quick learning: 10-20 articles
  • Precise analysis: 20-50 articles
  • New accounts: 5-10 articles can be used, but results are for reference only

Why analyze 5 dimensions?

Answer: To comprehensively cover the key elements of writing style

Dimension Selection:

  • Title: Determines click-through rate
  • Opening: Affects reading completion rate
  • Structure: Affects readability
  • Language: Affects reading experience
  • Ending: Affects engagement rate

Data support:

  • 3 dimensions: insufficient coverage, accuracy 70%
  • 5 dimensions: covers key elements, accuracy 85-90%
  • 7 dimensions: marginal returns are small, accuracy 90-92%
  • Gap: 5 dimensions vs 3 dimensions, accuracy differs by 15-20%

Flexible application:

  • Quick analysis: analyze only the title + language + ending (3 dimensions)
  • Standard analysis: analyze all 5 dimensions
  • In-depth analysis: add emotional tendency, rhetorical devices, etc. (7+ dimensions)

Why generate a style Prompt?

Answer: Achieve reusability and transferability of style

Traditional problems:

  • AI needs to relearn the style every time
  • Style features are difficult to express quantitatively
  • Style consistency cannot be maintained across sessions

Prompt advantages:

  • Reusable: learn once, use many times
  • Transferable: different AI instances use the same style
  • Adjustable: fine-tune the style based on the Prompt

Data support:

  • Using Prompt: style consistency 80-90%
  • Not using Prompt: style consistency 50-60%
  • Gap: 1.5-1.8 times

Flexible application:

  • Style stability: continue using after generating the Prompt
  • Style evolution: regularly update the Prompt (monthly/quarterly)
  • Multiple styles: save multiple Prompt versions

Data volume recommendations

Minimum data volume

  • 10 articles: minimum requirement, features are basically stable
  • Suitable for: quick learning, style exploration
  • Accuracy: 80-85%

Recommended data volume

  • 20-30 articles: recommended range, features are stable
  • Suitable for: most scenarios
  • Accuracy: 90-95%

Optimal data volume

  • 50+ articles: optimal range, features are very stable
  • Suitable for: precise analysis, style library construction
  • Accuracy: 95%+

Notes

  1. Article quality: choose representative articles, avoid drafts
  2. Time span: choose articles from the last 3-6 months
  3. Content consistency: avoid mixing across domains (such as technology + emotions)

See: references/data-requirements.md

Style feature examples

Example: professional review style

Title style:

  • Pattern: numbers + highlights, suspense + results
  • Length: 15-35 characters
  • Keywords: reveal, techniques, breakthrough, must-have tool

Opening style:

  • Pattern: trending topic introduction, pain point question
  • Length: 100-200 characters
  • Tone: professional but not boring

Content structure:

  • Structure: general-specific-general
  • Paragraphs: 5-12 paragraphs, each 80-180 characters
  • Elements: 1-3 cases, 2-5 data points, 3-6 techniques

Language style:

  • Vocabulary: professional terminology + plain explanation
  • Sentence length: average 25 characters (range 10-50 characters)
  • Tone: pragmatic

Ending style:

  • Mode: summary enhancement, call to action
  • Length: 50-150 characters
  • Call to action: follow to receive

See: references/style-examples.md

Application scenarios

  1. Quickly learn a WeChat Official Account style: Collect 10-20 articles to quickly learn the writing style
  2. Unify team writing style: Analyze multiple authors and extract common features
  3. Style transfer: Transfer the style of high-quality articles to your own articles
  4. Style optimization: Analyze your own shortcomings and learn from the style of high-quality articles
  5. Batch content generation: Generate content in batches based on a style Prompt

Notes

Data quality

  1. Article representativeness: Choose representative articles and avoid drafts
  2. Time span: Choose articles from the most recent 3-6 months
  3. Content consistency: Avoid mixing across domains
  4. Data cleaning: Remove non-body content such as ads and promotions

Analysis limitations

  1. Style changes: An author's style evolves over time
  2. Topic influence: Different topics may affect style analysis
  3. Subjective factors: Style evaluation has a certain degree of subjectivity
  4. Data volume dependence: Results are unstable when the data volume is small

Usage recommendations

  1. Regular updates: Update the style analysis once every 3-6 months
  2. Human-machine combination: AI analysis + manual adjustment
  3. Flexible application: Adjust the style intensity according to the scenario
  4. Multi-version management: Save style versions from different periods

Reference materials

Core documents

  • Detailed explanation of analysis dimensions:references/analysis-dimensions.md
  • Data requirements:references/data-requirements.md
  • Style examples:references/style-examples.md
  • API reference:references/api-reference.md

Get started

Just say "learn style" or "analyze style", and the system will automatically guide you through it!

Detailed usage instructions: references/getting-started.md