-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathoptions.html
More file actions
226 lines (203 loc) · 5.83 KB
/
options.html
File metadata and controls
226 lines (203 loc) · 5.83 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
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
<!DOCTYPE html>
<html>
<head>
<title>Deep Research Citation Verifier Settings</title>
<style>
body {
padding: 20px;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
max-width: 800px;
margin: 0 auto;
color: #333;
}
.section {
margin-bottom: 30px;
padding: 20px;
border: 1px solid #eee;
border-radius: 8px;
}
h2 {
margin-top: 0;
color: #0066cc;
}
.field {
margin-bottom: 15px;
}
label {
display: block;
margin-bottom: 5px;
font-weight: 500;
}
input[type="text"], textarea {
width: 100%;
padding: 8px;
border: 1px solid #ddd;
border-radius: 4px;
font-family: inherit;
}
.api-key-container {
display: flex;
gap: 10px;
}
.api-key-container input {
flex: 1;
}
button {
padding: 8px 16px;
background: #0066cc;
color: white;
border: none;
border-radius: 4px;
cursor: pointer;
font-size: 14px;
}
button:hover {
background: #0052a3;
}
button:disabled {
background: #ccc;
cursor: not-allowed;
}
.toggle-container {
display: flex;
align-items: center;
gap: 10px;
}
.toggle {
position: relative;
width: 50px;
height: 24px;
}
.toggle input {
opacity: 0;
width: 0;
height: 0;
}
.slider {
position: absolute;
cursor: pointer;
top: 0;
left: 0;
right: 0;
bottom: 0;
background-color: #ccc;
transition: .4s;
border-radius: 24px;
}
.slider:before {
position: absolute;
content: "";
height: 16px;
width: 16px;
left: 4px;
bottom: 4px;
background-color: white;
transition: .4s;
border-radius: 50%;
}
input:checked + .slider {
background-color: #0066cc;
}
input:checked + .slider:before {
transform: translateX(26px);
}
.status {
margin-left: 10px;
font-size: 14px;
}
.success { color: #28a745; }
.error { color: #dc3545; }
</style>
</head>
<body>
<div class="section">
<h2>API Keys</h2>
<div class="field">
<label for="exaKey">Exa API Key (Required)</label>
<div class="api-key-container">
<input type="text" id="exaKey" placeholder="Enter your Exa API key">
<button id="testExaKey">Test Key</button>
</div>
<span id="exaKeyStatus" class="status"></span>
</div>
<div class="field">
<label for="openaiKey">OpenAI API Key (Optional - Enables advanced features)</label>
<div class="api-key-container">
<input type="text" id="openaiKey" placeholder="Enter your OpenAI API key">
<button id="testOpenAIKey">Test Key</button>
</div>
<span id="openaiKeyStatus" class="status"></span>
<p style="color: #dc3545; font-weight: bold; margin-top: 5px;">
IMPORTANT: After entering or changing API keys, click "Save Settings" below!
</p>
</div>
</div>
<div class="section">
<h2>Extraction & Appearance</h2>
<div class="field toggle-container">
<label class="toggle">
<input type="checkbox" id="useLLMExtraction">
<span class="slider"></span>
</label>
<span>Use AI-powered extraction (requires OpenAI key)</span>
<span style="display: block; margin-left: 60px; font-size: 13px; color: #666;">
When enabled, uses AI to identify factual claims. When disabled, uses rule-based extraction.
</span>
</div>
<div class="field toggle-container">
<label class="toggle">
<input type="checkbox" id="highlightsEnabled">
<span class="slider"></span>
</label>
<span>Enable claim highlights</span>
</div>
<div class="field toggle-container">
<label class="toggle">
<input type="checkbox" id="sidebarEnabled">
<span class="slider"></span>
</label>
<span>Show sidebar automatically</span>
</div>
<div class="field toggle-container">
<label class="toggle">
<input type="checkbox" id="darkMode">
<span class="slider"></span>
</label>
<span>Use dark mode for tooltips</span>
</div>
</div>
<div class="section">
<h2>Usage Management</h2>
<div class="field">
<label for="maxVerifications">Maximum API Verification Calls Per Day (0 = unlimited)</label>
<input type="number" id="maxVerifications" min="0" max="1000" placeholder="10" style="width: 100px;">
<div style="margin-top: 5px; color: #666; font-size: 14px;">
<span>Current usage today: </span>
<span id="currentUsage">0</span> calls
<button id="resetUsage" style="margin-left: 10px; background-color: #f8f9fa; color: #333; border: 1px solid #ddd;">Reset Counter</button>
</div>
</div>
<div class="field toggle-container">
<label class="toggle">
<input type="checkbox" id="enableCaching">
<span class="slider"></span>
</label>
<span>Enable Claim Caching (save API costs)</span>
</div>
<div class="field">
<label for="cacheDuration">Cache Duration (in days)</label>
<input type="number" id="cacheDuration" min="1" max="30" placeholder="7" style="width: 100px;">
</div>
</div>
<div class="section">
<h2>Site Settings</h2>
<div class="field">
<label for="excludedDomains">Excluded Domains (one per line)</label>
<textarea id="excludedDomains" rows="5" placeholder="example.com internal.company.com"></textarea>
</div>
</div>
<button id="saveSettings" style="padding: 10px 20px; font-size: 16px; font-weight: bold; background-color: #34C759;">Save Settings</button>
<span id="saveStatus" class="status" style="font-size: 16px;"></span>
</body>
<script src="dist/options.js"></script>
</html>