kangjun-story-mcp
Version:
Kangjun Story MCP: Novel writing assistant MCP server with character and RPG equipment tools
799 lines (691 loc) • 20.8 kB
JavaScript
export const TEMPLATES = {
cursorRules: `# Novel Writing AI Assistant Rules
## Core Principles
1. **Always maintain character consistency** - Check character files before writing dialogue
2. **Respect world rules** - Never violate established worldbuilding
3. **Track emotional continuity** - Reference emotion graphs for character reactions
4. **Preserve voice** - Match established narrative style in style-guide.md
5. **Check timeline** - Verify all temporal references against timeline.md
## Before Writing
- Read: active-context.md, relevant character files, current chapter
- Check: plot-holes.md, foreshadowing.md, relationships.md
- Verify: timeline consistency, character availability, location logic
## While Writing
- Maintain POV consistency within scenes
- Apply dialogue styles from dialogue-styles.md
- Include sensory details (5 senses)
- Balance dialogue, action, and introspection
- Check scene checklist for each scene
- **NEVER use markdown formatting in narrative text**
- Write in proper prose format without bullets or lists
- Use natural paragraph flow for descriptions
- **NEVER use markdown formatting in creative text**
- **Write in pure narrative prose without headers or bullets**
- **Use natural paragraph breaks, not markdown structures**
## After Writing
- Update: progress.md, emotion tracking, timeline.md
- Log: new foreshadowing, character developments, world details
- Check: plot consistency, character voice, pacing
## Special Commands
- \`check consistency\` - Validate against all established rules
- \`analyze emotions\` - Generate emotion graph for scene
- \`create image prompt\` - Generate detailed AI art prompt
- \`expand description\` - Enhance sensory details
- \`dialogue polish\` - Refine character voice consistency
## Language Preferences
- Genre: [Adaptive based on project]
- Tone: [Set in style-guide.md]
- POV: [Set per chapter]
- Tense: [Set in project-brief.md]
## File Update Triggers
- New chapter completed → Update progress.md
- Character development → Update character file + arcs
- World detail added → Update relevant worldbuilding
- Plot point resolved → Update foreshadowing.md
- Research completed → Update fact-checking.md
`,
novelBrainJson: `{
"projectType": "novel",
"version": "2.0.0",
"metadata": {
"title": "",
"author": "",
"genre": [],
"targetWordCount": 0,
"currentWordCount": 0,
"startDate": "",
"deadline": ""
},
"settings": {
"defaultPOV": "third-limited",
"tense": "past",
"chapterTargetWords": 3000,
"scenesPerChapter": 3,
"dailyWordGoal": 1000
},
"aiAssistant": {
"autoCheckConsistency": true,
"validateDialogue": true,
"trackEmotions": true,
"generateImagePrompts": true,
"suggestPacing": true,
"autoSelectStructure": true
},
"narrativeModels": {
"autoSelect": true,
"primaryModel": "",
"secondaryModels": [],
"genreModelMap": {
"fantasy": ["Hero's Journey", "Quest Structure", "MICE-Milieu"],
"mystery": ["7-Point Structure", "In Medias Res", "Ping-Pong"],
"romance": ["Save the Cat", "Emotional Arc", "W Plot"],
"thriller": ["Three-Act", "Point of No Return", "Spiral"],
"literary": ["Kishotenketsu", "Vignette", "Mosaic"],
"scifi": ["MICE-Idea", "Nested Loops", "Frame Story"],
"horror": ["Freytag's Pyramid", "Spiral", "Point of No Return"]
},
"currentAnalysis": {
"detectedGenre": [],
"recommendedModels": [],
"activeModel": "",
"confidence": 0
}
},
"actantialModel": {
"wholeStory": {
"subject": "",
"object": "",
"sender": "",
"receiver": "",
"helpers": [],
"opponents": []
},
"currentChapter": {
"subject": "",
"object": "",
"helpers": [],
"opponents": []
},
"roleTransitions": []
},
"characterTracking": {
"mainCharacters": [],
"activeInCurrentScene": [],
"emotionalStates": {},
"relationshipMatrix": {}
},
"plotTracking": {
"currentChapter": 1,
"currentScene": 1,
"unresolvedPlotPoints": [],
"activeForeshadowing": [],
"tensionLevel": 5
},
"worldState": {
"currentLocation": "",
"currentTime": "",
"weatherCondition": "",
"activeWorldRules": []
},
"structureTracking": {
"currentStructure": {
"primary": "",
"secondary": [],
"progress": {
"totalBeats": 0,
"completedBeats": 0,
"currentBeat": "",
"nextBeat": ""
}
},
"structureHistory": [],
"aiRecommendations": {
"lastAnalysis": "",
"suggestions": []
}
},
"automations": [
{
"trigger": "chapter_complete",
"actions": [
"update_progress",
"check_foreshadowing",
"validate_timeline",
"backup_version",
"analyze_structure"
]
},
{
"trigger": "scene_start",
"actions": [
"load_character_states",
"check_location_consistency",
"suggest_sensory_details",
"check_structure_beat"
]
},
{
"trigger": "genre_change",
"actions": [
"recommend_structure",
"suggest_hybrid_model",
"update_genre_map"
]
}
],
"validation": {
"rules": [
"character_presence",
"timeline_consistency",
"dialogue_style",
"world_rules",
"plot_continuity",
"structure_coherence",
"actantial_balance"
],
"frequency": "per_scene"
}
}
`,
characterTemplate: `# Character: [Name]
## Basic Information
- **Full Name**:
- **Age**:
- **Gender**:
- **Role**: [Protagonist/Antagonist/Supporting/Minor]
- **First Appearance**: Chapter X
- **POV Character**: Yes/No
## Physical Description
- **Height/Build**:
- **Hair**:
- **Eyes**:
- **Distinguishing Features**:
- **Typical Clothing**:
- **Body Language**:
## Background
- **Origin**:
- **Family**:
- **Education**:
- **Occupation**:
- **Social Status**:
## Personality
### Core Traits
1.
2.
3.
### Strengths
-
### Weaknesses
-
### Fears
-
### Desires
- **Conscious Goal**:
- **Unconscious Need**:
## Psychology Profile
### MBTI/Enneagram
- Type:
### Emotional Patterns
- **Default State**:
- **Under Stress**:
- **When Happy**:
- **Defense Mechanisms**:
### Internal Conflicts
-
## Relationships
### Family
-
### Friends
-
### Romantic
-
### Enemies
-
## Character Arc
### Starting Point
- **External Situation**:
- **Internal State**:
- **Worldview**:
### Turning Points
1. **Catalyst** (Chapter X):
2. **Midpoint** (Chapter X):
3. **Dark Night** (Chapter X):
### End Point
- **External Situation**:
- **Internal State**:
- **Worldview**:
## Dialogue Style
### Vocabulary
- **Education Level**:
- **Unique Phrases**:
- **Forbidden Words**:
### Speech Patterns
- **Pace**: [Fast/Medium/Slow]
- **Directness**: [Direct/Indirect/Evasive]
- **Formality**: [Formal/Casual/Mixed]
### Sample Dialogue
> "Example of how this character speaks."
### Voice Notes
- **Accent/Dialect**:
- **Verbal Tics**:
- **Changes When Emotional**:
## Story Function
- **Plot Role**:
- **Thematic Role**:
- **Symbolic Meaning**:
## Secrets
- **Known to Character**:
- **Unknown to Character**:
- **Known to Reader**:
## Author Notes
- **Inspiration**:
- **Writing Challenges**:
- **Key Scenes**:
## Visual Reference
### AI Image Prompt
[Detailed prompt for AI image generation]
### Mood/Aesthetic
-
## Change Log
- [Date]: Created character
- [Date]: Updated after Chapter X
`,
emotionGraphTemplate: `# Emotion Tracking: [Character Name] - Chapter [X]
## Scene-by-Scene Emotional Journey
### Scene 1: [Scene Title]
**Context**: [Brief scene description]
**Emotional State** (Scale 1-10):
- Joy: 3
- Fear: 7
- Anger: 2
- Sadness: 5
- Disgust: 1
- Surprise: 4
- Trust: 3
- Anticipation: 6
**Dominant Emotion**: Fear (7)
**Secondary Emotions**: Anticipation (6), Sadness (5)
**Internal Monologue Keywords**: worried, uncertain, hopeful
**Physical Manifestations**: tense shoulders, rapid heartbeat, forced smile
**Motivation**:
- **External Goal**: [What they want to achieve]
- **Internal Need**: [What they actually need]
- **Obstacle**: [What's blocking them]
**Behavioral Response**:
- **Action Taken**:
- **Action Avoided**:
- **Subtext in Dialogue**:
### Emotional Arc Summary
Start: Fear(7) + Anticipation(6)
↓ [Trigger Event]
Middle: Anger(8) + Surprise(7)
↓ [Revelation]
End: Sadness(6) + Trust(4)
## Complex Emotion Mapping
### Emotional Layers
1. **Surface**: What others see
2. **Conscious**: What character acknowledges
3. **Subconscious**: What character denies/suppresses
### Emotional Conflict
- **Want vs Need**:
- **Fear vs Desire**:
- **Loyalty vs Self-Interest**:
## Relationship Impact
- **How This Affects [Other Character]**:
- **Changed Dynamics**:
## Author Notes
- **Intended Reader Emotion**:
- **Subtext Success**:
- **Revision Notes**:
`,
creativePrompts: `# Creative Prompts for Writer's Block
## Character Development Prompts
1. "What would [character] do if they found a mysterious letter addressed to them from 20 years ago?"
2. "Write [character]'s worst nightmare becoming reality"
3. "How would [character] react to winning the lottery?"
4. "Describe [character]'s most embarrassing childhood memory"
5. "What lie does [character] tell themselves every day?"
## Dialogue Prompts
1. "Two characters argue without using the word 'no'"
2. "A confession that changes everything"
3. "Characters speak only in questions"
4. "A goodbye neither character wants"
5. "Revealing a secret through subtext only"
## Scene Expansion Prompts
1. "Add a sensory detail for each of the five senses"
2. "Introduce an unexpected interruption"
3. "Change the weather to oppose the mood"
4. "Add a ticking clock element"
5. "Include a symbolic object"
## Plot Development Prompts
1. "What's the worst thing that could happen right now?"
2. "Reverse the expected outcome"
3. "Introduce a moral dilemma with no good answer"
4. "Connect two unrelated plot threads"
5. "Kill a darling - remove what's not truly needed"
## Description Enhancement Prompts
1. "Describe this through a child's eyes"
2. "Use only taste and touch words"
3. "Write it as if it's the last thing the character sees"
4. "Make the setting a character"
5. "Use weather to mirror emotions"
## Emotional Depth Prompts
1. "What physical sensation does this emotion create?"
2. "How would this feeling taste?"
3. "What memory does this trigger?"
4. "What are they pretending not to feel?"
5. "How does their body betray their words?"
## World-Building Prompts
1. "What's the history of this location?"
2. "What's considered taboo in this society?"
3. "How does magic/technology affect daily life?"
4. "What's the local folklore about?"
5. "What do children learn in school here?"
## Conflict Escalation
1. "Add a time limit"
2. "Remove the easy solution"
3. "Make allies into obstacles"
4. "Reveal hidden stakes"
5. "Force a sacrifice"
## Custom Prompt Generator
When stuck, combine:
- [Character] + [Emotion] + [Obstacle] + [Stakes]
- "What if [character] felt [emotion] but had to [action] because [reason]?"
`,
imagePromptTemplate: `# AI Image Generation Prompt Template
## Character Portrait
[Art style]: [realistic/anime/fantasy art/oil painting/etc]
[Subject]: [Age] year old [gender] with [key features]
[Appearance]: [Hair detail], [eye detail], [skin tone], [build]
[Clothing]: [Detailed outfit description]
[Expression]: [Emotional state and facial expression]
[Pose]: [Body position and gesture]
[Background]: [Simple/detailed environment]
[Lighting]: [Type and direction of light]
[Mood]: [Overall atmosphere]
[Color palette]: [Dominant colors]
[Additional details]: [Accessories, scars, tattoos, etc]
[Camera angle]: [Close-up/medium shot/full body]
[Quality tags]: masterpiece, best quality, highly detailed, 8k
[Negative prompt]: [What to avoid]
### Example:
Fantasy art style: 25 year old female warrior with battle-worn confidence
Appearance: Long silver hair in a practical braid, piercing amber eyes, sun-kissed skin, athletic build
Clothing: Worn leather armor with brass accents, dark traveling cloak, practical boots
Expression: Determined gaze with a slight smirk, battle-ready alertness
Pose: Standing with weight on one hip, hand resting on sword hilt
Background: Misty mountain pass at dawn
Lighting: Golden sunrise backlighting creating rim light on armor
Mood: Epic and adventurous with a sense of journey ahead
Color palette: Warm golds, cool blues, earth tones
Additional details: Scar through left eyebrow, clan symbol on shoulder guard
Camera angle: Medium shot, slightly low angle for heroic feel
Quality tags: masterpiece, best quality, highly detailed, fantasy illustration, 8k
Negative prompt: modern elements, excessive armor, oversexualized
## Scene Illustration
[Art style]:
[Scene type]: [Action/quiet/emotional/landscape]
[Setting]: [Detailed location description]
[Time/Weather]:
[Characters present]: [Positions and actions]
[Focus point]: [What draws the eye]
[Foreground/Middle/Background]: [Compositional layers]
[Lighting]: [Source, quality, mood]
[Atmosphere]: [Emotional tone]
[Color scheme]:
[Special effects]: [Magic, particles, weather effects]
[Perspective]: [Bird's eye/eye level/worm's eye]
[Quality tags]:
## Location/Environment
[Art style]:
[Location type]: [Interior/exterior/natural/urban]
[Architectural style]: [If applicable]
[Time period/Tech level]:
[Time of day]:
[Weather/Season]:
[Key features]: [What makes this location unique]
[Scale indicators]: [Objects/people for size reference]
[Lighting]:
[Mood]:
[Color palette]:
[Detail level]: [How much detail to include]
[Quality tags]:
## Object/Item Design
[Art style]:
[Object type]:
[Material]: [What it's made of]
[Size/Scale]:
[Condition]: [New/worn/ancient/magical]
[Unique features]:
[Decorative elements]:
[Function indicators]: [How it's used]
[Background]: [Plain/contextual]
[Lighting]: [To show form and texture]
[Level of detail]:
[Quality tags]:
`,
sceneChecklist: `# Scene Requirements Checklist
## Essential Elements
□ **Clear POV** - Whose perspective are we in?
□ **Setting Established** - Where and when?
□ **Conflict Present** - What's the tension/problem?
□ **Character Goal** - What does POV character want?
□ **Stakes Clear** - What happens if they fail?
□ **Change Occurs** - How is end different from beginning?
## Scene Structure
□ **Hook** - Engaging opening line/paragraph
□ **Context** - Orient reader quickly
□ **Build** - Rising tension/complications
□ **Climax** - Peak moment/revelation/decision
□ **Resolution** - Immediate aftermath
□ **Transition** - Lead to next scene
## Character Work
□ **Voice Consistent** - Matches character profile
□ **Emotion Shown** - Through action/dialogue/internals
□ **Relationships Developed** - Dynamics evolve
□ **Motivation Clear** - Why they act
□ **Growth Moment** - Learn/change/realize
## Craft Elements
□ **Sensory Details** - At least 3 senses
□ **Show Don't Tell** - Action over exposition
□ **Dialogue Purpose** - Advances plot/reveals character
□ **Subtext Present** - Meaning beneath words
□ **Pacing Appropriate** - Matches scene intention
## Plot Function
□ **Advances Main Plot** - Moves story forward
□ **Connects to Theme** - Reinforces central idea
□ **Foreshadowing** - Plants or pays off
□ **Cause-Effect** - Logical from previous scenes
□ **Information Control** - Reveals/conceals appropriately
## Technical Checks
□ **Word Count Target** - [Scene target: XXX words]
□ **Timeline Consistent** - Matches established chronology
□ **Character Availability** - Are they physically here?
□ **World Rules Followed** - Magic/tech consistency
□ **POV Maintained** - No head-hopping
## Revision Notes
□ **Redundancies Removed** - No repeated information
□ **Transitions Smooth** - Scene flows naturally
□ **Kill Your Darlings** - Beautiful but unnecessary?
□ **Beta Reader Flags** - Address feedback
□ **Final Polish** - Grammar/style check
## Scene Metadata
- **Scene ID**: Volume_Chapter_Scene (e.g., 1_03_2)
- **Word Count**:
- **POV Character**:
- **Location**:
- **Time**:
- **Characters Present**:
- **Tension Level**: [1-10]
- **Completion Status**: [Draft/Revised/Final]
- **Key Plot Points**:
- **Foreshadowing Elements**:
- **Revision Priority**: [High/Medium/Low]
`,
dashboard: `# Writing Dashboard
## Today's Status
**Date**: [Auto-update]
**Current Chapter**:
**Current Scene**:
**Today's Word Count**: 0 / 1000
**Week Total**: 0 / 7000
## Project Overview
**Title**: [Project Title]
**Genre**: [Genre]
**Total Word Count**: 0 / 80,000
**Completion**: 0%
## Progress Tracker
### Volume 1
- [ ] Chapter 1 - [0/3000 words]
- [ ] Chapter 2 - [0/3000 words]
- [ ] Chapter 3 - [0/3000 words]
[...]
## Current Sprint
**Goal**: Complete Chapter X by [Date]
**Daily Target**: 1000 words
**Days Remaining**: X
### This Week's Focus
- [ ] Monday: Scene 1 - Setup
- [ ] Tuesday: Scene 2 - Conflict
- [ ] Wednesday: Scene 3 - Resolution
- [ ] Thursday: Revision
- [ ] Friday: Character development
## Active Tasks
### High Priority
- [ ] Resolve plot hole in Ch.3
- [ ] Fix timeline inconsistency
- [ ] Develop villain backstory
### Medium Priority
- [ ] Enhance setting descriptions
- [ ] Add sensory details to Ch.2
### Low Priority
- [ ] Research medieval weapons
- [ ] Create location map
## Blocking Points
1. **Issue**: Can't resolve how character escapes
**Chapter**: 5
**Potential Solutions**:
- Hidden ally
- Previously established skill
- Environmental advantage
## Recent Achievements
- ✅ Completed Chapter 4
- ✅ Fixed character voice inconsistency
- ✅ Established magic system rules
## Upcoming Deadlines
- Beta Reader Draft: [Date]
- Final Draft: [Date]
- Query Letter: [Date]
## Inspiration Today
> [Random prompt or quote]
## Session Notes
[Quick notes during writing session]
## Tomorrow's Plan
- [ ]
- [ ]
- [ ]
---
*Last Updated: [Timestamp]*
`,
projectOverview: `# 작품개요
## 기본 정보
- 제목: {title}
- 저자: {author}
- 장르: {genres}
- 톤/분위기: {tone}
- 목표 분량: {targetWords}자
- 시작일: {startDate}
- 마감일: {deadline}
## 로그라인
{logline}
## 핵심 테마
- {theme1}
- {theme2}
- {theme3}
## 한 줄 피치
{oneLiner}
## 독자 타겟
- 연령대: {audienceAge}
- 독서 성향: {audienceTaste}
## 차별점(USP)
- {usp1}
- {usp2}
- {usp3}
`,
styleGuide: `# 스타일가이드
## 서술 시점/시제
- 기본 시점: {pov}
- 시제: {tense}
## 문체
- 길이: 짧고 선명한 문장/중간 길이/유려한 장문 → {sentenceStyle}
- 어휘: 쉬운/중간/전문적 → {vocabulary}
- 감정 표현: 절제/중간/풍부 → {emotionLevel}
## 대화
- 말줄임/감탄사 사용 기준: {dialogueParticles}
- 캐릭터별 말투 차별화 원칙: {dialogueDiff}
## 묘사
- 감각 디테일 최소 3개 포함
- 보이는 것 먼저 → 소리/촉감/냄새/맛 보완
- 메타포/상징은 절도 있게 사용({metaphor})
## 금칙
- 서사 내 마크다운 사용 금지(내러티브 텍스트는 순수 문단)
- 과도한 정보 덤프 금지, 장면 중심 진행
`,
worldRules: `# 세계관 규칙
## 절대 규칙(변경 불가)
1. 물리 법칙: {physics}
2. 마법/과학 체계: {magicSystem}
3. 역사적 사실: {history}
4. 지리적 설정: {geography}
## 유연한 규칙(조정 가능)
1. 문화적 관습: {culture}
2. 언어 변형: {language}
3. 기술 발전: {tech}
4. 사회 변화: {society}
## 체크 포인트
- 시간대별 기술 수준, 거리/이동 시간, 계절/날씨, 문화 규범, 언어 사용
`,
mainPlotBase: `# 메인 플롯 개요
## 구조 모델: {model}
## 장별 계획: 총 {chapters}장, 장면당 {scenesPerChapter} 씬
### 핵심 갈등
- 외적 갈등: {externalConflict}
- 내적 갈등: {internalConflict}
- 대립자: {antagonist}
### 목표/위험/보상
- 목표: {goal}
- 실패 시 위험: {stakes}
- 성공 시 보상: {reward}
### 주요 전환점(요약)
- 도입: {beat_setup}
- 1전환: {beat_turn1}
- 중간점: {beat_mid}
- 2전환: {beat_turn2}
- 절정: {beat_climax}
- 결말: {beat_resolution}
`,
timelineBase: `# 타임라인
## 연표
- 사건 0(프롤로그): {t0}
- 사건 1: {t1}
- 사건 2: {t2}
- 사건 3: {t3}
- 사건 4: {t4}
- 사건 5(클라이맥스): {t5}
- 사건 6(여운): {t6}
`,
worldSeed: `# World Seed
- 세계명: {worldName}
- 장르: {genres}
- 톤: {tone}
- 기술 수준: {techLevel}
- 마법 수준: {magicLevel}
- 키워드: {tags}
## 한 문단 요약
{summary}
## 지역/세력/종족(개요)
- 지역: {regions}
- 세력: {factions}
- 종족: {species}
`
};