-
Notifications
You must be signed in to change notification settings - Fork 4
/
index.html
83 lines (79 loc) · 2.82 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/orderly.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<!-- HTML Meta Tags -->
<title>Orderly: A Proof of Concept Writing Tool</title>
<meta
name="description"
content="Using WASM, Orderly allows you to dictate books in small chunks using Whisper.cpp and SQLite all in the browser. No server involved."
/>
<!-- Facebook Meta Tags -->
<meta property="og:url" content="https://orderly.cmgriffing.com" />
<meta property="og:type" content="website" />
<meta
property="og:title"
content="Orderly: WASM-Powered Audio Dictation"
/>
<meta
property="og:description"
content="Using WASM, Orderly allows you to dictate books in small chunks using Whisper.cpp and SQLite all in the browser. No server involved."
/>
<meta
property="og:image"
content="https://orderly.cmgriffing.com/microphone.jpg"
/>
<!-- Twitter Meta Tags -->
<meta name="twitter:card" content="summary_large_image" />
<meta property="twitter:domain" content="orderly.cmgriffing.com" />
<meta property="twitter:url" content="https://orderly.cmgriffing.com" />
<meta
name="twitter:title"
content="Orderly: A Proof of Concept Writing Tool"
/>
<meta
name="twitter:description"
content="Using WASM, Orderly allows you to dictate books in small chunks using Whisper.cpp and SQLite all in the browser. No server involved."
/>
<meta
name="twitter:image"
content="https://orderly.cmgriffing.com/aaron-burden-xG8IQMqMITM-unsplash.jpg"
/>
<!-- Meta Tags Generated via https://opengraph.dev -->
<script
defer
data-domain="orderly.cmgriffing.com"
src="https://plausible.io/js/script.js"
></script>
</head>
<body>
<div id="root"></div>
<script>
let recentResult = [];
const bracketRegex = new RegExp("^\\[.*?\\]");
const blankAudioRegex = new RegExp("\\[BLANK_AUDIO\\]$");
const whisperTimingRegex = new RegExp("^whisper_print_timings: ");
window.Module = {
print: function (message) {
if (bracketRegex.test(message) && !blankAudioRegex.test(message)) {
recentResult.push(message.replace(bracketRegex, "").trim());
}
},
printErr: function (message) {
if (whisperTimingRegex.test(message) && recentResult.length > 0) {
window.dispatchEvent(
new CustomEvent("whisperResult", {
detail: recentResult.join(" "),
})
);
recentResult = [];
}
},
};
</script>
<script src="/main.js"></script>
<script type="module" src="/src/main.tsx"></script>
</body>
</html>