Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
CS101 - Cognitive Science and Artificial Intelligence
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jacob Mwangu CS2023
CS101 - Cognitive Science and Artificial Intelligence
Commits
78b607b4
Commit
78b607b4
authored
1 year ago
by
William Waites
Browse files
Options
Downloads
Patches
Plain Diff
add README
parent
175de21d
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
imitation/README.md
+14
-0
14 additions, 0 deletions
imitation/README.md
imitation/imitation/server.py
+2
-2
2 additions, 2 deletions
imitation/imitation/server.py
imitation/setup.py
+2
-2
2 additions, 2 deletions
imitation/setup.py
with
18 additions
and
4 deletions
imitation/README.md
0 → 100644
+
14
−
0
View file @
78b607b4
# The Imitation Game
This is a server for playing Turing's Imitation Game. It is intended
for use in a classroom setting. Installation is as usual for Python
packages, it requires Python 3, the
`llm`
wrapper package, an NumPy.
By default the server listens on TCP port 1950 (the year of Turing's
"Computing Machinery and Intelligence" paper. Connecting to this port,
using e.g.
`telnet`
or
`netcat`
will start a session. The role of
interrogator or player is randomly assigned. An interrogator may be
paired with either a human or a suitably prompted language model. The
task of the interrogator is to determine if they are conversing with a
human or a machine.
This diff is collapsed.
Click to expand it.
imitation/imitation/server.py
+
2
−
2
View file @
78b607b4
...
@@ -117,7 +117,7 @@ class Interrogator(Interlocutor):
...
@@ -117,7 +117,7 @@ class Interrogator(Interlocutor):
def
handle
(
self
):
def
handle
(
self
):
self
.
log
.
info
(
"
connecting...
"
)
self
.
log
.
info
(
"
connecting...
"
)
self
.
write
(
f
"""
self
.
write
(
f
"""
Welcome to the Imitation Game. Your role is
"
interrogator
"
. You get to
Welcome to the Imitation Game. Your role is
INTERROGATOR
. You get to
ask
{
self
.
n
}
questions of your interlocutor to determine if they are a
ask
{
self
.
n
}
questions of your interlocutor to determine if they are a
human or a machine. At the end of the session you will be asked which
human or a machine. At the end of the session you will be asked which
you think they are and why. If you have made up your mind and want to
you think they are and why. If you have made up your mind and want to
...
@@ -180,7 +180,7 @@ class Human(Interlocutor):
...
@@ -180,7 +180,7 @@ class Human(Interlocutor):
def
handle
(
self
):
def
handle
(
self
):
self
.
log
.
info
(
"
connecting...
"
)
self
.
log
.
info
(
"
connecting...
"
)
self
.
write
(
f
"""
self
.
write
(
f
"""
Welcome to the Imitation Game. Your role is
HUMAN
. You will be asked
Welcome to the Imitation Game. Your role is
PLAYER
. You will be asked
{
self
.
n
}
questions by an interlocutor who is attempting to find out if
{
self
.
n
}
questions by an interlocutor who is attempting to find out if
you are a human or a machine. Your task is to convince them that you
you are a human or a machine. Your task is to convince them that you
are human. Good luck!
are human. Good luck!
...
...
This diff is collapsed.
Click to expand it.
imitation/setup.py
+
2
−
2
View file @
78b607b4
...
@@ -4,7 +4,7 @@ from setuptools import setup, find_packages
...
@@ -4,7 +4,7 @@ from setuptools import setup, find_packages
setup
(
name
=
'
imitation
'
,
setup
(
name
=
'
imitation
'
,
version
=
'
0.2
'
,
version
=
'
0.2
'
,
description
=
'
Turing
Test
'
,
description
=
"
Turing
'
s Imitation Game
"
,
author
=
[
'
William Waites
'
],
author
=
[
'
William Waites
'
],
author_email
=
'
william.waites@strath.ac.uk
'
,
author_email
=
'
william.waites@strath.ac.uk
'
,
keywords
=
[
'
AI
'
],
keywords
=
[
'
AI
'
],
...
@@ -34,7 +34,7 @@ setup(name='imitation',
...
@@ -34,7 +34,7 @@ setup(name='imitation',
],
],
entry_points
=
{
entry_points
=
{
'
console_scripts
'
:
[
'
console_scripts
'
:
[
'
imitation
_server
= imitation.server:cli
'
,
'
imitation = imitation.server:cli
'
,
],
],
},
},
)
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment