Upload 16 files
Browse files- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/ama.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/amass.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/bushiss.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/dave.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/edback.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/etcss.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/mak.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/makss.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/mic.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/micss.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/opback.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/sac.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/ss.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/yuj.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/yum.txt.gz +3 -0
- v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/灰色的迷宫.py +299 -0
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/ama.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:85b27bb2ddc4a4605499fee13e0fca77cc4aef66316254fd78872c978b580caf
|
3 |
+
size 74135
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/amass.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:39ba0f5d09f83e6911e6979a7123f7ca65341cb8964a3a270a5525dfecd2abf6
|
3 |
+
size 8475
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/bushiss.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:540f3d7d7b46937c0c76f67b35286619f682c0308e761ac178ea42bf249c88e7
|
3 |
+
size 2985
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/dave.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:9b9ef9c45995653524f3c7c58dcf8ee80cb92c23665f933d7500e0dee6bb50f4
|
3 |
+
size 66343
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/edback.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:a000b8be45c4c2dc9c5b5858a1d244477c45c6d0068d9994e5c4dcdf8ce96229
|
3 |
+
size 7493
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/etcss.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:1f76df5765ed3eb2ac25e1c525049127fae008157fae7b7e7be2bc628089233e
|
3 |
+
size 4062
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/mak.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:5c486c7d1d8b004425f767436e901a28953e6e4a6b22c8269ca6e3d039892259
|
3 |
+
size 95153
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/makss.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:dad9543a947e11c8ede8ad3b2d458e4d2c6fc04d24cea8643e481f1af8949094
|
3 |
+
size 9346
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/mic.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:5e86a8b40b7c5a250119495c85def2aff88679861050ee5dc019dacb61391b51
|
3 |
+
size 93602
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/micss.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:8e70915a8e88e0a3c9acdf93621625c383546f556f32cdd1fcd3f552340d9af9
|
3 |
+
size 8613
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/opback.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:e4bece91d17494d77c0917b1d3cbb7b2ef0edcf3f3476f861264e76eb2f871fb
|
3 |
+
size 37147
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/sac.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:aae3977187e654a82fd7b9b035549f9b97fd0fcfb20f1e593163f6adf2e9ce49
|
3 |
+
size 95190
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/ss.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:8718f40c05f61417ad6168366f53e847512d1da39f5cccb7931dbec9017c1458
|
3 |
+
size 32022
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/yuj.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:5c49a112b9a80da6363e46989624dadcf368c4fe456244b54c9bebba8c5730b3
|
3 |
+
size 250380
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/yum.txt.gz
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:36202b51bbd899628941be96dbd5f1b0396a6e507afd3afe37e776c2c9e752dc
|
3 |
+
size 93602
|
v-corpus-zh/FrontWing/灰色的果实/灰色的迷宫/灰色的迷宫.py
ADDED
@@ -0,0 +1,299 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
def get_all_files_in_directory(directory, ext=''):
|
2 |
+
import os
|
3 |
+
import re
|
4 |
+
custom_sort_key_re = re.compile('([0-9]+)')
|
5 |
+
|
6 |
+
def custom_sort_key(s):
|
7 |
+
# 将字符串中的数字部分转换为整数,然后进行排序
|
8 |
+
return [int(x) if x.isdigit() else x for x in custom_sort_key_re.split(s)]
|
9 |
+
|
10 |
+
all_files = []
|
11 |
+
for root, dirs, files in os.walk(directory):
|
12 |
+
for file in files:
|
13 |
+
if file.endswith(ext):
|
14 |
+
file_path = os.path.join(root, file)
|
15 |
+
all_files.append(file_path)
|
16 |
+
return sorted(all_files, key=custom_sort_key)
|
17 |
+
|
18 |
+
|
19 |
+
def clearT():
|
20 |
+
import unicodedata
|
21 |
+
from opencc import OpenCC
|
22 |
+
|
23 |
+
def full2half(input_str):
|
24 |
+
return ''.join([unicodedata.normalize('NFKC', char) for char in input_str])
|
25 |
+
|
26 |
+
cc = OpenCC('t2s') # 't2s'表示繁体转简体
|
27 |
+
|
28 |
+
def _clearT(s):
|
29 |
+
s = cc.convert(full2half(s))
|
30 |
+
return s.strip().strip(r'\n').replace('\n', '\\n')
|
31 |
+
|
32 |
+
return _clearT
|
33 |
+
|
34 |
+
|
35 |
+
clearT = clearT()
|
36 |
+
|
37 |
+
import re
|
38 |
+
reg_rq = re.compile(r'(.+?)')
|
39 |
+
def removeQ(_s:str):
|
40 |
+
return reg_rq.sub('',_s).strip()
|
41 |
+
|
42 |
+
|
43 |
+
# =================
|
44 |
+
|
45 |
+
a = get_all_files_in_directory(r'E:\tmp\灰色的迷宫\TextDump', ext='.txt')
|
46 |
+
b = r'D:\datasets\tmp'
|
47 |
+
|
48 |
+
# =================
|
49 |
+
|
50 |
+
sc = {}
|
51 |
+
|
52 |
+
_n = {
|
53 |
+
"雄二": "雄二",
|
54 |
+
"男人": "男人",
|
55 |
+
"上田": "上田",
|
56 |
+
"天音": "天音",
|
57 |
+
"???": "?",
|
58 |
+
"幸": "幸",
|
59 |
+
"莳菜": "莳菜",
|
60 |
+
"满": "满",
|
61 |
+
"由美子": "由美子",
|
62 |
+
"学园长": "学园长",
|
63 |
+
"蔬菜店大叔": "蔬菜店大叔",
|
64 |
+
"天音母亲": "天音母亲",
|
65 |
+
"天音父亲": "天音父亲",
|
66 |
+
"婴儿": "婴儿",
|
67 |
+
"——然后,要说实际被抱过之后的感想的话": "旁白",
|
68 |
+
"天音": "天音",
|
69 |
+
"一姬": "一姬",
|
70 |
+
"一姬": "一姬",
|
71 |
+
"声音": "声音",
|
72 |
+
"古森": "古森",
|
73 |
+
"男人2": "男人2",
|
74 |
+
"天音·一姬": "天音&一姬",
|
75 |
+
"幸": "幸",
|
76 |
+
"薮犬": "薮犬",
|
77 |
+
"全员": "全员",
|
78 |
+
"容器": "容器",
|
79 |
+
"三人": "三人",
|
80 |
+
"雄二": "雄二",
|
81 |
+
"JB": "JB",
|
82 |
+
"JB": "JB",
|
83 |
+
"琪娅拉": "琪娅拉",
|
84 |
+
"接待员": "接待员",
|
85 |
+
"泽田": "泽田",
|
86 |
+
"清夏": "清夏",
|
87 |
+
"「咕呼呜!!才不是!不是!嗯啊!」": "清夏",
|
88 |
+
"「啊啊啊啊!不要!明明不想的,却来了…!」": "清夏",
|
89 |
+
"$str122": "千鹤",
|
90 |
+
"第一次见到男性的那个就是如此令人吃惊的大小。": "千鹤",
|
91 |
+
"「哈啊、啊、啊嗯! 嗯啊、啊啊、啊啊啊!」": "千鹤",
|
92 |
+
"$str122": "千鹤",
|
93 |
+
"「久等——」": "千鹤",
|
94 |
+
"「嗯、嗯! 嗯、哈…啊、啊啊…嗯嗯! 嗯…」": "千鹤",
|
95 |
+
"「~~! 嗯哈、啊啊、哼啊! 啊、啊啊…」": "千鹤",
|
96 |
+
"「风见君…嗯! 你想去的话,那就去吧」": "千鹤",
|
97 |
+
"戴夫教授": "戴夫教授",
|
98 |
+
"戴夫教授": "戴夫教授",
|
99 |
+
"满": "满",
|
100 |
+
"阿尔法": "阿尔法",
|
101 |
+
"阿达姆": "阿达姆",
|
102 |
+
"阿达姆": "阿达姆",
|
103 |
+
"学园长": "学园长",
|
104 |
+
"牛肋肉将军": "牛肋肉将军",
|
105 |
+
"牛肋肉将军": "牛肋肉将军",
|
106 |
+
"鲔鱼侠": "鲔鱼侠",
|
107 |
+
"小姐姐": "小姐姐",
|
108 |
+
"面包店老板": "面包店老板",
|
109 |
+
"旁白": "旁白",
|
110 |
+
"邻座男子": "邻座男子",
|
111 |
+
"巴士上的邻座男子": "巴士上的邻座男子",
|
112 |
+
"教官": "教官",
|
113 |
+
"队员": "队员",
|
114 |
+
"货车司机": "货车司机",
|
115 |
+
"森口": "森口",
|
116 |
+
"莳菜": "莳菜",
|
117 |
+
"猫": "猫",
|
118 |
+
"主妇": "主妇",
|
119 |
+
"便利店店员A": "便利店店员A",
|
120 |
+
"广播": "广播",
|
121 |
+
"牛肋肉": "牛肋肉",
|
122 |
+
"莫莫特尔教授": "莫莫特尔教授",
|
123 |
+
"牛喉管": "牛喉管",
|
124 |
+
"女人": "女人",
|
125 |
+
"女店员": "女店员",
|
126 |
+
"机器": "机器",
|
127 |
+
"女孩A": "女孩A",
|
128 |
+
"女孩A": "女孩A",
|
129 |
+
"女孩B": "女孩B",
|
130 |
+
"中谷": "中谷",
|
131 |
+
"催收员": "催收员",
|
132 |
+
"杰西德维": "杰西德维",
|
133 |
+
"杰西阿什巴哈": "杰西阿什巴哈",
|
134 |
+
"店员": "店员",
|
135 |
+
"便利店店员B": "便利店店员B",
|
136 |
+
"女服务员": "女服务员",
|
137 |
+
"阿姨": "阿姨",
|
138 |
+
"“满”": "满",
|
139 |
+
"鱼": "鱼",
|
140 |
+
"少女": "少女",
|
141 |
+
"少女": "少女",
|
142 |
+
"X岭幸": "X岭幸",
|
143 |
+
"T音": "T音",
|
144 |
+
"M满": "M满",
|
145 |
+
"Y美子": "Y美子",
|
146 |
+
"S菜": "S菜",
|
147 |
+
"幸的母亲": "幸的母亲",
|
148 |
+
"桑原": "桑原",
|
149 |
+
"大塚": "大冢",
|
150 |
+
"父亲": "父亲",
|
151 |
+
"老妇人": "老妇人",
|
152 |
+
"男子A": "男子A",
|
153 |
+
"年轻男子": "年轻男子",
|
154 |
+
"女主持人": "女主持人",
|
155 |
+
"策划人": "策划人",
|
156 |
+
"幸·雄二": "幸&雄二",
|
157 |
+
"四人": "四人",
|
158 |
+
"幸·JB": "幸&JB",
|
159 |
+
"JB·幸": "JB&幸",
|
160 |
+
"工作人员": "工作人员",
|
161 |
+
"老妇人1": "老妇人1",
|
162 |
+
"老妇人2": "老妇人2",
|
163 |
+
"幸穗": "幸穗",
|
164 |
+
"新闻播报员": "新闻播报员",
|
165 |
+
"当地���民": "当地居民",
|
166 |
+
"?": "?",
|
167 |
+
"鲸君": "鲸君",
|
168 |
+
"微型计算机电饭煲": "微型计算机电饭煲",
|
169 |
+
"机器人": "机器人",
|
170 |
+
"由美子·幸·机器人": "由美子&幸&机器人",
|
171 |
+
"幸德瑞拉": "幸德瑞拉",
|
172 |
+
"蹭得累拉": "蹭得累拉",
|
173 |
+
"老鼠": "老鼠",
|
174 |
+
"酷德瑞拉": "酷德瑞拉",
|
175 |
+
"妖精": "妖精",
|
176 |
+
"由美子": "由美子",
|
177 |
+
"满·幸·莳菜": "满&幸&莳菜",
|
178 |
+
"满·幸": "满&幸",
|
179 |
+
"由美子(猫)": "由美子(猫)",
|
180 |
+
"猫(由美子)": "猫(由美子)",
|
181 |
+
"幸·满": "幸&满",
|
182 |
+
"老奶奶": "老奶奶",
|
183 |
+
"母亲": "母亲",
|
184 |
+
"救护队员": "救护队员",
|
185 |
+
"桐原": "桐原",
|
186 |
+
"奥斯陆": "奥斯陆",
|
187 |
+
"女孩子": "女孩子",
|
188 |
+
"玛琳": "玛琳",
|
189 |
+
"周围的声音": "周围的声音",
|
190 |
+
"护士": "护士",
|
191 |
+
"酒店接待": "酒店接待",
|
192 |
+
"格伦法官": "格伦法官",
|
193 |
+
"奥斯陆的部下": "奥斯陆的部下",
|
194 |
+
"麻子": "麻子",
|
195 |
+
"麻子": "麻子",
|
196 |
+
"修女": "修女",
|
197 |
+
"黑人男性": "黑人男性",
|
198 |
+
"前辈": "前辈",
|
199 |
+
"丹尼": "丹尼",
|
200 |
+
"加勒特大尉": "加勒特大尉",
|
201 |
+
"前辈店员": "前辈店员",
|
202 |
+
"米莉": "米莉",
|
203 |
+
"艾迪": "艾迪",
|
204 |
+
"PC男": "PC男",
|
205 |
+
"罗比": "罗比",
|
206 |
+
"工兵": "工兵",
|
207 |
+
"J少尉": "J少尉",
|
208 |
+
"补充士兵": "补充士兵",
|
209 |
+
"武藤": "武藤",
|
210 |
+
"队员A": "队员A",
|
211 |
+
"队员B": "队员B",
|
212 |
+
"队员C": "队员C",
|
213 |
+
"队员全员": "队员全员",
|
214 |
+
"队员D": "队员D",
|
215 |
+
"队员E": "队员E",
|
216 |
+
"大使馆职员": "大使馆职员",
|
217 |
+
"机场设施责任人": "机场设施责任人",
|
218 |
+
"机场警察局长": "机场警察局长",
|
219 |
+
"接线员": "接线员",
|
220 |
+
"千鹤": "千鹤",
|
221 |
+
"「啊……呜!呜呜呜!嗯嗯……!呜,啊……」": "麻子",
|
222 |
+
"莳菜·幸": "莳菜&幸",
|
223 |
+
"满·天音": "满&天音",
|
224 |
+
"黑猫": "黑猫",
|
225 |
+
"小男孩": "小男孩",
|
226 |
+
"妈妈": "妈妈",
|
227 |
+
"年轻女店员": "年轻女店员",
|
228 |
+
"金发男": "金发男",
|
229 |
+
"一同": "一同"
|
230 |
+
}
|
231 |
+
|
232 |
+
# =================
|
233 |
+
for path in a:
|
234 |
+
name = path[path.rindex('\\'):]
|
235 |
+
if 'select' in name:
|
236 |
+
continue
|
237 |
+
idx = name.index('_')
|
238 |
+
name = name[:idx]
|
239 |
+
if name not in sc:
|
240 |
+
sc[name] = []
|
241 |
+
print(name)
|
242 |
+
# =================
|
243 |
+
|
244 |
+
with open(path, 'r', encoding='utf-8') as f:
|
245 |
+
data = list(filter(lambda x: x,
|
246 |
+
(x.strip() for x in f.readlines())))
|
247 |
+
w_i = -1
|
248 |
+
while w_i < len(data) - 1:
|
249 |
+
w_i += 1
|
250 |
+
line: str = data[w_i]
|
251 |
+
if line in _n:
|
252 |
+
if line.startswith('「'):
|
253 |
+
pass
|
254 |
+
elif len(line) - len(_n[line]) > 4:
|
255 |
+
pass
|
256 |
+
elif data[w_i + 1].startswith('『'):
|
257 |
+
assert removeQ(data[w_i + 1]).endswith('』')
|
258 |
+
data[w_i + 1] = f'「{data[w_i + 1]}」'
|
259 |
+
print(data[w_i + 1])
|
260 |
+
continue
|
261 |
+
elif not (data[w_i + 1].startswith('「')):
|
262 |
+
pass
|
263 |
+
else:
|
264 |
+
continue
|
265 |
+
# print(line)
|
266 |
+
if line.startswith('「'):
|
267 |
+
n = data[w_i-1]
|
268 |
+
if n in _n:
|
269 |
+
n = _n[n]
|
270 |
+
else:
|
271 |
+
pass
|
272 |
+
# _n[n] = clearT(n).replace('・', '&')
|
273 |
+
# print(n, line)
|
274 |
+
tmp = []
|
275 |
+
while not (removeQ(line).endswith('」')):
|
276 |
+
tmp.append(line)
|
277 |
+
w_i += 1
|
278 |
+
line: str = data[w_i]
|
279 |
+
if line in _n:
|
280 |
+
w_i -= 1
|
281 |
+
break
|
282 |
+
else:
|
283 |
+
tmp.append(line)
|
284 |
+
line = '\\n'.join(tmp)
|
285 |
+
else:
|
286 |
+
n = '旁白'
|
287 |
+
d = clearT(line)
|
288 |
+
if d:
|
289 |
+
sc[name].append(n + ':' + d)
|
290 |
+
|
291 |
+
# =================
|
292 |
+
|
293 |
+
for k, v in sc.items():
|
294 |
+
if v:
|
295 |
+
with open(b + f'\\{k}.txt', 'w', encoding='utf-8') as f:
|
296 |
+
f.write('\n'.join(v))
|
297 |
+
# =================
|
298 |
+
import json
|
299 |
+
tmp = json.dumps(_n, ensure_ascii=False, indent=4)
|