-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
126 lines (124 loc) · 6.42 KB
/
index.html
File metadata and controls
126 lines (124 loc) · 6.42 KB
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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
<!DOCTYPE html>
<html>
<head>
<!-- <script src="https://unpkg.com/vue@3"></script>-->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bulma@0.9.4/css/bulma.min.css">
<!-- <link rel="stylesheet" href="index.css">-->
<!-- <link rel="stylesheet" href="bulma.css">-->
<script type="module" src="./src/main.js"></script>
<title>Reddit Turing Test</title>
</head>
<body id="app">
<!-- Header-->
<div :class="{blinkFail: lastIncorrect, blinkSuccess: lastCorrect}" style="z-index: -1">
<nav class="navbar is-light">
<div class="container">
<div class="navbar-brand">
<h1 class="title navbar-item"> Reddit Turing Test </h1>
</div>
<div class="navbar-end">
<a href="#about" class="navbar-item">What is this?</a>
<a class="navbar-item">
<span>Made with love by </span> <span class="has-text-link">basta</span>
</a>
</div>
</div>
</nav>
<section class="section">
<div class="hero">
<div class="hero-body has-text-centered">
<p class="subtitle">Current subreddit:</p>
<h2 class="title"><span class="has-text-grey">r/</span>{{ turtest["subreddit"] }}</h2>
<div v-if="incorrect + correct !== 0" class="p-1" style="display: flex; justify-content: space-between">
<p class="has-text-info has-text-weight-bold">Correct: {{ correct }}</p>
<p class="has-text-danger has-text-weight-bold">Incorrect: {{ incorrect }} </p>
</div>
<progress
v-if="incorrect + correct !== 0"
class="progress is-info has-background-danger" :max="correct + incorrect"
:value="correct"></progress>
<div class="columns">
<div class="column">
<div class="container has-background-primary-light is-rounded p-4"
style="height: 100%; flex-direction: column; display: flex; z-index: 2; justify-content: space-between">
<article class="media mb-4">
<div class="media-content">
<strong>{{ turtest.leftpost.title }}</strong>
<p class="content">
{{ turtest.leftpost.text }}
</p>
</div>
</article>
<button id="left" @click="select"
class="button is-primary is-fullwidth has-text-weight-bold">
<span v-if="asking">
This is
human!
</span>
<span v-if="!asking">
Next
</span>
</button>
</div>
<h3 class="subtitle has-text-info is-size-1 answer"
style="position: relative; top: -100px; z-index: 1"
:class="{answerVisibleHuman: !asking && turtest.leftpost.isHuman}"
>HUMAN</h3>
<h3 class="subtitle has-text-danger is-size-1 answer mb-4"
style="position: relative; top: -100px; z-index: 1;"
:class="{answerVisibleAI: !asking && !turtest.leftpost.isHuman}"
>AI</h3>
</div>
<div class="column">
<div class="container has-background-primary-light is-rounded p-4"
style="height: 100%; flex-direction: column; display: flex; z-index: 2; justify-content: space-between">
<article class="media mb-4">
<div class="media-content">
<strong>{{ turtest.rightpost.title }}</strong>
<p class="content">
{{ turtest.rightpost.text }}
</p>
</div>
</article>
<button id="right" @click="select"
class="button has-text-weight-bold is-primary is-fullwidth">
<span v-if="asking">
No, This is
human!
</span>
<span v-if="!asking">
Next
</span>
</button>
</div>
<h3 class="subtitle has-text-info is-size-1 answer"
style="position: relative; top: -100px; z-index: 1;"
:class="{answerVisibleHuman: !asking && turtest.rightpost.isHuman}"
>HUMAN</h3>
<h3 class="subtitle has-text-danger is-size-1 answer"
style="position: relative; top: -200px; z-index: 1"
:class="{answerVisibleAI: !asking && !turtest.rightpost.isHuman}"
>AI</h3>
</div>
</div>
</div>
</div>
</section>
<section class="section content">
<h2 class="title is-primary" id="about"> What is this?</h2>
<p>
Select the reddit post which you think is made by a human. The other one is created using a GPT-2 model,
which was trained on the given subreddit. The AI generated posts are taken from the subreddit
<a href="https://www.reddit.com/r/SubSimulatorGPT2">r/SubSimulatorGPT2</a> thanks to the brilliant work done
by <span class="has-text-primary-dark"> u/disumbrationist</span>.
</p>
<p>
This Turing Test presents you with a post created by GPT2 and a random hot post from the subreddit, where
this model was trained.
</p>
</section>
</div>
</body>
</html>