Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -1192,12 +1192,12 @@ Continue the flow and develop into new phase."""
|
|
| 1192 |
narrative_tracker: ProgressiveNarrativeTracker,
|
| 1193 |
user_query: str, language: str) -> str:
|
| 1194 |
"""๊ฐํ๋ ๋นํ๊ฐ ์ค๊ฐ ๊ฒํ - ๋ฐ๋ณต ๊ฒ์ถ ๊ฐํ"""
|
| 1195 |
-
|
| 1196 |
-
|
| 1197 |
phase_count = len(narrative_tracker.phase_summaries)
|
| 1198 |
progression_ok, issues = narrative_tracker.check_narrative_progression(phase_count)
|
| 1199 |
-
|
| 1200 |
-
|
| 1201 |
duplicates = []
|
| 1202 |
paragraphs = all_content.split('\n\n')
|
| 1203 |
for i, para1 in enumerate(paragraphs[:20]): # ์ต๊ทผ 20๊ฐ ๋ฌธ๋จ
|
|
@@ -1259,8 +1259,7 @@ Continue the flow and develop into new phase."""
|
|
| 1259 |
๊ฐ ์๊ฐ์๊ฒ ๊ตฌ์ฒด์ ์ธ ์งํ ๋ฐฉํฅ๊ณผ ๊ธ์ง์ฌํญ ์ ์.
|
| 1260 |
๋ฐ๊ฒฌ๋ ๋ฐ๋ณต์ ๋ชจ๋ ์ ๊ฑฐํ๋๋ก ๋ช
์.""",
|
| 1261 |
|
| 1262 |
-
|
| 1263 |
-
|
| 1264 |
|
| 1265 |
**Original Theme:** {user_query}
|
| 1266 |
|
|
@@ -1278,30 +1277,30 @@ Continue the flow and develop into new phase."""
|
|
| 1278 |
**Mandatory Verification Items:**
|
| 1279 |
|
| 1280 |
1. **Duplication Detection (Top Priority)**
|
| 1281 |
-
|
| 1282 |
-
|
| 1283 |
-
|
| 1284 |
-
|
| 1285 |
|
| 1286 |
2. **Narrative Progression Measurement**
|
| 1287 |
-
|
| 1288 |
-
|
| 1289 |
-
|
| 1290 |
-
|
| 1291 |
|
| 1292 |
3. **Setting Consistency**
|
| 1293 |
-
|
| 1294 |
-
|
| 1295 |
-
|
| 1296 |
|
| 1297 |
4. **Length and Density**
|
| 1298 |
-
|
| 1299 |
-
|
| 1300 |
|
| 1301 |
5. **Literary Completion**
|
| 1302 |
-
|
| 1303 |
-
|
| 1304 |
-
|
| 1305 |
|
| 1306 |
**Failure Criteria:**
|
| 1307 |
- Similar content in 2+ phases
|
|
@@ -1312,10 +1311,11 @@ Continue the flow and develop into new phase."""
|
|
| 1312 |
**Revision Instructions:**
|
| 1313 |
Specific progression directions and prohibitions for each writer.
|
| 1314 |
All detected repetitions must be removed."""
|
| 1315 |
-
|
| 1316 |
-
|
| 1317 |
-
|
| 1318 |
|
|
|
|
| 1319 |
def create_writer_revision_prompt(self, writer_number: int, initial_content: str,
|
| 1320 |
critic_feedback: str, language: str) -> str:
|
| 1321 |
"""์๊ฐ ์์ ํ๋กฌํํธ"""
|
|
|
|
| 1192 |
narrative_tracker: ProgressiveNarrativeTracker,
|
| 1193 |
user_query: str, language: str) -> str:
|
| 1194 |
"""๊ฐํ๋ ๋นํ๊ฐ ์ค๊ฐ ๊ฒํ - ๋ฐ๋ณต ๊ฒ์ถ ๊ฐํ"""
|
| 1195 |
+
|
| 1196 |
+
# ์์ฌ ์งํ ์ฒดํฌ
|
| 1197 |
phase_count = len(narrative_tracker.phase_summaries)
|
| 1198 |
progression_ok, issues = narrative_tracker.check_narrative_progression(phase_count)
|
| 1199 |
+
|
| 1200 |
+
# ์ค๋ณต ๊ฐ์ง
|
| 1201 |
duplicates = []
|
| 1202 |
paragraphs = all_content.split('\n\n')
|
| 1203 |
for i, para1 in enumerate(paragraphs[:20]): # ์ต๊ทผ 20๊ฐ ๋ฌธ๋จ
|
|
|
|
| 1259 |
๊ฐ ์๊ฐ์๊ฒ ๊ตฌ์ฒด์ ์ธ ์งํ ๋ฐฉํฅ๊ณผ ๊ธ์ง์ฌํญ ์ ์.
|
| 1260 |
๋ฐ๊ฒฌ๋ ๋ฐ๋ณต์ ๋ชจ๋ ์ ๊ฑฐํ๋๋ก ๋ช
์.""",
|
| 1261 |
|
| 1262 |
+
"English": f"""As a narrative progression critic, strictly review the work.
|
|
|
|
| 1263 |
|
| 1264 |
**Original Theme:** {user_query}
|
| 1265 |
|
|
|
|
| 1277 |
**Mandatory Verification Items:**
|
| 1278 |
|
| 1279 |
1. **Duplication Detection (Top Priority)**
|
| 1280 |
+
- Same/similar sentences appearing 2+ times?
|
| 1281 |
+
- Same situations with only variations?
|
| 1282 |
+
- Actually new content in each phase?
|
| 1283 |
+
- Repeated expressions like specific phrases?
|
| 1284 |
|
| 1285 |
2. **Narrative Progression Measurement**
|
| 1286 |
+
- Clear difference between phase 1 and current?
|
| 1287 |
+
- Protagonist's psychology/perception changed?
|
| 1288 |
+
- Conflict deepening/turning/resolving?
|
| 1289 |
+
- Insights accumulating, not resetting?
|
| 1290 |
|
| 1291 |
3. **Setting Consistency**
|
| 1292 |
+
- All character names consistent? (especially protagonist)
|
| 1293 |
+
- Logical space/time settings?
|
| 1294 |
+
- Settings not changing mid-story?
|
| 1295 |
|
| 1296 |
4. **Length and Density**
|
| 1297 |
+
- Current total word count
|
| 1298 |
+
- Can reach 8,000 word target?
|
| 1299 |
|
| 1300 |
5. **Literary Completion**
|
| 1301 |
+
- "Showing" technique well used?
|
| 1302 |
+
- Philosophical insights naturally integrated?
|
| 1303 |
+
- Effective metaphors and symbols?
|
| 1304 |
|
| 1305 |
**Failure Criteria:**
|
| 1306 |
- Similar content in 2+ phases
|
|
|
|
| 1311 |
**Revision Instructions:**
|
| 1312 |
Specific progression directions and prohibitions for each writer.
|
| 1313 |
All detected repetitions must be removed."""
|
| 1314 |
+
}
|
| 1315 |
+
|
| 1316 |
+
return lang_prompts.get(language, lang_prompts["Korean"])
|
| 1317 |
|
| 1318 |
+
|
| 1319 |
def create_writer_revision_prompt(self, writer_number: int, initial_content: str,
|
| 1320 |
critic_feedback: str, language: str) -> str:
|
| 1321 |
"""์๊ฐ ์์ ํ๋กฌํํธ"""
|