Skip to content

feat: add Korean language compression modes#215

Open
levx-me wants to merge 1 commit intoJuliusBrussee:mainfrom
levx-me:feat/korean-mode
Open

feat: add Korean language compression modes#215
levx-me wants to merge 1 commit intoJuliusBrussee:mainfrom
levx-me:feat/korean-mode

Conversation

@levx-me
Copy link
Copy Markdown

@levx-me levx-me commented Apr 17, 2026

Summary

  • Add korean-lite/full/ultra intensity levels for Korean language compression
  • Korean-specific rules: drop particles (은/λŠ”/이/κ°€/을/λ₯Ό), use noun endings (함/됨/ν•„μš”/μ™„λ£Œ), remove filler words (사싀/기본적으둜/정말), empty pleasantries (λ“œλ¦¬κ² μŠ΅λ‹ˆλ‹€), hedging (것 κ°™μŠ΅λ‹ˆλ‹€), connective endings β†’ symbols (λ•Œλ¬Έμ—β†’β†’), honorific stripping (μ‹œ/μœΌμ‹œ)
  • Hook support: /caveman korean command parsing, Korean per-turn reminder, alias resolution
  • Benchmark infrastructure: --lang ko flag for run.py, Korean prompts, results

Benchmark Results

Korean caveman mode: 67% average token savings (range 57%–84%)

Task Normal (tokens) Caveman Korean (tokens) Saved
React re-render bug 611 236 61%
Auth middleware fix 1176 191 84%
PostgreSQL pool setup 2363 539 77%
git rebase vs merge 1149 429 63%
Async refactor 739 316 57%
Microservices vs monolith 1225 508 59%
Security review 817 337 59%
Docker multi-stage 1210 442 63%
Race condition debug 1254 252 80%
Error boundary 2851 1011 65%
Average 1340 426 67%

Model: claude-sonnet-4-20250514, 1 trial per prompt. Comparable to English caveman mode (65% avg).

Why

Current caveman rules are English-optimized (drop articles a/an/the, English filler words). Korean has no articles β€” compression requires targeting different grammar elements: particles, verb endings, connective endings, honorifics, and Korean-specific filler patterns. Same gap that wenyan modes fill for Classical Chinese.

What changed

File Change
skills/caveman/SKILL.md Korean intensity table rows, rules, and examples
hooks/caveman-config.js korean-lite, korean, korean-full, korean-ultra in VALID_MODES
hooks/caveman-mode-tracker.js /caveman korean[-lite|-full|-ultra] parsing + Korean per-turn reminder
hooks/caveman-activate.js korean β†’ korean-full alias resolution
rules/caveman-activate.md korean added to switch line
evals/prompts/ko.txt 10 Korean evaluation prompts
benchmarks/run.py --lang ko support
benchmarks/prompts_ko.json 10 Korean benchmark prompts
benchmarks/results/ Korean benchmark results JSON

Before / After

Before (caveman full, responding in Korean):

"이 ν•¨μˆ˜λŠ” 사싀 기본적으둜 λΆˆν•„μš”ν•œ API ν˜ΈμΆœμ„ ν•˜κ³  μžˆλŠ” 것 κ°™μŠ΅λ‹ˆλ‹€. 확인해 λ³΄μ‹œλ©΄ 쒋을 것 κ°™μŠ΅λ‹ˆλ‹€."

Inconsistent compression β€” English rules don't map to Korean grammar.

After (caveman korean-full):

"ν•¨μˆ˜ λΆˆν•„μš” API 호좜 있음. 제거 ν•„μš”."

Systematic compression targeting Korean-specific patterns.

Design decisions

  • Rules section written in English (matching wenyan pattern) β€” LLMs follow English instructions more precisely
  • Korean examples use natural compressed Korean, not literal translations of English caveman
  • Three levels mirror English/wenyan pattern: lite (grammar intact), full (particles dropped), ultra (maximum compression)
  • Korean-specific compression strategies: particle dropping, noun endings, connective ending β†’ symbol conversion, honorific stripping

πŸ€– Generated with Claude Code

Add Korean-specific caveman modes that compress Korean prose by dropping
particles (은/λŠ”/이/κ°€/을/λ₯Ό), using noun endings (함/됨/ν•„μš”), and
removing filler words, empty pleasantries, and hedging expressions.

Changes:
- skills/caveman/SKILL.md: Korean intensity levels, rules, and examples
- hooks/caveman-config.js: korean modes in VALID_MODES whitelist
- hooks/caveman-mode-tracker.js: /caveman korean command parsing + Korean per-turn reminder
- hooks/caveman-activate.js: korean -> korean-full alias resolution
- rules/caveman-activate.md: korean in switch line
- evals/prompts/ko.txt: 10 Korean evaluation prompts

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@qodo-ai-reviewer
Copy link
Copy Markdown

Hi, When skills/caveman/SKILL.md can’t be read, hooks/caveman-activate.js falls back to an English-only ruleset and switch list, so standalone installs won’t get Korean instructions even if the active mode is Korean.

Severity: remediation recommended | Category: correctness

How to fix: Add korean-aware fallback text

Agent prompt to fix - you can give this to your LLM of choice:

Issue description

Standalone path (no skills/caveman/SKILL.md) uses a hardcoded fallback ruleset that doesn’t mention Korean modes/rules, even though modeLabel can be korean-*.

Issue Context

Affects standalone hook installs; plugin installs likely have SKILL.md available.

Fix Focus Areas

  • hooks/caveman-activate.js[47-111]

Qodo code review - free for open-source.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants