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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
19 |
</html>
|
|
|
1 |
+
<!DOCTYPE html>
|
2 |
+
<html lang="en">
|
3 |
+
<head>
|
4 |
+
<meta charset="UTF-8" />
|
5 |
+
<title>History of AI TicTacToe</title>
|
6 |
+
<script src="https://cdn.tailwindcss.com"></script>
|
7 |
+
</head>
|
8 |
+
<body class="bg-gradient-to-br from-sky-50 to-indigo-100 flex items-center justify-center min-h-screen">
|
9 |
+
<div class="max-w-5xl w-full bg-white rounded-2xl shadow-lg p-6">
|
10 |
+
<h1 class="text-3xl font-extrabold mb-4 text-center text-indigo-800">History of AI TicTacToe</h1>
|
11 |
+
|
12 |
+
<p class="text-center text-sm text-gray-600 mb-4">
|
13 |
+
Source:
|
14 |
+
<a href="https://www.linkedin.com/pulse/milestones-ai-conversational-systems-michael-lively-5k24e/"
|
15 |
+
class="text-blue-600 underline" target="_blank" rel="noopener">
|
16 |
+
Milestones in AI Conversational Systems (LinkedIn)
|
17 |
+
</a>
|
18 |
+
</p>
|
19 |
+
|
20 |
+
<div id="banner" class="hidden bg-green-100 border border-green-300 text-green-800 font-bold text-center py-2 rounded mb-4"></div>
|
21 |
+
|
22 |
+
<div class="flex flex-col md:flex-row items-start justify-center md:space-x-4 space-y-4 md:space-y-0">
|
23 |
+
<div id="board" class="grid grid-cols-3 gap-1 border-4 border-gray-300 rounded-lg p-2 bg-white mx-auto"></div>
|
24 |
+
|
25 |
+
<div id="questionPanel" class="md:w-1/2 w-full bg-gray-50 rounded-lg shadow p-4">
|
26 |
+
<h2 id="panelQuestion" class="text-xl font-semibold text-gray-800">Select a square to view the question</h2>
|
27 |
+
<ul id="panelChoices" class="mt-4 space-y-2"></ul>
|
28 |
+
<p id="panelHint" class="mt-3 text-sm text-gray-600 hidden"></p>
|
29 |
+
<button id="hintBtn" class="mt-4 px-3 py-1 bg-gray-200 text-gray-700 rounded hover:bg-gray-300">Show Hint</button>
|
30 |
+
</div>
|
31 |
+
</div>
|
32 |
+
|
33 |
+
<div class="flex justify-between mt-6">
|
34 |
+
<p id="status" class="text-lg font-medium text-gray-800"></p>
|
35 |
+
<button id="restartBtn" class="px-4 py-2 bg-indigo-700 text-white rounded hover:bg-indigo-800">Restart</button>
|
36 |
+
</div>
|
37 |
+
</div>
|
38 |
+
|
39 |
+
<script>
|
40 |
+
// Question bank derived from the provided timeline content.
|
41 |
+
// Answers are 1-based indexes.
|
42 |
+
const questions = [
|
43 |
+
{
|
44 |
+
question: 'What is the core idea of the Turing Test?',
|
45 |
+
choices: [
|
46 |
+
'Measuring model size in parameters',
|
47 |
+
'Testing if a machine’s behavior is indistinguishable from a human',
|
48 |
+
'Scoring accuracy on multiple-choice exams',
|
49 |
+
'Ranking search results by PageRank'
|
50 |
+
],
|
51 |
+
answer: 2,
|
52 |
+
hint: 'It’s about human-like behavior in conversation.'
|
53 |
+
},
|
54 |
+
{
|
55 |
+
question: 'ELIZA (1966) is best known for:',
|
56 |
+
choices: [
|
57 |
+
'Learning Go from scratch',
|
58 |
+
'A DOCTOR script that mimicked a psychotherapist via keyword matching',
|
59 |
+
'Speech recognition on smartphones',
|
60 |
+
'A proactive card-based assistant'
|
61 |
+
],
|
62 |
+
answer: 2,
|
63 |
+
hint: 'Think “keyword matching” and therapy-style replies.'
|
64 |
+
},
|
65 |
+
{
|
66 |
+
question: 'PARRY (1972) primarily focused on:',
|
67 |
+
choices: [
|
68 |
+
'Financial forecasting',
|
69 |
+
'Modeling a patient with paranoid schizophrenia with emotionally consistent replies',
|
70 |
+
'Generating images from text prompts',
|
71 |
+
'Machine translation between English and French'
|
72 |
+
],
|
73 |
+
answer: 2,
|
74 |
+
hint: 'Psychiatrist Kenneth Colby created it.'
|
75 |
+
},
|
76 |
+
{
|
77 |
+
question: 'SHRDLU (1973) operated in which environment?',
|
78 |
+
choices: [
|
79 |
+
'A simulated “blocks world” following natural language commands',
|
80 |
+
'A self-driving car simulator',
|
81 |
+
'A web-scale search index',
|
82 |
+
'A voice-controlled smart home'
|
83 |
+
],
|
84 |
+
answer: 1,
|
85 |
+
hint: 'Small world, big reasoning.'
|
86 |
+
},
|
87 |
+
{
|
88 |
+
question: 'Jabberwacky (1988) aimed to:',
|
89 |
+
choices: [
|
90 |
+
'Translate languages in real time',
|
91 |
+
'Hold human-like, entertaining conversations using contextual pattern matching',
|
92 |
+
'Provide medical triage on kiosks',
|
93 |
+
'Control industrial robots'
|
94 |
+
],
|
95 |
+
answer: 2,
|
96 |
+
hint: 'Entertainment and personality.'
|
97 |
+
},
|
98 |
+
{
|
99 |
+
question: 'A.L.I.C.E. (1995) was built on:',
|
100 |
+
choices: [
|
101 |
+
'AIML (Artificial Intelligence Markup Language)',
|
102 |
+
'TensorFlow',
|
103 |
+
'Prolog',
|
104 |
+
'Reinforcement Learning from Human Feedback'
|
105 |
+
],
|
106 |
+
answer: 1,
|
107 |
+
hint: 'Markup language for pattern-based chats.'
|
108 |
+
},
|
109 |
+
{
|
110 |
+
question: 'Reinforcement Learning (2000s) teaches agents by:',
|
111 |
+
choices: [
|
112 |
+
'Backtranslating sentences',
|
113 |
+
'Labeled images only',
|
114 |
+
'Trial and error with rewards and penalties',
|
115 |
+
'Counting word frequencies'
|
116 |
+
],
|
117 |
+
answer: 3,
|
118 |
+
hint: 'Actions → rewards → policy.'
|
119 |
+
},
|
120 |
+
{
|
121 |
+
question: 'IBM Watson gained fame by winning which game show in 2011?',
|
122 |
+
choices: [
|
123 |
+
'Who Wants to Be a Millionaire?',
|
124 |
+
'The Price Is Right',
|
125 |
+
'Jeopardy!',
|
126 |
+
'Family Feud'
|
127 |
+
],
|
128 |
+
answer: 3,
|
129 |
+
hint: 'Clues in natural language.'
|
130 |
+
},
|
131 |
+
{
|
132 |
+
question: 'The Medical Bayesian Kiosk (2010) showcased:',
|
133 |
+
choices: [
|
134 |
+
'Self-attention networks',
|
135 |
+
'Probabilistic diagnosis using Bayesian inference via a kiosk',
|
136 |
+
'Neural machine translation',
|
137 |
+
'Edge TPU acceleration'
|
138 |
+
],
|
139 |
+
answer: 2,
|
140 |
+
hint: 'Bayes at the point of care.'
|
141 |
+
},
|
142 |
+
{
|
143 |
+
question: 'Apple Siri (2011) marked the mainstreaming of:',
|
144 |
+
choices: [
|
145 |
+
'On-device GAN image synthesis',
|
146 |
+
'Voice assistants integrating speech recognition and NLP',
|
147 |
+
'Quantum encryption',
|
148 |
+
'AR glasses for shoppers'
|
149 |
+
],
|
150 |
+
answer: 2,
|
151 |
+
hint: '“Hey…” on phones.'
|
152 |
+
},
|
153 |
+
{
|
154 |
+
question: 'Google Now (2012) was known for:',
|
155 |
+
choices: [
|
156 |
+
'Pattern-based AIML chats',
|
157 |
+
'Proactive, context-aware cards with personalized info',
|
158 |
+
'Only offline speech dictation',
|
159 |
+
'Generating code from prompts'
|
160 |
+
],
|
161 |
+
answer: 2,
|
162 |
+
hint: 'Cards and context.'
|
163 |
+
},
|
164 |
+
{
|
165 |
+
question: 'Word2Vec (2013) introduced:',
|
166 |
+
choices: [
|
167 |
+
'Symbolic logic rules',
|
168 |
+
'Dense word embeddings capturing semantic relationships',
|
169 |
+
'Only one-hot encodings',
|
170 |
+
'Audio-to-text pipelines'
|
171 |
+
],
|
172 |
+
answer: 2,
|
173 |
+
hint: 'Vectors that reflect meaning.'
|
174 |
+
},
|
175 |
+
{
|
176 |
+
question: 'Microsoft Cortana (2014) focused on:',
|
177 |
+
choices: [
|
178 |
+
'Windows integration for productivity tasks and reminders',
|
179 |
+
'Cloud GPU scheduling',
|
180 |
+
'Streaming video recommendations only',
|
181 |
+
'IoT sensor calibration'
|
182 |
+
],
|
183 |
+
answer: 1,
|
184 |
+
hint: 'Assistant baked into Windows.'
|
185 |
+
},
|
186 |
+
{
|
187 |
+
question: 'Amazon Alexa (2015) popularized:',
|
188 |
+
choices: [
|
189 |
+
'Home voice interaction and smart-home integration',
|
190 |
+
'Neural radiance fields',
|
191 |
+
'Handwriting recognition on PDAs',
|
192 |
+
'Genome assembly'
|
193 |
+
],
|
194 |
+
answer: 1,
|
195 |
+
hint: '“Skills” + smart speakers.'
|
196 |
+
},
|
197 |
+
{
|
198 |
+
question: 'AlphaGo (2016) was notable because:',
|
199 |
+
choices: [
|
200 |
+
'It solved protein folding first',
|
201 |
+
'It defeated world champions in Go using deep RL',
|
202 |
+
'It ran only on mobile phones',
|
203 |
+
'It was purely rule-based'
|
204 |
+
],
|
205 |
+
answer: 2,
|
206 |
+
hint: 'Monte Carlo search + policy/value nets.'
|
207 |
+
},
|
208 |
+
{
|
209 |
+
question: 'Transformers (2017) revolutionized NLP by using:',
|
210 |
+
choices: [
|
211 |
+
'Only convolution',
|
212 |
+
'Self-attention mechanisms instead of recurrence',
|
213 |
+
'Rule-based grammars',
|
214 |
+
'Acoustic models'
|
215 |
+
],
|
216 |
+
answer: 2,
|
217 |
+
hint: '“Attention Is All You Need.”'
|
218 |
+
},
|
219 |
+
{
|
220 |
+
question: 'BERT (2018) provided:',
|
221 |
+
choices: [
|
222 |
+
'Static embeddings',
|
223 |
+
'Contextual embeddings that vary by sentence context',
|
224 |
+
'Purely symbolic parsing',
|
225 |
+
'Only character-level models'
|
226 |
+
],
|
227 |
+
answer: 2,
|
228 |
+
hint: 'Bidirectional context.'
|
229 |
+
},
|
230 |
+
{
|
231 |
+
question: 'ChatGPT (2022) was fine-tuned for:',
|
232 |
+
choices: [
|
233 |
+
'Dialogue—coherent, context-aware conversations',
|
234 |
+
'3D mesh reconstruction',
|
235 |
+
'Time-series forecasting only',
|
236 |
+
'Optical flow estimation'
|
237 |
+
],
|
238 |
+
answer: 1,
|
239 |
+
hint: 'It chats. A lot.'
|
240 |
+
},
|
241 |
+
{
|
242 |
+
question: 'Which pairing is correct?',
|
243 |
+
choices: [
|
244 |
+
'ELIZA — deep reinforcement learning',
|
245 |
+
'PARRY — proactive card-based assistant',
|
246 |
+
'SHRDLU — blocks world language understanding',
|
247 |
+
'Word2Vec — rule-based templates'
|
248 |
+
],
|
249 |
+
answer: 3,
|
250 |
+
hint: 'Think Winograd.'
|
251 |
+
},
|
252 |
+
{
|
253 |
+
question: 'Which is the correct chronological order?',
|
254 |
+
choices: [
|
255 |
+
'A.L.I.C.E. (1995) → ELIZA (1966) → PARRY (1972)',
|
256 |
+
'ELIZA (1966) → PARRY (1972) → A.L.I.C.E. (1995)',
|
257 |
+
'PARRY (1972) → A.L.I.C.E. (1995) → ELIZA (1966)',
|
258 |
+
'A.L.I.C.E. (1995) → PARRY (1972) → ELIZA (1966)'
|
259 |
+
],
|
260 |
+
answer: 2,
|
261 |
+
hint: '1960s → 1970s → 1990s.'
|
262 |
+
},
|
263 |
+
{
|
264 |
+
question: 'Which statement best captures the timeline’s theme?',
|
265 |
+
choices: [
|
266 |
+
'Shift from symbolic rules to data-driven and deep learning approaches enabling human-like communication',
|
267 |
+
'Decline of NLP research over time',
|
268 |
+
'Exclusive focus on robotics',
|
269 |
+
'Abandonment of embeddings'
|
270 |
+
],
|
271 |
+
answer: 1,
|
272 |
+
hint: 'From patterns → embeddings → transformers.'
|
273 |
+
}
|
274 |
+
];
|
275 |
+
|
276 |
+
let currentPlayer, boardState, cellQuestions, selectedCell;
|
277 |
+
|
278 |
+
const boardEl = document.getElementById('board');
|
279 |
+
const statusEl = document.getElementById('status');
|
280 |
+
const bannerEl = document.getElementById('banner');
|
281 |
+
const hintBtn = document.getElementById('hintBtn');
|
282 |
+
const panelQuestion = document.getElementById('panelQuestion');
|
283 |
+
const panelChoices = document.getElementById('panelChoices');
|
284 |
+
const panelHint = document.getElementById('panelHint');
|
285 |
+
const restartBtn = document.getElementById('restartBtn');
|
286 |
+
|
287 |
+
function initGame() {
|
288 |
+
currentPlayer = 'X';
|
289 |
+
boardState = Array(9).fill('');
|
290 |
+
bannerEl.classList.add('hidden');
|
291 |
+
statusEl.innerText = '';
|
292 |
+
const shuffled = [...questions].sort(() => 0.5 - Math.random());
|
293 |
+
cellQuestions = shuffled.slice(0, 9);
|
294 |
+
panelQuestion.innerText = 'Select a square to view the question';
|
295 |
+
panelChoices.innerHTML = '';
|
296 |
+
panelHint.classList.add('hidden');
|
297 |
+
panelHint.innerText = '';
|
298 |
+
renderBoard();
|
299 |
+
}
|
300 |
+
|
301 |
+
function renderBoard() {
|
302 |
+
boardEl.innerHTML = '';
|
303 |
+
boardState.forEach((mark, idx) => {
|
304 |
+
const btn = document.createElement('button');
|
305 |
+
let cls = 'bg-white h-24 w-24 flex items-center justify-center text-2xl font-bold rounded-lg shadow hover:bg-gray-100 transition';
|
306 |
+
if (mark === 'X') cls += ' text-blue-600';
|
307 |
+
if (mark === 'O') cls += ' text-red-600';
|
308 |
+
btn.className = cls;
|
309 |
+
btn.innerText = mark;
|
310 |
+
btn.disabled = mark !== '';
|
311 |
+
btn.addEventListener('click', () => openQuestion(idx));
|
312 |
+
boardEl.appendChild(btn);
|
313 |
+
});
|
314 |
+
statusEl.innerText = `Current: ${currentPlayer}`;
|
315 |
+
}
|
316 |
+
|
317 |
+
function openQuestion(idx) {
|
318 |
+
selectedCell = idx;
|
319 |
+
const q = cellQuestions[idx];
|
320 |
+
panelQuestion.innerText = q.question;
|
321 |
+
panelChoices.innerHTML = '';
|
322 |
+
panelHint.classList.add('hidden');
|
323 |
+
panelHint.innerText = q.hint || '';
|
324 |
+
q.choices.forEach((c, i) => {
|
325 |
+
const li = document.createElement('li');
|
326 |
+
const btn = document.createElement('button');
|
327 |
+
btn.innerText = c;
|
328 |
+
btn.className = 'w-full text-left px-4 py-2 bg-gray-100 rounded hover:bg-gray-200';
|
329 |
+
btn.addEventListener('click', () => handleAnswer(i + 1));
|
330 |
+
li.appendChild(btn);
|
331 |
+
panelChoices.appendChild(li);
|
332 |
+
});
|
333 |
+
}
|
334 |
+
|
335 |
+
function handleAnswer(choice) {
|
336 |
+
const q = cellQuestions[selectedCell];
|
337 |
+
if (choice === q.answer) {
|
338 |
+
boardState[selectedCell] = currentPlayer;
|
339 |
+
renderBoard();
|
340 |
+
if (checkWin()) return endGame(`${currentPlayer} wins!`);
|
341 |
+
if (boardState.every(c => c)) return endGame('Stalemate!');
|
342 |
+
} else {
|
343 |
+
alert('Incorrect! Turn missed.');
|
344 |
+
}
|
345 |
+
currentPlayer = currentPlayer === 'X' ? 'O' : 'X';
|
346 |
+
statusEl.innerText = `Current: ${currentPlayer}`;
|
347 |
+
}
|
348 |
+
|
349 |
+
function checkWin() {
|
350 |
+
const wins = [
|
351 |
+
[0,1,2],[3,4,5],[6,7,8],
|
352 |
+
[0,3,6],[1,4,7],[2,5,8],
|
353 |
+
[0,4,8],[2,4,6]
|
354 |
+
];
|
355 |
+
return wins.some(combo => combo.every(i => boardState[i] === currentPlayer));
|
356 |
+
}
|
357 |
+
|
358 |
+
function endGame(msg) {
|
359 |
+
bannerEl.innerText = `🎉 ${msg}`;
|
360 |
+
bannerEl.classList.remove('hidden');
|
361 |
+
document.querySelectorAll('#board button').forEach(b => b.disabled = true);
|
362 |
+
}
|
363 |
+
|
364 |
+
hintBtn.addEventListener('click', () => panelHint.classList.toggle('hidden'));
|
365 |
+
restartBtn.addEventListener('click', initGame);
|
366 |
+
|
367 |
+
initGame();
|
368 |
+
</script>
|
369 |
+
</body>
|
370 |
</html>
|