@bendyline/gilde 0.2.2 → 0.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/authoring/chat-models/btl4-35b-q4.json +1 -0
- package/authoring/chat-models/glm-5.3-flash-320b-q2.json +5 -4
- package/authoring/chat-models/minicpm-v4.7-35b-a3b-q4.json +3 -1
- package/authoring/chat-models/nemotron3.5-bolt-74b-iq2.json +145 -0
- package/authoring/chat-models/nemotron3.5-super-vl-120b-nvfp4.json +143 -0
- package/data/chat-models/bt/btl4-35b-q4/manifest.json +1 -0
- package/data/chat-models/gl/glm-5.3-flash-320b-q2/manifest.json +5 -4
- package/data/chat-models/gl/glm-5.3-flash-320b-q2/versions/1.0.2/manifest.json +27 -0
- package/data/chat-models/index.json +1 -1
- package/data/chat-models/mi/minicpm-v4.7-35b-a3b-q4/manifest.json +2 -1
- package/data/chat-models/mi/minicpm-v4.7-35b-a3b-q4/versions/1.0.0/manifest.json +1 -0
- package/data/chat-models/ne/nemotron3.5-bolt-74b-iq2/manifest.json +157 -0
- package/data/chat-models/ne/nemotron3.5-bolt-74b-iq2/versions/1.0.0/manifest.json +30 -0
- package/data/chat-models/ne/nemotron3.5-super-vl-120b-nvfp4/manifest.json +156 -0
- package/data/chat-models/ne/nemotron3.5-super-vl-120b-nvfp4/versions/1.0.0/manifest.json +28 -0
- package/data/chat-models/raw-index.json +1 -1
- package/data/craftbook-templates/index.json +1 -1
- package/data/craftbook-templates/raw-index.json +1 -1
- package/data/craftbook-templates/st/status-report/versions/1.0.4/craftbook.json +314 -0
- package/data/craftbook-templates/st/status-report/versions/1.0.4/test.json +110 -0
- package/data/project-types/index.json +1 -1
- package/data/project-types/raw-index.json +1 -1
- package/data/project-types/so/social-feed/versions/1.0.2/about.md +19 -0
- package/data/project-types/so/social-feed/versions/1.0.2/manifest.json +348 -0
- package/data/project-types/so/social-feed/versions/1.0.2/mission.md +10 -0
- package/data/project-types/so/social-feed/versions/1.0.2/pages/dashboard/index.html +754 -0
- package/data/project-types/so/social-feed/versions/1.0.2/posts/index.json +4 -0
- package/data/project-types/so/social-feed/versions/1.0.2/voice-guide.md +22 -0
- package/data/project-types/wo/word-clues/versions/1.0.1/about.md +7 -0
- package/data/project-types/wo/word-clues/versions/1.0.1/game.json +14 -0
- package/data/project-types/wo/word-clues/versions/1.0.1/manifest.json +205 -0
- package/data/project-types/wo/word-clues/versions/1.0.1/mission.md +3 -0
- package/data/project-types/wo/word-clues/versions/1.0.1/pages/board/index.html +399 -0
- package/data/project-types/wo/word-clues/versions/1.0.1/words.json +216 -0
- package/package.json +2 -1
- package/schemas/chat-model-version.schema.json +23 -0
|
@@ -0,0 +1,399 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="utf-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
6
|
+
<meta name="gezel-demo" content="standalone" />
|
|
7
|
+
<title>Word Clues</title>
|
|
8
|
+
<style>
|
|
9
|
+
:root {
|
|
10
|
+
color-scheme: light dark;
|
|
11
|
+
--bg: #faf7f2;
|
|
12
|
+
--card: #fff;
|
|
13
|
+
--ink: #2b2620;
|
|
14
|
+
--muted: #7a7166;
|
|
15
|
+
--accent: #b5651d;
|
|
16
|
+
--track: #ece5da;
|
|
17
|
+
--good: #4a7c59;
|
|
18
|
+
--good-bg: #e3efe6;
|
|
19
|
+
--warn: #a4552e;
|
|
20
|
+
--warn-bg: #f6e3d8;
|
|
21
|
+
}
|
|
22
|
+
:root[data-theme='dark'] {
|
|
23
|
+
--bg: #1c1a17;
|
|
24
|
+
--card: #262320;
|
|
25
|
+
--ink: #efe9e0;
|
|
26
|
+
--muted: #a59a8c;
|
|
27
|
+
--accent: #e0894a;
|
|
28
|
+
--track: #3a352f;
|
|
29
|
+
--good: #7fae8d;
|
|
30
|
+
--good-bg: #26352a;
|
|
31
|
+
--warn: #d98a63;
|
|
32
|
+
--warn-bg: #3b2a21;
|
|
33
|
+
}
|
|
34
|
+
@media (prefers-color-scheme: dark) {
|
|
35
|
+
:root:not([data-theme='light']) {
|
|
36
|
+
--bg: #1c1a17;
|
|
37
|
+
--card: #262320;
|
|
38
|
+
--ink: #efe9e0;
|
|
39
|
+
--muted: #a59a8c;
|
|
40
|
+
--accent: #e0894a;
|
|
41
|
+
--track: #3a352f;
|
|
42
|
+
--good: #7fae8d;
|
|
43
|
+
--good-bg: #26352a;
|
|
44
|
+
--warn: #d98a63;
|
|
45
|
+
--warn-bg: #3b2a21;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
* { box-sizing: border-box; }
|
|
49
|
+
body {
|
|
50
|
+
margin: 0;
|
|
51
|
+
font: 15px/1.45 system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
|
|
52
|
+
background: var(--bg);
|
|
53
|
+
color: var(--ink);
|
|
54
|
+
padding: 1.25rem 0.75rem;
|
|
55
|
+
}
|
|
56
|
+
main { max-width: 560px; margin: 0 auto; }
|
|
57
|
+
h1 {
|
|
58
|
+
font-family: Georgia, 'PT Serif', 'Times New Roman', serif;
|
|
59
|
+
font-size: 1.35rem;
|
|
60
|
+
font-weight: 600;
|
|
61
|
+
margin: 0 0 0.15rem;
|
|
62
|
+
}
|
|
63
|
+
.sub { color: var(--muted); font-size: 0.9rem; margin: 0 0 0.85rem; }
|
|
64
|
+
.clue {
|
|
65
|
+
background: var(--card);
|
|
66
|
+
border: 1px solid var(--track);
|
|
67
|
+
border-radius: 10px;
|
|
68
|
+
padding: 0.65rem 0.85rem;
|
|
69
|
+
margin-bottom: 0.75rem;
|
|
70
|
+
min-height: 3.2rem;
|
|
71
|
+
}
|
|
72
|
+
.clue strong { font-size: 1.15rem; letter-spacing: 0.04em; }
|
|
73
|
+
.clue .muted { color: var(--muted); font-size: 0.85rem; }
|
|
74
|
+
.grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0.4rem; }
|
|
75
|
+
button {
|
|
76
|
+
font: inherit;
|
|
77
|
+
color: var(--ink);
|
|
78
|
+
background: var(--card);
|
|
79
|
+
border: 1px solid var(--track);
|
|
80
|
+
border-radius: 6px;
|
|
81
|
+
min-height: 48px;
|
|
82
|
+
padding: 0.35rem 0.25rem;
|
|
83
|
+
cursor: pointer;
|
|
84
|
+
}
|
|
85
|
+
button:hover:not(:disabled) { border-color: var(--accent); }
|
|
86
|
+
button:disabled { cursor: default; }
|
|
87
|
+
.cell { font-size: 0.85rem; overflow-wrap: anywhere; text-transform: lowercase; }
|
|
88
|
+
.cell.target { background: var(--good-bg); border-color: var(--good); color: var(--good); }
|
|
89
|
+
.cell.trap { background: var(--warn-bg); border-color: var(--warn); color: var(--warn); }
|
|
90
|
+
.cell.neutral { color: var(--muted); text-decoration: line-through; }
|
|
91
|
+
.cell.hidden-target { border-style: dashed; border-color: var(--good); }
|
|
92
|
+
.actions { display: flex; gap: 0.5rem; margin-top: 0.75rem; flex-wrap: wrap; }
|
|
93
|
+
.actions button { padding: 0.35rem 0.9rem; }
|
|
94
|
+
.stats { color: var(--muted); font-size: 0.85rem; margin-top: 0.75rem; }
|
|
95
|
+
.banner {
|
|
96
|
+
border: 1px solid var(--accent);
|
|
97
|
+
border-radius: 6px;
|
|
98
|
+
padding: 0.45rem 0.7rem;
|
|
99
|
+
font-size: 0.85rem;
|
|
100
|
+
margin-bottom: 0.75rem;
|
|
101
|
+
}
|
|
102
|
+
.banner[hidden] { display: none; }
|
|
103
|
+
.demo-banner {
|
|
104
|
+
display: flex;
|
|
105
|
+
align-items: center;
|
|
106
|
+
justify-content: space-between;
|
|
107
|
+
gap: 0.75rem;
|
|
108
|
+
margin: 0 0 0.85rem;
|
|
109
|
+
padding: 0.5rem 0.65rem;
|
|
110
|
+
border: 1px solid var(--accent);
|
|
111
|
+
border-radius: 6px;
|
|
112
|
+
background: color-mix(in srgb, var(--card) 88%, var(--accent));
|
|
113
|
+
color: var(--ink);
|
|
114
|
+
font-size: 0.8rem;
|
|
115
|
+
}
|
|
116
|
+
.demo-banner[hidden] { display: none; }
|
|
117
|
+
.demo-reset { flex: none; min-height: 44px; padding: 0.25rem 0.6rem; }
|
|
118
|
+
</style>
|
|
119
|
+
</head>
|
|
120
|
+
<body>
|
|
121
|
+
<main>
|
|
122
|
+
<div class="demo-banner" data-gezel-demo-banner hidden>
|
|
123
|
+
<span><strong>Demo mode</strong>: sample data stays in this page.</span>
|
|
124
|
+
<button type="button" class="demo-reset" onclick="location.reload()">Reset demo</button>
|
|
125
|
+
</div>
|
|
126
|
+
<h1>Word Clues</h1>
|
|
127
|
+
<p class="sub" id="sub">Find your six words. Steer clear of the trap.</p>
|
|
128
|
+
<p class="banner" id="notice" hidden></p>
|
|
129
|
+
<div class="clue" id="clue" aria-live="polite"></div>
|
|
130
|
+
<div class="grid" id="grid"></div>
|
|
131
|
+
<div class="actions">
|
|
132
|
+
<button type="button" id="pass">Stop guessing</button>
|
|
133
|
+
<button type="button" id="ask-again" hidden>Ask again</button>
|
|
134
|
+
<button type="button" id="new-game">New game</button>
|
|
135
|
+
</div>
|
|
136
|
+
<p class="stats" id="stats"></p>
|
|
137
|
+
</main>
|
|
138
|
+
<script>
|
|
139
|
+
/* gezel-page-demo-stub v1 */
|
|
140
|
+
/*
|
|
141
|
+
* The canonical demo stub for Gezel type pages. MIT License.
|
|
142
|
+
*
|
|
143
|
+
* Paste this file's bytes verbatim into a <script> block ahead of the
|
|
144
|
+
* page's own code, then call makeDemoGezel({ page, tools, data }) with the
|
|
145
|
+
* page's demo handlers. Served by Gezel, the real window.gezel is already
|
|
146
|
+
* injected and the stub steps aside; opened as a raw file (the live demos
|
|
147
|
+
* on gezelgilde.com), it installs a window.gezel whose tools and data are
|
|
148
|
+
* the page-supplied handler maps — one code path in every mode. `tools`
|
|
149
|
+
* and `data` map a tool name / declared read path to a function; data
|
|
150
|
+
* handlers back read() and list(), and url() returns the handler's value
|
|
151
|
+
* or passes a data: URI through. See docs/page-authoring.md.
|
|
152
|
+
*/
|
|
153
|
+
(function () {
|
|
154
|
+
'use strict';
|
|
155
|
+
window.makeDemoGezel = function (opts) {
|
|
156
|
+
if (window.gezel) return window.gezel;
|
|
157
|
+
var page = (opts && opts.page) || {};
|
|
158
|
+
var tools = (opts && opts.tools) || {};
|
|
159
|
+
var data = (opts && opts.data) || {};
|
|
160
|
+
var themeListeners = [];
|
|
161
|
+
var media = window.matchMedia ? window.matchMedia('(prefers-color-scheme: dark)') : null;
|
|
162
|
+
var ui = {
|
|
163
|
+
theme: { mode: media && media.matches ? 'dark' : 'light' },
|
|
164
|
+
onTheme: function (cb) {
|
|
165
|
+
themeListeners.push(cb);
|
|
166
|
+
return function () {
|
|
167
|
+
var at = themeListeners.indexOf(cb);
|
|
168
|
+
if (at >= 0) themeListeners.splice(at, 1);
|
|
169
|
+
};
|
|
170
|
+
},
|
|
171
|
+
};
|
|
172
|
+
if (media && media.addEventListener) {
|
|
173
|
+
media.addEventListener('change', function (ev) {
|
|
174
|
+
ui.theme = { mode: ev.matches ? 'dark' : 'light' };
|
|
175
|
+
themeListeners.slice().forEach(function (cb) { cb(ui.theme); });
|
|
176
|
+
});
|
|
177
|
+
}
|
|
178
|
+
function fail(code, message) {
|
|
179
|
+
var err = new Error(message);
|
|
180
|
+
err.code = code;
|
|
181
|
+
return Promise.reject(err);
|
|
182
|
+
}
|
|
183
|
+
function run(map, key, arg) {
|
|
184
|
+
if (!Object.prototype.hasOwnProperty.call(map, key)) return null;
|
|
185
|
+
return Promise.resolve().then(function () { return map[key](arg); });
|
|
186
|
+
}
|
|
187
|
+
window.gezel = {
|
|
188
|
+
page: {
|
|
189
|
+
api: 1,
|
|
190
|
+
projectId: 'demo',
|
|
191
|
+
source: 'type',
|
|
192
|
+
entry: page.entry || 'index.html',
|
|
193
|
+
typeName: page.typeName || 'demo',
|
|
194
|
+
params: page.params || {},
|
|
195
|
+
mode: 'demo',
|
|
196
|
+
},
|
|
197
|
+
tools: {
|
|
198
|
+
list: function () { return Promise.resolve(Object.keys(tools)); },
|
|
199
|
+
invoke: function (name, input) {
|
|
200
|
+
var call = run(tools, name, input || {});
|
|
201
|
+
if (!call) return fail('not-allowed', "The demo does not handle the tool '" + name + "'.");
|
|
202
|
+
return call.then(function (output) { return { output: output }; });
|
|
203
|
+
},
|
|
204
|
+
},
|
|
205
|
+
data: {
|
|
206
|
+
read: function (path, o) {
|
|
207
|
+
return run(data, path, o || {}) || fail('not-allowed', "The demo has no data for '" + path + "'.");
|
|
208
|
+
},
|
|
209
|
+
list: function (path, o) {
|
|
210
|
+
return run(data, path, o || {}) || Promise.resolve([]);
|
|
211
|
+
},
|
|
212
|
+
watch: function () { return function () {}; },
|
|
213
|
+
url: function (path) {
|
|
214
|
+
if (Object.prototype.hasOwnProperty.call(data, path)) return String(data[path]({}));
|
|
215
|
+
return typeof path === 'string' && path.indexOf('data:') === 0 ? path : '';
|
|
216
|
+
},
|
|
217
|
+
},
|
|
218
|
+
ui: ui,
|
|
219
|
+
refresh: function () {},
|
|
220
|
+
};
|
|
221
|
+
return window.gezel;
|
|
222
|
+
};
|
|
223
|
+
})();
|
|
224
|
+
</script>
|
|
225
|
+
<script>
|
|
226
|
+
// Reads game.json (pages.reads) and plays through the page tools
|
|
227
|
+
// new_game, guess, pass, and ask_clue_a / ask_clue_b, which summon the
|
|
228
|
+
// clue-giver whose turn it is.
|
|
229
|
+
(function () {
|
|
230
|
+
'use strict';
|
|
231
|
+
|
|
232
|
+
var GIVERS = { a: 'Woordsmid', b: 'Puzzelaar' };
|
|
233
|
+
|
|
234
|
+
// ── demo game (used only when the page opens as a raw file) ──
|
|
235
|
+
var demo = {
|
|
236
|
+
version: 1,
|
|
237
|
+
status: 'guessing',
|
|
238
|
+
giver: 'a',
|
|
239
|
+
round: 1,
|
|
240
|
+
clue: { word: 'SEA', count: 2, guessesLeft: 3, giver: 'a' },
|
|
241
|
+
words: [
|
|
242
|
+
['whale', 'target'], ['lantern', 'neutral'], ['sail', 'target'], ['piano', 'neutral'],
|
|
243
|
+
['volcano', 'trap'], ['shell', 'target'], ['carpet', 'neutral'], ['eagle', 'neutral'],
|
|
244
|
+
['cheese', 'neutral'], ['harbor', 'target'], ['castle', 'neutral'], ['glove', 'neutral'],
|
|
245
|
+
['rocket', 'target'], ['honey', 'neutral'], ['ladder', 'neutral'], ['wizard', 'target'],
|
|
246
|
+
].map(function (w) { return { word: w[0], kind: w[1], revealed: false }; }),
|
|
247
|
+
history: [],
|
|
248
|
+
stats: { played: 3, won: 2, lost: 1 },
|
|
249
|
+
};
|
|
250
|
+
var demoClues = [{ word: 'SPACE', count: 1 }, { word: 'MAGIC', count: 1 }, { word: 'PORT', count: 1 }];
|
|
251
|
+
function demoGuess(word) {
|
|
252
|
+
var cell = demo.words.find(function (w) { return w.word === word; });
|
|
253
|
+
if (!cell || cell.revealed || demo.status !== 'guessing') throw new Error('Pick a hidden word while guessing.');
|
|
254
|
+
cell.revealed = true;
|
|
255
|
+
var left = demo.words.filter(function (w) { return w.kind === 'target' && !w.revealed; }).length;
|
|
256
|
+
if (cell.kind === 'trap') demo.status = 'lost';
|
|
257
|
+
else if (!left) demo.status = 'won';
|
|
258
|
+
else if (cell.kind === 'neutral' || --demo.clue.guessesLeft <= 0) demo.status = 'clue_needed';
|
|
259
|
+
return { status: demo.status, result: cell.kind, giver: demo.giver };
|
|
260
|
+
}
|
|
261
|
+
function demoClue() {
|
|
262
|
+
if (demo.status !== 'clue_needed') return { status: demo.status };
|
|
263
|
+
demo.giver = demo.giver === 'a' ? 'b' : 'a';
|
|
264
|
+
var next = demoClues[demo.round % demoClues.length];
|
|
265
|
+
demo.round += 1;
|
|
266
|
+
demo.clue = { word: next.word, count: next.count, guessesLeft: next.count + 1, giver: demo.giver };
|
|
267
|
+
demo.status = 'guessing';
|
|
268
|
+
return { status: 'guessing' };
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
makeDemoGezel({
|
|
272
|
+
page: { entry: 'board/index.html', typeName: 'Word Clues', params: {} },
|
|
273
|
+
tools: {
|
|
274
|
+
guess: function (input) { return demoGuess(input.word); },
|
|
275
|
+
pass: function () { demo.status = 'clue_needed'; return { status: demo.status, giver: demo.giver }; },
|
|
276
|
+
new_game: function () { location.reload(); return { status: 'clue_needed' }; },
|
|
277
|
+
ask_clue_a: demoClue,
|
|
278
|
+
ask_clue_b: demoClue,
|
|
279
|
+
},
|
|
280
|
+
data: { 'game.json': function () { return demo; } },
|
|
281
|
+
});
|
|
282
|
+
|
|
283
|
+
// ── one code path from here: window.gezel exists in every mode ──
|
|
284
|
+
var demoMode = gezel.page.mode === 'demo';
|
|
285
|
+
var game = null;
|
|
286
|
+
var busy = false;
|
|
287
|
+
|
|
288
|
+
function applyTheme(mode) {
|
|
289
|
+
document.documentElement.setAttribute('data-theme', mode === 'dark' ? 'dark' : 'light');
|
|
290
|
+
}
|
|
291
|
+
applyTheme(gezel.ui.theme.mode);
|
|
292
|
+
gezel.ui.onTheme(function (theme) { applyTheme(theme.mode); });
|
|
293
|
+
if (demoMode) document.querySelector('[data-gezel-demo-banner]').hidden = false;
|
|
294
|
+
|
|
295
|
+
function el(id) { return document.getElementById(id); }
|
|
296
|
+
function esc(s) {
|
|
297
|
+
return String(s == null ? '' : s).replace(/[&<>"]/g, function (c) {
|
|
298
|
+
return { '&': '&', '<': '<', '>': '>', '"': '"' }[c];
|
|
299
|
+
});
|
|
300
|
+
}
|
|
301
|
+
function notice(text) {
|
|
302
|
+
el('notice').textContent = text;
|
|
303
|
+
el('notice').hidden = !text;
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
function render() {
|
|
307
|
+
var g = game || { status: 'new', words: [], stats: { played: 0, won: 0, lost: 0 } };
|
|
308
|
+
var over = g.status === 'won' || g.status === 'lost';
|
|
309
|
+
var clue = el('clue');
|
|
310
|
+
if (g.status === 'new' || !g.words.length) {
|
|
311
|
+
clue.innerHTML = '<span class="muted">Deal a board to start.</span>';
|
|
312
|
+
} else if (g.status === 'guessing' && g.clue) {
|
|
313
|
+
clue.innerHTML =
|
|
314
|
+
'<span class="muted">' + esc(GIVERS[g.clue.giver] || 'Your clue-giver') + ' says</span><br />' +
|
|
315
|
+
'<strong>' + esc(g.clue.word) + ', ' + g.clue.count + '</strong>' +
|
|
316
|
+
' <span class="muted">· ' + g.clue.guessesLeft + ' pick' + (g.clue.guessesLeft === 1 ? '' : 's') + ' left</span>';
|
|
317
|
+
} else if (g.status === 'clue_needed') {
|
|
318
|
+
clue.innerHTML = '<span class="muted">Waiting for the ' + esc(GIVERS[g.giver]) + '’s clue…</span>';
|
|
319
|
+
} else {
|
|
320
|
+
clue.innerHTML = g.status === 'won'
|
|
321
|
+
? '<strong>You found all six.</strong> <span class="muted">' + g.round + ' clue' + (g.round === 1 ? '' : 's') + '.</span>'
|
|
322
|
+
: '<strong>The trap.</strong> <span class="muted">Better luck next game.</span>';
|
|
323
|
+
}
|
|
324
|
+
el('grid').innerHTML = g.words
|
|
325
|
+
.map(function (w) {
|
|
326
|
+
var shown = w.revealed || over;
|
|
327
|
+
var cls = shown ? w.kind : '';
|
|
328
|
+
if (over && !w.revealed && w.kind === 'target') cls = 'hidden-target';
|
|
329
|
+
return (
|
|
330
|
+
'<button type="button" class="cell ' + cls + '" data-word="' + esc(w.word) + '"' +
|
|
331
|
+
(shown || g.status !== 'guessing' || busy ? ' disabled' : '') + '>' + esc(w.word) + '</button>'
|
|
332
|
+
);
|
|
333
|
+
})
|
|
334
|
+
.join('');
|
|
335
|
+
Array.prototype.forEach.call(el('grid').querySelectorAll('[data-word]'), function (b) {
|
|
336
|
+
b.onclick = function () { play('guess', { word: b.getAttribute('data-word') }); };
|
|
337
|
+
});
|
|
338
|
+
el('pass').disabled = g.status !== 'guessing' || busy;
|
|
339
|
+
// A clue-giver's turn can end without a clue; never leave the player stuck.
|
|
340
|
+
el('ask-again').hidden = g.status !== 'clue_needed';
|
|
341
|
+
el('ask-again').disabled = busy;
|
|
342
|
+
el('new-game').disabled = busy;
|
|
343
|
+
var s = g.stats || { played: 0, won: 0, lost: 0 };
|
|
344
|
+
el('stats').textContent = s.played ? 'Games: ' + s.won + ' won, ' + s.lost + ' lost.' : '';
|
|
345
|
+
}
|
|
346
|
+
|
|
347
|
+
function askClue(giver) {
|
|
348
|
+
return gezel.tools.invoke(giver === 'b' ? 'ask_clue_b' : 'ask_clue_a', {});
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
function play(tool, input) {
|
|
352
|
+
if (busy) return;
|
|
353
|
+
busy = true;
|
|
354
|
+
notice('');
|
|
355
|
+
render();
|
|
356
|
+
gezel.tools
|
|
357
|
+
.invoke(tool, input)
|
|
358
|
+
.then(function (res) {
|
|
359
|
+
var out = (res && res.output) || {};
|
|
360
|
+
// A turn that ends, or a game that ends, goes to the clue-giver.
|
|
361
|
+
if (out.status === 'clue_needed' || out.status === 'won' || out.status === 'lost')
|
|
362
|
+
return askClue(out.giver || (game && game.giver));
|
|
363
|
+
})
|
|
364
|
+
.catch(function (err) {
|
|
365
|
+
if (err && err.code === 'unavailable') notice('Playing happens in the app’s Output pane.');
|
|
366
|
+
else notice((err && err.message) || 'That did not work. Try again.');
|
|
367
|
+
})
|
|
368
|
+
.then(function () {
|
|
369
|
+
busy = false;
|
|
370
|
+
return load();
|
|
371
|
+
});
|
|
372
|
+
}
|
|
373
|
+
|
|
374
|
+
function load() {
|
|
375
|
+
return gezel.data
|
|
376
|
+
.read('game.json')
|
|
377
|
+
.then(function (g) { game = g; render(); })
|
|
378
|
+
.catch(function () { render(); });
|
|
379
|
+
}
|
|
380
|
+
|
|
381
|
+
el('pass').onclick = function () { play('pass', {}); };
|
|
382
|
+
el('ask-again').onclick = function () {
|
|
383
|
+
if (busy || !game) return;
|
|
384
|
+
busy = true;
|
|
385
|
+
notice('');
|
|
386
|
+
render();
|
|
387
|
+
askClue(game.giver)
|
|
388
|
+
.catch(function (err) {
|
|
389
|
+
notice(err && err.code === 'unavailable' ? 'Playing happens in the app’s Output pane.' : (err && err.message) || 'That did not work. Try again.');
|
|
390
|
+
})
|
|
391
|
+
.then(function () { busy = false; return load(); });
|
|
392
|
+
};
|
|
393
|
+
el('new-game').onclick = function () { play('new_game', {}); };
|
|
394
|
+
load();
|
|
395
|
+
gezel.data.watch('game.json', function () { load(); });
|
|
396
|
+
})();
|
|
397
|
+
</script>
|
|
398
|
+
</body>
|
|
399
|
+
</html>
|
|
@@ -0,0 +1,216 @@
|
|
|
1
|
+
{
|
|
2
|
+
"words": [
|
|
3
|
+
"anchor",
|
|
4
|
+
"apple",
|
|
5
|
+
"arrow",
|
|
6
|
+
"bakery",
|
|
7
|
+
"balloon",
|
|
8
|
+
"bank",
|
|
9
|
+
"barrel",
|
|
10
|
+
"basket",
|
|
11
|
+
"battery",
|
|
12
|
+
"beach",
|
|
13
|
+
"bean",
|
|
14
|
+
"bear",
|
|
15
|
+
"bell",
|
|
16
|
+
"belt",
|
|
17
|
+
"bicycle",
|
|
18
|
+
"bird",
|
|
19
|
+
"blanket",
|
|
20
|
+
"boat",
|
|
21
|
+
"bone",
|
|
22
|
+
"book",
|
|
23
|
+
"boot",
|
|
24
|
+
"bottle",
|
|
25
|
+
"bowl",
|
|
26
|
+
"box",
|
|
27
|
+
"bread",
|
|
28
|
+
"bridge",
|
|
29
|
+
"brush",
|
|
30
|
+
"bucket",
|
|
31
|
+
"button",
|
|
32
|
+
"cabin",
|
|
33
|
+
"cactus",
|
|
34
|
+
"cake",
|
|
35
|
+
"camera",
|
|
36
|
+
"candle",
|
|
37
|
+
"canoe",
|
|
38
|
+
"card",
|
|
39
|
+
"carpet",
|
|
40
|
+
"castle",
|
|
41
|
+
"cat",
|
|
42
|
+
"chain",
|
|
43
|
+
"chair",
|
|
44
|
+
"cheese",
|
|
45
|
+
"chess",
|
|
46
|
+
"chimney",
|
|
47
|
+
"circus",
|
|
48
|
+
"cloud",
|
|
49
|
+
"coat",
|
|
50
|
+
"coin",
|
|
51
|
+
"comb",
|
|
52
|
+
"compass",
|
|
53
|
+
"cookie",
|
|
54
|
+
"corn",
|
|
55
|
+
"crown",
|
|
56
|
+
"cup",
|
|
57
|
+
"curtain",
|
|
58
|
+
"desert",
|
|
59
|
+
"diamond",
|
|
60
|
+
"dice",
|
|
61
|
+
"dog",
|
|
62
|
+
"dolphin",
|
|
63
|
+
"door",
|
|
64
|
+
"dragon",
|
|
65
|
+
"drum",
|
|
66
|
+
"duck",
|
|
67
|
+
"eagle",
|
|
68
|
+
"egg",
|
|
69
|
+
"engine",
|
|
70
|
+
"envelope",
|
|
71
|
+
"feather",
|
|
72
|
+
"fence",
|
|
73
|
+
"field",
|
|
74
|
+
"fire",
|
|
75
|
+
"fish",
|
|
76
|
+
"flag",
|
|
77
|
+
"flute",
|
|
78
|
+
"fog",
|
|
79
|
+
"forest",
|
|
80
|
+
"fork",
|
|
81
|
+
"fountain",
|
|
82
|
+
"frog",
|
|
83
|
+
"garden",
|
|
84
|
+
"ghost",
|
|
85
|
+
"giant",
|
|
86
|
+
"glass",
|
|
87
|
+
"glove",
|
|
88
|
+
"gold",
|
|
89
|
+
"grape",
|
|
90
|
+
"guitar",
|
|
91
|
+
"hammer",
|
|
92
|
+
"harbor",
|
|
93
|
+
"hat",
|
|
94
|
+
"hive",
|
|
95
|
+
"honey",
|
|
96
|
+
"horse",
|
|
97
|
+
"ice",
|
|
98
|
+
"island",
|
|
99
|
+
"jacket",
|
|
100
|
+
"jam",
|
|
101
|
+
"kettle",
|
|
102
|
+
"key",
|
|
103
|
+
"kite",
|
|
104
|
+
"knife",
|
|
105
|
+
"ladder",
|
|
106
|
+
"lamp",
|
|
107
|
+
"lantern",
|
|
108
|
+
"leaf",
|
|
109
|
+
"lemon",
|
|
110
|
+
"letter",
|
|
111
|
+
"lighthouse",
|
|
112
|
+
"lion",
|
|
113
|
+
"lock",
|
|
114
|
+
"map",
|
|
115
|
+
"mask",
|
|
116
|
+
"match",
|
|
117
|
+
"mirror",
|
|
118
|
+
"moon",
|
|
119
|
+
"mountain",
|
|
120
|
+
"mouse",
|
|
121
|
+
"needle",
|
|
122
|
+
"nest",
|
|
123
|
+
"net",
|
|
124
|
+
"nut",
|
|
125
|
+
"ocean",
|
|
126
|
+
"olive",
|
|
127
|
+
"orange",
|
|
128
|
+
"owl",
|
|
129
|
+
"paint",
|
|
130
|
+
"palace",
|
|
131
|
+
"paper",
|
|
132
|
+
"parrot",
|
|
133
|
+
"peach",
|
|
134
|
+
"pearl",
|
|
135
|
+
"pencil",
|
|
136
|
+
"penguin",
|
|
137
|
+
"piano",
|
|
138
|
+
"pillow",
|
|
139
|
+
"pilot",
|
|
140
|
+
"pipe",
|
|
141
|
+
"pirate",
|
|
142
|
+
"planet",
|
|
143
|
+
"plate",
|
|
144
|
+
"pocket",
|
|
145
|
+
"post",
|
|
146
|
+
"potato",
|
|
147
|
+
"pumpkin",
|
|
148
|
+
"queen",
|
|
149
|
+
"rabbit",
|
|
150
|
+
"rain",
|
|
151
|
+
"river",
|
|
152
|
+
"robot",
|
|
153
|
+
"rocket",
|
|
154
|
+
"rose",
|
|
155
|
+
"ruler",
|
|
156
|
+
"sail",
|
|
157
|
+
"salt",
|
|
158
|
+
"sand",
|
|
159
|
+
"saddle",
|
|
160
|
+
"scarf",
|
|
161
|
+
"school",
|
|
162
|
+
"shadow",
|
|
163
|
+
"shark",
|
|
164
|
+
"sheep",
|
|
165
|
+
"shell",
|
|
166
|
+
"ship",
|
|
167
|
+
"shoe",
|
|
168
|
+
"silver",
|
|
169
|
+
"skate",
|
|
170
|
+
"snow",
|
|
171
|
+
"sock",
|
|
172
|
+
"soup",
|
|
173
|
+
"spider",
|
|
174
|
+
"spoon",
|
|
175
|
+
"star",
|
|
176
|
+
"stone",
|
|
177
|
+
"storm",
|
|
178
|
+
"sugar",
|
|
179
|
+
"sun",
|
|
180
|
+
"swan",
|
|
181
|
+
"sword",
|
|
182
|
+
"table",
|
|
183
|
+
"tail",
|
|
184
|
+
"tea",
|
|
185
|
+
"telescope",
|
|
186
|
+
"tent",
|
|
187
|
+
"thread",
|
|
188
|
+
"thunder",
|
|
189
|
+
"ticket",
|
|
190
|
+
"tiger",
|
|
191
|
+
"tooth",
|
|
192
|
+
"torch",
|
|
193
|
+
"tower",
|
|
194
|
+
"train",
|
|
195
|
+
"treasure",
|
|
196
|
+
"tree",
|
|
197
|
+
"trumpet",
|
|
198
|
+
"tunnel",
|
|
199
|
+
"umbrella",
|
|
200
|
+
"valley",
|
|
201
|
+
"violin",
|
|
202
|
+
"volcano",
|
|
203
|
+
"wagon",
|
|
204
|
+
"wall",
|
|
205
|
+
"watch",
|
|
206
|
+
"wave",
|
|
207
|
+
"whale",
|
|
208
|
+
"wheel",
|
|
209
|
+
"whistle",
|
|
210
|
+
"window",
|
|
211
|
+
"wing",
|
|
212
|
+
"wizard",
|
|
213
|
+
"wolf",
|
|
214
|
+
"wool"
|
|
215
|
+
]
|
|
216
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bendyline/gilde",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.4",
|
|
4
4
|
"description": "The gilde catalog: model manifests, toolsets, craftbooks, roles, and project types for gezel.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"private": false,
|
|
@@ -38,6 +38,7 @@
|
|
|
38
38
|
"build-index": "node tools/build-index.mjs",
|
|
39
39
|
"check-index": "node tools/build-index.mjs --check",
|
|
40
40
|
"lint-models": "node tools/lint-models.mjs",
|
|
41
|
+
"lint-handoffs": "node tools/lint-handoffs.mjs",
|
|
41
42
|
"check-page-demos": "node tools/check-page-demos.mjs",
|
|
42
43
|
"demos": "node tools/serve-page-demos.mjs",
|
|
43
44
|
"format": "node tools/format.mjs --write",
|
|
@@ -114,6 +114,13 @@
|
|
|
114
114
|
"draftModel": {
|
|
115
115
|
"type": "object",
|
|
116
116
|
"properties": {
|
|
117
|
+
"huggingfaceRepo": {
|
|
118
|
+
"type": "string",
|
|
119
|
+
"pattern": "^[A-Za-z0-9_\\-.]+\\/[A-Za-z0-9_\\-.]+$"
|
|
120
|
+
},
|
|
121
|
+
"revision": {
|
|
122
|
+
"type": "string"
|
|
123
|
+
},
|
|
117
124
|
"filename": {
|
|
118
125
|
"type": "string"
|
|
119
126
|
},
|
|
@@ -132,6 +139,22 @@
|
|
|
132
139
|
"sha256",
|
|
133
140
|
"sizeBytes"
|
|
134
141
|
]
|
|
142
|
+
},
|
|
143
|
+
"excludeBackends": {
|
|
144
|
+
"type": "array",
|
|
145
|
+
"items": {
|
|
146
|
+
"type": "string",
|
|
147
|
+
"enum": [
|
|
148
|
+
"cuda",
|
|
149
|
+
"vulkan",
|
|
150
|
+
"metal",
|
|
151
|
+
"cpu"
|
|
152
|
+
]
|
|
153
|
+
}
|
|
154
|
+
},
|
|
155
|
+
"excludeReason": {
|
|
156
|
+
"type": "string",
|
|
157
|
+
"minLength": 1
|
|
135
158
|
}
|
|
136
159
|
},
|
|
137
160
|
"required": [
|