style-extract

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

风格提取

Style Extraction

从文章中提取写作风格特征,建立和维护个人风格档案。
Extract writing style characteristics from articles to establish and maintain personal style profiles.

核心概念

Core Concepts

风格不是抽象的"好"或"差",而是一组可量化、可复制的具体特征。这个技能做两件事:
  1. 分析入库:把一篇文章的风格拆解为具体维度,存入风格素材库
  2. 融合更新:从风格素材库中挑选特征,合成或更新主力风格档案
主力风格档案(
my_style.json
)是创作和润色技能实际调用的配方。风格素材库是长期积累的原材料。
Style is not an abstract "good" or "bad", but a set of quantifiable and replicable specific characteristics. This skill does two things:
  1. Analyze and Store: Break down the style of an article into specific dimensions and store it in the style material library
  2. Merge and Update: Select features from the style material library to synthesize or update the main style profile
The main style profile (
my_style.json
) is the recipe actually called by creation and polishing skills. The style material library is the raw material accumulated over the long term.

数据目录

Data Directory

所有风格数据存放在
./writing-workspace/styles/
writing-workspace/styles/
├── my_style.json       # 主力风格档案(创作/润色读取的那一份)
├── index.jsonl          # 风格素材索引(JSONL 格式,每行一条 {id, source_title, author, analyzed_at})
└── entries/            # 每篇分析过的文章一条记录
    └── sty_xxx.json
首次使用时自动创建目录结构。
All style data is stored in
./writing-workspace/styles/
:
writing-workspace/styles/
├── my_style.json       # 主力风格档案(创作/润色读取的那一份)
├── index.jsonl          # 风格素材索引(JSONL 格式,每行一条 {id, source_title, author, analyzed_at})
└── entries/            # 每篇分析过的文章一条记录
    └── sty_xxx.json
The directory structure is automatically created on first use.

模式判断

Mode Judgment

根据用户意图自动选择模式:
  • 用户投喂文章说"分析风格""看看这篇文章的写法" → 模式 A:分析入库
  • 用户说"吸收进来""更新我的风格""融合这几个" → 模式 B:融合更新
  • 用户投喂自己的文章说"分析我的文风" → 模式 A,且标记
    is_self: true

Automatically select the mode based on user intent:
  • User provides an article and says "analyze style" or "look at the writing style of this article" → Mode A: Analyze and Store
  • User says "absorb this", "update my style", "merge these" → Mode B: Merge and Update
  • User provides their own article and says "analyze my writing style" → Mode A, and mark
    is_self: true

模式 A:分析入库

Mode A: Analyze and Store

分析维度

Analysis Dimensions

逐一分析以下维度,每个维度用一句话概括特征:
语言维度:
维度关注点
vocabulary_level口语化 / 书面 / 混合?用词偏日常还是专业?
sentence_rhythm短句为主还是长句?节奏是急促还是舒缓?
favorite_expressions反复出现的口头禅、过渡语、语气词(提取 3-5 个)
punctuation_habits破折号多还是省略号多?逗号密度?
person_perspective第一人称 / 第二人称 / 第三人称?是否切换?
emotion_intensity冷静克制 / 中等 / 热烈煽情?态度鲜明还是温和?
结构维度:
维度关注点
opening_pattern故事切入 / 提问切入 / 数据冲击 / 场景描写 / 直接亮观点?
paragraph_rhythm段落长短交替规律?关键句是否独立成段?
argument_logic归纳型(案例→观点)/ 演绎型(观点→论证)/ 并列型?
transition_style用连接词过渡 / 口语化过渡 / 直接跳转?
closing_pattern金句收尾 / 开放提问 / 行动号召 / 故事回环?
title_pattern反常识 / 数字型 / 痛点型 / 悬念型 / 直给型?
Analyze the following dimensions one by one, with each dimension summarized in one sentence:
Language Dimensions:
DimensionFocus
vocabulary_levelColloquial / formal / mixed? Are words more daily or professional?
sentence_rhythmDominated by short sentences or long sentences? Is the rhythm rapid or slow?
favorite_expressionsRepeated catchphrases, transition words, modal particles (extract 3-5)
punctuation_habitsMore dashes or ellipses? Comma density?
person_perspectiveFirst person / second person / third person? Is there any switch?
emotion_intensityCalm and restrained / moderate / passionate and sensational? Is the attitude clear or gentle?
Structure Dimensions:
DimensionFocus
opening_patternStory introduction / question introduction / data impact / scene description / direct presentation of viewpoint?
paragraph_rhythmRegular alternation of paragraph lengths? Are key sentences independent into paragraphs?
argument_logicInductive (case → viewpoint) / deductive (viewpoint → argument) / parallel?
transition_styleTransition with conjunctions / colloquial transition / direct jump?
closing_patternClosing with golden sentences / open question / call to action / story loop?
title_patternCounter-intuitive / numeric / pain point / suspense / direct?

提炼亮点

Refine Highlights

除了维度分析,额外提炼 2-3 个这篇文章最值得借鉴的具体技巧。不要泛泛而谈,要具体到"怎么做"。
好的亮点示例:
  • "用连续三个反问句制造节奏感,然后用一句陈述句收住,形成'问问问→答'的冲击力"
  • "每个大段落结尾都用一句独立成行的短句做总结,像钉钉子一样把观点钉住"
In addition to dimension analysis, extract 2-3 most worthy specific skills from this article for reference. Don't talk in general terms, be specific about "how to do it".
Good examples of highlights:
  • "Use three consecutive rhetorical questions to create rhythm, then wrap up with a declarative sentence to form the impact of 'ask-ask-ask → answer'"
  • "End each large paragraph with a short sentence on a separate line as a summary, nailing the viewpoint like a nail"

执行流程

Execution Process

  1. 确保
    ./writing-workspace/styles/
    目录存在,不存在则创建(含
    entries/
    子目录)
  2. 如果
    index.jsonl
    不存在,创建空文件
  3. 通读全文,理解整体风格基调
  4. 逐一分析 12 个维度,每个维度一句话概括
  5. 提炼 2-3 个最值得借鉴的具体技巧
  6. 生成风格素材条目 JSON,ID 格式:
    sty_YYYYMMDD_NNN
    NNN 确定方式:取
    index.jsonl
    最后一行的 ID 序号,再列出
    entries/
    目录下当日已有的
    sty_YYYYMMDD_*.json
    文件,以两者中较大的序号 +1 作为起始编号。
    如果索引为空且当日无已有文件,才从 001 开始。
  7. 写入
    styles/entries/{id}.json
  8. 立即更新
    styles/index.jsonl
    ——在文件末尾追加一行 JSON
    {id, source_title, author, analyzed_at}
    。这一步不能跳过,索引是其他技能检索的入口。
  9. 向用户展示分析结果(用可读的格式,不是 raw JSON)
  10. 询问用户:"要把其中某些特征吸收到主力风格里吗?"
  1. Ensure the
    ./writing-workspace/styles/
    directory exists; create it (including the
    entries/
    subdirectory) if it doesn't
  2. If
    index.jsonl
    doesn't exist, create an empty file
  3. Read the full text and understand the overall style tone
  4. Analyze the 12 dimensions one by one, with each dimension summarized in one sentence
  5. Extract 2-3 most worthy specific skills
  6. Generate a style material entry JSON, with ID format:
    sty_YYYYMMDD_NNN
    . How to determine NNN: Take the ID serial number of the last line in
    index.jsonl
    , then list the
    sty_YYYYMMDD_*.json
    files already existing in the
    entries/
    directory on the same day, use the larger serial number +1 from the two as the starting number.
    If the index is empty and there are no existing files on the day, start from 001.
  7. Write to
    styles/entries/{id}.json
  8. Update
    styles/index.jsonl
    immediately
    ——append a line of JSON
    {id, source_title, author, analyzed_at}
    at the end of the file. This step cannot be skipped, as the index is the entry for other skills to retrieve.
  9. Show the analysis results to the user (in a readable format, not raw JSON)
  10. Ask the user: "Would you like to absorb some of these features into your main style?"

风格素材 JSON 结构

Style Material JSON Structure

json
{
  "id": "sty_20260327_001",
  "source": {
    "title": "原文标题",
    "author": "作者",
    "url": "来源链接(如有)",
    "is_self": false
  },
  "language": {
    "vocabulary_level": "",
    "sentence_rhythm": "",
    "favorite_expressions": [],
    "punctuation_habits": "",
    "person_perspective": "",
    "emotion_intensity": ""
  },
  "structure": {
    "opening_pattern": "",
    "paragraph_rhythm": "",
    "argument_logic": "",
    "transition_style": "",
    "closing_pattern": "",
    "title_pattern": ""
  },
  "highlights": "2-3 个具体技巧的自然语言描述",
  "analyzed_at": "ISO 8601 时间戳"
}
json
{
  "id": "sty_20260327_001",
  "source": {
    "title": "Original Title",
    "author": "Author",
    "url": "Source Link (if any)",
    "is_self": false
  },
  "language": {
    "vocabulary_level": "",
    "sentence_rhythm": "",
    "favorite_expressions": [],
    "punctuation_habits": "",
    "person_perspective": "",
    "emotion_intensity": ""
  },
  "structure": {
    "opening_pattern": "",
    "paragraph_rhythm": "",
    "argument_logic": "",
    "transition_style": "",
    "closing_pattern": "",
    "title_pattern": ""
  },
  "highlights": "Natural language description of 2-3 specific skills",
  "analyzed_at": "ISO 8601 timestamp"
}

注意事项

Notes

  • 如果只给了一篇文章,分析完后提醒用户:"一篇文章的风格分析可能不够全面,建议提供 3-5 篇同作者/同风格的文章以获得更准确的特征提取。"
  • 分析时重点关注"人味"特征——那些让这篇文章读起来不像 AI 写的元素。这些特征在后续创作和润色中特别有价值。
  • 写入 JSON 时必须正确转义特殊字符
    highlights
    overall_tone
    anti_ai_notes
    favorite_expressions
    等文本字段中的双引号
    "
    必须转义为
    \"
    ,反斜杠
    \
    转义为
    \\
    ,换行符转义为
    \n
    。使用 Write 工具写入 JSON 时,确保字符串值中不包含未转义的双引号。

  • If only one article is provided, after analysis, remind the user: "The style analysis of a single article may not be comprehensive. It is recommended to provide 3-5 articles by the same author or with the same style for more accurate feature extraction."
  • Focus on "human-like" features during analysis——those elements that make the article not read like it was written by AI. These features are particularly valuable in subsequent creation and polishing.
  • Must correctly escape special characters when writing JSON: Double quotes
    "
    in text fields such as
    highlights
    ,
    overall_tone
    ,
    anti_ai_notes
    ,
    favorite_expressions
    must be escaped as
    \"
    , backslashes
    \
    as
    \\
    , and line breaks as
    \n
    . When using the Write tool to write JSON, ensure that string values do not contain unescaped double quotes.

模式 B:融合/更新主力风格

Mode B: Merge/Update Main Style

执行流程

Execution Process

  1. 读取当前主力风格档案
    styles/my_style.json
    • 如果不存在,进入初始化流程(见下方)
  2. 读取用户指定的风格素材(可以是刚分析完的,也可以是 entries/ 里已有的)
  3. 逐维度对比当前主力风格 vs 新素材的特征差异
  4. 对每个有差异的维度,向用户展示对比并询问:
    • "你当前的
      opening_pattern
      是'故事切入',这篇文章用的是'数据冲击'。要替换、保留、还是两者兼收?"
  5. 按用户选择更新
    my_style.json
    • version
      加 1
    • last_updated
      更新为当前时间
    • trait_sources
      记录每个特征的来源(哪个风格素材条目)
  6. 展示更新后的主力风格摘要
  1. Read the current main style profile
    styles/my_style.json
    • If it doesn't exist, enter the initialization process (see below)
  2. Read the style materials specified by the user (can be the newly analyzed ones or existing ones in entries/)
  3. Compare the feature differences between the current main style and the new materials dimension by dimension
  4. For each dimension with differences, show the comparison to the user and ask:
    • "Your current
      opening_pattern
      is 'story introduction', this article uses 'data impact'. Would you like to replace, keep, or combine both?"
  5. Update
    my_style.json
    according to the user's choice:
    • Increase
      version
      by 1
    • Update
      last_updated
      to the current time
    • Record the source of each feature in
      trait_sources
      (which style material entry)
  6. Show the updated summary of the main style

主力风格初始化

Main Style Initialization

my_style.json
不存在时:
情况 1:用户投喂了自己的文章
  • 分析完直接将结果作为主力风格的初始版本
  • version 设为 1,trait_sources 全部标记为"自己的文章"
情况 2:用户投喂了别人的文章
  • 分析完后引导用户挑选想要的特征
  • 组装成第一版主力风格
When
my_style.json
does not exist:
Case 1: User provides their own article
  • Directly use the analysis result as the initial version of the main style
  • Set version to 1, and mark all
    trait_sources
    as "my own article"
Case 2: User provides someone else's article
  • After analysis, guide the user to select the desired features
  • Assemble into the first version of the main style

主力风格 JSON 结构

Main Style JSON Structure

json
{
  "name": "我的主力风格",
  "version": 1,
  "last_updated": "ISO 8601 时间戳",
  "language": {
    "vocabulary_level": "",
    "sentence_rhythm": "",
    "favorite_expressions": [],
    "punctuation_habits": "",
    "person_perspective": "",
    "emotion_intensity": "",
    "forbidden_words": ["值得注意的是", "总而言之", "综上所述", "让我们", "在当今社会"]
  },
  "structure": {
    "opening_pattern": "",
    "paragraph_rhythm": "",
    "argument_logic": "",
    "transition_style": "",
    "closing_pattern": "",
    "title_pattern": ""
  },
  "overall_tone": "一段自然语言描述整体风格基调",
  "anti_ai_notes": "避免排比句、避免'首先其次最后'的机械结构、避免每段都差不多长...",
  "trait_sources": {
    "opening_pattern": "来自 sty_xxx",
    "sentence_rhythm": "自己的文章"
  }
}
forbidden_words
初始包含常见 AI 用语,用户可以随时补充。创作和润色技能会读取这个列表。

json
{
  "name": "My Main Style",
  "version": 1,
  "last_updated": "ISO 8601 timestamp",
  "language": {
    "vocabulary_level": "",
    "sentence_rhythm": "",
    "favorite_expressions": [],
    "punctuation_habits": "",
    "person_perspective": "",
    "emotion_intensity": "",
    "forbidden_words": ["值得注意的是", "总而言之", "综上所述", "让我们", "在当今社会"]
  },
  "structure": {
    "opening_pattern": "",
    "paragraph_rhythm": "",
    "argument_logic": "",
    "transition_style": "",
    "closing_pattern": "",
    "title_pattern": ""
  },
  "overall_tone": "A natural language description of the overall style tone",
  "anti_ai_notes": "Avoid parallel sentences, avoid mechanical structures like 'first, second, last', avoid paragraphs of similar length...",
  "trait_sources": {
    "opening_pattern": "From sty_xxx",
    "sentence_rhythm": "My own article"
  }
}
forbidden_words
initially contains common AI phrases, and users can supplement it at any time. Creation and polishing skills will read this list.

输出格式

Output Format

分析结果用可读的中文呈现,不要直接输出 JSON。示例格式:
undefined
Present the analysis results in readable Chinese, do not directly output JSON. Example format:
undefined

风格分析报告

风格分析报告

来源: 《文章标题》 by 作者
来源: 《文章标题》 by 作者

语言特征

语言特征

  • 词汇风格: 口语化为主,偶尔蹦出书面用语制造反差
  • 句式节奏: 短句密集,长句用来收尾,形成"碎碎碎——收"的节奏
  • 常用表达: "说白了""你想想看""本质上就是"
  • ...
  • 词汇风格: 口语化为主,偶尔蹦出书面用语制造反差
  • 句式节奏: 短句密集,长句用来收尾,形成"碎碎碎——收"的节奏
  • 常用表达: "说白了""你想想看""本质上就是"
  • ...

结构特征

结构特征

  • 开头方式: 故事切入——用一个具体场景把读者拉进来
  • ...
  • 开头方式: 故事切入——用一个具体场景把读者拉进来
  • ...

最值得借鉴的技巧

最值得借鉴的技巧

  1. ...
  2. ...

风格素材已保存为 sty_20260327_001 要把其中某些特征吸收到你的主力风格里吗?
undefined
  1. ...
  2. ...

风格素材已保存为 sty_20260327_001 要把其中某些特征吸收到你的主力风格里吗?
undefined