asj319 commited on
Commit
f9b1fc4
·
1 Parent(s): b2e196c

Upload 35 files

Browse files
Files changed (35) hide show
  1. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/.gitignore +4 -0
  2. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/LICENSE +21 -0
  3. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/README.md +3 -0
  4. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/javascript/bak/interactive_tag_selector.js +323 -0
  5. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/javascript/bak/js-yaml.min.js +2 -0
  6. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/javascript/easy_prompt_selector.js +342 -0
  7. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/javascript/js-yaml.min.js +2 -0
  8. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/scripts/__pycache__/easy_prompt_selector.cpython-310.pyc +0 -0
  9. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/scripts/__pycache__/settings.cpython-310.pyc +0 -0
  10. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/scripts/__pycache__/setup.cpython-310.pyc +0 -0
  11. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/scripts/easy_prompt_selector.py +132 -0
  12. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/scripts/settings.py +6 -0
  13. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/scripts/setup.py +38 -0
  14. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/style.css +10 -0
  15. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/.keep +0 -0
  16. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物.yml +61 -0
  17. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_五官.yml +75 -0
  18. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_头发.yml +81 -0
  19. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_姿势.yml +125 -0
  20. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_尾翅膀角.yml +44 -0
  21. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_服装.yml +82 -0
  22. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_表情.yml +38 -0
  23. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_装饰.yml +71 -0
  24. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_角色.yml +77 -0
  25. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_鞋袜帽.yml +82 -0
  26. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/十八禁.yml +163 -0
  27. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/汉服.yml +170 -0
  28. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/环境.yml +124 -0
  29. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/画质和视角.yml +58 -0
  30. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/艺术风格.yml +68 -0
  31. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/负面.yml +24 -0
  32. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/魔法系.yml +68 -0
  33. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags_examples/人.yml +66 -0
  34. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags_examples/人_顔.yml +78 -0
  35. sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags_examples/人_髪.yml +81 -0
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/.gitignore ADDED
@@ -0,0 +1,4 @@
 
 
 
 
 
1
+ # Byte-compiled / optimized / DLL files
2
+ __pycache__/
3
+
4
+ tags/**
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/LICENSE ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ MIT License
2
+
3
+ Copyright (c) 2022 Adi Eyal
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/README.md ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ # Easy Prompt Selector
2
+
3
+ [使い方(暫定)](https://blue-pen5805.fanbox.cc/posts/5306601)
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/javascript/bak/interactive_tag_selector.js ADDED
@@ -0,0 +1,323 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ class ITSElementBuilder {
2
+ // Templates
3
+ static baseButton(text, { size = 'sm', color = 'primary' }) {
4
+ const button = gradioApp().getElementById('txt2img_generate').cloneNode()
5
+ button.id = ''
6
+ button.classList.remove('gr-button-lg', 'gr-button-primary', 'lg', 'primary')
7
+ button.classList.add(
8
+ // gradio 3.16
9
+ `gr-button-${size}`,
10
+ `gr-button-${color}`,
11
+ // gradio 3.22
12
+ size,
13
+ color
14
+ )
15
+ button.textContent = text
16
+
17
+ return button
18
+ }
19
+
20
+ static tagFields() {
21
+ const fields = document.createElement('div')
22
+ fields.style.display = 'flex'
23
+ fields.style.flexDirection = 'row'
24
+ fields.style.flexWrap = 'wrap'
25
+ fields.style.minWidth = 'min(320px, 100%)'
26
+ fields.style.maxWidth = '100%'
27
+ fields.style.flex = '1 calc(50% - 20px)'
28
+ fields.style.borderWidth = '1px'
29
+ fields.style.borderColor = 'var(--block-border-color,#374151)'
30
+ fields.style.borderRadius = 'var(--block-radius,8px)'
31
+ fields.style.padding = '8px'
32
+ fields.style.height = 'fit-content'
33
+
34
+ return fields
35
+ }
36
+
37
+ // Elements
38
+ static openButton({ onClick }) {
39
+ const button = ITSElementBuilder.baseButton('🔯タグを選択', { size: 'sm', color: 'secondary' })
40
+ button.style = 'margin-top: 0.5rem;'
41
+ button.addEventListener('click', onClick)
42
+
43
+ return button
44
+ }
45
+
46
+ static areaContainer(id = undefined) {
47
+ const container = gradioApp().getElementById('txt2img_results').cloneNode()
48
+ container.id = id
49
+ container.style.gap = 0
50
+ container.style.display = 'none'
51
+
52
+ return container
53
+ }
54
+
55
+ static tagButton({ title, onClick, onRightClick, color = 'primary' }) {
56
+ const button = ITSElementBuilder.baseButton(title, { color })
57
+ button.style.height = '2rem'
58
+ button.style.flexGrow = '0'
59
+ button.style.margin = '2px'
60
+
61
+ button.addEventListener('click', onClick)
62
+ button.addEventListener('contextmenu', onRightClick)
63
+
64
+ return button
65
+ }
66
+
67
+ static dropDown(id, options, { onChange }) {
68
+ const select = document.createElement('select')
69
+ select.id = id
70
+
71
+ // gradio 3.16
72
+ select.classList.add('gr-box', 'gr-input')
73
+
74
+ // gradio 3.22
75
+ select.style.color = 'var(--body-text-color)'
76
+ select.style.backgroundColor = 'var(--input-background-fill)'
77
+ select.style.borderColor = 'var(--block-border-color)'
78
+ select.style.borderRadius = 'var(--block-radius)'
79
+ select.style.margin = '2px'
80
+ select.addEventListener('change', (event) => { onChange(event.target.value) })
81
+
82
+ const none = ['なし']
83
+ none.concat(options).forEach((key) => {
84
+ const option = document.createElement('option')
85
+ option.value = key
86
+ option.textContent = key
87
+ select.appendChild(option)
88
+ })
89
+
90
+ return select
91
+ }
92
+
93
+ static checkbox(text, { onChange }) {
94
+ const label = document.createElement('label')
95
+ label.style.display = 'flex'
96
+ label.style.alignItems = 'center'
97
+
98
+ const checkbox = gradioApp().querySelector('input[type=checkbox]').cloneNode()
99
+ checkbox.addEventListener('change', (event) => {
100
+ onChange(event.target.checked)
101
+ })
102
+
103
+ const span = document.createElement('span')
104
+ span.style.marginLeft = 'var(--size-2, 8px)'
105
+ span.textContent = text
106
+
107
+ label.appendChild(checkbox)
108
+ label.appendChild(span)
109
+
110
+ return label
111
+ }
112
+ }
113
+
114
+ class InteractiveTagSelector {
115
+ PATH_FILE = 'tmp/interactiveTagSelector.txt'
116
+ AREA_ID = 'interactive-tag-selector'
117
+ SELECT_ID = 'interactive-tag-selector-select'
118
+ CONTENT_ID = 'interactive-tag-selector-content'
119
+ TO_NEGATIVE_PROMPT_ID = 'interactive-tag-selector-to-negative-prompt'
120
+
121
+ constructor(yaml, gradioApp) {
122
+ this.yaml = yaml
123
+ this.gradioApp = gradioApp
124
+ this.visible = false
125
+ this.toNegative = false
126
+ this.tags = undefined
127
+ }
128
+
129
+ async init() {
130
+ this.tags = await this.parseFiles()
131
+ }
132
+
133
+ async readFile(filepath) {
134
+ const response = await fetch(`file=${filepath}?${new Date().getTime()}`);
135
+
136
+ return await response.text();
137
+ }
138
+
139
+ async parseFiles() {
140
+ const text = await this.readFile(this.PATH_FILE);
141
+ if (text === '') { return {} }
142
+
143
+ const paths = text.split(/\r\n|\n/)
144
+
145
+ const tags = {}
146
+ for (const path of paths) {
147
+ const filename = path.split('/').pop().split('.').shift()
148
+ const data = await this.readFile(path)
149
+ yaml.loadAll(data, function (doc) {
150
+ tags[filename] = doc
151
+ })
152
+ }
153
+
154
+ return tags
155
+ }
156
+
157
+ // Render
158
+ render() {
159
+ const row = document.createElement('div')
160
+ row.style.display = 'flex'
161
+ row.style.alignItems = 'center'
162
+ row.style.gap = '10px'
163
+
164
+ const dropDown = this.renderDropdown()
165
+ dropDown.style.flex = '1'
166
+ dropDown.style.minWidth = '1'
167
+ row.appendChild(dropDown)
168
+
169
+ const settings = document.createElement('div')
170
+ const checkbox = ITSElementBuilder.checkbox('ネガティブプロンプトに入力', {
171
+ onChange: (checked) => { this.toNegative = checked }
172
+ })
173
+ settings.style.flex = '1'
174
+ settings.appendChild(checkbox)
175
+
176
+ row.appendChild(settings)
177
+
178
+ const container = ITSElementBuilder.areaContainer(this.AREA_ID)
179
+
180
+ container.appendChild(row)
181
+ container.appendChild(this.renderContent())
182
+
183
+ return container
184
+ }
185
+
186
+ renderDropdown() {
187
+ const dropDown = ITSElementBuilder.dropDown(
188
+ this.SELECT_ID,
189
+ Object.keys(this.tags), {
190
+ onChange: (selected) => {
191
+ const content = gradioApp().getElementById(this.CONTENT_ID)
192
+ Array.from(content.childNodes).forEach((node) => {
193
+ const visible = node.id === `interactive-tag-selector-container-${selected}`
194
+ this.changeVisibility(node, visible)
195
+ })
196
+ }
197
+ }
198
+ )
199
+
200
+ return dropDown
201
+ }
202
+
203
+ renderContent() {
204
+ const content = document.createElement('div')
205
+ content.id = this.CONTENT_ID
206
+
207
+ Object.keys(this.tags).forEach((key) => {
208
+ const values = this.tags[key]
209
+
210
+ const fields = ITSElementBuilder.tagFields()
211
+ fields.id = `interactive-tag-selector-container-${key}`
212
+ fields.style.display = 'none'
213
+ fields.style.flexDirection = 'row'
214
+ fields.style.marginTop = '10px'
215
+
216
+ this.renderTagButtons(values, key).forEach((group) => {
217
+ fields.appendChild(group)
218
+ })
219
+
220
+ content.appendChild(fields)
221
+ })
222
+
223
+ return content
224
+ }
225
+
226
+ renderTagButtons(tags, prefix = '') {
227
+ if (Array.isArray(tags)) {
228
+ return tags.map((tag) => this.renderTagButton(tag, tag, 'secondary'))
229
+ } else {
230
+ return Object.keys(tags).map((key) => {
231
+ const values = tags[key]
232
+ const randomKey = `${prefix}:${key}`
233
+
234
+ if (typeof values === 'string') { return this.renderTagButton(key, values, 'secondary') }
235
+
236
+ const fields = ITSElementBuilder.tagFields()
237
+ fields.style.flexDirection = 'column'
238
+
239
+ fields.append(this.renderTagButton(key, `@${randomKey}@`))
240
+
241
+ const buttons = ITSElementBuilder.tagFields()
242
+ buttons.id = 'buttons'
243
+ fields.append(buttons)
244
+ this.renderTagButtons(values, randomKey).forEach((button) => {
245
+ buttons.appendChild(button)
246
+ })
247
+
248
+ return fields
249
+ })
250
+ }
251
+ }
252
+
253
+ renderTagButton(title, value, color = 'primary') {
254
+ return ITSElementBuilder.tagButton({
255
+ title,
256
+ onClick: (e) => {
257
+ e.preventDefault();
258
+
259
+ this.addTag(value, this.toNegative || e.metaKey || e.ctrlKey)
260
+ },
261
+ onRightClick: (e) => {
262
+ e.preventDefault();
263
+
264
+ this.removeTag(value, this.toNegative || e.metaKey || e.ctrlKey)
265
+ },
266
+ color
267
+ })
268
+ }
269
+
270
+ // Util
271
+ changeVisibility(node, visible) {
272
+ node.style.display = visible ? 'flex' : 'none'
273
+ }
274
+
275
+ addTag(tag, toNegative = false) {
276
+ const id = toNegative ? 'txt2img_neg_prompt' : 'txt2img_prompt'
277
+ const textarea = gradioApp().getElementById(id).querySelector('textarea')
278
+
279
+ if (textarea.value.trim() === '') {
280
+ textarea.value = tag
281
+ } else if (textarea.value.trim().endsWith(',')) {
282
+ textarea.value += ' ' + tag
283
+ } else {
284
+ textarea.value += ', ' + tag
285
+ }
286
+
287
+ updateInput(textarea)
288
+ }
289
+
290
+ removeTag(tag, toNegative = false) {
291
+ const id = toNegative ? 'txt2img_neg_prompt' : 'txt2img_prompt'
292
+ const textarea = gradioApp().getElementById(id).querySelector('textarea')
293
+
294
+ if (textarea.value.trimStart().startsWith(tag)) {
295
+ const matched = textarea.value.match(new RegExp(`${tag.replace(/[-\/\\^$*+?.()|\[\]{}]/g, '\\$&') },*`))
296
+ textarea.value = textarea.value.replace(matched[0], '').trimStart()
297
+ } else {
298
+ textarea.value = textarea.value.replace(`, ${tag}`, '')
299
+ }
300
+
301
+ updateInput(textarea)
302
+ }
303
+ }
304
+
305
+ onUiLoaded(async () => {
306
+ yaml = window.jsyaml
307
+ const interactiveTagSelector = new InteractiveTagSelector(yaml, gradioApp())
308
+ await interactiveTagSelector.init()
309
+
310
+ const button = ITSElementBuilder.openButton({
311
+ onClick: () => {
312
+ const tagArea = gradioApp().querySelector(`#${interactiveTagSelector.AREA_ID}`)
313
+ interactiveTagSelector.changeVisibility(tagArea, interactiveTagSelector.visible = !interactiveTagSelector.visible)
314
+ }
315
+ })
316
+
317
+ const txt2imgActionColumn = gradioApp().getElementById('txt2img_actions_column')
318
+ txt2imgActionColumn.appendChild(button)
319
+
320
+ gradioApp()
321
+ .getElementById('txt2img_toprow')
322
+ .after(interactiveTagSelector.render())
323
+ })
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/javascript/bak/js-yaml.min.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ /*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */
2
+ !function (e, t) { "object" == typeof exports && "undefined" != typeof module ? t(exports) : "function" == typeof define && define.amd ? define(["exports"], t) : t((e = "undefined" != typeof globalThis ? globalThis : e || self).jsyaml = {}) }(this, (function (e) { "use strict"; function t(e) { return null == e } var n = { isNothing: t, isObject: function (e) { return "object" == typeof e && null !== e }, toArray: function (e) { return Array.isArray(e) ? e : t(e) ? [] : [e] }, repeat: function (e, t) { var n, i = ""; for (n = 0; n < t; n += 1)i += e; return i }, isNegativeZero: function (e) { return 0 === e && Number.NEGATIVE_INFINITY === 1 / e }, extend: function (e, t) { var n, i, r, o; if (t) for (n = 0, i = (o = Object.keys(t)).length; n < i; n += 1)e[r = o[n]] = t[r]; return e } }; function i(e, t) { var n = "", i = e.reason || "(unknown reason)"; return e.mark ? (e.mark.name && (n += 'in "' + e.mark.name + '" '), n += "(" + (e.mark.line + 1) + ":" + (e.mark.column + 1) + ")", !t && e.mark.snippet && (n += "\n\n" + e.mark.snippet), i + " " + n) : i } function r(e, t) { Error.call(this), this.name = "YAMLException", this.reason = e, this.mark = t, this.message = i(this, !1), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = (new Error).stack || "" } r.prototype = Object.create(Error.prototype), r.prototype.constructor = r, r.prototype.toString = function (e) { return this.name + ": " + i(this, e) }; var o = r; function a(e, t, n, i, r) { var o = "", a = "", l = Math.floor(r / 2) - 1; return i - t > l && (t = i - l + (o = " ... ").length), n - i > l && (n = i + l - (a = " ...").length), { str: o + e.slice(t, n).replace(/\t/g, "→") + a, pos: i - t + o.length } } function l(e, t) { return n.repeat(" ", t - e.length) + e } var c = function (e, t) { if (t = Object.create(t || null), !e.buffer) return null; t.maxLength || (t.maxLength = 79), "number" != typeof t.indent && (t.indent = 1), "number" != typeof t.linesBefore && (t.linesBefore = 3), "number" != typeof t.linesAfter && (t.linesAfter = 2); for (var i, r = /\r?\n|\r|\0/g, o = [0], c = [], s = -1; i = r.exec(e.buffer);)c.push(i.index), o.push(i.index + i[0].length), e.position <= i.index && s < 0 && (s = o.length - 2); s < 0 && (s = o.length - 1); var u, p, f = "", d = Math.min(e.line + t.linesAfter, c.length).toString().length, h = t.maxLength - (t.indent + d + 3); for (u = 1; u <= t.linesBefore && !(s - u < 0); u++)p = a(e.buffer, o[s - u], c[s - u], e.position - (o[s] - o[s - u]), h), f = n.repeat(" ", t.indent) + l((e.line - u + 1).toString(), d) + " | " + p.str + "\n" + f; for (p = a(e.buffer, o[s], c[s], e.position, h), f += n.repeat(" ", t.indent) + l((e.line + 1).toString(), d) + " | " + p.str + "\n", f += n.repeat("-", t.indent + d + 3 + p.pos) + "^\n", u = 1; u <= t.linesAfter && !(s + u >= c.length); u++)p = a(e.buffer, o[s + u], c[s + u], e.position - (o[s] - o[s + u]), h), f += n.repeat(" ", t.indent) + l((e.line + u + 1).toString(), d) + " | " + p.str + "\n"; return f.replace(/\n$/, "") }, s = ["kind", "multi", "resolve", "construct", "instanceOf", "predicate", "represent", "representName", "defaultStyle", "styleAliases"], u = ["scalar", "sequence", "mapping"]; var p = function (e, t) { if (t = t || {}, Object.keys(t).forEach((function (t) { if (-1 === s.indexOf(t)) throw new o('Unknown option "' + t + '" is met in definition of "' + e + '" YAML type.') })), this.options = t, this.tag = e, this.kind = t.kind || null, this.resolve = t.resolve || function () { return !0 }, this.construct = t.construct || function (e) { return e }, this.instanceOf = t.instanceOf || null, this.predicate = t.predicate || null, this.represent = t.represent || null, this.representName = t.representName || null, this.defaultStyle = t.defaultStyle || null, this.multi = t.multi || !1, this.styleAliases = function (e) { var t = {}; return null !== e && Object.keys(e).forEach((function (n) { e[n].forEach((function (e) { t[String(e)] = n })) })), t }(t.styleAliases || null), -1 === u.indexOf(this.kind)) throw new o('Unknown kind "' + this.kind + '" is specified for "' + e + '" YAML type.') }; function f(e, t) { var n = []; return e[t].forEach((function (e) { var t = n.length; n.forEach((function (n, i) { n.tag === e.tag && n.kind === e.kind && n.multi === e.multi && (t = i) })), n[t] = e })), n } function d(e) { return this.extend(e) } d.prototype.extend = function (e) { var t = [], n = []; if (e instanceof p) n.push(e); else if (Array.isArray(e)) n = n.concat(e); else { if (!e || !Array.isArray(e.implicit) && !Array.isArray(e.explicit)) throw new o("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })"); e.implicit && (t = t.concat(e.implicit)), e.explicit && (n = n.concat(e.explicit)) } t.forEach((function (e) { if (!(e instanceof p)) throw new o("Specified list of YAML types (or a single Type object) contains a non-Type object."); if (e.loadKind && "scalar" !== e.loadKind) throw new o("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported."); if (e.multi) throw new o("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.") })), n.forEach((function (e) { if (!(e instanceof p)) throw new o("Specified list of YAML types (or a single Type object) contains a non-Type object.") })); var i = Object.create(d.prototype); return i.implicit = (this.implicit || []).concat(t), i.explicit = (this.explicit || []).concat(n), i.compiledImplicit = f(i, "implicit"), i.compiledExplicit = f(i, "explicit"), i.compiledTypeMap = function () { var e, t, n = { scalar: {}, sequence: {}, mapping: {}, fallback: {}, multi: { scalar: [], sequence: [], mapping: [], fallback: [] } }; function i(e) { e.multi ? (n.multi[e.kind].push(e), n.multi.fallback.push(e)) : n[e.kind][e.tag] = n.fallback[e.tag] = e } for (e = 0, t = arguments.length; e < t; e += 1)arguments[e].forEach(i); return n }(i.compiledImplicit, i.compiledExplicit), i }; var h = d, g = new p("tag:yaml.org,2002:str", { kind: "scalar", construct: function (e) { return null !== e ? e : "" } }), m = new p("tag:yaml.org,2002:seq", { kind: "sequence", construct: function (e) { return null !== e ? e : [] } }), y = new p("tag:yaml.org,2002:map", { kind: "mapping", construct: function (e) { return null !== e ? e : {} } }), b = new h({ explicit: [g, m, y] }); var A = new p("tag:yaml.org,2002:null", { kind: "scalar", resolve: function (e) { if (null === e) return !0; var t = e.length; return 1 === t && "~" === e || 4 === t && ("null" === e || "Null" === e || "NULL" === e) }, construct: function () { return null }, predicate: function (e) { return null === e }, represent: { canonical: function () { return "~" }, lowercase: function () { return "null" }, uppercase: function () { return "NULL" }, camelcase: function () { return "Null" }, empty: function () { return "" } }, defaultStyle: "lowercase" }); var v = new p("tag:yaml.org,2002:bool", { kind: "scalar", resolve: function (e) { if (null === e) return !1; var t = e.length; return 4 === t && ("true" === e || "True" === e || "TRUE" === e) || 5 === t && ("false" === e || "False" === e || "FALSE" === e) }, construct: function (e) { return "true" === e || "True" === e || "TRUE" === e }, predicate: function (e) { return "[object Boolean]" === Object.prototype.toString.call(e) }, represent: { lowercase: function (e) { return e ? "true" : "false" }, uppercase: function (e) { return e ? "TRUE" : "FALSE" }, camelcase: function (e) { return e ? "True" : "False" } }, defaultStyle: "lowercase" }); function w(e) { return 48 <= e && e <= 55 } function k(e) { return 48 <= e && e <= 57 } var C = new p("tag:yaml.org,2002:int", { kind: "scalar", resolve: function (e) { if (null === e) return !1; var t, n, i = e.length, r = 0, o = !1; if (!i) return !1; if ("-" !== (t = e[r]) && "+" !== t || (t = e[++r]), "0" === t) { if (r + 1 === i) return !0; if ("b" === (t = e[++r])) { for (r++; r < i; r++)if ("_" !== (t = e[r])) { if ("0" !== t && "1" !== t) return !1; o = !0 } return o && "_" !== t } if ("x" === t) { for (r++; r < i; r++)if ("_" !== (t = e[r])) { if (!(48 <= (n = e.charCodeAt(r)) && n <= 57 || 65 <= n && n <= 70 || 97 <= n && n <= 102)) return !1; o = !0 } return o && "_" !== t } if ("o" === t) { for (r++; r < i; r++)if ("_" !== (t = e[r])) { if (!w(e.charCodeAt(r))) return !1; o = !0 } return o && "_" !== t } } if ("_" === t) return !1; for (; r < i; r++)if ("_" !== (t = e[r])) { if (!k(e.charCodeAt(r))) return !1; o = !0 } return !(!o || "_" === t) }, construct: function (e) { var t, n = e, i = 1; if (-1 !== n.indexOf("_") && (n = n.replace(/_/g, "")), "-" !== (t = n[0]) && "+" !== t || ("-" === t && (i = -1), t = (n = n.slice(1))[0]), "0" === n) return 0; if ("0" === t) { if ("b" === n[1]) return i * parseInt(n.slice(2), 2); if ("x" === n[1]) return i * parseInt(n.slice(2), 16); if ("o" === n[1]) return i * parseInt(n.slice(2), 8) } return i * parseInt(n, 10) }, predicate: function (e) { return "[object Number]" === Object.prototype.toString.call(e) && e % 1 == 0 && !n.isNegativeZero(e) }, represent: { binary: function (e) { return e >= 0 ? "0b" + e.toString(2) : "-0b" + e.toString(2).slice(1) }, octal: function (e) { return e >= 0 ? "0o" + e.toString(8) : "-0o" + e.toString(8).slice(1) }, decimal: function (e) { return e.toString(10) }, hexadecimal: function (e) { return e >= 0 ? "0x" + e.toString(16).toUpperCase() : "-0x" + e.toString(16).toUpperCase().slice(1) } }, defaultStyle: "decimal", styleAliases: { binary: [2, "bin"], octal: [8, "oct"], decimal: [10, "dec"], hexadecimal: [16, "hex"] } }), x = new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"); var I = /^[-+]?[0-9]+e/; var S = new p("tag:yaml.org,2002:float", { kind: "scalar", resolve: function (e) { return null !== e && !(!x.test(e) || "_" === e[e.length - 1]) }, construct: function (e) { var t, n; return n = "-" === (t = e.replace(/_/g, "").toLowerCase())[0] ? -1 : 1, "+-".indexOf(t[0]) >= 0 && (t = t.slice(1)), ".inf" === t ? 1 === n ? Number.POSITIVE_INFINITY : Number.NEGATIVE_INFINITY : ".nan" === t ? NaN : n * parseFloat(t, 10) }, predicate: function (e) { return "[object Number]" === Object.prototype.toString.call(e) && (e % 1 != 0 || n.isNegativeZero(e)) }, represent: function (e, t) { var i; if (isNaN(e)) switch (t) { case "lowercase": return ".nan"; case "uppercase": return ".NAN"; case "camelcase": return ".NaN" } else if (Number.POSITIVE_INFINITY === e) switch (t) { case "lowercase": return ".inf"; case "uppercase": return ".INF"; case "camelcase": return ".Inf" } else if (Number.NEGATIVE_INFINITY === e) switch (t) { case "lowercase": return "-.inf"; case "uppercase": return "-.INF"; case "camelcase": return "-.Inf" } else if (n.isNegativeZero(e)) return "-0.0"; return i = e.toString(10), I.test(i) ? i.replace("e", ".e") : i }, defaultStyle: "lowercase" }), O = b.extend({ implicit: [A, v, C, S] }), j = O, T = new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"), N = new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$"); var F = new p("tag:yaml.org,2002:timestamp", { kind: "scalar", resolve: function (e) { return null !== e && (null !== T.exec(e) || null !== N.exec(e)) }, construct: function (e) { var t, n, i, r, o, a, l, c, s = 0, u = null; if (null === (t = T.exec(e)) && (t = N.exec(e)), null === t) throw new Error("Date resolve error"); if (n = +t[1], i = +t[2] - 1, r = +t[3], !t[4]) return new Date(Date.UTC(n, i, r)); if (o = +t[4], a = +t[5], l = +t[6], t[7]) { for (s = t[7].slice(0, 3); s.length < 3;)s += "0"; s = +s } return t[9] && (u = 6e4 * (60 * +t[10] + +(t[11] || 0)), "-" === t[9] && (u = -u)), c = new Date(Date.UTC(n, i, r, o, a, l, s)), u && c.setTime(c.getTime() - u), c }, instanceOf: Date, represent: function (e) { return e.toISOString() } }); var E = new p("tag:yaml.org,2002:merge", { kind: "scalar", resolve: function (e) { return "<<" === e || null === e } }), M = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r"; var L = new p("tag:yaml.org,2002:binary", { kind: "scalar", resolve: function (e) { if (null === e) return !1; var t, n, i = 0, r = e.length, o = M; for (n = 0; n < r; n++)if (!((t = o.indexOf(e.charAt(n))) > 64)) { if (t < 0) return !1; i += 6 } return i % 8 == 0 }, construct: function (e) { var t, n, i = e.replace(/[\r\n=]/g, ""), r = i.length, o = M, a = 0, l = []; for (t = 0; t < r; t++)t % 4 == 0 && t && (l.push(a >> 16 & 255), l.push(a >> 8 & 255), l.push(255 & a)), a = a << 6 | o.indexOf(i.charAt(t)); return 0 === (n = r % 4 * 6) ? (l.push(a >> 16 & 255), l.push(a >> 8 & 255), l.push(255 & a)) : 18 === n ? (l.push(a >> 10 & 255), l.push(a >> 2 & 255)) : 12 === n && l.push(a >> 4 & 255), new Uint8Array(l) }, predicate: function (e) { return "[object Uint8Array]" === Object.prototype.toString.call(e) }, represent: function (e) { var t, n, i = "", r = 0, o = e.length, a = M; for (t = 0; t < o; t++)t % 3 == 0 && t && (i += a[r >> 18 & 63], i += a[r >> 12 & 63], i += a[r >> 6 & 63], i += a[63 & r]), r = (r << 8) + e[t]; return 0 === (n = o % 3) ? (i += a[r >> 18 & 63], i += a[r >> 12 & 63], i += a[r >> 6 & 63], i += a[63 & r]) : 2 === n ? (i += a[r >> 10 & 63], i += a[r >> 4 & 63], i += a[r << 2 & 63], i += a[64]) : 1 === n && (i += a[r >> 2 & 63], i += a[r << 4 & 63], i += a[64], i += a[64]), i } }), _ = Object.prototype.hasOwnProperty, D = Object.prototype.toString; var U = new p("tag:yaml.org,2002:omap", { kind: "sequence", resolve: function (e) { if (null === e) return !0; var t, n, i, r, o, a = [], l = e; for (t = 0, n = l.length; t < n; t += 1) { if (i = l[t], o = !1, "[object Object]" !== D.call(i)) return !1; for (r in i) if (_.call(i, r)) { if (o) return !1; o = !0 } if (!o) return !1; if (-1 !== a.indexOf(r)) return !1; a.push(r) } return !0 }, construct: function (e) { return null !== e ? e : [] } }), q = Object.prototype.toString; var Y = new p("tag:yaml.org,2002:pairs", { kind: "sequence", resolve: function (e) { if (null === e) return !0; var t, n, i, r, o, a = e; for (o = new Array(a.length), t = 0, n = a.length; t < n; t += 1) { if (i = a[t], "[object Object]" !== q.call(i)) return !1; if (1 !== (r = Object.keys(i)).length) return !1; o[t] = [r[0], i[r[0]]] } return !0 }, construct: function (e) { if (null === e) return []; var t, n, i, r, o, a = e; for (o = new Array(a.length), t = 0, n = a.length; t < n; t += 1)i = a[t], r = Object.keys(i), o[t] = [r[0], i[r[0]]]; return o } }), R = Object.prototype.hasOwnProperty; var B = new p("tag:yaml.org,2002:set", { kind: "mapping", resolve: function (e) { if (null === e) return !0; var t, n = e; for (t in n) if (R.call(n, t) && null !== n[t]) return !1; return !0 }, construct: function (e) { return null !== e ? e : {} } }), K = j.extend({ implicit: [F, E], explicit: [L, U, Y, B] }), P = Object.prototype.hasOwnProperty, W = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, H = /[\x85\u2028\u2029]/, $ = /[,\[\]\{\}]/, G = /^(?:!|!!|![a-z\-]+!)$/i, V = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i; function Z(e) { return Object.prototype.toString.call(e) } function J(e) { return 10 === e || 13 === e } function Q(e) { return 9 === e || 32 === e } function z(e) { return 9 === e || 32 === e || 10 === e || 13 === e } function X(e) { return 44 === e || 91 === e || 93 === e || 123 === e || 125 === e } function ee(e) { var t; return 48 <= e && e <= 57 ? e - 48 : 97 <= (t = 32 | e) && t <= 102 ? t - 97 + 10 : -1 } function te(e) { return 48 === e ? "\0" : 97 === e ? "" : 98 === e ? "\b" : 116 === e || 9 === e ? "\t" : 110 === e ? "\n" : 118 === e ? "\v" : 102 === e ? "\f" : 114 === e ? "\r" : 101 === e ? "" : 32 === e ? " " : 34 === e ? '"' : 47 === e ? "/" : 92 === e ? "\\" : 78 === e ? "…" : 95 === e ? " " : 76 === e ? "\u2028" : 80 === e ? "\u2029" : "" } function ne(e) { return e <= 65535 ? String.fromCharCode(e) : String.fromCharCode(55296 + (e - 65536 >> 10), 56320 + (e - 65536 & 1023)) } for (var ie = new Array(256), re = new Array(256), oe = 0; oe < 256; oe++)ie[oe] = te(oe) ? 1 : 0, re[oe] = te(oe); function ae(e, t) { this.input = e, this.filename = t.filename || null, this.schema = t.schema || K, this.onWarning = t.onWarning || null, this.legacy = t.legacy || !1, this.json = t.json || !1, this.listener = t.listener || null, this.implicitTypes = this.schema.compiledImplicit, this.typeMap = this.schema.compiledTypeMap, this.length = e.length, this.position = 0, this.line = 0, this.lineStart = 0, this.lineIndent = 0, this.firstTabInLine = -1, this.documents = [] } function le(e, t) { var n = { name: e.filename, buffer: e.input.slice(0, -1), position: e.position, line: e.line, column: e.position - e.lineStart }; return n.snippet = c(n), new o(t, n) } function ce(e, t) { throw le(e, t) } function se(e, t) { e.onWarning && e.onWarning.call(null, le(e, t)) } var ue = { YAML: function (e, t, n) { var i, r, o; null !== e.version && ce(e, "duplication of %YAML directive"), 1 !== n.length && ce(e, "YAML directive accepts exactly one argument"), null === (i = /^([0-9]+)\.([0-9]+)$/.exec(n[0])) && ce(e, "ill-formed argument of the YAML directive"), r = parseInt(i[1], 10), o = parseInt(i[2], 10), 1 !== r && ce(e, "unacceptable YAML version of the document"), e.version = n[0], e.checkLineBreaks = o < 2, 1 !== o && 2 !== o && se(e, "unsupported YAML version of the document") }, TAG: function (e, t, n) { var i, r; 2 !== n.length && ce(e, "TAG directive accepts exactly two arguments"), i = n[0], r = n[1], G.test(i) || ce(e, "ill-formed tag handle (first argument) of the TAG directive"), P.call(e.tagMap, i) && ce(e, 'there is a previously declared suffix for "' + i + '" tag handle'), V.test(r) || ce(e, "ill-formed tag prefix (second argument) of the TAG directive"); try { r = decodeURIComponent(r) } catch (t) { ce(e, "tag prefix is malformed: " + r) } e.tagMap[i] = r } }; function pe(e, t, n, i) { var r, o, a, l; if (t < n) { if (l = e.input.slice(t, n), i) for (r = 0, o = l.length; r < o; r += 1)9 === (a = l.charCodeAt(r)) || 32 <= a && a <= 1114111 || ce(e, "expected valid JSON character"); else W.test(l) && ce(e, "the stream contains non-printable characters"); e.result += l } } function fe(e, t, i, r) { var o, a, l, c; for (n.isObject(i) || ce(e, "cannot merge mappings; the provided source object is unacceptable"), l = 0, c = (o = Object.keys(i)).length; l < c; l += 1)a = o[l], P.call(t, a) || (t[a] = i[a], r[a] = !0) } function de(e, t, n, i, r, o, a, l, c) { var s, u; if (Array.isArray(r)) for (s = 0, u = (r = Array.prototype.slice.call(r)).length; s < u; s += 1)Array.isArray(r[s]) && ce(e, "nested arrays are not supported inside keys"), "object" == typeof r && "[object Object]" === Z(r[s]) && (r[s] = "[object Object]"); if ("object" == typeof r && "[object Object]" === Z(r) && (r = "[object Object]"), r = String(r), null === t && (t = {}), "tag:yaml.org,2002:merge" === i) if (Array.isArray(o)) for (s = 0, u = o.length; s < u; s += 1)fe(e, t, o[s], n); else fe(e, t, o, n); else e.json || P.call(n, r) || !P.call(t, r) || (e.line = a || e.line, e.lineStart = l || e.lineStart, e.position = c || e.position, ce(e, "duplicated mapping key")), "__proto__" === r ? Object.defineProperty(t, r, { configurable: !0, enumerable: !0, writable: !0, value: o }) : t[r] = o, delete n[r]; return t } function he(e) { var t; 10 === (t = e.input.charCodeAt(e.position)) ? e.position++ : 13 === t ? (e.position++, 10 === e.input.charCodeAt(e.position) && e.position++) : ce(e, "a line break is expected"), e.line += 1, e.lineStart = e.position, e.firstTabInLine = -1 } function ge(e, t, n) { for (var i = 0, r = e.input.charCodeAt(e.position); 0 !== r;) { for (; Q(r);)9 === r && -1 === e.firstTabInLine && (e.firstTabInLine = e.position), r = e.input.charCodeAt(++e.position); if (t && 35 === r) do { r = e.input.charCodeAt(++e.position) } while (10 !== r && 13 !== r && 0 !== r); if (!J(r)) break; for (he(e), r = e.input.charCodeAt(e.position), i++, e.lineIndent = 0; 32 === r;)e.lineIndent++, r = e.input.charCodeAt(++e.position) } return -1 !== n && 0 !== i && e.lineIndent < n && se(e, "deficient indentation"), i } function me(e) { var t, n = e.position; return !(45 !== (t = e.input.charCodeAt(n)) && 46 !== t || t !== e.input.charCodeAt(n + 1) || t !== e.input.charCodeAt(n + 2) || (n += 3, 0 !== (t = e.input.charCodeAt(n)) && !z(t))) } function ye(e, t) { 1 === t ? e.result += " " : t > 1 && (e.result += n.repeat("\n", t - 1)) } function be(e, t) { var n, i, r = e.tag, o = e.anchor, a = [], l = !1; if (-1 !== e.firstTabInLine) return !1; for (null !== e.anchor && (e.anchorMap[e.anchor] = a), i = e.input.charCodeAt(e.position); 0 !== i && (-1 !== e.firstTabInLine && (e.position = e.firstTabInLine, ce(e, "tab characters must not be used in indentation")), 45 === i) && z(e.input.charCodeAt(e.position + 1));)if (l = !0, e.position++, ge(e, !0, -1) && e.lineIndent <= t) a.push(null), i = e.input.charCodeAt(e.position); else if (n = e.line, we(e, t, 3, !1, !0), a.push(e.result), ge(e, !0, -1), i = e.input.charCodeAt(e.position), (e.line === n || e.lineIndent > t) && 0 !== i) ce(e, "bad indentation of a sequence entry"); else if (e.lineIndent < t) break; return !!l && (e.tag = r, e.anchor = o, e.kind = "sequence", e.result = a, !0) } function Ae(e) { var t, n, i, r, o = !1, a = !1; if (33 !== (r = e.input.charCodeAt(e.position))) return !1; if (null !== e.tag && ce(e, "duplication of a tag property"), 60 === (r = e.input.charCodeAt(++e.position)) ? (o = !0, r = e.input.charCodeAt(++e.position)) : 33 === r ? (a = !0, n = "!!", r = e.input.charCodeAt(++e.position)) : n = "!", t = e.position, o) { do { r = e.input.charCodeAt(++e.position) } while (0 !== r && 62 !== r); e.position < e.length ? (i = e.input.slice(t, e.position), r = e.input.charCodeAt(++e.position)) : ce(e, "unexpected end of the stream within a verbatim tag") } else { for (; 0 !== r && !z(r);)33 === r && (a ? ce(e, "tag suffix cannot contain exclamation marks") : (n = e.input.slice(t - 1, e.position + 1), G.test(n) || ce(e, "named tag handle cannot contain such characters"), a = !0, t = e.position + 1)), r = e.input.charCodeAt(++e.position); i = e.input.slice(t, e.position), $.test(i) && ce(e, "tag suffix cannot contain flow indicator characters") } i && !V.test(i) && ce(e, "tag name cannot contain such characters: " + i); try { i = decodeURIComponent(i) } catch (t) { ce(e, "tag name is malformed: " + i) } return o ? e.tag = i : P.call(e.tagMap, n) ? e.tag = e.tagMap[n] + i : "!" === n ? e.tag = "!" + i : "!!" === n ? e.tag = "tag:yaml.org,2002:" + i : ce(e, 'undeclared tag handle "' + n + '"'), !0 } function ve(e) { var t, n; if (38 !== (n = e.input.charCodeAt(e.position))) return !1; for (null !== e.anchor && ce(e, "duplication of an anchor property"), n = e.input.charCodeAt(++e.position), t = e.position; 0 !== n && !z(n) && !X(n);)n = e.input.charCodeAt(++e.position); return e.position === t && ce(e, "name of an anchor node must contain at least one character"), e.anchor = e.input.slice(t, e.position), !0 } function we(e, t, i, r, o) { var a, l, c, s, u, p, f, d, h, g = 1, m = !1, y = !1; if (null !== e.listener && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, a = l = c = 4 === i || 3 === i, r && ge(e, !0, -1) && (m = !0, e.lineIndent > t ? g = 1 : e.lineIndent === t ? g = 0 : e.lineIndent < t && (g = -1)), 1 === g) for (; Ae(e) || ve(e);)ge(e, !0, -1) ? (m = !0, c = a, e.lineIndent > t ? g = 1 : e.lineIndent === t ? g = 0 : e.lineIndent < t && (g = -1)) : c = !1; if (c && (c = m || o), 1 !== g && 4 !== i || (d = 1 === i || 2 === i ? t : t + 1, h = e.position - e.lineStart, 1 === g ? c && (be(e, h) || function (e, t, n) { var i, r, o, a, l, c, s, u = e.tag, p = e.anchor, f = {}, d = Object.create(null), h = null, g = null, m = null, y = !1, b = !1; if (-1 !== e.firstTabInLine) return !1; for (null !== e.anchor && (e.anchorMap[e.anchor] = f), s = e.input.charCodeAt(e.position); 0 !== s;) { if (y || -1 === e.firstTabInLine || (e.position = e.firstTabInLine, ce(e, "tab characters must not be used in indentation")), i = e.input.charCodeAt(e.position + 1), o = e.line, 63 !== s && 58 !== s || !z(i)) { if (a = e.line, l = e.lineStart, c = e.position, !we(e, n, 2, !1, !0)) break; if (e.line === o) { for (s = e.input.charCodeAt(e.position); Q(s);)s = e.input.charCodeAt(++e.position); if (58 === s) z(s = e.input.charCodeAt(++e.position)) || ce(e, "a whitespace character is expected after the key-value separator within a block mapping"), y && (de(e, f, d, h, g, null, a, l, c), h = g = m = null), b = !0, y = !1, r = !1, h = e.tag, g = e.result; else { if (!b) return e.tag = u, e.anchor = p, !0; ce(e, "can not read an implicit mapping pair; a colon is missed") } } else { if (!b) return e.tag = u, e.anchor = p, !0; ce(e, "can not read a block mapping entry; a multiline key may not be an implicit key") } } else 63 === s ? (y && (de(e, f, d, h, g, null, a, l, c), h = g = m = null), b = !0, y = !0, r = !0) : y ? (y = !1, r = !0) : ce(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, s = i; if ((e.line === o || e.lineIndent > t) && (y && (a = e.line, l = e.lineStart, c = e.position), we(e, t, 4, !0, r) && (y ? g = e.result : m = e.result), y || (de(e, f, d, h, g, m, a, l, c), h = g = m = null), ge(e, !0, -1), s = e.input.charCodeAt(e.position)), (e.line === o || e.lineIndent > t) && 0 !== s) ce(e, "bad indentation of a mapping entry"); else if (e.lineIndent < t) break } return y && de(e, f, d, h, g, null, a, l, c), b && (e.tag = u, e.anchor = p, e.kind = "mapping", e.result = f), b }(e, h, d)) || function (e, t) { var n, i, r, o, a, l, c, s, u, p, f, d, h = !0, g = e.tag, m = e.anchor, y = Object.create(null); if (91 === (d = e.input.charCodeAt(e.position))) a = 93, s = !1, o = []; else { if (123 !== d) return !1; a = 125, s = !0, o = {} } for (null !== e.anchor && (e.anchorMap[e.anchor] = o), d = e.input.charCodeAt(++e.position); 0 !== d;) { if (ge(e, !0, t), (d = e.input.charCodeAt(e.position)) === a) return e.position++, e.tag = g, e.anchor = m, e.kind = s ? "mapping" : "sequence", e.result = o, !0; h ? 44 === d && ce(e, "expected the node content, but found ','") : ce(e, "missed comma between flow collection entries"), f = null, l = c = !1, 63 === d && z(e.input.charCodeAt(e.position + 1)) && (l = c = !0, e.position++, ge(e, !0, t)), n = e.line, i = e.lineStart, r = e.position, we(e, t, 1, !1, !0), p = e.tag, u = e.result, ge(e, !0, t), d = e.input.charCodeAt(e.position), !c && e.line !== n || 58 !== d || (l = !0, d = e.input.charCodeAt(++e.position), ge(e, !0, t), we(e, t, 1, !1, !0), f = e.result), s ? de(e, o, y, p, u, f, n, i, r) : l ? o.push(de(e, null, y, p, u, f, n, i, r)) : o.push(u), ge(e, !0, t), 44 === (d = e.input.charCodeAt(e.position)) ? (h = !0, d = e.input.charCodeAt(++e.position)) : h = !1 } ce(e, "unexpected end of the stream within a flow collection") }(e, d) ? y = !0 : (l && function (e, t) { var i, r, o, a, l, c = 1, s = !1, u = !1, p = t, f = 0, d = !1; if (124 === (a = e.input.charCodeAt(e.position))) r = !1; else { if (62 !== a) return !1; r = !0 } for (e.kind = "scalar", e.result = ""; 0 !== a;)if (43 === (a = e.input.charCodeAt(++e.position)) || 45 === a) 1 === c ? c = 43 === a ? 3 : 2 : ce(e, "repeat of a chomping mode identifier"); else { if (!((o = 48 <= (l = a) && l <= 57 ? l - 48 : -1) >= 0)) break; 0 === o ? ce(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : u ? ce(e, "repeat of an indentation width identifier") : (p = t + o - 1, u = !0) } if (Q(a)) { do { a = e.input.charCodeAt(++e.position) } while (Q(a)); if (35 === a) do { a = e.input.charCodeAt(++e.position) } while (!J(a) && 0 !== a) } for (; 0 !== a;) { for (he(e), e.lineIndent = 0, a = e.input.charCodeAt(e.position); (!u || e.lineIndent < p) && 32 === a;)e.lineIndent++, a = e.input.charCodeAt(++e.position); if (!u && e.lineIndent > p && (p = e.lineIndent), J(a)) f++; else { if (e.lineIndent < p) { 3 === c ? e.result += n.repeat("\n", s ? 1 + f : f) : 1 === c && s && (e.result += "\n"); break } for (r ? Q(a) ? (d = !0, e.result += n.repeat("\n", s ? 1 + f : f)) : d ? (d = !1, e.result += n.repeat("\n", f + 1)) : 0 === f ? s && (e.result += " ") : e.result += n.repeat("\n", f) : e.result += n.repeat("\n", s ? 1 + f : f), s = !0, u = !0, f = 0, i = e.position; !J(a) && 0 !== a;)a = e.input.charCodeAt(++e.position); pe(e, i, e.position, !1) } } return !0 }(e, d) || function (e, t) { var n, i, r; if (39 !== (n = e.input.charCodeAt(e.position))) return !1; for (e.kind = "scalar", e.result = "", e.position++, i = r = e.position; 0 !== (n = e.input.charCodeAt(e.position));)if (39 === n) { if (pe(e, i, e.position, !0), 39 !== (n = e.input.charCodeAt(++e.position))) return !0; i = e.position, e.position++, r = e.position } else J(n) ? (pe(e, i, r, !0), ye(e, ge(e, !1, t)), i = r = e.position) : e.position === e.lineStart && me(e) ? ce(e, "unexpected end of the document within a single quoted scalar") : (e.position++, r = e.position); ce(e, "unexpected end of the stream within a single quoted scalar") }(e, d) || function (e, t) { var n, i, r, o, a, l, c; if (34 !== (l = e.input.charCodeAt(e.position))) return !1; for (e.kind = "scalar", e.result = "", e.position++, n = i = e.position; 0 !== (l = e.input.charCodeAt(e.position));) { if (34 === l) return pe(e, n, e.position, !0), e.position++, !0; if (92 === l) { if (pe(e, n, e.position, !0), J(l = e.input.charCodeAt(++e.position))) ge(e, !1, t); else if (l < 256 && ie[l]) e.result += re[l], e.position++; else if ((a = 120 === (c = l) ? 2 : 117 === c ? 4 : 85 === c ? 8 : 0) > 0) { for (r = a, o = 0; r > 0; r--)(a = ee(l = e.input.charCodeAt(++e.position))) >= 0 ? o = (o << 4) + a : ce(e, "expected hexadecimal character"); e.result += ne(o), e.position++ } else ce(e, "unknown escape sequence"); n = i = e.position } else J(l) ? (pe(e, n, i, !0), ye(e, ge(e, !1, t)), n = i = e.position) : e.position === e.lineStart && me(e) ? ce(e, "unexpected end of the document within a double quoted scalar") : (e.position++, i = e.position) } ce(e, "unexpected end of the stream within a double quoted scalar") }(e, d) ? y = !0 : !function (e) { var t, n, i; if (42 !== (i = e.input.charCodeAt(e.position))) return !1; for (i = e.input.charCodeAt(++e.position), t = e.position; 0 !== i && !z(i) && !X(i);)i = e.input.charCodeAt(++e.position); return e.position === t && ce(e, "name of an alias node must contain at least one character"), n = e.input.slice(t, e.position), P.call(e.anchorMap, n) || ce(e, 'unidentified alias "' + n + '"'), e.result = e.anchorMap[n], ge(e, !0, -1), !0 }(e) ? function (e, t, n) { var i, r, o, a, l, c, s, u, p = e.kind, f = e.result; if (z(u = e.input.charCodeAt(e.position)) || X(u) || 35 === u || 38 === u || 42 === u || 33 === u || 124 === u || 62 === u || 39 === u || 34 === u || 37 === u || 64 === u || 96 === u) return !1; if ((63 === u || 45 === u) && (z(i = e.input.charCodeAt(e.position + 1)) || n && X(i))) return !1; for (e.kind = "scalar", e.result = "", r = o = e.position, a = !1; 0 !== u;) { if (58 === u) { if (z(i = e.input.charCodeAt(e.position + 1)) || n && X(i)) break } else if (35 === u) { if (z(e.input.charCodeAt(e.position - 1))) break } else { if (e.position === e.lineStart && me(e) || n && X(u)) break; if (J(u)) { if (l = e.line, c = e.lineStart, s = e.lineIndent, ge(e, !1, -1), e.lineIndent >= t) { a = !0, u = e.input.charCodeAt(e.position); continue } e.position = o, e.line = l, e.lineStart = c, e.lineIndent = s; break } } a && (pe(e, r, o, !1), ye(e, e.line - l), r = o = e.position, a = !1), Q(u) || (o = e.position + 1), u = e.input.charCodeAt(++e.position) } return pe(e, r, o, !1), !!e.result || (e.kind = p, e.result = f, !1) }(e, d, 1 === i) && (y = !0, null === e.tag && (e.tag = "?")) : (y = !0, null === e.tag && null === e.anchor || ce(e, "alias node should not have any properties")), null !== e.anchor && (e.anchorMap[e.anchor] = e.result)) : 0 === g && (y = c && be(e, h))), null === e.tag) null !== e.anchor && (e.anchorMap[e.anchor] = e.result); else if ("?" === e.tag) { for (null !== e.result && "scalar" !== e.kind && ce(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), s = 0, u = e.implicitTypes.length; s < u; s += 1)if ((f = e.implicitTypes[s]).resolve(e.result)) { e.result = f.construct(e.result), e.tag = f.tag, null !== e.anchor && (e.anchorMap[e.anchor] = e.result); break } } else if ("!" !== e.tag) { if (P.call(e.typeMap[e.kind || "fallback"], e.tag)) f = e.typeMap[e.kind || "fallback"][e.tag]; else for (f = null, s = 0, u = (p = e.typeMap.multi[e.kind || "fallback"]).length; s < u; s += 1)if (e.tag.slice(0, p[s].tag.length) === p[s].tag) { f = p[s]; break } f || ce(e, "unknown tag !<" + e.tag + ">"), null !== e.result && f.kind !== e.kind && ce(e, "unacceptable node kind for !<" + e.tag + '> tag; it should be "' + f.kind + '", not "' + e.kind + '"'), f.resolve(e.result, e.tag) ? (e.result = f.construct(e.result, e.tag), null !== e.anchor && (e.anchorMap[e.anchor] = e.result)) : ce(e, "cannot resolve a node with !<" + e.tag + "> explicit tag") } return null !== e.listener && e.listener("close", e), null !== e.tag || null !== e.anchor || y } function ke(e) { var t, n, i, r, o = e.position, a = !1; for (e.version = null, e.checkLineBreaks = e.legacy, e.tagMap = Object.create(null), e.anchorMap = Object.create(null); 0 !== (r = e.input.charCodeAt(e.position)) && (ge(e, !0, -1), r = e.input.charCodeAt(e.position), !(e.lineIndent > 0 || 37 !== r));) { for (a = !0, r = e.input.charCodeAt(++e.position), t = e.position; 0 !== r && !z(r);)r = e.input.charCodeAt(++e.position); for (i = [], (n = e.input.slice(t, e.position)).length < 1 && ce(e, "directive name must not be less than one character in length"); 0 !== r;) { for (; Q(r);)r = e.input.charCodeAt(++e.position); if (35 === r) { do { r = e.input.charCodeAt(++e.position) } while (0 !== r && !J(r)); break } if (J(r)) break; for (t = e.position; 0 !== r && !z(r);)r = e.input.charCodeAt(++e.position); i.push(e.input.slice(t, e.position)) } 0 !== r && he(e), P.call(ue, n) ? ue[n](e, n, i) : se(e, 'unknown document directive "' + n + '"') } ge(e, !0, -1), 0 === e.lineIndent && 45 === e.input.charCodeAt(e.position) && 45 === e.input.charCodeAt(e.position + 1) && 45 === e.input.charCodeAt(e.position + 2) ? (e.position += 3, ge(e, !0, -1)) : a && ce(e, "directives end mark is expected"), we(e, e.lineIndent - 1, 4, !1, !0), ge(e, !0, -1), e.checkLineBreaks && H.test(e.input.slice(o, e.position)) && se(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && me(e) ? 46 === e.input.charCodeAt(e.position) && (e.position += 3, ge(e, !0, -1)) : e.position < e.length - 1 && ce(e, "end of the stream or a document separator is expected") } function Ce(e, t) { t = t || {}, 0 !== (e = String(e)).length && (10 !== e.charCodeAt(e.length - 1) && 13 !== e.charCodeAt(e.length - 1) && (e += "\n"), 65279 === e.charCodeAt(0) && (e = e.slice(1))); var n = new ae(e, t), i = e.indexOf("\0"); for (-1 !== i && (n.position = i, ce(n, "null byte is not allowed in input")), n.input += "\0"; 32 === n.input.charCodeAt(n.position);)n.lineIndent += 1, n.position += 1; for (; n.position < n.length - 1;)ke(n); return n.documents } var xe = { loadAll: function (e, t, n) { null !== t && "object" == typeof t && void 0 === n && (n = t, t = null); var i = Ce(e, n); if ("function" != typeof t) return i; for (var r = 0, o = i.length; r < o; r += 1)t(i[r]) }, load: function (e, t) { var n = Ce(e, t); if (0 !== n.length) { if (1 === n.length) return n[0]; throw new o("expected a single document in the stream, but found more") } } }, Ie = Object.prototype.toString, Se = Object.prototype.hasOwnProperty, Oe = 65279, je = { 0: "\\0", 7: "\\a", 8: "\\b", 9: "\\t", 10: "\\n", 11: "\\v", 12: "\\f", 13: "\\r", 27: "\\e", 34: '\\"', 92: "\\\\", 133: "\\N", 160: "\\_", 8232: "\\L", 8233: "\\P" }, Te = ["y", "Y", "yes", "Yes", "YES", "on", "On", "ON", "n", "N", "no", "No", "NO", "off", "Off", "OFF"], Ne = /^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/; function Fe(e) { var t, i, r; if (t = e.toString(16).toUpperCase(), e <= 255) i = "x", r = 2; else if (e <= 65535) i = "u", r = 4; else { if (!(e <= 4294967295)) throw new o("code point within a string may not be greater than 0xFFFFFFFF"); i = "U", r = 8 } return "\\" + i + n.repeat("0", r - t.length) + t } function Ee(e) { this.schema = e.schema || K, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = n.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap = function (e, t) { var n, i, r, o, a, l, c; if (null === t) return {}; for (n = {}, r = 0, o = (i = Object.keys(t)).length; r < o; r += 1)a = i[r], l = String(t[a]), "!!" === a.slice(0, 2) && (a = "tag:yaml.org,2002:" + a.slice(2)), (c = e.compiledTypeMap.fallback[a]) && Se.call(c.styleAliases, l) && (l = c.styleAliases[l]), n[a] = l; return n }(this.schema, e.styles || null), this.sortKeys = e.sortKeys || !1, this.lineWidth = e.lineWidth || 80, this.noRefs = e.noRefs || !1, this.noCompatMode = e.noCompatMode || !1, this.condenseFlow = e.condenseFlow || !1, this.quotingType = '"' === e.quotingType ? 2 : 1, this.forceQuotes = e.forceQuotes || !1, this.replacer = "function" == typeof e.replacer ? e.replacer : null, this.implicitTypes = this.schema.compiledImplicit, this.explicitTypes = this.schema.compiledExplicit, this.tag = null, this.result = "", this.duplicates = [], this.usedDuplicates = null } function Me(e, t) { for (var i, r = n.repeat(" ", t), o = 0, a = -1, l = "", c = e.length; o < c;)-1 === (a = e.indexOf("\n", o)) ? (i = e.slice(o), o = c) : (i = e.slice(o, a + 1), o = a + 1), i.length && "\n" !== i && (l += r), l += i; return l } function Le(e, t) { return "\n" + n.repeat(" ", e.indent * t) } function _e(e) { return 32 === e || 9 === e } function De(e) { return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && 8232 !== e && 8233 !== e || 57344 <= e && e <= 65533 && e !== Oe || 65536 <= e && e <= 1114111 } function Ue(e) { return De(e) && e !== Oe && 13 !== e && 10 !== e } function qe(e, t, n) { var i = Ue(e), r = i && !_e(e); return (n ? i : i && 44 !== e && 91 !== e && 93 !== e && 123 !== e && 125 !== e) && 35 !== e && !(58 === t && !r) || Ue(t) && !_e(t) && 35 === e || 58 === t && r } function Ye(e, t) { var n, i = e.charCodeAt(t); return i >= 55296 && i <= 56319 && t + 1 < e.length && (n = e.charCodeAt(t + 1)) >= 56320 && n <= 57343 ? 1024 * (i - 55296) + n - 56320 + 65536 : i } function Re(e) { return /^\n* /.test(e) } function Be(e, t, n, i, r, o, a, l) { var c, s, u = 0, p = null, f = !1, d = !1, h = -1 !== i, g = -1, m = De(s = Ye(e, 0)) && s !== Oe && !_e(s) && 45 !== s && 63 !== s && 58 !== s && 44 !== s && 91 !== s && 93 !== s && 123 !== s && 125 !== s && 35 !== s && 38 !== s && 42 !== s && 33 !== s && 124 !== s && 61 !== s && 62 !== s && 39 !== s && 34 !== s && 37 !== s && 64 !== s && 96 !== s && function (e) { return !_e(e) && 58 !== e }(Ye(e, e.length - 1)); if (t || a) for (c = 0; c < e.length; u >= 65536 ? c += 2 : c++) { if (!De(u = Ye(e, c))) return 5; m = m && qe(u, p, l), p = u } else { for (c = 0; c < e.length; u >= 65536 ? c += 2 : c++) { if (10 === (u = Ye(e, c))) f = !0, h && (d = d || c - g - 1 > i && " " !== e[g + 1], g = c); else if (!De(u)) return 5; m = m && qe(u, p, l), p = u } d = d || h && c - g - 1 > i && " " !== e[g + 1] } return f || d ? n > 9 && Re(e) ? 5 : a ? 2 === o ? 5 : 2 : d ? 4 : 3 : !m || a || r(e) ? 2 === o ? 5 : 2 : 1 } function Ke(e, t, n, i, r) { e.dump = function () { if (0 === t.length) return 2 === e.quotingType ? '""' : "''"; if (!e.noCompatMode && (-1 !== Te.indexOf(t) || Ne.test(t))) return 2 === e.quotingType ? '"' + t + '"' : "'" + t + "'"; var a = e.indent * Math.max(1, n), l = -1 === e.lineWidth ? -1 : Math.max(Math.min(e.lineWidth, 40), e.lineWidth - a), c = i || e.flowLevel > -1 && n >= e.flowLevel; switch (Be(t, c, e.indent, l, (function (t) { return function (e, t) { var n, i; for (n = 0, i = e.implicitTypes.length; n < i; n += 1)if (e.implicitTypes[n].resolve(t)) return !0; return !1 }(e, t) }), e.quotingType, e.forceQuotes && !i, r)) { case 1: return t; case 2: return "'" + t.replace(/'/g, "''") + "'"; case 3: return "|" + Pe(t, e.indent) + We(Me(t, a)); case 4: return ">" + Pe(t, e.indent) + We(Me(function (e, t) { var n, i, r = /(\n+)([^\n]*)/g, o = (l = e.indexOf("\n"), l = -1 !== l ? l : e.length, r.lastIndex = l, He(e.slice(0, l), t)), a = "\n" === e[0] || " " === e[0]; var l; for (; i = r.exec(e);) { var c = i[1], s = i[2]; n = " " === s[0], o += c + (a || n || "" === s ? "" : "\n") + He(s, t), a = n } return o }(t, l), a)); case 5: return '"' + function (e) { for (var t, n = "", i = 0, r = 0; r < e.length; i >= 65536 ? r += 2 : r++)i = Ye(e, r), !(t = je[i]) && De(i) ? (n += e[r], i >= 65536 && (n += e[r + 1])) : n += t || Fe(i); return n }(t) + '"'; default: throw new o("impossible error: invalid scalar style") } }() } function Pe(e, t) { var n = Re(e) ? String(t) : "", i = "\n" === e[e.length - 1]; return n + (i && ("\n" === e[e.length - 2] || "\n" === e) ? "+" : i ? "" : "-") + "\n" } function We(e) { return "\n" === e[e.length - 1] ? e.slice(0, -1) : e } function He(e, t) { if ("" === e || " " === e[0]) return e; for (var n, i, r = / [^ ]/g, o = 0, a = 0, l = 0, c = ""; n = r.exec(e);)(l = n.index) - o > t && (i = a > o ? a : l, c += "\n" + e.slice(o, i), o = i + 1), a = l; return c += "\n", e.length - o > t && a > o ? c += e.slice(o, a) + "\n" + e.slice(a + 1) : c += e.slice(o), c.slice(1) } function $e(e, t, n, i) { var r, o, a, l = "", c = e.tag; for (r = 0, o = n.length; r < o; r += 1)a = n[r], e.replacer && (a = e.replacer.call(n, String(r), a)), (Ve(e, t + 1, a, !0, !0, !1, !0) || void 0 === a && Ve(e, t + 1, null, !0, !0, !1, !0)) && (i && "" === l || (l += Le(e, t)), e.dump && 10 === e.dump.charCodeAt(0) ? l += "-" : l += "- ", l += e.dump); e.tag = c, e.dump = l || "[]" } function Ge(e, t, n) { var i, r, a, l, c, s; for (a = 0, l = (r = n ? e.explicitTypes : e.implicitTypes).length; a < l; a += 1)if (((c = r[a]).instanceOf || c.predicate) && (!c.instanceOf || "object" == typeof t && t instanceof c.instanceOf) && (!c.predicate || c.predicate(t))) { if (n ? c.multi && c.representName ? e.tag = c.representName(t) : e.tag = c.tag : e.tag = "?", c.represent) { if (s = e.styleMap[c.tag] || c.defaultStyle, "[object Function]" === Ie.call(c.represent)) i = c.represent(t, s); else { if (!Se.call(c.represent, s)) throw new o("!<" + c.tag + '> tag resolver accepts not "' + s + '" style'); i = c.represent[s](t, s) } e.dump = i } return !0 } return !1 } function Ve(e, t, n, i, r, a, l) { e.tag = null, e.dump = n, Ge(e, n, !1) || Ge(e, n, !0); var c, s = Ie.call(e.dump), u = i; i && (i = e.flowLevel < 0 || e.flowLevel > t); var p, f, d = "[object Object]" === s || "[object Array]" === s; if (d && (f = -1 !== (p = e.duplicates.indexOf(n))), (null !== e.tag && "?" !== e.tag || f || 2 !== e.indent && t > 0) && (r = !1), f && e.usedDuplicates[p]) e.dump = "*ref_" + p; else { if (d && f && !e.usedDuplicates[p] && (e.usedDuplicates[p] = !0), "[object Object]" === s) i && 0 !== Object.keys(e.dump).length ? (!function (e, t, n, i) { var r, a, l, c, s, u, p = "", f = e.tag, d = Object.keys(n); if (!0 === e.sortKeys) d.sort(); else if ("function" == typeof e.sortKeys) d.sort(e.sortKeys); else if (e.sortKeys) throw new o("sortKeys must be a boolean or a function"); for (r = 0, a = d.length; r < a; r += 1)u = "", i && "" === p || (u += Le(e, t)), c = n[l = d[r]], e.replacer && (c = e.replacer.call(n, l, c)), Ve(e, t + 1, l, !0, !0, !0) && ((s = null !== e.tag && "?" !== e.tag || e.dump && e.dump.length > 1024) && (e.dump && 10 === e.dump.charCodeAt(0) ? u += "?" : u += "? "), u += e.dump, s && (u += Le(e, t)), Ve(e, t + 1, c, !0, s) && (e.dump && 10 === e.dump.charCodeAt(0) ? u += ":" : u += ": ", p += u += e.dump)); e.tag = f, e.dump = p || "{}" }(e, t, e.dump, r), f && (e.dump = "&ref_" + p + e.dump)) : (!function (e, t, n) { var i, r, o, a, l, c = "", s = e.tag, u = Object.keys(n); for (i = 0, r = u.length; i < r; i += 1)l = "", "" !== c && (l += ", "), e.condenseFlow && (l += '"'), a = n[o = u[i]], e.replacer && (a = e.replacer.call(n, o, a)), Ve(e, t, o, !1, !1) && (e.dump.length > 1024 && (l += "? "), l += e.dump + (e.condenseFlow ? '"' : "") + ":" + (e.condenseFlow ? "" : " "), Ve(e, t, a, !1, !1) && (c += l += e.dump)); e.tag = s, e.dump = "{" + c + "}" }(e, t, e.dump), f && (e.dump = "&ref_" + p + " " + e.dump)); else if ("[object Array]" === s) i && 0 !== e.dump.length ? (e.noArrayIndent && !l && t > 0 ? $e(e, t - 1, e.dump, r) : $e(e, t, e.dump, r), f && (e.dump = "&ref_" + p + e.dump)) : (!function (e, t, n) { var i, r, o, a = "", l = e.tag; for (i = 0, r = n.length; i < r; i += 1)o = n[i], e.replacer && (o = e.replacer.call(n, String(i), o)), (Ve(e, t, o, !1, !1) || void 0 === o && Ve(e, t, null, !1, !1)) && ("" !== a && (a += "," + (e.condenseFlow ? "" : " ")), a += e.dump); e.tag = l, e.dump = "[" + a + "]" }(e, t, e.dump), f && (e.dump = "&ref_" + p + " " + e.dump)); else { if ("[object String]" !== s) { if ("[object Undefined]" === s) return !1; if (e.skipInvalid) return !1; throw new o("unacceptable kind of an object to dump " + s) } "?" !== e.tag && Ke(e, e.dump, t, a, u) } null !== e.tag && "?" !== e.tag && (c = encodeURI("!" === e.tag[0] ? e.tag.slice(1) : e.tag).replace(/!/g, "%21"), c = "!" === e.tag[0] ? "!" + c : "tag:yaml.org,2002:" === c.slice(0, 18) ? "!!" + c.slice(18) : "!<" + c + ">", e.dump = c + " " + e.dump) } return !0 } function Ze(e, t) { var n, i, r = [], o = []; for (Je(e, r, o), n = 0, i = o.length; n < i; n += 1)t.duplicates.push(r[o[n]]); t.usedDuplicates = new Array(i) } function Je(e, t, n) { var i, r, o; if (null !== e && "object" == typeof e) if (-1 !== (r = t.indexOf(e))) -1 === n.indexOf(r) && n.push(r); else if (t.push(e), Array.isArray(e)) for (r = 0, o = e.length; r < o; r += 1)Je(e[r], t, n); else for (r = 0, o = (i = Object.keys(e)).length; r < o; r += 1)Je(e[i[r]], t, n) } function Qe(e, t) { return function () { throw new Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + t + " instead, which is now safe by default.") } } var ze = p, Xe = h, et = b, tt = O, nt = j, it = K, rt = xe.load, ot = xe.loadAll, at = { dump: function (e, t) { var n = new Ee(t = t || {}); n.noRefs || Ze(e, n); var i = e; return n.replacer && (i = n.replacer.call({ "": i }, "", i)), Ve(n, 0, i, !0, !0) ? n.dump + "\n" : "" } }.dump, lt = o, ct = { binary: L, float: S, map: y, null: A, pairs: Y, set: B, timestamp: F, bool: v, int: C, merge: E, omap: U, seq: m, str: g }, st = Qe("safeLoad", "load"), ut = Qe("safeLoadAll", "loadAll"), pt = Qe("safeDump", "dump"), ft = { Type: ze, Schema: Xe, FAILSAFE_SCHEMA: et, JSON_SCHEMA: tt, CORE_SCHEMA: nt, DEFAULT_SCHEMA: it, load: rt, loadAll: ot, dump: at, YAMLException: lt, types: ct, safeLoad: st, safeLoadAll: ut, safeDump: pt }; e.CORE_SCHEMA = nt, e.DEFAULT_SCHEMA = it, e.FAILSAFE_SCHEMA = et, e.JSON_SCHEMA = tt, e.Schema = Xe, e.Type = ze, e.YAMLException = lt, e.default = ft, e.dump = at, e.load = rt, e.loadAll = ot, e.safeDump = pt, e.safeLoad = st, e.safeLoadAll = ut, e.types = ct, Object.defineProperty(e, "__esModule", { value: !0 }) }));
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/javascript/easy_prompt_selector.js ADDED
@@ -0,0 +1,342 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ class EPSElementBuilder {
2
+ // Templates
3
+ static baseButton(text, { size = 'sm', color = 'primary' }) {
4
+ const button = gradioApp().getElementById('txt2img_generate').cloneNode()
5
+ button.id = ''
6
+ button.classList.remove('gr-button-lg', 'gr-button-primary', 'lg', 'primary')
7
+ button.classList.add(
8
+ // gradio 3.16
9
+ `gr-button-${size}`,
10
+ `gr-button-${color}`,
11
+ // gradio 3.22
12
+ size,
13
+ color
14
+ )
15
+ button.textContent = text
16
+
17
+ return button
18
+ }
19
+
20
+ static tagFields() {
21
+ const fields = document.createElement('div')
22
+ fields.style.display = 'flex'
23
+ fields.style.flexDirection = 'row'
24
+ fields.style.flexWrap = 'wrap'
25
+ fields.style.minWidth = 'min(320px, 100%)'
26
+ fields.style.maxWidth = '100%'
27
+ fields.style.flex = '1 calc(50% - 20px)'
28
+ fields.style.borderWidth = '1px'
29
+ fields.style.borderColor = 'var(--block-border-color,#374151)'
30
+ fields.style.borderRadius = 'var(--block-radius,8px)'
31
+ fields.style.padding = '8px'
32
+ fields.style.height = 'fit-content'
33
+
34
+ return fields
35
+ }
36
+
37
+ // Elements
38
+ static openButton({ onClick }) {
39
+ const button = EPSElementBuilder.baseButton('🔯提示词', { size: 'sm', color: 'secondary' })
40
+ button.classList.add('easy_prompt_selector_button')
41
+ button.addEventListener('click', onClick)
42
+
43
+ return button
44
+ }
45
+
46
+ static areaContainer(id = undefined) {
47
+ const container = gradioApp().getElementById('txt2img_results').cloneNode()
48
+ container.id = id
49
+ container.style.gap = 0
50
+ container.style.display = 'none'
51
+
52
+ return container
53
+ }
54
+
55
+ static tagButton({ title, onClick, onRightClick, color = 'primary' }) {
56
+ const button = EPSElementBuilder.baseButton(title, { color })
57
+ button.style.height = '2rem'
58
+ button.style.flexGrow = '0'
59
+ button.style.margin = '2px'
60
+
61
+ button.addEventListener('click', onClick)
62
+ button.addEventListener('contextmenu', onRightClick)
63
+
64
+ return button
65
+ }
66
+
67
+ static dropDown(id, options, { onChange }) {
68
+ const select = document.createElement('select')
69
+ select.id = id
70
+
71
+ // gradio 3.16
72
+ select.classList.add('gr-box', 'gr-input')
73
+
74
+ // gradio 3.22
75
+ select.style.color = 'var(--body-text-color)'
76
+ select.style.backgroundColor = 'var(--input-background-fill)'
77
+ select.style.borderColor = 'var(--block-border-color)'
78
+ select.style.borderRadius = 'var(--block-radius)'
79
+ select.style.margin = '2px'
80
+ select.addEventListener('change', (event) => { onChange(event.target.value) })
81
+
82
+ const none = ['空']
83
+ none.concat(options).forEach((key) => {
84
+ const option = document.createElement('option')
85
+ option.value = key
86
+ option.textContent = key
87
+ select.appendChild(option)
88
+ })
89
+
90
+ return select
91
+ }
92
+
93
+ static checkbox(text, { onChange }) {
94
+ const label = document.createElement('label')
95
+ label.style.display = 'flex'
96
+ label.style.alignItems = 'center'
97
+
98
+ const checkbox = gradioApp().querySelector('input[type=checkbox]').cloneNode()
99
+ checkbox.checked = false
100
+ checkbox.addEventListener('change', (event) => {
101
+ onChange(event.target.checked)
102
+ })
103
+
104
+ const span = document.createElement('span')
105
+ span.style.marginLeft = 'var(--size-2, 8px)'
106
+ span.textContent = text
107
+
108
+ label.appendChild(checkbox)
109
+ label.appendChild(span)
110
+
111
+ return label
112
+ }
113
+ }
114
+
115
+ class EasyPromptSelector {
116
+ PATH_FILE = 'tmp/easyPromptSelector.txt'
117
+ AREA_ID = 'easy-prompt-selector'
118
+ SELECT_ID = 'easy-prompt-selector-select'
119
+ CONTENT_ID = 'easy-prompt-selector-content'
120
+ TO_NEGATIVE_PROMPT_ID = 'easy-prompt-selector-to-negative-prompt'
121
+
122
+ constructor(yaml, gradioApp) {
123
+ this.yaml = yaml
124
+ this.gradioApp = gradioApp
125
+ this.visible = false
126
+ this.toNegative = false
127
+ this.tags = undefined
128
+ }
129
+
130
+ async init() {
131
+ this.tags = await this.parseFiles()
132
+
133
+ const tagArea = gradioApp().querySelector(`#${this.AREA_ID}`)
134
+ if (tagArea != null) {
135
+ this.visible = false
136
+ this.changeVisibility(tagArea, this.visible)
137
+ tagArea.remove()
138
+ }
139
+
140
+ gradioApp()
141
+ .getElementById('txt2img_toprow')
142
+ .after(this.render())
143
+ }
144
+
145
+ async readFile(filepath) {
146
+ const response = await fetch(`file=${filepath}?${new Date().getTime()}`);
147
+
148
+ return await response.text();
149
+ }
150
+
151
+ async parseFiles() {
152
+ const text = await this.readFile(this.PATH_FILE);
153
+ if (text === '') { return {} }
154
+
155
+ const paths = text.split(/\r\n|\n/)
156
+
157
+ const tags = {}
158
+ for (const path of paths) {
159
+ const filename = path.split('/').pop().split('.').slice(0, -1).join('.')
160
+ const data = await this.readFile(path)
161
+ yaml.loadAll(data, function (doc) {
162
+ tags[filename] = doc
163
+ })
164
+ }
165
+
166
+ return tags
167
+ }
168
+
169
+ // Render
170
+ render() {
171
+ const row = document.createElement('div')
172
+ row.style.display = 'flex'
173
+ row.style.alignItems = 'center'
174
+ row.style.gap = '10px'
175
+
176
+ const dropDown = this.renderDropdown()
177
+ dropDown.style.flex = '1'
178
+ dropDown.style.minWidth = '1'
179
+ row.appendChild(dropDown)
180
+
181
+ const settings = document.createElement('div')
182
+ const checkbox = EPSElementBuilder.checkbox('负面', {
183
+ onChange: (checked) => { this.toNegative = checked }
184
+ })
185
+ settings.style.flex = '1'
186
+ settings.appendChild(checkbox)
187
+
188
+ row.appendChild(settings)
189
+
190
+ const container = EPSElementBuilder.areaContainer(this.AREA_ID)
191
+
192
+ container.appendChild(row)
193
+ container.appendChild(this.renderContent())
194
+
195
+ return container
196
+ }
197
+
198
+ renderDropdown() {
199
+ const dropDown = EPSElementBuilder.dropDown(
200
+ this.SELECT_ID,
201
+ Object.keys(this.tags), {
202
+ onChange: (selected) => {
203
+ const content = gradioApp().getElementById(this.CONTENT_ID)
204
+ Array.from(content.childNodes).forEach((node) => {
205
+ const visible = node.id === `easy-prompt-selector-container-${selected}`
206
+ this.changeVisibility(node, visible)
207
+ })
208
+ }
209
+ }
210
+ )
211
+
212
+ return dropDown
213
+ }
214
+
215
+ renderContent() {
216
+ const content = document.createElement('div')
217
+ content.id = this.CONTENT_ID
218
+
219
+ Object.keys(this.tags).forEach((key) => {
220
+ const values = this.tags[key]
221
+
222
+ const fields = EPSElementBuilder.tagFields()
223
+ fields.id = `easy-prompt-selector-container-${key}`
224
+ fields.style.display = 'none'
225
+ fields.style.flexDirection = 'row'
226
+ fields.style.marginTop = '10px'
227
+
228
+ this.renderTagButtons(values, key).forEach((group) => {
229
+ fields.appendChild(group)
230
+ })
231
+
232
+ content.appendChild(fields)
233
+ })
234
+
235
+ return content
236
+ }
237
+
238
+ renderTagButtons(tags, prefix = '') {
239
+ if (Array.isArray(tags)) {
240
+ return tags.map((tag) => this.renderTagButton(tag, tag, 'secondary'))
241
+ } else {
242
+ return Object.keys(tags).map((key) => {
243
+ const values = tags[key]
244
+ const randomKey = `${prefix}:${key}`
245
+
246
+ if (typeof values === 'string') { return this.renderTagButton(key, values, 'secondary') }
247
+
248
+ const fields = EPSElementBuilder.tagFields()
249
+ fields.style.flexDirection = 'column'
250
+
251
+ fields.append(this.renderTagButton(key, `@${randomKey}@`))
252
+
253
+ const buttons = EPSElementBuilder.tagFields()
254
+ buttons.id = 'buttons'
255
+ fields.append(buttons)
256
+ this.renderTagButtons(values, randomKey).forEach((button) => {
257
+ buttons.appendChild(button)
258
+ })
259
+
260
+ return fields
261
+ })
262
+ }
263
+ }
264
+
265
+ renderTagButton(title, value, color = 'primary') {
266
+ return EPSElementBuilder.tagButton({
267
+ title,
268
+ onClick: (e) => {
269
+ e.preventDefault();
270
+
271
+ this.addTag(value, this.toNegative || e.metaKey || e.ctrlKey)
272
+ },
273
+ onRightClick: (e) => {
274
+ e.preventDefault();
275
+
276
+ this.removeTag(value, this.toNegative || e.metaKey || e.ctrlKey)
277
+ },
278
+ color
279
+ })
280
+ }
281
+
282
+ // Util
283
+ changeVisibility(node, visible) {
284
+ node.style.display = visible ? 'flex' : 'none'
285
+ }
286
+
287
+ addTag(tag, toNegative = false) {
288
+ const id = toNegative ? 'txt2img_neg_prompt' : 'txt2img_prompt'
289
+ const textarea = gradioApp().getElementById(id).querySelector('textarea')
290
+
291
+ if (textarea.value.trim() === '') {
292
+ textarea.value = tag
293
+ } else if (textarea.value.trim().endsWith(',')) {
294
+ textarea.value += ' ' + tag
295
+ } else {
296
+ textarea.value += ', ' + tag
297
+ }
298
+
299
+ updateInput(textarea)
300
+ }
301
+
302
+ removeTag(tag, toNegative = false) {
303
+ const id = toNegative ? 'txt2img_neg_prompt' : 'txt2img_prompt'
304
+ const textarea = gradioApp().getElementById(id).querySelector('textarea')
305
+
306
+ if (textarea.value.trimStart().startsWith(tag)) {
307
+ const matched = textarea.value.match(new RegExp(`${tag.replace(/[-\/\\^$*+?.()|\[\]{}]/g, '\\$&') },*`))
308
+ textarea.value = textarea.value.replace(matched[0], '').trimStart()
309
+ } else {
310
+ textarea.value = textarea.value.replace(`, ${tag}`, '')
311
+ }
312
+
313
+ updateInput(textarea)
314
+ }
315
+ }
316
+
317
+ onUiLoaded(async () => {
318
+ yaml = window.jsyaml
319
+ const easyPromptSelector = new EasyPromptSelector(yaml, gradioApp())
320
+
321
+ const button = EPSElementBuilder.openButton({
322
+ onClick: () => {
323
+ const tagArea = gradioApp().querySelector(`#${easyPromptSelector.AREA_ID}`)
324
+ easyPromptSelector.changeVisibility(tagArea, easyPromptSelector.visible = !easyPromptSelector.visible)
325
+ }
326
+ })
327
+
328
+ const reloadButton = gradioApp().getElementById('easy_prompt_selector_reload_button')
329
+ reloadButton.addEventListener('click', async () => {
330
+ await easyPromptSelector.init()
331
+ })
332
+
333
+ const txt2imgActionColumn = gradioApp().getElementById('txt2img_actions_column')
334
+ const container = document.createElement('div')
335
+ container.classList.add('easy_prompt_selector_container')
336
+ container.appendChild(button)
337
+ container.appendChild(reloadButton)
338
+
339
+ txt2imgActionColumn.appendChild(container)
340
+
341
+ await easyPromptSelector.init()
342
+ })
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/javascript/js-yaml.min.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ /*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */
2
+ !function (e, t) { "object" == typeof exports && "undefined" != typeof module ? t(exports) : "function" == typeof define && define.amd ? define(["exports"], t) : t((e = "undefined" != typeof globalThis ? globalThis : e || self).jsyaml = {}) }(this, (function (e) { "use strict"; function t(e) { return null == e } var n = { isNothing: t, isObject: function (e) { return "object" == typeof e && null !== e }, toArray: function (e) { return Array.isArray(e) ? e : t(e) ? [] : [e] }, repeat: function (e, t) { var n, i = ""; for (n = 0; n < t; n += 1)i += e; return i }, isNegativeZero: function (e) { return 0 === e && Number.NEGATIVE_INFINITY === 1 / e }, extend: function (e, t) { var n, i, r, o; if (t) for (n = 0, i = (o = Object.keys(t)).length; n < i; n += 1)e[r = o[n]] = t[r]; return e } }; function i(e, t) { var n = "", i = e.reason || "(unknown reason)"; return e.mark ? (e.mark.name && (n += 'in "' + e.mark.name + '" '), n += "(" + (e.mark.line + 1) + ":" + (e.mark.column + 1) + ")", !t && e.mark.snippet && (n += "\n\n" + e.mark.snippet), i + " " + n) : i } function r(e, t) { Error.call(this), this.name = "YAMLException", this.reason = e, this.mark = t, this.message = i(this, !1), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = (new Error).stack || "" } r.prototype = Object.create(Error.prototype), r.prototype.constructor = r, r.prototype.toString = function (e) { return this.name + ": " + i(this, e) }; var o = r; function a(e, t, n, i, r) { var o = "", a = "", l = Math.floor(r / 2) - 1; return i - t > l && (t = i - l + (o = " ... ").length), n - i > l && (n = i + l - (a = " ...").length), { str: o + e.slice(t, n).replace(/\t/g, "→") + a, pos: i - t + o.length } } function l(e, t) { return n.repeat(" ", t - e.length) + e } var c = function (e, t) { if (t = Object.create(t || null), !e.buffer) return null; t.maxLength || (t.maxLength = 79), "number" != typeof t.indent && (t.indent = 1), "number" != typeof t.linesBefore && (t.linesBefore = 3), "number" != typeof t.linesAfter && (t.linesAfter = 2); for (var i, r = /\r?\n|\r|\0/g, o = [0], c = [], s = -1; i = r.exec(e.buffer);)c.push(i.index), o.push(i.index + i[0].length), e.position <= i.index && s < 0 && (s = o.length - 2); s < 0 && (s = o.length - 1); var u, p, f = "", d = Math.min(e.line + t.linesAfter, c.length).toString().length, h = t.maxLength - (t.indent + d + 3); for (u = 1; u <= t.linesBefore && !(s - u < 0); u++)p = a(e.buffer, o[s - u], c[s - u], e.position - (o[s] - o[s - u]), h), f = n.repeat(" ", t.indent) + l((e.line - u + 1).toString(), d) + " | " + p.str + "\n" + f; for (p = a(e.buffer, o[s], c[s], e.position, h), f += n.repeat(" ", t.indent) + l((e.line + 1).toString(), d) + " | " + p.str + "\n", f += n.repeat("-", t.indent + d + 3 + p.pos) + "^\n", u = 1; u <= t.linesAfter && !(s + u >= c.length); u++)p = a(e.buffer, o[s + u], c[s + u], e.position - (o[s] - o[s + u]), h), f += n.repeat(" ", t.indent) + l((e.line + u + 1).toString(), d) + " | " + p.str + "\n"; return f.replace(/\n$/, "") }, s = ["kind", "multi", "resolve", "construct", "instanceOf", "predicate", "represent", "representName", "defaultStyle", "styleAliases"], u = ["scalar", "sequence", "mapping"]; var p = function (e, t) { if (t = t || {}, Object.keys(t).forEach((function (t) { if (-1 === s.indexOf(t)) throw new o('Unknown option "' + t + '" is met in definition of "' + e + '" YAML type.') })), this.options = t, this.tag = e, this.kind = t.kind || null, this.resolve = t.resolve || function () { return !0 }, this.construct = t.construct || function (e) { return e }, this.instanceOf = t.instanceOf || null, this.predicate = t.predicate || null, this.represent = t.represent || null, this.representName = t.representName || null, this.defaultStyle = t.defaultStyle || null, this.multi = t.multi || !1, this.styleAliases = function (e) { var t = {}; return null !== e && Object.keys(e).forEach((function (n) { e[n].forEach((function (e) { t[String(e)] = n })) })), t }(t.styleAliases || null), -1 === u.indexOf(this.kind)) throw new o('Unknown kind "' + this.kind + '" is specified for "' + e + '" YAML type.') }; function f(e, t) { var n = []; return e[t].forEach((function (e) { var t = n.length; n.forEach((function (n, i) { n.tag === e.tag && n.kind === e.kind && n.multi === e.multi && (t = i) })), n[t] = e })), n } function d(e) { return this.extend(e) } d.prototype.extend = function (e) { var t = [], n = []; if (e instanceof p) n.push(e); else if (Array.isArray(e)) n = n.concat(e); else { if (!e || !Array.isArray(e.implicit) && !Array.isArray(e.explicit)) throw new o("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })"); e.implicit && (t = t.concat(e.implicit)), e.explicit && (n = n.concat(e.explicit)) } t.forEach((function (e) { if (!(e instanceof p)) throw new o("Specified list of YAML types (or a single Type object) contains a non-Type object."); if (e.loadKind && "scalar" !== e.loadKind) throw new o("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported."); if (e.multi) throw new o("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.") })), n.forEach((function (e) { if (!(e instanceof p)) throw new o("Specified list of YAML types (or a single Type object) contains a non-Type object.") })); var i = Object.create(d.prototype); return i.implicit = (this.implicit || []).concat(t), i.explicit = (this.explicit || []).concat(n), i.compiledImplicit = f(i, "implicit"), i.compiledExplicit = f(i, "explicit"), i.compiledTypeMap = function () { var e, t, n = { scalar: {}, sequence: {}, mapping: {}, fallback: {}, multi: { scalar: [], sequence: [], mapping: [], fallback: [] } }; function i(e) { e.multi ? (n.multi[e.kind].push(e), n.multi.fallback.push(e)) : n[e.kind][e.tag] = n.fallback[e.tag] = e } for (e = 0, t = arguments.length; e < t; e += 1)arguments[e].forEach(i); return n }(i.compiledImplicit, i.compiledExplicit), i }; var h = d, g = new p("tag:yaml.org,2002:str", { kind: "scalar", construct: function (e) { return null !== e ? e : "" } }), m = new p("tag:yaml.org,2002:seq", { kind: "sequence", construct: function (e) { return null !== e ? e : [] } }), y = new p("tag:yaml.org,2002:map", { kind: "mapping", construct: function (e) { return null !== e ? e : {} } }), b = new h({ explicit: [g, m, y] }); var A = new p("tag:yaml.org,2002:null", { kind: "scalar", resolve: function (e) { if (null === e) return !0; var t = e.length; return 1 === t && "~" === e || 4 === t && ("null" === e || "Null" === e || "NULL" === e) }, construct: function () { return null }, predicate: function (e) { return null === e }, represent: { canonical: function () { return "~" }, lowercase: function () { return "null" }, uppercase: function () { return "NULL" }, camelcase: function () { return "Null" }, empty: function () { return "" } }, defaultStyle: "lowercase" }); var v = new p("tag:yaml.org,2002:bool", { kind: "scalar", resolve: function (e) { if (null === e) return !1; var t = e.length; return 4 === t && ("true" === e || "True" === e || "TRUE" === e) || 5 === t && ("false" === e || "False" === e || "FALSE" === e) }, construct: function (e) { return "true" === e || "True" === e || "TRUE" === e }, predicate: function (e) { return "[object Boolean]" === Object.prototype.toString.call(e) }, represent: { lowercase: function (e) { return e ? "true" : "false" }, uppercase: function (e) { return e ? "TRUE" : "FALSE" }, camelcase: function (e) { return e ? "True" : "False" } }, defaultStyle: "lowercase" }); function w(e) { return 48 <= e && e <= 55 } function k(e) { return 48 <= e && e <= 57 } var C = new p("tag:yaml.org,2002:int", { kind: "scalar", resolve: function (e) { if (null === e) return !1; var t, n, i = e.length, r = 0, o = !1; if (!i) return !1; if ("-" !== (t = e[r]) && "+" !== t || (t = e[++r]), "0" === t) { if (r + 1 === i) return !0; if ("b" === (t = e[++r])) { for (r++; r < i; r++)if ("_" !== (t = e[r])) { if ("0" !== t && "1" !== t) return !1; o = !0 } return o && "_" !== t } if ("x" === t) { for (r++; r < i; r++)if ("_" !== (t = e[r])) { if (!(48 <= (n = e.charCodeAt(r)) && n <= 57 || 65 <= n && n <= 70 || 97 <= n && n <= 102)) return !1; o = !0 } return o && "_" !== t } if ("o" === t) { for (r++; r < i; r++)if ("_" !== (t = e[r])) { if (!w(e.charCodeAt(r))) return !1; o = !0 } return o && "_" !== t } } if ("_" === t) return !1; for (; r < i; r++)if ("_" !== (t = e[r])) { if (!k(e.charCodeAt(r))) return !1; o = !0 } return !(!o || "_" === t) }, construct: function (e) { var t, n = e, i = 1; if (-1 !== n.indexOf("_") && (n = n.replace(/_/g, "")), "-" !== (t = n[0]) && "+" !== t || ("-" === t && (i = -1), t = (n = n.slice(1))[0]), "0" === n) return 0; if ("0" === t) { if ("b" === n[1]) return i * parseInt(n.slice(2), 2); if ("x" === n[1]) return i * parseInt(n.slice(2), 16); if ("o" === n[1]) return i * parseInt(n.slice(2), 8) } return i * parseInt(n, 10) }, predicate: function (e) { return "[object Number]" === Object.prototype.toString.call(e) && e % 1 == 0 && !n.isNegativeZero(e) }, represent: { binary: function (e) { return e >= 0 ? "0b" + e.toString(2) : "-0b" + e.toString(2).slice(1) }, octal: function (e) { return e >= 0 ? "0o" + e.toString(8) : "-0o" + e.toString(8).slice(1) }, decimal: function (e) { return e.toString(10) }, hexadecimal: function (e) { return e >= 0 ? "0x" + e.toString(16).toUpperCase() : "-0x" + e.toString(16).toUpperCase().slice(1) } }, defaultStyle: "decimal", styleAliases: { binary: [2, "bin"], octal: [8, "oct"], decimal: [10, "dec"], hexadecimal: [16, "hex"] } }), x = new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"); var I = /^[-+]?[0-9]+e/; var S = new p("tag:yaml.org,2002:float", { kind: "scalar", resolve: function (e) { return null !== e && !(!x.test(e) || "_" === e[e.length - 1]) }, construct: function (e) { var t, n; return n = "-" === (t = e.replace(/_/g, "").toLowerCase())[0] ? -1 : 1, "+-".indexOf(t[0]) >= 0 && (t = t.slice(1)), ".inf" === t ? 1 === n ? Number.POSITIVE_INFINITY : Number.NEGATIVE_INFINITY : ".nan" === t ? NaN : n * parseFloat(t, 10) }, predicate: function (e) { return "[object Number]" === Object.prototype.toString.call(e) && (e % 1 != 0 || n.isNegativeZero(e)) }, represent: function (e, t) { var i; if (isNaN(e)) switch (t) { case "lowercase": return ".nan"; case "uppercase": return ".NAN"; case "camelcase": return ".NaN" } else if (Number.POSITIVE_INFINITY === e) switch (t) { case "lowercase": return ".inf"; case "uppercase": return ".INF"; case "camelcase": return ".Inf" } else if (Number.NEGATIVE_INFINITY === e) switch (t) { case "lowercase": return "-.inf"; case "uppercase": return "-.INF"; case "camelcase": return "-.Inf" } else if (n.isNegativeZero(e)) return "-0.0"; return i = e.toString(10), I.test(i) ? i.replace("e", ".e") : i }, defaultStyle: "lowercase" }), O = b.extend({ implicit: [A, v, C, S] }), j = O, T = new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"), N = new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$"); var F = new p("tag:yaml.org,2002:timestamp", { kind: "scalar", resolve: function (e) { return null !== e && (null !== T.exec(e) || null !== N.exec(e)) }, construct: function (e) { var t, n, i, r, o, a, l, c, s = 0, u = null; if (null === (t = T.exec(e)) && (t = N.exec(e)), null === t) throw new Error("Date resolve error"); if (n = +t[1], i = +t[2] - 1, r = +t[3], !t[4]) return new Date(Date.UTC(n, i, r)); if (o = +t[4], a = +t[5], l = +t[6], t[7]) { for (s = t[7].slice(0, 3); s.length < 3;)s += "0"; s = +s } return t[9] && (u = 6e4 * (60 * +t[10] + +(t[11] || 0)), "-" === t[9] && (u = -u)), c = new Date(Date.UTC(n, i, r, o, a, l, s)), u && c.setTime(c.getTime() - u), c }, instanceOf: Date, represent: function (e) { return e.toISOString() } }); var E = new p("tag:yaml.org,2002:merge", { kind: "scalar", resolve: function (e) { return "<<" === e || null === e } }), M = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r"; var L = new p("tag:yaml.org,2002:binary", { kind: "scalar", resolve: function (e) { if (null === e) return !1; var t, n, i = 0, r = e.length, o = M; for (n = 0; n < r; n++)if (!((t = o.indexOf(e.charAt(n))) > 64)) { if (t < 0) return !1; i += 6 } return i % 8 == 0 }, construct: function (e) { var t, n, i = e.replace(/[\r\n=]/g, ""), r = i.length, o = M, a = 0, l = []; for (t = 0; t < r; t++)t % 4 == 0 && t && (l.push(a >> 16 & 255), l.push(a >> 8 & 255), l.push(255 & a)), a = a << 6 | o.indexOf(i.charAt(t)); return 0 === (n = r % 4 * 6) ? (l.push(a >> 16 & 255), l.push(a >> 8 & 255), l.push(255 & a)) : 18 === n ? (l.push(a >> 10 & 255), l.push(a >> 2 & 255)) : 12 === n && l.push(a >> 4 & 255), new Uint8Array(l) }, predicate: function (e) { return "[object Uint8Array]" === Object.prototype.toString.call(e) }, represent: function (e) { var t, n, i = "", r = 0, o = e.length, a = M; for (t = 0; t < o; t++)t % 3 == 0 && t && (i += a[r >> 18 & 63], i += a[r >> 12 & 63], i += a[r >> 6 & 63], i += a[63 & r]), r = (r << 8) + e[t]; return 0 === (n = o % 3) ? (i += a[r >> 18 & 63], i += a[r >> 12 & 63], i += a[r >> 6 & 63], i += a[63 & r]) : 2 === n ? (i += a[r >> 10 & 63], i += a[r >> 4 & 63], i += a[r << 2 & 63], i += a[64]) : 1 === n && (i += a[r >> 2 & 63], i += a[r << 4 & 63], i += a[64], i += a[64]), i } }), _ = Object.prototype.hasOwnProperty, D = Object.prototype.toString; var U = new p("tag:yaml.org,2002:omap", { kind: "sequence", resolve: function (e) { if (null === e) return !0; var t, n, i, r, o, a = [], l = e; for (t = 0, n = l.length; t < n; t += 1) { if (i = l[t], o = !1, "[object Object]" !== D.call(i)) return !1; for (r in i) if (_.call(i, r)) { if (o) return !1; o = !0 } if (!o) return !1; if (-1 !== a.indexOf(r)) return !1; a.push(r) } return !0 }, construct: function (e) { return null !== e ? e : [] } }), q = Object.prototype.toString; var Y = new p("tag:yaml.org,2002:pairs", { kind: "sequence", resolve: function (e) { if (null === e) return !0; var t, n, i, r, o, a = e; for (o = new Array(a.length), t = 0, n = a.length; t < n; t += 1) { if (i = a[t], "[object Object]" !== q.call(i)) return !1; if (1 !== (r = Object.keys(i)).length) return !1; o[t] = [r[0], i[r[0]]] } return !0 }, construct: function (e) { if (null === e) return []; var t, n, i, r, o, a = e; for (o = new Array(a.length), t = 0, n = a.length; t < n; t += 1)i = a[t], r = Object.keys(i), o[t] = [r[0], i[r[0]]]; return o } }), R = Object.prototype.hasOwnProperty; var B = new p("tag:yaml.org,2002:set", { kind: "mapping", resolve: function (e) { if (null === e) return !0; var t, n = e; for (t in n) if (R.call(n, t) && null !== n[t]) return !1; return !0 }, construct: function (e) { return null !== e ? e : {} } }), K = j.extend({ implicit: [F, E], explicit: [L, U, Y, B] }), P = Object.prototype.hasOwnProperty, W = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, H = /[\x85\u2028\u2029]/, $ = /[,\[\]\{\}]/, G = /^(?:!|!!|![a-z\-]+!)$/i, V = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i; function Z(e) { return Object.prototype.toString.call(e) } function J(e) { return 10 === e || 13 === e } function Q(e) { return 9 === e || 32 === e } function z(e) { return 9 === e || 32 === e || 10 === e || 13 === e } function X(e) { return 44 === e || 91 === e || 93 === e || 123 === e || 125 === e } function ee(e) { var t; return 48 <= e && e <= 57 ? e - 48 : 97 <= (t = 32 | e) && t <= 102 ? t - 97 + 10 : -1 } function te(e) { return 48 === e ? "\0" : 97 === e ? "" : 98 === e ? "\b" : 116 === e || 9 === e ? "\t" : 110 === e ? "\n" : 118 === e ? "\v" : 102 === e ? "\f" : 114 === e ? "\r" : 101 === e ? "" : 32 === e ? " " : 34 === e ? '"' : 47 === e ? "/" : 92 === e ? "\\" : 78 === e ? "…" : 95 === e ? " " : 76 === e ? "\u2028" : 80 === e ? "\u2029" : "" } function ne(e) { return e <= 65535 ? String.fromCharCode(e) : String.fromCharCode(55296 + (e - 65536 >> 10), 56320 + (e - 65536 & 1023)) } for (var ie = new Array(256), re = new Array(256), oe = 0; oe < 256; oe++)ie[oe] = te(oe) ? 1 : 0, re[oe] = te(oe); function ae(e, t) { this.input = e, this.filename = t.filename || null, this.schema = t.schema || K, this.onWarning = t.onWarning || null, this.legacy = t.legacy || !1, this.json = t.json || !1, this.listener = t.listener || null, this.implicitTypes = this.schema.compiledImplicit, this.typeMap = this.schema.compiledTypeMap, this.length = e.length, this.position = 0, this.line = 0, this.lineStart = 0, this.lineIndent = 0, this.firstTabInLine = -1, this.documents = [] } function le(e, t) { var n = { name: e.filename, buffer: e.input.slice(0, -1), position: e.position, line: e.line, column: e.position - e.lineStart }; return n.snippet = c(n), new o(t, n) } function ce(e, t) { throw le(e, t) } function se(e, t) { e.onWarning && e.onWarning.call(null, le(e, t)) } var ue = { YAML: function (e, t, n) { var i, r, o; null !== e.version && ce(e, "duplication of %YAML directive"), 1 !== n.length && ce(e, "YAML directive accepts exactly one argument"), null === (i = /^([0-9]+)\.([0-9]+)$/.exec(n[0])) && ce(e, "ill-formed argument of the YAML directive"), r = parseInt(i[1], 10), o = parseInt(i[2], 10), 1 !== r && ce(e, "unacceptable YAML version of the document"), e.version = n[0], e.checkLineBreaks = o < 2, 1 !== o && 2 !== o && se(e, "unsupported YAML version of the document") }, TAG: function (e, t, n) { var i, r; 2 !== n.length && ce(e, "TAG directive accepts exactly two arguments"), i = n[0], r = n[1], G.test(i) || ce(e, "ill-formed tag handle (first argument) of the TAG directive"), P.call(e.tagMap, i) && ce(e, 'there is a previously declared suffix for "' + i + '" tag handle'), V.test(r) || ce(e, "ill-formed tag prefix (second argument) of the TAG directive"); try { r = decodeURIComponent(r) } catch (t) { ce(e, "tag prefix is malformed: " + r) } e.tagMap[i] = r } }; function pe(e, t, n, i) { var r, o, a, l; if (t < n) { if (l = e.input.slice(t, n), i) for (r = 0, o = l.length; r < o; r += 1)9 === (a = l.charCodeAt(r)) || 32 <= a && a <= 1114111 || ce(e, "expected valid JSON character"); else W.test(l) && ce(e, "the stream contains non-printable characters"); e.result += l } } function fe(e, t, i, r) { var o, a, l, c; for (n.isObject(i) || ce(e, "cannot merge mappings; the provided source object is unacceptable"), l = 0, c = (o = Object.keys(i)).length; l < c; l += 1)a = o[l], P.call(t, a) || (t[a] = i[a], r[a] = !0) } function de(e, t, n, i, r, o, a, l, c) { var s, u; if (Array.isArray(r)) for (s = 0, u = (r = Array.prototype.slice.call(r)).length; s < u; s += 1)Array.isArray(r[s]) && ce(e, "nested arrays are not supported inside keys"), "object" == typeof r && "[object Object]" === Z(r[s]) && (r[s] = "[object Object]"); if ("object" == typeof r && "[object Object]" === Z(r) && (r = "[object Object]"), r = String(r), null === t && (t = {}), "tag:yaml.org,2002:merge" === i) if (Array.isArray(o)) for (s = 0, u = o.length; s < u; s += 1)fe(e, t, o[s], n); else fe(e, t, o, n); else e.json || P.call(n, r) || !P.call(t, r) || (e.line = a || e.line, e.lineStart = l || e.lineStart, e.position = c || e.position, ce(e, "duplicated mapping key")), "__proto__" === r ? Object.defineProperty(t, r, { configurable: !0, enumerable: !0, writable: !0, value: o }) : t[r] = o, delete n[r]; return t } function he(e) { var t; 10 === (t = e.input.charCodeAt(e.position)) ? e.position++ : 13 === t ? (e.position++, 10 === e.input.charCodeAt(e.position) && e.position++) : ce(e, "a line break is expected"), e.line += 1, e.lineStart = e.position, e.firstTabInLine = -1 } function ge(e, t, n) { for (var i = 0, r = e.input.charCodeAt(e.position); 0 !== r;) { for (; Q(r);)9 === r && -1 === e.firstTabInLine && (e.firstTabInLine = e.position), r = e.input.charCodeAt(++e.position); if (t && 35 === r) do { r = e.input.charCodeAt(++e.position) } while (10 !== r && 13 !== r && 0 !== r); if (!J(r)) break; for (he(e), r = e.input.charCodeAt(e.position), i++, e.lineIndent = 0; 32 === r;)e.lineIndent++, r = e.input.charCodeAt(++e.position) } return -1 !== n && 0 !== i && e.lineIndent < n && se(e, "deficient indentation"), i } function me(e) { var t, n = e.position; return !(45 !== (t = e.input.charCodeAt(n)) && 46 !== t || t !== e.input.charCodeAt(n + 1) || t !== e.input.charCodeAt(n + 2) || (n += 3, 0 !== (t = e.input.charCodeAt(n)) && !z(t))) } function ye(e, t) { 1 === t ? e.result += " " : t > 1 && (e.result += n.repeat("\n", t - 1)) } function be(e, t) { var n, i, r = e.tag, o = e.anchor, a = [], l = !1; if (-1 !== e.firstTabInLine) return !1; for (null !== e.anchor && (e.anchorMap[e.anchor] = a), i = e.input.charCodeAt(e.position); 0 !== i && (-1 !== e.firstTabInLine && (e.position = e.firstTabInLine, ce(e, "tab characters must not be used in indentation")), 45 === i) && z(e.input.charCodeAt(e.position + 1));)if (l = !0, e.position++, ge(e, !0, -1) && e.lineIndent <= t) a.push(null), i = e.input.charCodeAt(e.position); else if (n = e.line, we(e, t, 3, !1, !0), a.push(e.result), ge(e, !0, -1), i = e.input.charCodeAt(e.position), (e.line === n || e.lineIndent > t) && 0 !== i) ce(e, "bad indentation of a sequence entry"); else if (e.lineIndent < t) break; return !!l && (e.tag = r, e.anchor = o, e.kind = "sequence", e.result = a, !0) } function Ae(e) { var t, n, i, r, o = !1, a = !1; if (33 !== (r = e.input.charCodeAt(e.position))) return !1; if (null !== e.tag && ce(e, "duplication of a tag property"), 60 === (r = e.input.charCodeAt(++e.position)) ? (o = !0, r = e.input.charCodeAt(++e.position)) : 33 === r ? (a = !0, n = "!!", r = e.input.charCodeAt(++e.position)) : n = "!", t = e.position, o) { do { r = e.input.charCodeAt(++e.position) } while (0 !== r && 62 !== r); e.position < e.length ? (i = e.input.slice(t, e.position), r = e.input.charCodeAt(++e.position)) : ce(e, "unexpected end of the stream within a verbatim tag") } else { for (; 0 !== r && !z(r);)33 === r && (a ? ce(e, "tag suffix cannot contain exclamation marks") : (n = e.input.slice(t - 1, e.position + 1), G.test(n) || ce(e, "named tag handle cannot contain such characters"), a = !0, t = e.position + 1)), r = e.input.charCodeAt(++e.position); i = e.input.slice(t, e.position), $.test(i) && ce(e, "tag suffix cannot contain flow indicator characters") } i && !V.test(i) && ce(e, "tag name cannot contain such characters: " + i); try { i = decodeURIComponent(i) } catch (t) { ce(e, "tag name is malformed: " + i) } return o ? e.tag = i : P.call(e.tagMap, n) ? e.tag = e.tagMap[n] + i : "!" === n ? e.tag = "!" + i : "!!" === n ? e.tag = "tag:yaml.org,2002:" + i : ce(e, 'undeclared tag handle "' + n + '"'), !0 } function ve(e) { var t, n; if (38 !== (n = e.input.charCodeAt(e.position))) return !1; for (null !== e.anchor && ce(e, "duplication of an anchor property"), n = e.input.charCodeAt(++e.position), t = e.position; 0 !== n && !z(n) && !X(n);)n = e.input.charCodeAt(++e.position); return e.position === t && ce(e, "name of an anchor node must contain at least one character"), e.anchor = e.input.slice(t, e.position), !0 } function we(e, t, i, r, o) { var a, l, c, s, u, p, f, d, h, g = 1, m = !1, y = !1; if (null !== e.listener && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, a = l = c = 4 === i || 3 === i, r && ge(e, !0, -1) && (m = !0, e.lineIndent > t ? g = 1 : e.lineIndent === t ? g = 0 : e.lineIndent < t && (g = -1)), 1 === g) for (; Ae(e) || ve(e);)ge(e, !0, -1) ? (m = !0, c = a, e.lineIndent > t ? g = 1 : e.lineIndent === t ? g = 0 : e.lineIndent < t && (g = -1)) : c = !1; if (c && (c = m || o), 1 !== g && 4 !== i || (d = 1 === i || 2 === i ? t : t + 1, h = e.position - e.lineStart, 1 === g ? c && (be(e, h) || function (e, t, n) { var i, r, o, a, l, c, s, u = e.tag, p = e.anchor, f = {}, d = Object.create(null), h = null, g = null, m = null, y = !1, b = !1; if (-1 !== e.firstTabInLine) return !1; for (null !== e.anchor && (e.anchorMap[e.anchor] = f), s = e.input.charCodeAt(e.position); 0 !== s;) { if (y || -1 === e.firstTabInLine || (e.position = e.firstTabInLine, ce(e, "tab characters must not be used in indentation")), i = e.input.charCodeAt(e.position + 1), o = e.line, 63 !== s && 58 !== s || !z(i)) { if (a = e.line, l = e.lineStart, c = e.position, !we(e, n, 2, !1, !0)) break; if (e.line === o) { for (s = e.input.charCodeAt(e.position); Q(s);)s = e.input.charCodeAt(++e.position); if (58 === s) z(s = e.input.charCodeAt(++e.position)) || ce(e, "a whitespace character is expected after the key-value separator within a block mapping"), y && (de(e, f, d, h, g, null, a, l, c), h = g = m = null), b = !0, y = !1, r = !1, h = e.tag, g = e.result; else { if (!b) return e.tag = u, e.anchor = p, !0; ce(e, "can not read an implicit mapping pair; a colon is missed") } } else { if (!b) return e.tag = u, e.anchor = p, !0; ce(e, "can not read a block mapping entry; a multiline key may not be an implicit key") } } else 63 === s ? (y && (de(e, f, d, h, g, null, a, l, c), h = g = m = null), b = !0, y = !0, r = !0) : y ? (y = !1, r = !0) : ce(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, s = i; if ((e.line === o || e.lineIndent > t) && (y && (a = e.line, l = e.lineStart, c = e.position), we(e, t, 4, !0, r) && (y ? g = e.result : m = e.result), y || (de(e, f, d, h, g, m, a, l, c), h = g = m = null), ge(e, !0, -1), s = e.input.charCodeAt(e.position)), (e.line === o || e.lineIndent > t) && 0 !== s) ce(e, "bad indentation of a mapping entry"); else if (e.lineIndent < t) break } return y && de(e, f, d, h, g, null, a, l, c), b && (e.tag = u, e.anchor = p, e.kind = "mapping", e.result = f), b }(e, h, d)) || function (e, t) { var n, i, r, o, a, l, c, s, u, p, f, d, h = !0, g = e.tag, m = e.anchor, y = Object.create(null); if (91 === (d = e.input.charCodeAt(e.position))) a = 93, s = !1, o = []; else { if (123 !== d) return !1; a = 125, s = !0, o = {} } for (null !== e.anchor && (e.anchorMap[e.anchor] = o), d = e.input.charCodeAt(++e.position); 0 !== d;) { if (ge(e, !0, t), (d = e.input.charCodeAt(e.position)) === a) return e.position++, e.tag = g, e.anchor = m, e.kind = s ? "mapping" : "sequence", e.result = o, !0; h ? 44 === d && ce(e, "expected the node content, but found ','") : ce(e, "missed comma between flow collection entries"), f = null, l = c = !1, 63 === d && z(e.input.charCodeAt(e.position + 1)) && (l = c = !0, e.position++, ge(e, !0, t)), n = e.line, i = e.lineStart, r = e.position, we(e, t, 1, !1, !0), p = e.tag, u = e.result, ge(e, !0, t), d = e.input.charCodeAt(e.position), !c && e.line !== n || 58 !== d || (l = !0, d = e.input.charCodeAt(++e.position), ge(e, !0, t), we(e, t, 1, !1, !0), f = e.result), s ? de(e, o, y, p, u, f, n, i, r) : l ? o.push(de(e, null, y, p, u, f, n, i, r)) : o.push(u), ge(e, !0, t), 44 === (d = e.input.charCodeAt(e.position)) ? (h = !0, d = e.input.charCodeAt(++e.position)) : h = !1 } ce(e, "unexpected end of the stream within a flow collection") }(e, d) ? y = !0 : (l && function (e, t) { var i, r, o, a, l, c = 1, s = !1, u = !1, p = t, f = 0, d = !1; if (124 === (a = e.input.charCodeAt(e.position))) r = !1; else { if (62 !== a) return !1; r = !0 } for (e.kind = "scalar", e.result = ""; 0 !== a;)if (43 === (a = e.input.charCodeAt(++e.position)) || 45 === a) 1 === c ? c = 43 === a ? 3 : 2 : ce(e, "repeat of a chomping mode identifier"); else { if (!((o = 48 <= (l = a) && l <= 57 ? l - 48 : -1) >= 0)) break; 0 === o ? ce(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : u ? ce(e, "repeat of an indentation width identifier") : (p = t + o - 1, u = !0) } if (Q(a)) { do { a = e.input.charCodeAt(++e.position) } while (Q(a)); if (35 === a) do { a = e.input.charCodeAt(++e.position) } while (!J(a) && 0 !== a) } for (; 0 !== a;) { for (he(e), e.lineIndent = 0, a = e.input.charCodeAt(e.position); (!u || e.lineIndent < p) && 32 === a;)e.lineIndent++, a = e.input.charCodeAt(++e.position); if (!u && e.lineIndent > p && (p = e.lineIndent), J(a)) f++; else { if (e.lineIndent < p) { 3 === c ? e.result += n.repeat("\n", s ? 1 + f : f) : 1 === c && s && (e.result += "\n"); break } for (r ? Q(a) ? (d = !0, e.result += n.repeat("\n", s ? 1 + f : f)) : d ? (d = !1, e.result += n.repeat("\n", f + 1)) : 0 === f ? s && (e.result += " ") : e.result += n.repeat("\n", f) : e.result += n.repeat("\n", s ? 1 + f : f), s = !0, u = !0, f = 0, i = e.position; !J(a) && 0 !== a;)a = e.input.charCodeAt(++e.position); pe(e, i, e.position, !1) } } return !0 }(e, d) || function (e, t) { var n, i, r; if (39 !== (n = e.input.charCodeAt(e.position))) return !1; for (e.kind = "scalar", e.result = "", e.position++, i = r = e.position; 0 !== (n = e.input.charCodeAt(e.position));)if (39 === n) { if (pe(e, i, e.position, !0), 39 !== (n = e.input.charCodeAt(++e.position))) return !0; i = e.position, e.position++, r = e.position } else J(n) ? (pe(e, i, r, !0), ye(e, ge(e, !1, t)), i = r = e.position) : e.position === e.lineStart && me(e) ? ce(e, "unexpected end of the document within a single quoted scalar") : (e.position++, r = e.position); ce(e, "unexpected end of the stream within a single quoted scalar") }(e, d) || function (e, t) { var n, i, r, o, a, l, c; if (34 !== (l = e.input.charCodeAt(e.position))) return !1; for (e.kind = "scalar", e.result = "", e.position++, n = i = e.position; 0 !== (l = e.input.charCodeAt(e.position));) { if (34 === l) return pe(e, n, e.position, !0), e.position++, !0; if (92 === l) { if (pe(e, n, e.position, !0), J(l = e.input.charCodeAt(++e.position))) ge(e, !1, t); else if (l < 256 && ie[l]) e.result += re[l], e.position++; else if ((a = 120 === (c = l) ? 2 : 117 === c ? 4 : 85 === c ? 8 : 0) > 0) { for (r = a, o = 0; r > 0; r--)(a = ee(l = e.input.charCodeAt(++e.position))) >= 0 ? o = (o << 4) + a : ce(e, "expected hexadecimal character"); e.result += ne(o), e.position++ } else ce(e, "unknown escape sequence"); n = i = e.position } else J(l) ? (pe(e, n, i, !0), ye(e, ge(e, !1, t)), n = i = e.position) : e.position === e.lineStart && me(e) ? ce(e, "unexpected end of the document within a double quoted scalar") : (e.position++, i = e.position) } ce(e, "unexpected end of the stream within a double quoted scalar") }(e, d) ? y = !0 : !function (e) { var t, n, i; if (42 !== (i = e.input.charCodeAt(e.position))) return !1; for (i = e.input.charCodeAt(++e.position), t = e.position; 0 !== i && !z(i) && !X(i);)i = e.input.charCodeAt(++e.position); return e.position === t && ce(e, "name of an alias node must contain at least one character"), n = e.input.slice(t, e.position), P.call(e.anchorMap, n) || ce(e, 'unidentified alias "' + n + '"'), e.result = e.anchorMap[n], ge(e, !0, -1), !0 }(e) ? function (e, t, n) { var i, r, o, a, l, c, s, u, p = e.kind, f = e.result; if (z(u = e.input.charCodeAt(e.position)) || X(u) || 35 === u || 38 === u || 42 === u || 33 === u || 124 === u || 62 === u || 39 === u || 34 === u || 37 === u || 64 === u || 96 === u) return !1; if ((63 === u || 45 === u) && (z(i = e.input.charCodeAt(e.position + 1)) || n && X(i))) return !1; for (e.kind = "scalar", e.result = "", r = o = e.position, a = !1; 0 !== u;) { if (58 === u) { if (z(i = e.input.charCodeAt(e.position + 1)) || n && X(i)) break } else if (35 === u) { if (z(e.input.charCodeAt(e.position - 1))) break } else { if (e.position === e.lineStart && me(e) || n && X(u)) break; if (J(u)) { if (l = e.line, c = e.lineStart, s = e.lineIndent, ge(e, !1, -1), e.lineIndent >= t) { a = !0, u = e.input.charCodeAt(e.position); continue } e.position = o, e.line = l, e.lineStart = c, e.lineIndent = s; break } } a && (pe(e, r, o, !1), ye(e, e.line - l), r = o = e.position, a = !1), Q(u) || (o = e.position + 1), u = e.input.charCodeAt(++e.position) } return pe(e, r, o, !1), !!e.result || (e.kind = p, e.result = f, !1) }(e, d, 1 === i) && (y = !0, null === e.tag && (e.tag = "?")) : (y = !0, null === e.tag && null === e.anchor || ce(e, "alias node should not have any properties")), null !== e.anchor && (e.anchorMap[e.anchor] = e.result)) : 0 === g && (y = c && be(e, h))), null === e.tag) null !== e.anchor && (e.anchorMap[e.anchor] = e.result); else if ("?" === e.tag) { for (null !== e.result && "scalar" !== e.kind && ce(e, 'unacceptable node kind for !<?> tag; it should be "scalar", not "' + e.kind + '"'), s = 0, u = e.implicitTypes.length; s < u; s += 1)if ((f = e.implicitTypes[s]).resolve(e.result)) { e.result = f.construct(e.result), e.tag = f.tag, null !== e.anchor && (e.anchorMap[e.anchor] = e.result); break } } else if ("!" !== e.tag) { if (P.call(e.typeMap[e.kind || "fallback"], e.tag)) f = e.typeMap[e.kind || "fallback"][e.tag]; else for (f = null, s = 0, u = (p = e.typeMap.multi[e.kind || "fallback"]).length; s < u; s += 1)if (e.tag.slice(0, p[s].tag.length) === p[s].tag) { f = p[s]; break } f || ce(e, "unknown tag !<" + e.tag + ">"), null !== e.result && f.kind !== e.kind && ce(e, "unacceptable node kind for !<" + e.tag + '> tag; it should be "' + f.kind + '", not "' + e.kind + '"'), f.resolve(e.result, e.tag) ? (e.result = f.construct(e.result, e.tag), null !== e.anchor && (e.anchorMap[e.anchor] = e.result)) : ce(e, "cannot resolve a node with !<" + e.tag + "> explicit tag") } return null !== e.listener && e.listener("close", e), null !== e.tag || null !== e.anchor || y } function ke(e) { var t, n, i, r, o = e.position, a = !1; for (e.version = null, e.checkLineBreaks = e.legacy, e.tagMap = Object.create(null), e.anchorMap = Object.create(null); 0 !== (r = e.input.charCodeAt(e.position)) && (ge(e, !0, -1), r = e.input.charCodeAt(e.position), !(e.lineIndent > 0 || 37 !== r));) { for (a = !0, r = e.input.charCodeAt(++e.position), t = e.position; 0 !== r && !z(r);)r = e.input.charCodeAt(++e.position); for (i = [], (n = e.input.slice(t, e.position)).length < 1 && ce(e, "directive name must not be less than one character in length"); 0 !== r;) { for (; Q(r);)r = e.input.charCodeAt(++e.position); if (35 === r) { do { r = e.input.charCodeAt(++e.position) } while (0 !== r && !J(r)); break } if (J(r)) break; for (t = e.position; 0 !== r && !z(r);)r = e.input.charCodeAt(++e.position); i.push(e.input.slice(t, e.position)) } 0 !== r && he(e), P.call(ue, n) ? ue[n](e, n, i) : se(e, 'unknown document directive "' + n + '"') } ge(e, !0, -1), 0 === e.lineIndent && 45 === e.input.charCodeAt(e.position) && 45 === e.input.charCodeAt(e.position + 1) && 45 === e.input.charCodeAt(e.position + 2) ? (e.position += 3, ge(e, !0, -1)) : a && ce(e, "directives end mark is expected"), we(e, e.lineIndent - 1, 4, !1, !0), ge(e, !0, -1), e.checkLineBreaks && H.test(e.input.slice(o, e.position)) && se(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && me(e) ? 46 === e.input.charCodeAt(e.position) && (e.position += 3, ge(e, !0, -1)) : e.position < e.length - 1 && ce(e, "end of the stream or a document separator is expected") } function Ce(e, t) { t = t || {}, 0 !== (e = String(e)).length && (10 !== e.charCodeAt(e.length - 1) && 13 !== e.charCodeAt(e.length - 1) && (e += "\n"), 65279 === e.charCodeAt(0) && (e = e.slice(1))); var n = new ae(e, t), i = e.indexOf("\0"); for (-1 !== i && (n.position = i, ce(n, "null byte is not allowed in input")), n.input += "\0"; 32 === n.input.charCodeAt(n.position);)n.lineIndent += 1, n.position += 1; for (; n.position < n.length - 1;)ke(n); return n.documents } var xe = { loadAll: function (e, t, n) { null !== t && "object" == typeof t && void 0 === n && (n = t, t = null); var i = Ce(e, n); if ("function" != typeof t) return i; for (var r = 0, o = i.length; r < o; r += 1)t(i[r]) }, load: function (e, t) { var n = Ce(e, t); if (0 !== n.length) { if (1 === n.length) return n[0]; throw new o("expected a single document in the stream, but found more") } } }, Ie = Object.prototype.toString, Se = Object.prototype.hasOwnProperty, Oe = 65279, je = { 0: "\\0", 7: "\\a", 8: "\\b", 9: "\\t", 10: "\\n", 11: "\\v", 12: "\\f", 13: "\\r", 27: "\\e", 34: '\\"', 92: "\\\\", 133: "\\N", 160: "\\_", 8232: "\\L", 8233: "\\P" }, Te = ["y", "Y", "yes", "Yes", "YES", "on", "On", "ON", "n", "N", "no", "No", "NO", "off", "Off", "OFF"], Ne = /^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/; function Fe(e) { var t, i, r; if (t = e.toString(16).toUpperCase(), e <= 255) i = "x", r = 2; else if (e <= 65535) i = "u", r = 4; else { if (!(e <= 4294967295)) throw new o("code point within a string may not be greater than 0xFFFFFFFF"); i = "U", r = 8 } return "\\" + i + n.repeat("0", r - t.length) + t } function Ee(e) { this.schema = e.schema || K, this.indent = Math.max(1, e.indent || 2), this.noArrayIndent = e.noArrayIndent || !1, this.skipInvalid = e.skipInvalid || !1, this.flowLevel = n.isNothing(e.flowLevel) ? -1 : e.flowLevel, this.styleMap = function (e, t) { var n, i, r, o, a, l, c; if (null === t) return {}; for (n = {}, r = 0, o = (i = Object.keys(t)).length; r < o; r += 1)a = i[r], l = String(t[a]), "!!" === a.slice(0, 2) && (a = "tag:yaml.org,2002:" + a.slice(2)), (c = e.compiledTypeMap.fallback[a]) && Se.call(c.styleAliases, l) && (l = c.styleAliases[l]), n[a] = l; return n }(this.schema, e.styles || null), this.sortKeys = e.sortKeys || !1, this.lineWidth = e.lineWidth || 80, this.noRefs = e.noRefs || !1, this.noCompatMode = e.noCompatMode || !1, this.condenseFlow = e.condenseFlow || !1, this.quotingType = '"' === e.quotingType ? 2 : 1, this.forceQuotes = e.forceQuotes || !1, this.replacer = "function" == typeof e.replacer ? e.replacer : null, this.implicitTypes = this.schema.compiledImplicit, this.explicitTypes = this.schema.compiledExplicit, this.tag = null, this.result = "", this.duplicates = [], this.usedDuplicates = null } function Me(e, t) { for (var i, r = n.repeat(" ", t), o = 0, a = -1, l = "", c = e.length; o < c;)-1 === (a = e.indexOf("\n", o)) ? (i = e.slice(o), o = c) : (i = e.slice(o, a + 1), o = a + 1), i.length && "\n" !== i && (l += r), l += i; return l } function Le(e, t) { return "\n" + n.repeat(" ", e.indent * t) } function _e(e) { return 32 === e || 9 === e } function De(e) { return 32 <= e && e <= 126 || 161 <= e && e <= 55295 && 8232 !== e && 8233 !== e || 57344 <= e && e <= 65533 && e !== Oe || 65536 <= e && e <= 1114111 } function Ue(e) { return De(e) && e !== Oe && 13 !== e && 10 !== e } function qe(e, t, n) { var i = Ue(e), r = i && !_e(e); return (n ? i : i && 44 !== e && 91 !== e && 93 !== e && 123 !== e && 125 !== e) && 35 !== e && !(58 === t && !r) || Ue(t) && !_e(t) && 35 === e || 58 === t && r } function Ye(e, t) { var n, i = e.charCodeAt(t); return i >= 55296 && i <= 56319 && t + 1 < e.length && (n = e.charCodeAt(t + 1)) >= 56320 && n <= 57343 ? 1024 * (i - 55296) + n - 56320 + 65536 : i } function Re(e) { return /^\n* /.test(e) } function Be(e, t, n, i, r, o, a, l) { var c, s, u = 0, p = null, f = !1, d = !1, h = -1 !== i, g = -1, m = De(s = Ye(e, 0)) && s !== Oe && !_e(s) && 45 !== s && 63 !== s && 58 !== s && 44 !== s && 91 !== s && 93 !== s && 123 !== s && 125 !== s && 35 !== s && 38 !== s && 42 !== s && 33 !== s && 124 !== s && 61 !== s && 62 !== s && 39 !== s && 34 !== s && 37 !== s && 64 !== s && 96 !== s && function (e) { return !_e(e) && 58 !== e }(Ye(e, e.length - 1)); if (t || a) for (c = 0; c < e.length; u >= 65536 ? c += 2 : c++) { if (!De(u = Ye(e, c))) return 5; m = m && qe(u, p, l), p = u } else { for (c = 0; c < e.length; u >= 65536 ? c += 2 : c++) { if (10 === (u = Ye(e, c))) f = !0, h && (d = d || c - g - 1 > i && " " !== e[g + 1], g = c); else if (!De(u)) return 5; m = m && qe(u, p, l), p = u } d = d || h && c - g - 1 > i && " " !== e[g + 1] } return f || d ? n > 9 && Re(e) ? 5 : a ? 2 === o ? 5 : 2 : d ? 4 : 3 : !m || a || r(e) ? 2 === o ? 5 : 2 : 1 } function Ke(e, t, n, i, r) { e.dump = function () { if (0 === t.length) return 2 === e.quotingType ? '""' : "''"; if (!e.noCompatMode && (-1 !== Te.indexOf(t) || Ne.test(t))) return 2 === e.quotingType ? '"' + t + '"' : "'" + t + "'"; var a = e.indent * Math.max(1, n), l = -1 === e.lineWidth ? -1 : Math.max(Math.min(e.lineWidth, 40), e.lineWidth - a), c = i || e.flowLevel > -1 && n >= e.flowLevel; switch (Be(t, c, e.indent, l, (function (t) { return function (e, t) { var n, i; for (n = 0, i = e.implicitTypes.length; n < i; n += 1)if (e.implicitTypes[n].resolve(t)) return !0; return !1 }(e, t) }), e.quotingType, e.forceQuotes && !i, r)) { case 1: return t; case 2: return "'" + t.replace(/'/g, "''") + "'"; case 3: return "|" + Pe(t, e.indent) + We(Me(t, a)); case 4: return ">" + Pe(t, e.indent) + We(Me(function (e, t) { var n, i, r = /(\n+)([^\n]*)/g, o = (l = e.indexOf("\n"), l = -1 !== l ? l : e.length, r.lastIndex = l, He(e.slice(0, l), t)), a = "\n" === e[0] || " " === e[0]; var l; for (; i = r.exec(e);) { var c = i[1], s = i[2]; n = " " === s[0], o += c + (a || n || "" === s ? "" : "\n") + He(s, t), a = n } return o }(t, l), a)); case 5: return '"' + function (e) { for (var t, n = "", i = 0, r = 0; r < e.length; i >= 65536 ? r += 2 : r++)i = Ye(e, r), !(t = je[i]) && De(i) ? (n += e[r], i >= 65536 && (n += e[r + 1])) : n += t || Fe(i); return n }(t) + '"'; default: throw new o("impossible error: invalid scalar style") } }() } function Pe(e, t) { var n = Re(e) ? String(t) : "", i = "\n" === e[e.length - 1]; return n + (i && ("\n" === e[e.length - 2] || "\n" === e) ? "+" : i ? "" : "-") + "\n" } function We(e) { return "\n" === e[e.length - 1] ? e.slice(0, -1) : e } function He(e, t) { if ("" === e || " " === e[0]) return e; for (var n, i, r = / [^ ]/g, o = 0, a = 0, l = 0, c = ""; n = r.exec(e);)(l = n.index) - o > t && (i = a > o ? a : l, c += "\n" + e.slice(o, i), o = i + 1), a = l; return c += "\n", e.length - o > t && a > o ? c += e.slice(o, a) + "\n" + e.slice(a + 1) : c += e.slice(o), c.slice(1) } function $e(e, t, n, i) { var r, o, a, l = "", c = e.tag; for (r = 0, o = n.length; r < o; r += 1)a = n[r], e.replacer && (a = e.replacer.call(n, String(r), a)), (Ve(e, t + 1, a, !0, !0, !1, !0) || void 0 === a && Ve(e, t + 1, null, !0, !0, !1, !0)) && (i && "" === l || (l += Le(e, t)), e.dump && 10 === e.dump.charCodeAt(0) ? l += "-" : l += "- ", l += e.dump); e.tag = c, e.dump = l || "[]" } function Ge(e, t, n) { var i, r, a, l, c, s; for (a = 0, l = (r = n ? e.explicitTypes : e.implicitTypes).length; a < l; a += 1)if (((c = r[a]).instanceOf || c.predicate) && (!c.instanceOf || "object" == typeof t && t instanceof c.instanceOf) && (!c.predicate || c.predicate(t))) { if (n ? c.multi && c.representName ? e.tag = c.representName(t) : e.tag = c.tag : e.tag = "?", c.represent) { if (s = e.styleMap[c.tag] || c.defaultStyle, "[object Function]" === Ie.call(c.represent)) i = c.represent(t, s); else { if (!Se.call(c.represent, s)) throw new o("!<" + c.tag + '> tag resolver accepts not "' + s + '" style'); i = c.represent[s](t, s) } e.dump = i } return !0 } return !1 } function Ve(e, t, n, i, r, a, l) { e.tag = null, e.dump = n, Ge(e, n, !1) || Ge(e, n, !0); var c, s = Ie.call(e.dump), u = i; i && (i = e.flowLevel < 0 || e.flowLevel > t); var p, f, d = "[object Object]" === s || "[object Array]" === s; if (d && (f = -1 !== (p = e.duplicates.indexOf(n))), (null !== e.tag && "?" !== e.tag || f || 2 !== e.indent && t > 0) && (r = !1), f && e.usedDuplicates[p]) e.dump = "*ref_" + p; else { if (d && f && !e.usedDuplicates[p] && (e.usedDuplicates[p] = !0), "[object Object]" === s) i && 0 !== Object.keys(e.dump).length ? (!function (e, t, n, i) { var r, a, l, c, s, u, p = "", f = e.tag, d = Object.keys(n); if (!0 === e.sortKeys) d.sort(); else if ("function" == typeof e.sortKeys) d.sort(e.sortKeys); else if (e.sortKeys) throw new o("sortKeys must be a boolean or a function"); for (r = 0, a = d.length; r < a; r += 1)u = "", i && "" === p || (u += Le(e, t)), c = n[l = d[r]], e.replacer && (c = e.replacer.call(n, l, c)), Ve(e, t + 1, l, !0, !0, !0) && ((s = null !== e.tag && "?" !== e.tag || e.dump && e.dump.length > 1024) && (e.dump && 10 === e.dump.charCodeAt(0) ? u += "?" : u += "? "), u += e.dump, s && (u += Le(e, t)), Ve(e, t + 1, c, !0, s) && (e.dump && 10 === e.dump.charCodeAt(0) ? u += ":" : u += ": ", p += u += e.dump)); e.tag = f, e.dump = p || "{}" }(e, t, e.dump, r), f && (e.dump = "&ref_" + p + e.dump)) : (!function (e, t, n) { var i, r, o, a, l, c = "", s = e.tag, u = Object.keys(n); for (i = 0, r = u.length; i < r; i += 1)l = "", "" !== c && (l += ", "), e.condenseFlow && (l += '"'), a = n[o = u[i]], e.replacer && (a = e.replacer.call(n, o, a)), Ve(e, t, o, !1, !1) && (e.dump.length > 1024 && (l += "? "), l += e.dump + (e.condenseFlow ? '"' : "") + ":" + (e.condenseFlow ? "" : " "), Ve(e, t, a, !1, !1) && (c += l += e.dump)); e.tag = s, e.dump = "{" + c + "}" }(e, t, e.dump), f && (e.dump = "&ref_" + p + " " + e.dump)); else if ("[object Array]" === s) i && 0 !== e.dump.length ? (e.noArrayIndent && !l && t > 0 ? $e(e, t - 1, e.dump, r) : $e(e, t, e.dump, r), f && (e.dump = "&ref_" + p + e.dump)) : (!function (e, t, n) { var i, r, o, a = "", l = e.tag; for (i = 0, r = n.length; i < r; i += 1)o = n[i], e.replacer && (o = e.replacer.call(n, String(i), o)), (Ve(e, t, o, !1, !1) || void 0 === o && Ve(e, t, null, !1, !1)) && ("" !== a && (a += "," + (e.condenseFlow ? "" : " ")), a += e.dump); e.tag = l, e.dump = "[" + a + "]" }(e, t, e.dump), f && (e.dump = "&ref_" + p + " " + e.dump)); else { if ("[object String]" !== s) { if ("[object Undefined]" === s) return !1; if (e.skipInvalid) return !1; throw new o("unacceptable kind of an object to dump " + s) } "?" !== e.tag && Ke(e, e.dump, t, a, u) } null !== e.tag && "?" !== e.tag && (c = encodeURI("!" === e.tag[0] ? e.tag.slice(1) : e.tag).replace(/!/g, "%21"), c = "!" === e.tag[0] ? "!" + c : "tag:yaml.org,2002:" === c.slice(0, 18) ? "!!" + c.slice(18) : "!<" + c + ">", e.dump = c + " " + e.dump) } return !0 } function Ze(e, t) { var n, i, r = [], o = []; for (Je(e, r, o), n = 0, i = o.length; n < i; n += 1)t.duplicates.push(r[o[n]]); t.usedDuplicates = new Array(i) } function Je(e, t, n) { var i, r, o; if (null !== e && "object" == typeof e) if (-1 !== (r = t.indexOf(e))) -1 === n.indexOf(r) && n.push(r); else if (t.push(e), Array.isArray(e)) for (r = 0, o = e.length; r < o; r += 1)Je(e[r], t, n); else for (r = 0, o = (i = Object.keys(e)).length; r < o; r += 1)Je(e[i[r]], t, n) } function Qe(e, t) { return function () { throw new Error("Function yaml." + e + " is removed in js-yaml 4. Use yaml." + t + " instead, which is now safe by default.") } } var ze = p, Xe = h, et = b, tt = O, nt = j, it = K, rt = xe.load, ot = xe.loadAll, at = { dump: function (e, t) { var n = new Ee(t = t || {}); n.noRefs || Ze(e, n); var i = e; return n.replacer && (i = n.replacer.call({ "": i }, "", i)), Ve(n, 0, i, !0, !0) ? n.dump + "\n" : "" } }.dump, lt = o, ct = { binary: L, float: S, map: y, null: A, pairs: Y, set: B, timestamp: F, bool: v, int: C, merge: E, omap: U, seq: m, str: g }, st = Qe("safeLoad", "load"), ut = Qe("safeLoadAll", "loadAll"), pt = Qe("safeDump", "dump"), ft = { Type: ze, Schema: Xe, FAILSAFE_SCHEMA: et, JSON_SCHEMA: tt, CORE_SCHEMA: nt, DEFAULT_SCHEMA: it, load: rt, loadAll: ot, dump: at, YAMLException: lt, types: ct, safeLoad: st, safeLoadAll: ut, safeDump: pt }; e.CORE_SCHEMA = nt, e.DEFAULT_SCHEMA = it, e.FAILSAFE_SCHEMA = et, e.JSON_SCHEMA = tt, e.Schema = Xe, e.Type = ze, e.YAMLException = lt, e.default = ft, e.dump = at, e.load = rt, e.loadAll = ot, e.safeDump = pt, e.safeLoad = st, e.safeLoadAll = ut, e.types = ct, Object.defineProperty(e, "__esModule", { value: !0 }) }));
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/scripts/__pycache__/easy_prompt_selector.cpython-310.pyc ADDED
Binary file (4.57 kB). View file
 
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/scripts/__pycache__/settings.cpython-310.pyc ADDED
Binary file (575 Bytes). View file
 
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/scripts/__pycache__/setup.cpython-310.pyc ADDED
Binary file (1.5 kB). View file
 
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/scripts/easy_prompt_selector.py ADDED
@@ -0,0 +1,132 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from pathlib import Path
2
+ import random
3
+ import re
4
+ import yaml
5
+ import gradio as gr
6
+
7
+ import modules.scripts as scripts
8
+ from modules.scripts import AlwaysVisible, basedir
9
+ from modules import shared
10
+ from scripts.setup import write_filename_list
11
+
12
+ FILE_DIR = Path().absolute()
13
+ BASE_DIR = Path(basedir())
14
+ TAGS_DIR = BASE_DIR.joinpath('tags')
15
+
16
+ def tag_files():
17
+ return TAGS_DIR.rglob("*.yml")
18
+
19
+ def load_tags():
20
+ tags = {}
21
+ for filepath in tag_files():
22
+ with open(filepath, "r", encoding="utf-8") as file:
23
+ yml = yaml.safe_load(file)
24
+ tags[filepath.stem] = yml
25
+
26
+ return tags
27
+
28
+ def find_tag(tags, location):
29
+ if type(location) == str:
30
+ return tags[location]
31
+
32
+ value = ''
33
+ if len(location) > 0:
34
+ value = tags
35
+ for tag in location:
36
+ value = value[tag]
37
+
38
+ if type(value) == dict:
39
+ key = random.choice(list(value.keys()))
40
+ tag = value[key]
41
+ if type(tag) == dict:
42
+ value = find_tag(tag, [random.choice(list(tag.keys()))])
43
+ else:
44
+ value = find_tag(value, key)
45
+
46
+ if (type(value) == list):
47
+ value = random.choice(value)
48
+
49
+ return value
50
+
51
+ def replace_template(tags, prompt, seed = None):
52
+ random.seed(seed)
53
+
54
+ count = 0
55
+ while count < 100:
56
+ if not '@' in prompt:
57
+ break
58
+
59
+ for match in re.finditer(r'(@((?P<num>\d+(-\d+)?)\$\$)?(?P<ref>[^>]+?)@)', prompt):
60
+ template = match.group()
61
+ try:
62
+ try:
63
+ result = list(map(lambda x: int(x), match.group('num').split('-')))
64
+ min_count = min(result)
65
+ max_count = max(result)
66
+ except Exception as e:
67
+ min_count, max_count = 1, 1
68
+ count = random.randint(min_count, max_count)
69
+
70
+ values = list(map(lambda x: find_tag(tags, match.group('ref').split(':')), list(range(count))))
71
+ prompt = prompt.replace(template, ', '.join(values), 1)
72
+ except Exception as e:
73
+ prompt = prompt.replace(template, '', 1)
74
+ count += 1
75
+
76
+ random.seed()
77
+ return prompt
78
+
79
+ class Script(scripts.Script):
80
+ tags = {}
81
+
82
+ def __init__(self):
83
+ super().__init__()
84
+ self.tags = load_tags()
85
+
86
+ def title(self):
87
+ return "EasyPromptSelector"
88
+
89
+ def show(self, is_img2img):
90
+ return AlwaysVisible
91
+
92
+ def ui(self, is_img2img):
93
+ if (is_img2img):
94
+ return None
95
+
96
+ reload_button = gr.Button('🔄', variant='secondary', elem_id='easy_prompt_selector_reload_button')
97
+ reload_button.style(size='sm')
98
+
99
+ def reload():
100
+ self.tags = load_tags()
101
+ write_filename_list()
102
+
103
+ reload_button.click(fn=reload)
104
+
105
+ return [reload_button]
106
+
107
+ def replace_template_tags(self, p):
108
+ prompts = [
109
+ [p.prompt, p.all_prompts, 'Input Prompt'],
110
+ [p.negative_prompt, p.all_negative_prompts, 'Input NegativePrompt'],
111
+ ]
112
+ if getattr(p, 'hr_prompt', None): prompts.append([p.hr_prompt, p.all_hr_prompts, 'Input Prompt(Hires)'])
113
+ if getattr(p, 'hr_negative_prompt', None): prompts.append([p.hr_negative_prompt, p.all_hr_negative_prompts, 'Input NegativePrompt(Hires)'])
114
+
115
+ for i in range(len(p.all_prompts)):
116
+ seed = random.random()
117
+ for [prompt, all_prompts, raw_prompt_param_name] in prompts:
118
+ if '@' not in prompt: continue
119
+
120
+ self.save_prompt_to_pnginfo(p, prompt, raw_prompt_param_name)
121
+
122
+ replaced = "".join(replace_template(self.tags, all_prompts[i], seed))
123
+ all_prompts[i] = replaced
124
+
125
+ def save_prompt_to_pnginfo(self, p, prompt, name):
126
+ if shared.opts.eps_enable_save_raw_prompt_to_pnginfo == False:
127
+ return
128
+
129
+ p.extra_generation_params.update({name: prompt.replace('\n', ' ')})
130
+
131
+ def process(self, p, *args):
132
+ self.replace_template_tags(p)
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/scripts/settings.py ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
 
1
+ from modules import script_callbacks, shared
2
+
3
+ def on_ui_settings():
4
+ shared.opts.add_option("eps_enable_save_raw_prompt_to_pnginfo", shared.OptionInfo(False, "元プロンプトを pngninfo に保存する", section=("easy_prompt_selector", "EasyPromptSelector")))
5
+
6
+ script_callbacks.on_ui_settings(on_ui_settings)
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/scripts/setup.py ADDED
@@ -0,0 +1,38 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from pathlib import Path
2
+ import shutil
3
+ import os
4
+
5
+ from modules import scripts
6
+
7
+ FILE_DIR = Path().absolute()
8
+ BASE_DIR = Path(scripts.basedir())
9
+ TEMP_DIR = FILE_DIR.joinpath('tmp')
10
+
11
+ TAGS_DIR = BASE_DIR.joinpath('tags')
12
+ EXAMPLES_DIR = BASE_DIR.joinpath('tags_examples')
13
+
14
+ FILENAME_LIST = 'easyPromptSelector.txt'
15
+
16
+ os.makedirs(TEMP_DIR, exist_ok=True)
17
+
18
+ def examples():
19
+ return EXAMPLES_DIR.rglob("*.yml")
20
+
21
+ def copy_examples():
22
+ for file in examples():
23
+ file_path = str(file).replace('tags_examples', 'tags')
24
+ shutil.copy2(file, file_path)
25
+
26
+ def tags():
27
+ return TAGS_DIR.rglob("*.yml")
28
+
29
+ def write_filename_list():
30
+ filepaths = map(lambda path: path.relative_to(FILE_DIR).as_posix(), list(tags()))
31
+
32
+ with open(TEMP_DIR.joinpath(FILENAME_LIST), 'w', encoding="utf-8") as f:
33
+ f.write('\n'.join(sorted(filepaths)))
34
+
35
+ if len(list(TAGS_DIR.rglob("*.yml"))) == 0:
36
+ copy_examples()
37
+
38
+ write_filename_list()
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/style.css ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ .easy_prompt_selector_container {
2
+ display: flex;
3
+ flex-direction: row;
4
+ gap: 0.5em;
5
+ margin-top: 0.5em;
6
+ }
7
+
8
+ .easy_prompt_selector_button {
9
+ flex: 1;
10
+ }
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/.keep ADDED
File without changes
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物.yml ADDED
@@ -0,0 +1,61 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 対象:
2
+ - 1girl
3
+ - 1boy
4
+ - 1other
5
+ - multiple girls
6
+
7
+ 年龄:
8
+ 十几岁: teen
9
+ 少年: early teen
10
+ 大人: adult
11
+ 老人: elder
12
+ 小儿: child
13
+ 幼儿园儿: kindergartener
14
+ 幼儿: toddler
15
+ 萝莉: loli
16
+ 正太: shota
17
+
18
+ 肤色:
19
+ 白: white skin
20
+ 色白: pale skin
21
+ 褐色: dark skin
22
+ 明亮: shiny skin
23
+ 有色: colored skin
24
+
25
+ 皮肤性质:
26
+ 日晒: tan
27
+ 晒痕: tanlines
28
+ 纹身: tattoo
29
+ 油性: oil
30
+
31
+ 体形:
32
+ 运动员: athlete
33
+ 模特: model
34
+ 苗条: slender
35
+ 诱惑: glamor
36
+ 丰满: plump
37
+ 胖: fat
38
+ 高: tall
39
+ 纤弱: petite
40
+ 矮: chibi
41
+ 怀孕: pregnant
42
+ 肌肉: muscular
43
+ 细腰: narrow waist
44
+ 大屁股: wide hips
45
+
46
+ 胸:
47
+ 平胸: flat chest
48
+ 贫乳: small breasts
49
+ 普通: medium breasts
50
+ 巨乳: large breasts
51
+ 爆乳: huge breasts
52
+ 垂乳: hanging breasts
53
+
54
+ 身体部位:
55
+ 腋: armpits
56
+ 锁骨: collarbone
57
+ 肚脐: navel
58
+ 屁股: ass
59
+ 大腿: thighs
60
+
61
+
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_五官.yml ADDED
@@ -0,0 +1,75 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 眉毛:
2
+ 浓眉: thick eyebrows
3
+ 眉毛翘起: cocked eyebrow
4
+ 短眉毛: short eyebrows
5
+ V字眉: v-shaped eyebrows
6
+ 眼睛:
7
+ 黒: black eyes
8
+ 白: white eyes
9
+ 红: red eyes
10
+ 蓝: blue eyes
11
+ 绿: green eyes
12
+ 紫: purple eyes
13
+ 银色: silver eyes
14
+ 金色: golden eyes
15
+ 灰色: gray eyes
16
+ 水色: aqua eyes
17
+ 茶色: brown eyes
18
+ 粉色: pink eyes
19
+ 橙色: orange eyes
20
+ 异色: heterochromia
21
+ 空洞眼睛: empty eyes
22
+ 睁大眼睛: wide eyes
23
+ 闭上一只眼: one eye closed
24
+ 半闭眼睛: half-closed eyes
25
+ 渐变眼: gradient_eyes
26
+ 水汪汪大眼: aqua eyes
27
+ 翻白眼: rolling eyes
28
+ 斗鸡眼: cross-eyed
29
+ 猫眼: slit pupils
30
+ 布满血丝的眼睛: bloodshot eyes
31
+ 发光眼睛: glowing eyes
32
+ 吊眼角: tsurime
33
+ 垂眼角: tareme
34
+ 恶魔眼: devil eyes
35
+ 收缩的瞳孔: constricted pupils
36
+ 魔瞳: devil pupils
37
+ 蛇瞳: snake pupils
38
+ 闪闪发光瞳: pupils sparkling
39
+ 花形瞳: flower-shaped pupils
40
+ 爱心瞳: heart-shaped pupils
41
+ 异色瞳: heterochromia
42
+ 美瞳: color contact lenses
43
+ 长睫毛: longeyelashes
44
+ 彩色睫毛: colored eyelashes
45
+ 眼下痣: mole under eye
46
+ 嘴巴:
47
+ 栗子嘴: chestnut mouth
48
+ 厚嘴唇: thick lips
49
+ 嘴唇浮肿: puffy lips
50
+ 口红: lipstick
51
+ 心形嘴: heart-shaped mouth
52
+ 嘟嘴: pout
53
+ 张嘴: open mouth
54
+ 闭嘴: closed mouth
55
+ 猫咪嘴: :3
56
+ 鲨鱼嘴: shark mouth
57
+ 吐舌头: :p
58
+ 分开嘴唇: parted lips
59
+ 嘴下痣: mole under mouth
60
+ 耳朵:
61
+ 精灵耳: elf ears
62
+ 动物耳朵: fake animal ears
63
+ 猫耳朵: cat ears
64
+ 狗耳朵: dog ears
65
+ 狐狸耳朵: fox ears
66
+ 兔子耳朵: bunny ears
67
+ 熊耳朵: bear ears
68
+ 胡子&牙:
69
+ 胡须: beard
70
+ 小胡子: mustache
71
+ 山羊胡: goatee
72
+ 长鬓角: long sideburns
73
+ 尖牙: fangs
74
+ 虎牙: canine teeth
75
+ 咬紧牙关: clenched teeth
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_头发.yml ADDED
@@ -0,0 +1,81 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 发色:
2
+ 単色:
3
+ 黑发: black hair
4
+ 金发: blonde hair
5
+ 茶发: brown hair
6
+ 赤发: red hair
7
+ 粉发: pink hair
8
+ 蓝发: blue hair
9
+ 水色发: aqua hair
10
+ 緑发: green hair
11
+ 紫发: purple hair
12
+ 橙发: orange hair
13
+ 银发: silver hair
14
+ 灰发: gray hair
15
+ 白发: white hair
16
+ 多色:
17
+ 多色: multicolored hair
18
+ 条纹色: streaked hair
19
+ 渐变色: gradient hair
20
+ 内侧彩色: colored inner hair
21
+ 分叉色: split-color hair
22
+
23
+ 发型:
24
+ 长度:
25
+ 极短发: very short hair
26
+ 短发: short hair
27
+ 中等长度: medium hair
28
+ 长发: long hair
29
+ 超长发: very long hair
30
+ 超超长发: absurdly long hair
31
+ 种类:
32
+ 乱发: messy hair
33
+ 直发: straight hair
34
+ 波浪发: wavy hair
35
+ 翻卷发: flipped hair
36
+ 非対称: asymmetrical hair
37
+ 马尾:
38
+ 马尾: ponytail
39
+ 高马尾: high ponytail
40
+ 低马尾: low ponytail
41
+ 前马尾: front ponytail
42
+ 侧马尾: side ponytail
43
+ 分叉马尾: split ponytail
44
+ 折叠马尾: folded ponytail
45
+ 短马尾: short ponytail
46
+ 双马尾:
47
+ 双马尾: twintails
48
+ 低双马尾: low twintails
49
+ 短双马尾: short twintails
50
+ 三马尾: tri tails
51
+ 四马尾: quad tails
52
+ 辫子: braid
53
+ 半向上: half updo
54
+ 一边向上: one side up
55
+ 两边向上: two side up
56
+ 多股头发: multi-tied hair
57
+ 头顶结: topknot
58
+ 卷发: curly hair
59
+ 钻头毛: drill hair
60
+ 双钻头毛: twin drills
61
+ 垂长卷: ringlets
62
+ 弓型发: bow-shaped hair
63
+ 发髻: hair bun
64
+ 发圈: hair rings
65
+ 长发绺: dreadlocks
66
+
67
+ 前发:
68
+ 钝刘海: blunt bangs
69
+ 非対称刘海: asymmetrical bangs
70
+ 眼睛上方刘海: hair over eyes
71
+ 一直眼睛上方刘海: hair over one eye
72
+ 分刘海: parted bangs
73
+ 齐刘海: swept bangs
74
+ 眼睛间头发: hair between eyes
75
+ 发量: hair intakes
76
+ 触角: sidelocks
77
+
78
+ 其他:
79
+ 横发: hair flaps
80
+ 傻毛: ahoge
81
+ 天线毛: antenna hair
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_姿势.yml ADDED
@@ -0,0 +1,125 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 姿态:
2
+ 侧身坐: yokozuwari
3
+ 鸭子坐: ahirusuwari
4
+ 盘腿: indian style
5
+ 跪着: kneeling
6
+ 躬躯: arched back
7
+ 膝枕: lap pillow
8
+ 学猫叫: paw pose
9
+ 单膝跪地: one knee
10
+ 蜷起身子侧躺: fetal position
11
+ 仰卧: on back
12
+ 俯卧: on stomach
13
+ 坐着: sitting
14
+ 屈膝抱腿坐: hugging own legs
15
+ 立式跨骑: upright straddle
16
+ 站着: standing
17
+ 蹲着: squatting
18
+ 绑在十字架上: crucifixion
19
+ 双腿缠绕: leg lock
20
+ 四肢着地: all fours
21
+ 戴耳机: hand on headphones
22
+ 鬼姿势: ghost pose
23
+ 回头: turning around
24
+ 歪头: head tilt
25
+ 前倾: leaning forward
26
+ 手势:
27
+ 嘘手势: shushing
28
+ 翘大拇指: thumbs up
29
+ 手放脑后: arms behind head
30
+ 手放身后: arms behind back
31
+ 手插口袋: hand in pocket
32
+ 双手插口袋: hands in pocket
33
+ 十指相扣: interlocked fingers
34
+ V字手势: victory pose
35
+ 手在地板上: hand on floor
36
+ 手在额头上: hand on forehead
37
+ 手在肚子上: hand on own stomach
38
+ 手在肩膀上: arm over shoulder
39
+ 手搭别人的腿: hand on another's leg
40
+ 手搭别人的腰: hand on another's waist
41
+ 双手合十: own hands clasped
42
+ 翼展双臂: wide open arms
43
+ 手放嘴边: hand to mouth
44
+ 手枪手势: finger gun
45
+ 猫爪手势: cat pose
46
+ 视线:
47
+ 远眺: looking afar
48
+ 照镜子: looking at mirror
49
+ 看手机: looking at phone
50
+ 看向别处: looking away
51
+ 透过刘海看: visible through hair
52
+ 透过眼镜看: looking over glasses
53
+ 面向观者: look at viewer
54
+ 靠近观者: close to viewer
55
+ 动态角度: dynamic angle
56
+ 舞台角度: dramatic angle
57
+ 凝视: stare
58
+ 向上看: looking up
59
+ 向下看: looking down
60
+ 看向旁边: looking to the side
61
+ 移开目光: looking away
62
+ 整体:
63
+ 嗅闻: smelling
64
+ 公主抱: princess carry
65
+ 拥抱: hug
66
+ 背对背: back-to-back
67
+ 耶: peace symbol
68
+ 调整过膝袜: adjusting_thighhigh
69
+ 抓住: grabbing
70
+ 战斗姿态: fighting_stance
71
+ 走: walking
72
+ 跑: running
73
+ 跨坐: straddling
74
+ 跳: jump
75
+ 飞: fly
76
+ 靠墙: against wall
77
+ 躺: lie
78
+ 从背后抱: hug from behind
79
+ 遛狗: walk a dog
80
+ 提裙: skirt lift
81
+ 泡温泉: half body under water
82
+ 骑马: horse riding
83
+ 自拍: selfie
84
+ 一字马: standing split
85
+ 敬礼: salute
86
+ 祈祷: pray
87
+ 冥想: doing a meditation
88
+ 上半身:
89
+ 伸懒腰: stretch
90
+ 托腮: gill support
91
+ 牵手: holding hands
92
+ 单手叉腰: hand_on_hip
93
+ 双手叉腰: hands_on_hips
94
+ 招手: waving
95
+ 撮头发: hair scrunchie
96
+ 拉头发: hair_pull
97
+ 抓别人的头发: grabbing another's hair
98
+ 竖中指: middle_finger
99
+ 弯腰: bent over
100
+ 亲吻脸颊: kissing cheek
101
+ 亲吻额头: kissing forehead
102
+ 踮起脚尖吻: tiptoe kiss
103
+ 头顶水果: fruit on head
104
+ 咬手套: glove biting
105
+ 脸贴脸: cheek-to-cheek
106
+ 手牵手: hand on another's hand
107
+ 双手交叉: crossed arms
108
+ 双手张开伸直: spread arms
109
+ 挥动手臂: waving arms
110
+ 伸出手臂: outstretched arm
111
+ 用手臂支撑: carrying
112
+ 搂着手臂: arm hug
113
+ 拿着: holding
114
+ 拿着餐刀: holding knife
115
+ 拿着枪: holding gun
116
+ 拿着杯子: holding cup
117
+ 拿着食物: holding food
118
+ 拿着书: holding book
119
+ 拿着魔杖: holding wand
120
+ 打着伞: holding umbrella
121
+ 捧着花: holding flower
122
+ 拿着麦克风: holding microphone
123
+ 抱着物品: object hug
124
+ 抱着心: holding heart
125
+
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_尾翅膀角.yml ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 尾巴:
2
+ 宝可梦尾巴: pokemon tail
3
+ 皮卡丘尾巴: pikachu tail
4
+ 水獭尾巴: otter tail
5
+ 蝎尾: scorpion tail
6
+ 鹿尾: deer tail
7
+ 黄鼠狼尾巴: weasel tail
8
+ 羊驼尾巴: alpaca tail
9
+ 恐龙尾巴: dinosaur tail
10
+ 企鹅尾巴: penguin tail
11
+ 羊尾巴: sheep tail
12
+ 山羊尾巴: goat tail
13
+ 海狸尾巴: beaver tail
14
+ 小熊猫尾巴: red panda tail
15
+ 豺尾巴: jackal tail
16
+ 食蚁兽尾巴: anteater tail
17
+ 土狼尾巴: aardwolf tail
18
+ 猎豹尾巴: panther tail
19
+ 熊猫尾巴: panda tail
20
+ 天使尾巴: Angel wings
21
+ 翅膀:
22
+ 蝴蝶翅膀: Butterfly wings
23
+ 昆虫翅膀: insect wings
24
+ 蝙蝠翅膀: Bat wings
25
+ 鸟翼: bird wings
26
+ 羽翼: feathered wings
27
+ 妖精翅膀: Fairy wings
28
+ 龙之翼: Dragon wings
29
+ 恶魔之翼: Demon wings
30
+ 火焰翅膀: Fiery wings
31
+ 机械翅膀: Mechanical wings
32
+ 冰翅: ice crystal texture
33
+ 冰火之翼: ((burning feathers)),(feathers_made_of_ice),(frozen feathers),(((ice and fire together)))
34
+ 角:
35
+ 羚羊角: antelope horns
36
+ 山羊角: goat horns
37
+ 羊角: sheep horns
38
+ 奶牛角: cow horns
39
+ 公牛角: ox horns
40
+ 鬼角: oni horns
41
+ 断角: broken horn
42
+ 机械角: mechanical horns
43
+ 恶魔之角: demon horns
44
+ 龙之角: dragon horns
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_服装.yml ADDED
@@ -0,0 +1,82 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 上装:
2
+ 过手袖: sleeves_past_fingers
3
+ 背心: tank top
4
+ 白衬衫: white shirt
5
+ 水手衬衫: sailor shirt
6
+ T恤: T-shirt
7
+ 毛衣: sweater
8
+ 夏日长裙: summer dress
9
+ 连帽衫: hoodie
10
+ 毛领: fur trimmed colla
11
+ 兜帽斗篷: hooded cloak
12
+ 夹克: jacket
13
+ 皮夹克: leather jacket
14
+ 探险家夹克: safari jacket
15
+ 兜帽: hood
16
+ 牛仔夹克: denim jacket
17
+ 高领夹克: turtleneck jacket
18
+ 消防员夹克: firefighter jacket
19
+ 透明夹克: see-through jacket
20
+ 战壕大衣: trench coat
21
+ 实验室外套: lab coat
22
+ 羽绒服: Down Jackets
23
+ 防弹盔甲: body armor
24
+ 防弹衣: flak jacket
25
+ 大衣: overcoat
26
+ 粗呢大衣: duffel coat
27
+ 服装:
28
+ 透视装: transparent clothes
29
+ 燕尾服: tailcoat
30
+ 女仆装: Victoria black maid dress
31
+ 水手服: sailor suit
32
+ 学生服: school uniform
33
+ 职场制服: bussiness suit
34
+ 西装: suit
35
+ 军装: military uniform
36
+ 礼服: lucency full dress
37
+ 汉服: hanfu
38
+ 旗袍: cheongsam
39
+ 和服: japanses clothes
40
+ 运动服: sportswear
41
+ 工装服: dungarees
42
+ 婚纱: wedding dress
43
+ 银色连衣裙: silvercleavage dress
44
+ 长袍: robe
45
+ 围裙: apron
46
+ 快餐制服: fast food uniform
47
+ JK制服: JK
48
+ 健身服: gym_uniform
49
+ 巫女服: miko attire
50
+ 海军陆战队服: SWAT uniform
51
+ 无袖连衣裙: sleeveless dress
52
+ 雨衣: raincoat
53
+ 机甲衣: mech suit
54
+ 巫师法袍: wizard robe
55
+ 刺客装束: assassin-style
56
+ 下装:
57
+ 牛仔短裤: denim shorts
58
+ 百褶裙: pleated skirt
59
+ 热裤: short shorts
60
+ 铅笔裙: pencil skirt
61
+ 皮裙: leather skirt
62
+ 黑色紧身裤: black leggings
63
+ 和服下的裙子: skirt under kimono
64
+ 其他服装:
65
+ 褶边: frills
66
+ 花边: lace
67
+ 哥特风格: gothic
68
+ 洛丽塔风格: lolita fashion
69
+ 西部风格: western
70
+ 湿身: wet clothes
71
+ 露单肩: off_shoulder
72
+ 露双肩: bare_shoulders
73
+ 格子花纹: tartan
74
+ 横条花纹: striped
75
+ 披甲: armored skirt
76
+ 盔甲: armor
77
+ 金属盔甲: metal armor
78
+ 狂战士铠甲: berserker armor
79
+ 腰带: belt
80
+ 围巾: scarf
81
+ 披肩: cape
82
+ 皮草披肩: fur shawl
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_表情.yml ADDED
@@ -0,0 +1,38 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 表情:
2
+ 笑: smile
3
+ 微笑: light smile
4
+ 惨笑: sad smile
5
+ 邪恶笑: evil smile
6
+ 天使笑: angelic smile
7
+ 强笑: forced smile
8
+ 诱人笑: seductive smile
9
+ 咧嘴笑: grin
10
+ 邪恶咧嘴笑: evil grin
11
+ 傻笑: smirk
12
+ 怒: angry
13
+ 悲伤: sad
14
+ 哭: crying
15
+ 泪: tears
16
+ 恐怖: scared
17
+ 不好的: serious
18
+ 恼怒: annoyed
19
+ 黑暗人格: dark persona
20
+ 多亚脸: doyagao
21
+ 脸红: blush
22
+ 脸通红: full-face blush
23
+ 无聊: bored
24
+ 罪恶感: guilt
25
+ 无感情: expressionless
26
+ 决心: determined
27
+ 接吻: incoming kiss
28
+ 失望: disappointed
29
+ 轻蔑: disdain
30
+ 嫉妒: envy
31
+ 厌恶: disgust
32
+ 困惑: confused
33
+ 烦恼挑眉: troubled eyebrows
34
+ V型眉: v-shaped eyebrows
35
+ 羞耻: embarrassed
36
+ 顽皮: naughty
37
+ 困乏: sleepy
38
+
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_装饰.yml ADDED
@@ -0,0 +1,71 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 发饰:
2
+ 发带: hair ribbon
3
+ 头巾: head scarf
4
+ 动物头巾: animal hood
5
+ 蝴蝶结发饰: hair bow
6
+ 新月发饰: crescent hair ornament
7
+ 洛丽塔发饰: lolita hairband
8
+ 羽毛发饰: feather hair ornament
9
+ 头花: hair flower
10
+ 发髻: hair bun
11
+ 发夹: hairclip
12
+ 发箍: hair scrunchie
13
+ 发圈: hair rings
14
+ 发饰: hair ornament
15
+ 发棒: hair stick
16
+ 心形发饰: heart hair ornament
17
+ 首饰:
18
+ 手链: bracelet
19
+ 项圈: choker
20
+ 金属项圈: metal collar
21
+ 戒指: ring
22
+ 腕带: wristband
23
+ 吊坠: pendant
24
+ 胸针: brooch
25
+ 圈形耳环: hoop earrings
26
+ 手镯: bangle
27
+ 耳钉: stud earrings
28
+ 旭日形首饰: sunburst
29
+ 珍珠手链: pearl bracelet
30
+ 耳坠: drop earrings
31
+ 木偶戒指: puppet rings
32
+ 胸花: corsage
33
+ 蓝宝石胸针: sapphire brooch
34
+ 珠宝首饰: jewelry
35
+ 项链: necklace
36
+ 装饰:
37
+ 丝带: ribbon
38
+ 丝带饰边: ribbon trim
39
+ 蕾丝饰边: lace trim
40
+ 裙撑: skirt lift
41
+ 护手: gauntlets
42
+ 领巾: neckerchief
43
+ 红领巾: red neckerchief
44
+ 肩章: pauldrons
45
+ 臂带: arm strap
46
+ 臂镯: armlet
47
+ 细肩带: spaghetti strap
48
+ 般若面具: Prajna in mask
49
+ 面纱: veil
50
+ 新娘面纱: bridal veil
51
+ 皇冠: tiara
52
+ 迷你皇冠: mini crown
53
+ 耳罩: ear covers
54
+ 飞行员太阳镜: aviator sunglasses
55
+ 无边框眼镜: semi-rimless eyewear
56
+ 半无框眼镜: semi-rimless eyewear
57
+ 太阳镜: sunglasses
58
+ 风镜: goggles
59
+ 独眼眼罩: eyepatch
60
+ 黑色眼罩: black blindfold
61
+ 铁棘: metal thorns
62
+ 光环: halo
63
+ 口罩: mouth mask
64
+ 创口贴: bandaid hair ornament
65
+ 指甲油: nail polish
66
+ 玩偶关节: doll joints
67
+ 机械义肢: cybernetic prosthesis
68
+ 机械腿: mechanical legs
69
+ 沙滩巾: beach towel
70
+ 雨披: poncho
71
+ 浓妆: make up
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_角色.yml ADDED
@@ -0,0 +1,77 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 职业:
2
+ 救生员: lifeguard
3
+ 拳击手: boxer
4
+ 科学家: scientist
5
+ 运动员: athletes
6
+ 职场女性: office lady
7
+ 和尚: monk
8
+ 杂技演员: crobat
9
+ 修女: nun
10
+ 护士: nurse
11
+ 空姐: stewardess
12
+ 学生: student
13
+ 女服务员: waitress
14
+ 老师: teacher
15
+ 赛车手: racer
16
+ 警察: police
17
+ 士兵: soldier
18
+ 啦啦队: cheerleader
19
+ 男演员: actor
20
+ 女演员: actress
21
+ 间谍: spy
22
+ 特工: agent
23
+ 刺客: assassin
24
+ 诗人: poet
25
+ 日本武士: samurai
26
+ 舞女: dancing girl
27
+ 摩托车手: motorcyclist
28
+ 黑客: hacker
29
+ 魔术师: magician
30
+ 侦探: detective
31
+ 人偶: doll
32
+ 女仆: maid
33
+ 飞行员: pilot
34
+ 潜水员: diver
35
+ 酒吧审查员: bar censor
36
+ 传教士: missionary
37
+ 消防员: firefighter
38
+ 守门员: goalkeeper
39
+ 厨师: chef
40
+ 宇航员: astronaut
41
+ 收银员: cashier
42
+ 邮递员: mailman
43
+ 咖啡师: barista
44
+ 隐士: the hermit
45
+ 牧羊人: makihitsuji
46
+ 动漫:
47
+ 宝可梦: pokemon
48
+ 泰迪熊: teddy bear
49
+ 马里奥: mario
50
+ 皮卡丘: pikachu
51
+ 新世纪福音战士: neon genesis evangelion
52
+ 初音未来: hatsune miku
53
+ 哈利波特: harry potter
54
+ 哆啦A梦: doraemon
55
+ 圣斗士星矢: saint seiya
56
+ 五条悟: gojou satoru
57
+ 复仇者联盟: avengers
58
+ 神奇女侠: mazinger
59
+ 美国队长: captain america
60
+ 蜡笔小新: crayon shin-chan
61
+ 灌篮高手: slam dunk
62
+ 孙悟空: sun wukong
63
+ 女巫: witch
64
+ 忍者: ninja
65
+ 吸血鬼: vampire
66
+ 骑士: knight
67
+ 魔法少女: magical_girl
68
+ 半兽人: orc
69
+ 德鲁伊: druid
70
+ 妖精: elf
71
+ 小精灵: fairy
72
+ 兽人: furry
73
+ 美人鱼: mermaid
74
+ 假面骑士: kamen rider
75
+ 魔导师: magister
76
+ 蜘蛛侠: spider-man
77
+ 圣诞老人: santa alter
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/人物_鞋袜帽.yml ADDED
@@ -0,0 +1,82 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 帽饰:
2
+ 棒球帽: Baseball cap
3
+ 针织帽: Beanie
4
+ 拿破仑帽: Bicorne
5
+ 太阳帽: Boater hat
6
+ 遮阳帽: Visor cap
7
+ 圆顶礼帽: Bowler hat
8
+ 报童帽: Cabbie hat
9
+ 渔夫帽: Bucket hat
10
+ 侦探帽: Fedora
11
+ 牛仔帽: Cowboy hat
12
+ 厨师帽: Chef hat
13
+ 军官帽: Military hat
14
+ 圣诞帽: Santa hat
15
+ 派对帽: Party hat
16
+ 小丑帽: Jester cap
17
+ 安全帽: Hardhat
18
+ 棒球头盔: Baseball helmet
19
+ 橄榄球头盔: Football helmet
20
+ 动物头盔: animal helmet
21
+ 女巫帽: witch hat
22
+ 贝雷帽: beret
23
+ 鸭舌帽: peaked cap
24
+ 草帽: Straw hat
25
+ 鞋类:
26
+ 裸足: bare_legs
27
+ 靴子: boots
28
+ 马丁靴: knee boots
29
+ 脚踝靴: ankle boots
30
+ 系带靴: cross-laced_footwear
31
+ 战斗靴: combat boots
32
+ 装甲靴: armored boots
33
+ 过膝靴: knee boots
34
+ 防水橡胶靴: rubber boots
35
+ 皮靴: leather boots
36
+ 雪地靴: snow boots
37
+ 圣诞靴: santa boots
38
+ 鞋子: shoes
39
+ 厚底鞋: platform footwear
40
+ 尖头鞋: pointy footwear
41
+ 芭蕾舞鞋: ballet slippers
42
+ 运动鞋: sneakers
43
+ 旱冰鞋: roller skates
44
+ 溜冰鞋: ice skates
45
+ 钉鞋: spiked shoes
46
+ 高跟鞋: high heels
47
+ 玛丽珍鞋: mary janes
48
+ 乐福鞋: loafers
49
+ 女式学生鞋: uwabaki
50
+ 凉鞋: sandals
51
+ 木屐: geta
52
+ 拖鞋: slippers
53
+ 人字拖: flip-flops
54
+ 袜类:
55
+ 不穿袜子: no socks
56
+ 短袜: socks
57
+ 日式厚底短袜: tabi
58
+ 丝袜: stockings
59
+ 圣诞袜: christmas stocking
60
+ 暖腿袜: leg warmers
61
+ 荷叶边袜子: frilled socks
62
+ 丝带边袜子: ribbon-trimmed legwear
63
+ 闪亮袜子: shiny legwear
64
+ 褶边长筒袜: frilled thighhighs
65
+ 过膝袜: thighhighs
66
+ 渔网袜: fishnet stockings
67
+ 堆堆袜: loose socks
68
+ 裤袜: leggings
69
+ 蕾丝裤袜: lace legwear
70
+ 罗纹裤袜: ribbed legwear
71
+ 湿连裤袜: wet pantyhose
72
+ 格子裤袜: plaid legwear
73
+ 透视裤袜: see-through legwear
74
+ 连裤袜: pantyhose
75
+ 撕裂的连裤袜: torn pantyhose
76
+ 单腿连裤袜: single leg pantyhose
77
+ 荷叶边连裤袜: frilled pantyhose
78
+ 柳丁吊袜带: studded garter belt
79
+ 吊袜带: sock dangle
80
+ 大腿系带: thigh strap
81
+ 腿部花边环: leg_garter
82
+ 包扎腿: bandaged leg
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/十八禁.yml ADDED
@@ -0,0 +1,163 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 十八禁:
2
+ 触手: tentacle
3
+ 发交: hairjob
4
+ 口交吹箫: oral,fellatio
5
+ 深喉: deepthroat
6
+ 精液咽下: gokkun
7
+ 口塞: gag
8
+ 口球塞: ballgag
9
+ 咬嘴塞: bitgag
10
+ 环形口塞: ring_gag
11
+ 胶布口塞: cleave_gag
12
+ 内裤口塞: panty_gag
13
+ 胶带口塞: tapegag
14
+ 颜射: facial
15
+ 皮带: leash
16
+ 手淫: handjob
17
+ 抚摸: groping
18
+ 乳晕: areolae
19
+ 乳头: nipples
20
+ 鼓鼓的乳头: puffy_nipples
21
+ 小乳头: small_nipples
22
+ 拉乳头: nipple_pull
23
+ 乳头折磨: nipple_torture
24
+ 捏乳头: nipple_tweak
25
+ 乳头穿孔: nipple_piercing
26
+ 抓胸: breast_grab
27
+ 泌乳: lactation
28
+ 吸胸吸乳头: breast_sucking,nipple_suck
29
+ 母乳喂养: breast_feeding
30
+ 乳交: paizuri
31
+ 多重乳交: multiple_paizuri
32
+ 胸部压迫: breast_smother
33
+ 穿孔: piercing
34
+ 肚脐穿孔: navel_piercing
35
+ 大腿性爱: thigh_sex
36
+ 足交: footjob
37
+ 阴毛丛: mound_of_venus
38
+ 宽臀: wide_hips
39
+ 自渎: masturbation
40
+ 着衣自渎: clothed_masturbation
41
+ 阴茎: penis
42
+ 睾丸: testicles
43
+ 射精: ejaculation
44
+ 精液: cum
45
+ 内射: cum_inside
46
+ 射在胸部: cum_on_breast
47
+ 射在头发: cum_on_hair
48
+ 射在食物: cum_on_food
49
+ 蛋袋: tamakeri
50
+ 阴道阴部: pussy,vaginal
51
+ 阴毛: pubic_hair
52
+ 无阴毛: shaved_pussy
53
+ 无阴部: no_pussy
54
+ 阴蒂: clitoris
55
+ 肥胖的阴阜: fat_mons
56
+ 骆驼趾: cameltoe
57
+ 阴部液体: pussy_juice
58
+ 阴道射精: female_ejaculation
59
+ 潮吹: grinding
60
+ 摩擦阴部: crotch_rub
61
+ 颜面骑乘: facesitting
62
+ 子宫颈: cervix
63
+ 舔阴: cunnilingus
64
+ 插入: insertion
65
+ 肛门插入: anal_insertion
66
+ 果物插入: fruit_insertion
67
+ 巨大插入: large_insertion
68
+ 穿刺: penetration
69
+ 拳交: fisting
70
+ 指交: fingering
71
+ 多重插入: multiple_insertions
72
+ 双重穿刺: double_penetration
73
+ 三重穿刺: triple_penetration
74
+ 双重阴道: double_vaginal
75
+ 小便: peeing
76
+ 憋尿: have_to_pee
77
+ 屁股: ass
78
+ 巨大的臀部: huge_ass
79
+ 张开屁股: spread_ass
80
+ 臀交: buttjob
81
+ 打屁股: spanked
82
+ 肛门: anus
83
+ 肛交: anal
84
+ 双重肛交: double_anal
85
+ 肛门指交: anal_fingering
86
+ 肛门拳交: anal_fisting
87
+ 肛门舔: anilingus
88
+ 灌肠: enema
89
+ 胃部凸起: stomach_bulge
90
+ 内部射精: internal_cumshot
91
+ 库拉捏: wakamezake
92
+ 公共场合: public
93
+ 羞辱: humiliation
94
+ 一边内裤: panties_around_one_leg
95
+ 被抓住: caught
96
+ 闯入: walk_in
97
+ 身体书写: body_writing
98
+ 计数: tally
99
+ 双性: futanari
100
+ 乱伦: incest
101
+ 双胞胎乱伦: twincest
102
+ 任性玩耍: pegging
103
+ 女性支配: femdom
104
+ 胸罩提起: bra_lift
105
+ 冈古罗: ganguro
106
+ 畜性: bestiality
107
+ 群交: gangbang
108
+ 三人行: threesome
109
+ 群P: group_sex
110
+ 摩擦双性恋: tribadism
111
+ 性骚扰: molestation
112
+ 窥阴癖: voyeurism
113
+ 露阴癖: exhibitionism
114
+ 强奸: rape
115
+ 即将被强奸: about_to_be_raped
116
+ 性爱: sex
117
+ 着衣性爱: clothed_sex
118
+ 水下性爱: underwater_sex
119
+ 双向性爱: spitroast
120
+ 鸡巴连裤袜: cock_in_thighhigh
121
+ 后入式: doggystyle
122
+ 直立跨坐: upright_straddle
123
+ 盘腿: leg_lock
124
+ 传教士: missionary
125
+ 女上位: girl_on_top
126
+ 骑乘位: cowgirl_position
127
+ 反向骑乘: reverse_cowgirl
128
+ 快乐性爱: happy_sex
129
+ 处女: virgin
130
+ 捆绑: shibari
131
+ 奴役: bondage
132
+ BDSM: bdsm
133
+ 枷锁股: pillory_stocks
134
+ 绳子: rope
135
+ 绑住手臂: bound_arms
136
+ 绑住手腕: bound_wrists
137
+ 私处绳: crotch_rope
138
+ 肉球: hogtie
139
+ 青蛙姿势: frogtie
140
+ 悬吊: suspension
141
+ 奴隶: slave
142
+ 张开器: spreader_bar
143
+ 木马: wooden_horse
144
+ 肛门珠: anal_beads
145
+ 假阳具: dildo
146
+ 阴茎环: cock_ring
147
+ 思想控制: mind_control
148
+ 变化: transformation
149
+ 截肢: amputee
150
+ 吞食: vore
151
+ 奶油寿司: nyotaimori
152
+ 跳蛋连裤袜: vibrator_in_thighhighs
153
+ 跳蛋: vibrator
154
+ 双头假阳具: double_dildo
155
+ 魔术棒: hitachi_magic_wand
156
+ 人工阴道: artificial_vagina
157
+ 鸡蛋振动器: egg_vibrator
158
+ 审查: censored
159
+ 未审查: uncensored
160
+ 亚洲人: asian
161
+ 无脸男: faceless_male
162
+ 流血: blood
163
+
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/汉服.yml ADDED
@@ -0,0 +1,170 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 唐风:
2
+ 上杉:
3
+ 召唤唐风: hanfu, tang style outfits,<lora:hanfuTang_v32:0.7>
4
+ 橙色上杉: orange upper shan
5
+ 红色上杉: red upper shan
6
+ 绿色上杉: green upper shan
7
+ 蓝色上杉: blue upper shan
8
+ 粉色上杉: pink upper shan
9
+ 黄色上杉: yellow upper shan
10
+ 白色上杉: white upper shan
11
+ 淡蓝上杉: light blue upper shan
12
+ 浅绿上杉: light green upper shan
13
+ 浅红上杉: light red upper shan
14
+ 青蓝上杉: cyan blue upper shan
15
+ 浅紫上杉: light purple upper shan
16
+ 黑蓝上杉: black with blue upper shan
17
+ 橙白上杉: white with orange upper shan
18
+ 粉黑上杉: pink with black upper shan
19
+ 长上杉:
20
+ 橙色长上杉: orange long upper shan
21
+ 红色长上杉: red long upper shan
22
+ 绿色长上杉: green long upper shan
23
+ 蓝色长上杉: blue long upper shan
24
+ 粉色长上杉: pink long upper shan
25
+ 黄色长上杉: yellow long upper shan
26
+ 白色长上杉: white long upper shan
27
+ 淡蓝长上杉: light blue long upper shan
28
+ 浅绿长上杉: light green long upper shan
29
+ 浅红长上杉: light red long upper shan
30
+ 青蓝长上杉: cyan blue long upper shan
31
+ 浅紫长上杉: light purple long upper shan
32
+ 黑蓝长上杉: black with blue long upper shan
33
+ 橙白长上杉: white with orange long upper shan
34
+ 粉黑长上杉: pink with black long upper shan
35
+ 齐胸破裙:
36
+ 白色破裙: white chest po skirt
37
+ 红色破裙: red chest po skirt
38
+ 绿色破裙: green chest po skirt
39
+ 蓝色破裙: blue chest po skirt
40
+ 粉色破裙: pink chest po skirt
41
+ 紫色破裙: purple chest po skirt
42
+ 彩色破裙: multicolour chest po skirt
43
+ 紫白破裙: purple with white chest po skirt
44
+ 黄白破裙: white with yellow chest po skirt
45
+ 天蓝破裙: blue with white chest po skirt
46
+ 橙白破裙: orange with white chest po skirt
47
+ 灰豆绿破裙: green with white chest po skirt
48
+ 淡黄白破裙: light orange with white chest po skirt
49
+ 粉白破裙: pink with white chest po skirt
50
+ 白偏粉破裙: white with pink chest po skirt
51
+ 齐胸褶裙:
52
+ 白色褶裙: white chest pleated skirt
53
+ 红色褶裙: red chest pleated skirt
54
+ 绿色褶裙: green chest pleated skirt
55
+ 蓝色褶裙: blue chest pleated skirt
56
+ 粉色褶裙: pink chest pleated skirt
57
+ 紫色褶裙: purple chest pleated skirt
58
+ 彩色褶裙: multicolour chest pleated skirt
59
+ 紫白褶裙: purple with white chest pleated skirt
60
+ 黄白褶裙: white with yellow chest pleated skirt
61
+ 天蓝褶裙: blue with white chest pleated skirt
62
+ 橙白褶裙: orange with white chest pleated skirt
63
+ 灰豆绿褶裙: green with white chest pleated skirt
64
+ 淡黄白褶裙: light orange with white chest pleated skirt
65
+ 粉白褶裙: pink with white chest pleated skirt
66
+ 白偏粉褶裙: white with pink chest pleated skirt
67
+ 系带:
68
+ 绿色系带: green waistband
69
+ 黄色系带: yellow waistband
70
+ 红色系带: red waistband
71
+ 粉色系带: pink waistband
72
+ 橙色系带: orange waistband
73
+ 淡蓝系带: light blue waistband
74
+ 绿白系带: light green waistband
75
+ 黄绿系带: green with yellow waistband
76
+ 紫白系带: purple with white waistband
77
+ 红白系带: red with white waistband
78
+ 红黑系带: red with black waistband
79
+ 黄白系带: yellow with white waistband
80
+ 披帛:
81
+ 白色披帛: white pibo
82
+ 橙色披帛: orange pibo
83
+ 黑色披帛: black pibo
84
+ 粉色披帛: pink pibo
85
+ 红色披帛: red pibo
86
+ 紫色披帛: purple pibo
87
+ 浅绿披帛: light green pibo
88
+ 黄白披帛: white with yellow pibo
89
+
90
+ 宋风:
91
+ 短衫:
92
+ 召唤宋风: hanfu, song style outfits,<lora:hanfuSong_v31:0.7>
93
+ 紫色短杉: purple short shan
94
+ 红色短杉: red short shan
95
+ 绿色短杉: green short shan
96
+ 蓝色短杉: blue short shan
97
+ 粉色短杉: pink short shan
98
+ 黄色短杉: yellow short shan
99
+ 白色短杉: white short shan
100
+ 淡蓝短杉: light blue short shan
101
+ 浅绿短杉: light green short shan
102
+ 浅红短杉: light red short shan
103
+ 青蓝短杉: cyan blue short shan
104
+ 浅紫短杉: light purple short shan
105
+ 黑蓝短杉: black with blue short shan
106
+ 黄白短杉: white with yellow short shan
107
+ 浅黄白绿短: light yellow with green with white short shan
108
+ 长衫:
109
+ 紫色长杉: purple long shan
110
+ 红色长杉: red long shan
111
+ 绿色长杉: green long shan
112
+ 蓝色长杉: blue long shan
113
+ 粉色长杉: pink long shan
114
+ 黄色长杉: yellow long shan
115
+ 白色长杉: white long shan
116
+ 淡蓝长杉: light blue long shan
117
+ 浅绿长杉: light green long shan
118
+ 浅红长杉: light red long shan
119
+ 青蓝长杉: cyan blue long shan
120
+ 浅紫长杉: light purple long shan
121
+ 黑蓝长杉: black with blue long shan
122
+ 黄白长杉: white with yellow long shan
123
+ 浅黄白绿长: light yellow with green with white long shan
124
+ 百褶裙:
125
+ 白裙: white pleated skirt
126
+ 红裙: red pleated skirt
127
+ 绿裙: green pleated skirt
128
+ 蓝裙: blue pleated skirt
129
+ 粉裙: pink pleated skirt
130
+ 浅蓝裙: light blue pleated skirt
131
+ 白金裙: white golden pleated skirt
132
+ 渐变绿裙: gradient green pleated skirt
133
+ 半透白裙: translucent white pleated skirt
134
+ 红青渐变: red cyan gradient pleated skirt
135
+ 红绿渐变: red green gradient pleated skirt
136
+ 白绿相间: green with white pleated skirt
137
+ 浅黄绿相间: light yellow with green with white pleated skirt
138
+ 宋抹:
139
+ 橙色宋抹: orange songmo
140
+ 红色宋抹: red songmo
141
+ 绿色宋抹: green songmo
142
+ 蓝色宋抹: blue songmo
143
+ 粉色宋抹: pink songmo
144
+ 黄色宋抹: yellow songmo
145
+ 白色宋抹: white songmo
146
+ 紫色宋抹: purple songmo
147
+ 绿碎花宋抹: green floral songmo
148
+ 紫碎花宋抹: purple floral songmo
149
+ 青碎花宋抹: cyan floral songmo
150
+
151
+
152
+ 明风:
153
+ 上衣:
154
+ 召唤明风: hanfu, ming style outfits,<lora:hanfuMing_v31:0.7>
155
+ 短袄: short coat
156
+ 长袄: long coat
157
+ 裙子:
158
+ 马面裙: mamian skirt
159
+ 领子:
160
+ 交领: overlapping collar
161
+ 圆领: round collar
162
+ 立领: standing collar
163
+ 方领: square collar
164
+ 装饰:
165
+ 云肩: overlapping collar
166
+ 刺绣: embroidery
167
+ 织金: woven gold
168
+ 妆花: makeup flower
169
+ 补服: bufu
170
+
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/环境.yml ADDED
@@ -0,0 +1,124 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 四季朝暮:
2
+ 春天: in spring
3
+ 夏天: in summer
4
+ 秋天: in autumn
5
+ 冬天: in winter
6
+ 黄昏: dusk
7
+ 夜晚: night
8
+ 秋景: (autumn maple forest:1.3),(very few fallen leaves),(path)
9
+ 日月星辰:
10
+ 太阳: sun
11
+ 落日: sunset
12
+ 月亮: moon
13
+ 满月: full_moon
14
+ 星星: stars
15
+ 天空: sky
16
+ 多云: cloudy
17
+ 雨天: rain
18
+ 冰雪: snow,ice
19
+ 雪花: snowflakes
20
+ 闪电: lighting
21
+ 彩虹: rainbow
22
+ 流星雨: meteor shower
23
+ 宇宙: universe
24
+ 天涯海角:
25
+ 大海: sea
26
+ 山丘: hills
27
+ 草地: in a meadow
28
+ 海滩: on the beach
29
+ 水中: underwater
30
+ 海边: over the sea
31
+ 树林: grove
32
+ 沙漠: on a desert
33
+ 高原: plateau
34
+ 悬崖: cliff
35
+ 峡谷: canyon
36
+ 绿洲: oasis
37
+ 竹林: bamboo forest
38
+ 冰川: glacier
39
+ 浮岛: floating island
40
+ 火山: volcano
41
+ 大草原: savanna
42
+ 瀑布: waterfall
43
+ 溪流: stream
44
+ 荒地: wasteland
45
+ 稻田: rice paddy
46
+ 麦田: wheat field
47
+ 花田: flower field
48
+ 花海: flower sea
49
+ 室内场景:
50
+ 室内: indoor
51
+ 窗帘: curtain
52
+ 床: bed
53
+ 浴室: bathroom
54
+ 厕所隔间: toilet stall
55
+ 宅男房间: otaku room
56
+ 自助餐厅: cafeteria
57
+ 教室: classroom
58
+ 俱乐部: clubroom
59
+ 沙龙: salon
60
+ 酒吧: bar
61
+ 居酒屋: izakaya
62
+ 咖啡馆: cafe
63
+ 面包店: bakery
64
+ 便利店: convenience store
65
+ 超市: supermarket
66
+ 书店: bookstore
67
+ 药店: pharmacy
68
+ 剧院: theater
69
+ 电影院: movie theater
70
+ 温室: greenhouse
71
+ 地库: dungeon
72
+ 健身房: gym
73
+ 医务室: infirmary
74
+ 实验室: laboratory
75
+ 图书馆: library
76
+ 工作坊: workshop
77
+ 舞台: stage
78
+ 法庭: courtroom
79
+ 城市建筑:
80
+ 城堡: castle
81
+ 城市: city
82
+ 水上乐园: waterpark
83
+ 旋转木马: carousel
84
+ 摩天轮: ferris wheel
85
+ 水族馆: aquarium
86
+ 动物园: zoo
87
+ 保龄球馆: bowling alley
88
+ 美术馆: art gallery
89
+ 博物馆: museum
90
+ 天文馆: planetarium
91
+ 游泳池: swimming pool
92
+ 体育场: stadium
93
+ 寺庙: temple
94
+ 巴士车站: bus stop
95
+ 火车站: train station
96
+ 喷泉: fountain
97
+ 游乐场: playground
98
+ 市场摊位: market stall
99
+ 电话亭: phone booth
100
+ 铁轨: railroad tracks
101
+ 机场: airport
102
+ 隧道: tunnel
103
+ 背景氛围:
104
+ 新年: new year
105
+ 兔年: year of the rabbit
106
+ 情人节: valentine
107
+ 元宵节: lantern festival
108
+ 夏日祭: summer festival
109
+ 七夕节: tanabata
110
+ 中秋节: mid-autumn festival
111
+ 万圣节: halloween
112
+ 圣诞节: christmas
113
+ 爆炸: explosion
114
+ 蒸汽: water vapor
115
+ 焰火: fireworks
116
+ 落地窗: ceiling window
117
+ 彩色玻璃: colourful glass
118
+ 染色玻璃: stain glass
119
+ 涂鸦墙: Graffiti wall
120
+ 马赛克背景: mosaic background
121
+ 液体背景: liquid background, Sputtered water
122
+ 魔法环: magic circles
123
+ 荧光蘑菇森林: fluorescent mushroom forests background
124
+ 彩色泡泡: (((colorful bubble)))
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/画质和视角.yml ADDED
@@ -0,0 +1,58 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 画质:
2
+ 提高质量: HDR,UHD,8K
3
+ 最佳质量: best quality
4
+ 杰作: masterpiece
5
+ 更多细节: Highly detailed
6
+ 演播室灯光: Studio lighting
7
+ 超精细绘画: ultra-fine painting
8
+ 聚焦清晰: sharp focus
9
+ 物理渲染: physically-based rendering
10
+ 极详细刻画: extreme detail description
11
+ 改善细节: Professional
12
+ 添加鲜艳色彩: Vivid Colors
13
+ 虚化模糊景: Bokeh
14
+ 相机设置: (EOS R8,50mm,F1.2,8K,RAW photo:1.2)
15
+ 老照片: High resolution scan
16
+ 素描: Sketch
17
+ 绘画: Painting
18
+ 视角:
19
+ 动态角度: dynamic angle
20
+ 从左侧视角: from the left
21
+ 从右侧视角: from the right
22
+ 从上方: from above
23
+ 从下面: from below
24
+ 从下往上看: looking up
25
+ 从上往下看: looking down
26
+ 从正上方往下看: top down
27
+ 从侧面往上看: side view up
28
+ 从侧面往下看: side view down
29
+ 从人物的角度往上看: subject look up
30
+ 从人物的角度往下看: subject look down
31
+ 在地面往上看: ground view up
32
+ 在地面往下看: ground view down
33
+ 全景: panoramic view
34
+ 广角宽景: wide shot
35
+ 广角: wide-angle view
36
+ 空中俯瞰视图: aerial view
37
+ 在高处往下看: bird view
38
+ 鸟瞰视角: bird’s-eye view
39
+ 蚯蚓视角: worm’s eye view
40
+ 带有角度的视角: angled
41
+ 低角度视角: low-angle view
42
+ 俯视视角: top-down
43
+ 放大镜效果: zoomed in
44
+ 缩小镜效果: zoomed out
45
+ 俯视: top-down view
46
+ 高角度视角: high-angle view
47
+ 平视: eye level view/level gaze/straight gaze
48
+ 特写: close-up view
49
+ 极端特写: extreme close-up view
50
+ 视线:
51
+ 面对画面或观众: looking at viewer
52
+ 两个角色对视: looking at another
53
+ 看着别的方: looking away
54
+ 回头看: looking back
55
+ 向上看: looking up
56
+
57
+
58
+
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/艺术风格.yml ADDED
@@ -0,0 +1,68 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 艺术风格:
2
+ 8bit游戏: 8 Bit Game
3
+ 80动画: 1980s anime
4
+ 迪士尼电影: disney movie
5
+ 哥特摇滚: goth
6
+ 80电影: 80s movie
7
+ 泡泡龙: bubble bobble
8
+ 皮克斯动画: style of Pixar
9
+ 宝丽来艺术: Polaroid art
10
+ 万花筒摄影: Kaleidoscope Photography
11
+ 欧泊渲染: opal render
12
+ 色谱图: chemigram
13
+ 吉卜力风格: Studio Ghibli
14
+ 梦幻: dreamlike
15
+ 签绘风格: (faux traditional media)
16
+ 原神冲击: genshin impact
17
+ 碧蓝航线: azur lane
18
+ 舰队收藏: kantai collection
19
+ 边缘行者: rebecca (cyberpunk)
20
+ 电锯人: chainsaw man
21
+ 魔法旋涡: Magic Vortex
22
+ 柴油朋克: ((dieselpunk))
23
+ 四格: 4koma
24
+ 杂志扫描: magazine scan
25
+ 专辑封面: album cover
26
+ 线条变粗: (lineart)
27
+ 蒸汽波: synthwave
28
+ 洛可可: (illustration),(paper figure),(lococo),((impasto)),(shiny skin)
29
+ 艺术类型:
30
+ 单色图片: monochrome
31
+ 拼贴艺术: Collage
32
+ 彩色玻璃: Dalle de verre
33
+ 像素画: pixel art
34
+ 瓷画: Encaustic painting
35
+ 水墨画: Ink wash painting
36
+ 铜版雕刻: Mezzotint
37
+ 剪影: silhouette
38
+ 插画: illustration
39
+ 水彩画: (((ink))), ((watercolor))
40
+ 浮世绘: illustration,(((ukiyoe))),((sketch)),((japanese_art))
41
+ 中国风: ((wash painting)),((ink s...
42
+ 油画: ((dyeing)),((oil painting)),((impasto))
43
+ 黑白草图: (posing sketch), (monochrome)
44
+ 手画草稿: sketch
45
+ 铅笔速写: (monochrome), (gray scale), (pencil sketch lines
46
+ 彩铅画: (watercolor pencil)
47
+ 艺术派系:
48
+ 新艺术主义: ((art nouveau))
49
+ 古典主义: ((classicism))
50
+ 未来主义: ((futurism))
51
+ 达达主义: ((Dadaism))
52
+ 抽象艺术: ((abstract art))
53
+ ASCII艺术: ((ASCII art))
54
+ 艺术家风格:
55
+ 穆夏风格: ((alphonse mucha))
56
+ 莫奈风格: ((Monet style))
57
+ 光照:
58
+ 轮廓光: rim light
59
+ 体积光: Volumetric Lighting
60
+ 霓虹灯: glowing neon lights
61
+ 电影级光照: Cinematic Lighting
62
+ 透镜光晕: lens flare
63
+ 金属光泽: metallic luster
64
+ 氛围光照: moody lighting
65
+ 丁达尔效应: Tyndall effect
66
+ 漏光光效: light leaks
67
+ 背景光: background light
68
+ 自然光: available light
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/负面.yml ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 负面提示:
2
+ NSFW: nsfw,logo,text
3
+ embeddings: badhandv4,EasyNegative,ng_deepnegative_v1_75t,rev2-badprompt,verybadimagenegative_v1.3,negative_hand-neg,bad-picture-chill-75v
4
+ 变异手指: mutated hands and fingers
5
+ 畸形的: deformed
6
+ 解剖不良: bad anatomy
7
+ 毁容: disfigured
8
+ 脸不好: poorly drawn face
9
+ 变异的: mutated
10
+ 多余肢体: extra limb
11
+ 丑陋: ugly
12
+ 手画得差: poorly drawn hands
13
+ 缺少的肢体: missing limb
14
+ 漂浮的四肢: floating limbs
15
+ 肢体不连贯: disconnected limbs
16
+ 畸形的手: malformed hands
17
+ 脱离焦点: out of focus
18
+ 长颈: long neck
19
+ 身体长: long body
20
+ 全选: nsfw,logo,text,badhandv4,EasyNegative,ng_deepnegative_v1_75t,rev2-badprompt,verybadimagenegative_v1.3,negative_hand-neg,mutated hands and fingers,poorly drawn face,extra limb,missing limb,disconnected limbs,malformed hands,ugly
21
+
22
+
23
+
24
+
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags/魔法系.yml ADDED
@@ -0,0 +1,68 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 魔法1.0:
2
+ 水魔法: ((water drops)),wet clothes,((beautiful detailed water)),((floating)),dynamic angle
3
+ 冰魔法: beautiful detailed glow, (detailed ice), beautiful detailed water
4
+ 冰系改: beautiful detailed glow,detailed ice,beautiful detailed water,(floating palaces:1.2),(ice crystal texture wings),(Iridescence and rainbow hair:2.5)
5
+ 星冰乐: beautiful detailed glow,detailed ice,beautiful detailed water, (floating palaces:1.3),(((ice crystal texture wings)))
6
+ 森林冰: ((detailed beautiful snow forest with trees)), ((snowflakes)), floating
7
+ 结晶法: (((crystals texture Hair))),((beautiful detailed glass hair)),((glass shaped texture hand)),((crystallize texture body)),gem body,hands as clear as jewels,crystallization of clothes,((crystals texture skin)),sparkle, lens flare, light leaks,broken glass,detailed glass shaped clothes,beautiful detailed gemstone sky, gemstone sea, crystals texture flowers,((detailed crystallized clothing))
8
+ 核爆法: beautiful detailed glow,((flames of war)),(((nuclear explosion behide)))
9
+ 风魔法: ((breeze)), flying splashes, flying petals, wind
10
+ 流沙法: ((surrounded by heavy floating sand flow and floating sharp stones)),((((ink)))),((illustration)),((watercolor))
11
+ 雷电法: (detailed light), ((lightning in hand)),lightning surrounds,(((lightning chain)))
12
+ 圣光法: (sunlight),(angel),dynamic angle, floating, wing, halo, floating white silk,(Holy Light),silver stars
13
+ 苇名法: beautiful detailed pampas grass field, open hakama, surrounded by floating sakura, yellow full moon, beautiful detailed dark midnight sky, messy white long hair
14
+ 自然法: beautiful and delicate water, the finest grass, very delicate light, nature, painting, water spray, breeze, flowers and grass meadow, near the water edge, (sunset, starry sky in a circle), randomly distributed clouds, river, splashing water, falling petals
15
+ 森林法: (detailed light) , feather, leaves, nature, (sunlight), river, (forest),(bloom)
16
+ 虹彩法: floating and rainbow long hair,Iridescence and rainbow, beautiful detailed starry sky
17
+ 暗锁法: chain ring, chain storm, dark chain,((wholeblack bloomer)), darkside, night, deep dark, darkness, ((dark clouds)),((ruins)),shadow, death garden
18
+ 火烧云: beautiful detailed glow, floating ashes, beautiful and detailed explosion, red moon, fire, fire cloud, wings on fire, a cloudy sky, smoke of gunpowder, burning, black dress, dove of peace, (floating cloud:1.2)
19
+ 城堡法: beautiful detailed glow, detailed ice, beautiful detailed water, (magic circle:1.2), (floating palaces:1.3)
20
+ 黄昏法: (water bloom), (delicate glow), (breeze), long Flowers meadow,(((sunset)), (less stars form a circle), randomly distributed clouds, (rivers), (willows with branches falling into the water)
21
+ 泡泡法: ((colorful bubble)),(floating),detailed light
22
+ 蔷薇法: ((rose)), (vine), cage, bandage, red rope, (detail light), falling rose petals
23
+ 星空法: (starry tornado:1.4), starry Nebula, beautiful detailed sky
24
+ 月亮法: ((moon)), starry sky, (lighting particle), fog, snow,(bloom)
25
+ 雪月法: beautiful detailed glow, detailed ice, beautiful detailed water, (cold full moon), snowflake, (floating cloud:1.2)
26
+ 森火法: ((burning forest)), spark, light leaks, burning sky, flame, flames burning around, (flying sparks)
27
+ 废土法: ((destroyed)),explosion, buildings in disarray, The residual eaves DuanBi, cumulus, mouldy, floating, wind, Dead end machine,(broken robot),(Mechanical robot girl), in the rubble of a devastated city
28
+ 战甲法: mecha clothes, robot girl, sliver bodysuit,((sliver)) and (broken) body
29
+ 黄金法: Extremely gorgeous metal style, Metal crown with ornate stripes, Various metals background, Sputtered molten iron, floating hair, Hair like melted metal, Clothes made of silver, Clothes with gold lace, flowing gold and silver, everything flowing and melt, flowing iron, flowing silver, lace flowing and melt
30
+ 机娘法: mecha clothes, robot girl
31
+ 死灵法: ink,(((bone))), (((ribs))), rose, black hair, blue eyes, greyscale, no shadow, simple background, bright skin
32
+ 水晶法: (((gorgeous crystal armor))),(((crystal wings))),((altocumulus)),(clear_sky),(snow mountain),((flowery flowers)),(flowery bubbles),cloud map plane, crystal, crystal poppies,Brilliant light, thick_coating, glass tint,(watercolor)
33
+ 水森法: ((an extremely delicate and beautiful)),floating, (detailed wet clothes), (detailed light),feather, nature, (sunlight), river, floating palace, beautiful and delicate water,(bloom),(shine)
34
+ 冰火法: (blue spark),(red and blue hair),blue eyes, burning sky,flame,Rainbow in the sky,((Flames burning ice)),(((fire butterflies))),(((ice crystal texture wings))),(Flying sparks),(detailed ice),((a lot of luminous ice crystals)),((burning feathers)),(feathers made of ice),(frozen feathers),(((ice and fire together)))
35
+ 龙骑士: (anger), dragon horns, (silver armor), metal, complex pattern, cape, indifference
36
+ 坠落法: ((full body)),(helpless),tear, crying,(((((falling from the sky))))),((Weathering With You)),((falling)),((face towards the sky)),(hair flows upwards),((disheveled hair)),(1 girl), floating, beautiful detailed sky
37
+ 水下法: ((underwater)),(beautiful detailed water),((coral)),dynamic angle, floating,(detailed light),floating hair,(splash),((fishes)),leaves dress, feather, nature,(sunlight),(underwater forest),(bloom),(detailed glow),drenched, seaweed, fish,(((Tyndall effect)))
38
+ 秘境法: (extremely detailed CG unity 8k wallpaper),(((masterpiece))), (((best quality))), ((ultra-detailed)), (best illustration),(best shadow), ((an extremely delicate and beautiful)),dynamic angle,floating, fairyland,dynamic angle,sea of flowers,beautiful detailed garden,wind,classic,spring, (detailed light),feather, nature, (sunlight), river, forest,(((floating palace))),((the best building)),beautiful and delicate water,(painting),(sketch),(bloom),(shine)
39
+ 摄影法: (((masterpiece))), ((the best quality, super fine illustrations, beautiful and delicate water)), ((very delicate light)), ((nature, painting)), ((fine lighting, more transparent stars, high-quality snowflakes, high-quality mountains, very fine 8KCG wallpapers)), (plateau), (((snow mountain))), sunrise, randomly distributed clouds, (snow field), cliff, ((rotating star sky)), ((lake in mountain stream)), luminous particles
40
+ 摩登法: 1980s (style),simple background, retro artstyle
41
+ 血魔法: (white hair), red long hair, red eyes, (full body), (((with sword))), angry face, (beautiful detailed eyes), Blood drop,Blood fog, floating hair, disheveled hair, Splashing blood,(Bloodstain)
42
+ 唤龙术: ((dragon)), ((dragon background))
43
+ 战姬法: hair fluttering in the wind,((mechanical arm armor)),((mechanical body armor)),riding motor, bodysuit,((ruins of city in war, fire, burning cars, burning buildings)),air force fleet in the sky
44
+ 龙机法: mecha clothes, robot girl, sliver bodysuit, dragon wings, ((a dragon stands behind the girl)), beautiful detailed sliver dragon armor
45
+ 星蝶术: ((Beautiful butterflies in detail)),((Beautiful stars in detail)),(((halter dress ))),particle,(Starry sky in beautiful detail),(Hazy fog),(Ruins of beautiful details),(((Standing on the surface of the sea)))
46
+ 学院法: blonde wavy hair, (shiny long hair), ((Gothic Lolita)), blue white skirt, ((short skirt)), black Headdress, bowknot, (((hair ornament))), (hair flower), Lace, cross-laced footwear, ribbon-trimmed sleeves, building architecture, ((gothic architecture)), starry sky, outdoors, church, (castle)
47
+ 星霞海: walking, waves, wind,(((glistening light of waves))),(detailed sunset glow),(floating flow),((coral)),(Luminous),coast,(floating colorful bubbles),beautiful detailed sky,(fluorescence),detailed shadow,(conch),beautiful detailed water, starfish, meteor, rainbow,(seabirds),(glinting stars), (glowworm),(splash),detailed cloud, shell,(fireworks)
48
+ 冬雪法: beautiful detailed sky, night, stars, (red plum blossom),((winter)),(((snowflakes))), ((red and white flowers)),(starry sky),(sitting),((colorful)),scenery, lantern,(starfall)
49
+ 魔法1.5:
50
+ 万物熔炉: ((((melt)))),(((((black and white melt))))),(((wear Black and white Taoist robes))),((((gold and silver lace)))),(((gold and silver lace lace))),(((flowing ((black)) and white background))),extremely detailed gorgeous tiara
51
+ 暗鸦法: Floating black ashes, Beautiful and detailed black, red moon, ((The black clouds)), (black Wings) , a black cloudy sky, burning, black dress, ((Black fog)), Red eyes, (black smoke), ((Black feathers floating in the air)),bat, (floating black cloud:1.5),
52
+ 花火基础: dynamic angle, finely detail, (bloom), (shine), glinting stars, ((((best detailed fireworks)))), ((((depth of field)))), (((hanabi))),(((backlight))),
53
+ 星之彩: stars in the eyes, messy floating hair, colored inner hair, Starry sky adorns hair, (lots of big colorful Bubble), (pearl), (Galaxy), depth of field
54
+ 沉入星海: stars in the eyes, messy floating hair, colored inner hair, Starry sky adorns hair, depth of field
55
+ 百溺法: dynamic angle, detailed wet clothes, blank stare, overexplosure, floating, black long straight, red eyes, aqua eyes, gradient eyes, ((blood)), white dress, frills, ((expressionless)), extremely beautiful detailed water, ((lying on the lake)), (bloodred water:1.5), (red background:1.3)
56
+ 辉煌阳光法: ((messy hair)),(grassland),(yellow eyes),incredibly absurdres,(gold hair),floating hair,Large number of environments,the medieval ,grace,prospect,water eyes,wind,breeze,god ray,lawn,Mountains and lakes in the distance,The sun shines through the trees,A vast expanse of grassland
57
+ 星鬓法: Starry sky adorns hair, sparkling anime eyes,beautiful detailed stars,blighting stars,emerging dark purple across with white hair,multicolored hair,beautiful detailed sky, beautiful detailed water, cinematic lighting, dramatic angle,
58
+ 森罗法: There are many scattered luminous petals,Hidden in the light yellow flowers,Depth of field,Many flying drops of water,Many scattered leaves,branch ,angle ,contour deepening,cinematic angle
59
+ 星天使: sunlight, extremely light, extremely clothes, Holy Light, dynamic angle, Light particle, very long hair, white hair, yellow eyes, glowing eyes, expressionless, ((light smile)), ((((white Tulle skirt)))), white silk, looking at viewer, angel wings, large wings, multiple wings, angel halo, (((starry sky))), dusk sky, Floating light spot, Lots of feathers
60
+ 黄金律: blonde hair, yellow eyes, white skin, mature female, sunrise, golden sky, magnificent architecture, beautiful detailed sky, overexposure, delicate gold metal decorations
61
+ 机械姬: mechanical prosthesis,mecha coverage,emerging dark purple across with white hair,fluorescent purple,cool movement,rose red eyes,beatiful detailed cyberpunk city, hd semirealistic anime cg concept art digital painting
62
+ 人鱼法: (incredibly absurdres), (highly detailed beautiful fishtail:1.6), (((human hands))), (the lower body is a fish:1.9)AND(no human thigh:1.2), seaweed, (full body), (white seashell), (curved and slender fish tail), (the lower body is bare:1.1), {beautiful tailfin}, ((underwater)), (illustration), detailed water, ((fishes)), (floating), watercolor (medium), (small whirlpool), ((The sensation of water flowing)), (detailed scales on a mermaid)
63
+ 末日: Blood Mist, background Urban rooftop,despair,Blood Cherry Blossom,torn clothes,crying with eyes open,solo,Blood Rain,bandages,Gunpowder smoke,beautiful deatailed shadow, Splashing blood,dust,tyndall effect
64
+ 碎梦: Space opera,Space port,robot arm,elbow gloves,night,glisten,stare,cyberpunk,((((citylight)))),science fiction,bodysuit,Mechanical armor headdress,(bare shoulders)
65
+ 幻碎梦: dynamic angle,rainbow hair,detailed cute anime face,((loli)),flower,cry,water,corrugated,flowers tire,broken glass,(broken screen),atlantis,transparent glass
66
+ 血改法: (white hair),(((red streaked hair))), red eyes, (((full body))),(red hair), (((((Hold a red sword))))), (angry face),((Blood drop)),((Blood fog)),light shafts, soft focus, ((Splashing blood))),Long hair,((Bloodstain)),Fighting stance,{{{{{watercolor (medium)}}}},(((masterpiece))),((white clock)),((ultradetailed)),((Covered in blood)),flowing hair,Exquisite Flame,dynamic angle, floating, (shine), extremely delicate and beautiful girls, bright skin, lying red petals,Holy lighting
67
+ 留影术: dramatic shadows,black and white,monochrome,{{comic}},cross necklace,Cassock
68
+ 飘花法: ((ink)),(water color),bloom effect,detailed beautiful grassland with petal,flower,butterfly,necklace,smile,petal,(((surrounded by heavy floating petal flow)))
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags_examples/人.yml ADDED
@@ -0,0 +1,66 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 対象:
2
+ - 1girl
3
+ - 1boy
4
+ - 1other
5
+ - multiple girls
6
+
7
+ 年齢:
8
+ ティーン: teen
9
+ ローティーン: early teen
10
+ 大人: adult
11
+ 老人: elder
12
+ 子供: child
13
+ 幼稚園児: kindergartener
14
+ 幼児: toddler
15
+ ロリ: loli
16
+ ショタ: shota
17
+
18
+ 肌の色:
19
+ 白: white skin
20
+ 色白: pale skin
21
+ 褐色: dark skin
22
+ 明るい: shiny skin
23
+ 有色: colored skin
24
+
25
+ 肌の装飾:
26
+ 日焼け: tan
27
+ 日焼け跡: tanlines
28
+ 入れ墨: tattoo
29
+ 油: oil
30
+
31
+ 体形:
32
+ アスリート: athlete
33
+ モデル: model
34
+ スレンダー: slender
35
+ グラマー: glamor
36
+ ムチムチ: plump
37
+ 太い: fat
38
+ 大柄: tall
39
+ 小柄: petite
40
+ チビ: chibi
41
+ 妊娠: pregnant
42
+ 筋肉質: muscular
43
+ 細ウェスト: narrow waist
44
+ 大きな尻: wide hips
45
+
46
+ 胸:
47
+ まな板: flat chest
48
+ 貧乳: small breasts
49
+ 普通: medium breasts
50
+ 巨乳: large breasts
51
+ 爆乳: huge breasts
52
+ 垂れ乳: hanging breasts
53
+
54
+ 体のパーツ:
55
+ 腋: armpits
56
+ 鎖骨: collarbone
57
+ へそ: navel
58
+ 尻: ass
59
+ 太もも: thighs
60
+
61
+ 翼:
62
+ 翼: wings
63
+ コウモリの翼: bat wings
64
+ 蝶の翼: butterfly wings
65
+ 悪魔の翼: demon wings
66
+ ドラゴンの翼: dragon wings
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags_examples/人_顔.yml ADDED
@@ -0,0 +1,78 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 目:
2
+ 色:
3
+ 黒: black eyes
4
+ 白: white eyes
5
+ 赤: red eyes
6
+ 青: blue eyes
7
+ 緑: green eyes
8
+ 紫: purple eyes
9
+ 銀色: silver eyes
10
+ 金色: golden eyes
11
+ 灰色: gray eyes
12
+ 水色: aqua eyes
13
+ 茶色: brown eyes
14
+ ピンク: pink eyes
15
+ オレンジ: orange eyes
16
+ オッドアイ: heterochromia
17
+ 状態:
18
+ 半目: half-closed eyes
19
+ 閉じた目: closed eyes
20
+
21
+ 耳:
22
+ エルフ耳: elf ears
23
+ ケモミミ: animal ears
24
+ ネコミミ: cat ears
25
+ キツネ耳: fox ears
26
+
27
+ 表情:
28
+ 笑い: smile
29
+ 悲しい笑い: sad smile
30
+ 邪悪な笑い: evil smile
31
+ 天使の笑い: angelic smile
32
+ 笑い(強制): forced smile
33
+ 蠱惑的な笑み: seductive smile
34
+ 歯を見せる笑い: grin
35
+ 歯を見せる笑い(邪悪): evil grin
36
+ ニヤニヤ: smirk
37
+ 怒り: angry
38
+ 悲しみ: sad
39
+ 泣く: crying
40
+ 涙: tears
41
+ 恐怖: scared
42
+ 真剣: serious
43
+ イライラ: annoyed
44
+ 闇堕ち: dark persona
45
+ ドヤ顔: doyagao
46
+ 頬染め: blush
47
+ 頬染め(強): full-face blush
48
+ 退屈: bored
49
+ 罪悪感: guilt
50
+ 無感情: expressionless
51
+ 決意: determined
52
+ キス顔: incoming kiss
53
+ 失望: disappointed
54
+ 軽蔑: disdain
55
+ 嫉妬: envy
56
+ 嫌悪: disgust
57
+ 困惑: confused
58
+ 困り眉: troubled eyebrows
59
+ 怒り眉: v-shaped eyebrows
60
+ 羞恥: embarrassed
61
+ いたずら顔: naughty
62
+ 眠気: sleepy
63
+
64
+ 口:
65
+ 唇: lip
66
+ 開いた口: open mouth
67
+ 閉じた口: closed mouth
68
+ 歯: teeth
69
+ 出っ歯: buck teeth
70
+ 上の歯: upper teeth
71
+ 丸い歯: round teeth
72
+ ギザギザ歯: clenched teeth
73
+ 牙: fang
74
+ 舌舐めずり: licking lips
75
+ 舌だし: tongue out
76
+ 長舌: long tongue
77
+ てへぺろ: tehepero
78
+ よだれ: saliva
sdweb-easy-prompt-selector/sdweb-easy-prompt-selector/tags_examples/人_髪.yml ADDED
@@ -0,0 +1,81 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ 髪色:
2
+ 単色:
3
+ 黒髪: black hair
4
+ 金髪: blonde hair
5
+ 茶髪: brown hair
6
+ 赤髪: red hair
7
+ ピンク髪: pink hair
8
+ 青髪: blue hair
9
+ 水色髪: aqua hair
10
+ 緑髪: green hair
11
+ 紫髪: purple hair
12
+ オレンジ髪: orange hair
13
+ 銀髪: silver hair
14
+ 灰髪: gray hair
15
+ 白髪: white hair
16
+ 複数色:
17
+ マルチカラー: multicolored hair
18
+ メッシュ: streaked hair
19
+ グラデーション: gradient hair
20
+ インナーカラー: colored inner hair
21
+ スプリットカラー: split-color hair
22
+
23
+ 髪型:
24
+ 長さ:
25
+ ベリーショート: very short hair
26
+ ショートヘア: short hair
27
+ ミディアムヘア: medium hair
28
+ ロングヘアー: long hair
29
+ 超ロングヘアー: very long hair
30
+ 超超ロングヘアー: absurdly long hair
31
+ 種類:
32
+ くせ毛: messy hair
33
+ 直毛: straight hair
34
+ ウェーブヘア: wavy hair
35
+ 外ハネ: flipped hair
36
+ 非対称: asymmetrical hair
37
+ ポニーテール:
38
+ ポニーテール: ponytail
39
+ ハイポニーテール: high ponytail
40
+ ローポニーテール: low ponytail
41
+ フロントポニーテール: front ponytail
42
+ サイドポニーテール: side ponytail
43
+ スプリットポニーテール: split ponytail
44
+ 畳みポニーテール: folded ponytail
45
+ ショートポニーテール: short ponytail
46
+ ツインテール:
47
+ ツインテール: twintails
48
+ ローツインテール: low twintails
49
+ ショートツインテール: short twintails
50
+ トリプルテール: tri tails
51
+ クアッドテール: quad tails
52
+ 三つ編み: braid
53
+ ハーフアップ: half updo
54
+ ワンサイドアップ: one side up
55
+ ツーサイドアップ: two side up
56
+ マルチタイヘアー: multi-tied hair
57
+ 頭頂部結び: topknot
58
+ 巻き毛: curly hair
59
+ 縦ロール: drill hair
60
+ ツイン縦ロール: twin drills
61
+ リングレット: ringlets
62
+ 弓型髪: bow-shaped hair
63
+ お団子頭: hair bun
64
+ 輪っか髪: hair rings
65
+ ドレッドヘア: dreadlocks
66
+
67
+ 前髪:
68
+ パッツン: blunt bangs
69
+ 非対称: asymmetrical bangs
70
+ 両目隠れ: hair over eyes
71
+ 片目隠れ: hair over one eye
72
+ センター分け: parted bangs
73
+ センター分け(ゆるめ): swept bangs
74
+ 目の間: hair between eyes
75
+ インテーク: hair intakes
76
+ 触角: sidelocks
77
+
78
+ 他:
79
+ 横髪: hair flaps
80
+ アホ毛: ahoge
81
+ アンテナ: antenna hair