본문으로 건너뛰기
cccskills
무료GitHub에 공개

style-analyzer

Use when ingesting text samples to extract quantitative writing style metrics. Produces a structured JSON style profile with vocabulary patterns, sentence structure, tone markers, and formatting preferences. Invoke before voice-clone-generator to establish style constraints.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(10)

  • SKILL.md7.4 KB
  • commands/style-analyzer.md114 B
  • hooks/post-execute.cjs181 B
  • hooks/pre-execute.cjs287 B
  • references/research-requirements.md289 B
  • rules/style-analyzer.md287 B
  • schemas/input.schema.json490 B
  • schemas/output.schema.json258 B
  • scripts/main.cjs1009 B
  • templates/implementation-template.md188 B

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

Style Analyzer

Overview

Extract a structured, quantitative writing style profile from text samples. The profile captures vocabulary patterns, sentence structure, tone markers, and formatting preferences as measurable metrics that can constrain downstream content generation.

Core principle: Style is measurable. Every writer produces a statistical fingerprint across vocabulary, syntax, and formatting dimensions.

When to Use

  • Before generating content that should match a specific author's voice
  • When building a reusable style profile for brand voice consistency
  • When comparing writing styles across multiple authors or documents
  • When auditing content for style drift from an established voice

Workflow

Step 1: Ingest Text Samples

Accept text from one or more sources:

# Analyze a single file
node .claude/tools/cli/style-profiler.cjs /path/to/sample.txt

# Analyze a directory of text files
node .claude/tools/cli/style-profiler.cjs /path/to/samples/

# Output is written to .claude/context/data/user-style-profile.json

Alternatively, read files with the Read tool and analyze inline for smaller samples.

Minimum input requirements:

  • At least 3 text samples for reliable metrics
  • Each sample should be 200+ words
  • Samples should represent the author's typical output (not edge cases)

Step 2: Extract Vocabulary Patterns

Analyze word usage across all samples:

  1. Tokenize all text into words (lowercase, strip punctuation)
  2. Remove stop words (the, a, is, are, etc.)
  3. Compute frequency distribution of remaining words
  4. Extract top 50 vocabulary (most frequently used content words)
  5. Calculate type-token ratio (unique words / total words) as vocabulary richness score
  6. Identify signature phrases (2-3 word combinations that appear 3+ times)

Step 3: Analyze Sentence Structure

Measure syntactic patterns:

  1. Average sentence length (words per sentence)
  2. Sentence length variance (standard deviation)
  3. Short sentence ratio (sentences under 8 words / total sentences)
  4. Long sentence ratio (sentences over 25 words / total sentences)
  5. Question frequency (questions / total sentences)
  6. Clause complexity (average commas per sentence as a proxy)

Step 4: Identify Tone Markers

Score the writing on five dimensions (each 1.0 to 5.0):

Dimension1.0 (Low)5.0 (High)How Measured
FormalityVery formalVery casualContraction frequency, slang usage, punctuation
DirectnessHedgedBluntHedge word frequency (maybe, perhaps, somewhat)
EmotionNeutralExpressiveExclamation marks, emotional adjectives
HumorSeriousPlayfulParenthetical asides, informal interjections
AuthorityTentativeAuthoritativeImperative sentences, certainty language

Step 5: Detect Formatting Preferences

Analyze structural patterns:

  1. Average paragraph length (sentences per paragraph)
  2. Heading depth (H1 only, H1-H2, H1-H3, etc.)
  3. List frequency (bulleted/numbered lists per 1000 words)
  4. Code block frequency (code blocks per 1000 words, if technical)
  5. Bold/italic usage (emphasis markers per 1000 words)
  6. Punctuation signature (em-dash frequency, semicolon frequency, ellipsis frequency)

Step 6: Build Style Profile JSON

Assemble all metrics into a structured profile:

{
  "version": "1.0.0",
  "createdAt": "2026-03-21T00:00:00Z",
  "sampleCount": 5,
  "totalWords": 12450,
  "vocabulary": {
    "topWords": ["specific", "pattern", "implementation", "..."],
    "typeTokenRatio": 0.42,
    "signaturePhrases": ["in practice", "the key insight"]
  },
  "sentenceStructure": {
    "avgLength": 18.3,
    "lengthVariance": 7.2,
    "shortSentenceRatio": 0.15,
    "longSentenceRatio": 0.22,
    "questionFrequency": 0.08,
    "avgCommasPerSentence": 1.4
  },
  "tone": {
    "formality": 2.8,
    "directness": 4.1,
    "emotion": 2.0,
    "humor": 1.5,
    "authority": 3.8
  },
  "formatting": {
    "avgParagraphLength": 3.2,
    "headingDepth": 3,
    "listFrequencyPer1000": 2.1,
    "codeBlockFrequencyPer1000": 0.8,
    "emphasisFrequencyPer1000": 4.5,
    "punctuation": {
      "emDashFrequency": 0.03,
      "semicolonFrequency": 0.01,
      "ellipsisFrequency": 0.005,
      "exclamationFrequency": 0.02
    }
  }
}

Save to .claude/context/data/user-style-profile.json.

Iron Laws

  1. ALWAYS require minimum 3 text samples before computing a style profile -- fewer samples produce unreliable metrics that do not generalize.
  2. NEVER include stop words in the top-50 vocabulary list -- stop words are universal and carry no style signal.
  3. ALWAYS save the profile to .claude/context/data/user-style-profile.json -- downstream skills depend on this exact path.
  4. NEVER treat a single metric in isolation as the style fingerprint -- style is the combination of all dimensions; individual metrics can coincide across very different authors.
  5. ALWAYS include the sampleCount and totalWords fields in the profile -- consumers need to assess the statistical reliability of the metrics.

Anti-Patterns

Anti-PatternWhy It FailsCorrect Approach
Analyzing a single short sampleInsufficient data; metrics reflect one mood, not styleRequire 3+ samples of 200+ words each
Including stop words in vocabulary metricsUniversal words add noise; no discriminative powerFilter all stop words before frequency analysis
Outputting profile to a non-standard pathDownstream skills cannot find the profileAlways write to .claude/context/data/user-style-profile.json
Treating tone as a single numberTone is multidimensional; a single score loses nuanceScore all five dimensions independently
Skipping formatting analysisStyle includes structure, not just wordsAlways analyze paragraph length, heading depth, list usage

Assigned Agents

This skill is used by:

  • voice-replicator-agent -- Primary consumer for style-constrained content generation

Memory Protocol (MANDATORY)

Before starting:

node .claude/lib/memory/memory-search.cjs "style analysis text profiling"

Read .claude/context/memory/learnings.md

After completing:

  • New style pattern discovered -> .claude/context/memory/learnings.md
  • Issue with analysis -> .claude/context/memory/issues.md
  • Decision about metrics -> .claude/context/memory/decisions.md

ASSUME INTERRUPTION: Your context may reset. If it's not in memory, it didn't happen.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Ensure accessibility in UI components including semantic HTML, ARIA attributes, keyboard navigation, and WCAG 2.2 AA compliance.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

oimiragieo/agent-studio422026년 7월 14일 업데이트

Use when you want to improve response quality through meta-cognitive reasoning. Applies 15+ reasoning methods to reconsider and refine initial outputs.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

oimiragieo/agent-studio422026년 7월 14일 업데이트

N-round opposing-stance debates for trade-off analysis. Assigns pro/con roles to agents, runs structured debate rounds with quality scoring, and produces a moderator synthesis with confidence-rated recommendation. Generalizable to architecture, technology, security, and design decisions.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

oimiragieo/agent-studio422026년 7월 14일 업데이트

Force adversarial code review stance that eliminates confirmation bias — reviewer must find issues or re-analyze

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

oimiragieo/agent-studio422026년 7월 14일 업데이트

Creates specialized AI agents on-demand when no existing agent matches a request. Use when the Router cannot find a suitable agent for a task. Enables self-evolution by generating persistent agents.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

oimiragieo/agent-studio422026년 7월 14일 업데이트

LLM-as-judge evaluation framework with 5-dimension rubric (accuracy, groundedness, coherence, completeness, helpfulness) for scoring AI-generated content quality with weighted composite scores and evidence citations

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

oimiragieo/agent-studio422026년 7월 14일 업데이트

oimiragieo의 스킬 모두 보기

이 스킬의 문제 신고