## Rule Game Server Documentation

To get started...

- The main concepts of the Rule Game, a.k.a. the Game of Hidden Rules (GOHR)

### Designing an experiment

If you are a researcher designing new experiments, these documents are for you.

Preparing an experiment:

- Standard Operating Procedures: Preparing and running an experiment with the Rule Game Server
- Standard Operating Procedures: Special notes for working on the DoIT Shared Hosting hosts (aka the Plesk hosts)
- About the data files (read the first section, concerning the control files)
- About the syntax of rule set files
- About the syntax of rule set files: GS5 extension
- About stalemates and the stalemate tester (Includes an online stalemate tester)
- Bucket expression arithmetic: more about the expressions used to compute the accepting bucket number(s)
- Try out your arithmetic expressions!
- Creating trial list files: Notes on Rule Game Server parameter sets
- Using custom colors and shapes in Game Server 2.*
- Image-and-property-based objects in Game Server 3.*
- Composite image objects, available in Game Server 4.009.
- Using the random board generator with a post-processing script to create predefined initial boards.
- Adding a plan or a rule set to the MLC or APP launch pages
- "Experiment Design Checklist (on Google Sheets)
- Quick start guide: getting started on your laptop (Early 2024, targeting deployment on Plesk hosts)

Special topics:

- [Fairly obsolete] About the initial board settings and the control flow
- About the balancing algorithm, used to assign players to trial lists.
- What's new in Game Server 2.* (slides for a presentation, PDF)
- What's new in Game Server 2.* (same in HTML)

Online tools for experiment designers:

- The clear tables tool. You can use it after you have modified an existing rule set file, and want to make sure that the server reloads it right away.
- The experiment plan validation tool. Use it to check the syntax of your rules, etc.
- The Automatic Rule Generator

### Processing experimental results

Read here about the data saved by the Rule Game Server, and about the tools that can help you use them

- About the data files (read the 2nd and 3rd sections)
- Where are the analysis scripts? (and how to get them if you don't have them yet)
- The Export Transcripts tool. It selects the transcript files for a group of players based on your criteria, and saves appropriate extracts from the SQL tables.
- The Analyze Transcripts tool
- Analyze human results: M-W comparison of rule sets -- online form
- Analyze human results: M-W comparison of rule sets -- about the command-line tool
- Drawing and annotating ECD curves
- Pulling data from a remote server (e.g. from a Plesk host to a CAE host) fof analysis

### For the ML / AI team

- The Captive Game Server (CGS)
- Board display tool (for Shubham and the rest of the ML team)
- The Machine Learning Challenge (MLC):
  - MLC Participant's Guide
  - MLC Participant's Dashboard (submit results here; nickname password required -- obtain it from Paul or Eric)
  - MLC Manager's Guide
  - MLC Manager's Dashboard
- Gemini Harness: The Rule Game engine playing with Google Gemini
- Installing Gemini Harness App on your computer

### For partners at other institutions

- Set up your own Rule Game Server!

### Client-server interaction

If you are designing a TypeScript/JavaScript front end GUI app to run in a web browser, or an Android app, these documents discuss how the front end app is to talk to the Rule Game Server

- [Obsolete]: Web API: First Batch (for research API, without player name and SQL database). This also includes HTML play (old version), an HTML-GUI interface for the first batch API.
- Web API: Second Batch (in use for the main public-facing API). This page also includes:
  - HTML play (second batch -- current version),
  - GetImageServlet (since ver. 3.0)
- Web API: Pregame and postgame experience . (Since ver. 6.000)
- Web API: Two-player games (2PG). (Since ver. 7.000)
- Two-player games (2PG) with a bot. (Since ver. 8.012)
- Bot assist. (Since ver. 8.014)
- The DOUBLING incentive scheme
- Java API documentation

### Managing the Game Server

- SOP: Maintaining and deploying server code and server data files

### Working on the GUI client

- SOP: Development work on the GUI client

### Old proposals

Kept mostly for a historical reference

- Proposal: wildcard syntax for a wider object space (2021-04-01) -- an early proposal, mostly superseded by subsequent ones
- Proposal: image-and-property-based description of objects (2021-04-13) -- mostly implemented in GS 3.*, and described in Image-and-property-based objects
- Proposal: code snippets (2021-05-20) -- still outstanding

## Github repositories

- Rule-Game-server - server code
- RuleGame - client code.
- Rule-Game-game-data - experiment control files (trial lists, shapes, etc).
- ruleGameHumanDataAnalysis - ask Aria for access and details.

## The front-end (GUI) tools, from Kevin and Aryan

- GUI play (standard client) -- go here to start playing any game! This is what M-Turk and Prolific players see, if they use this version of the application
- GUI play (rule debugging client, formerly known as the dev client) -- go here to start playing any game! This comes with more debugging info about the rule set etc
- Normally, you don't need this form: GUI play (choose your client), but you can use it if you want to access a version of GUI client from some oddball location
- Launch form for Tanvi: (Experiment plan=) (Player ID prefix=)

  Dev client Prod client |  | Show intro Skip intro

  The above form uses the POST method, but the underlying service can be used with the GET method as well, using URLs such as http://action.rutgers.edu/w2020/front-end-form-2.jsp?exp=U/JF/tht/exp1&prefix=RU-JF-THT-&dev=false. (Change the host name and the experiment plan name as appropriate).
- Launch form for Jacob (with redirect): (Experiment plan=) (Player ID prefix=)

  Dev client Prod client |  | Show intro Skip intro

  The above form uses the POST method, but the underlying service can be used with the GET method as well, using URLs such as http://action.rutgers.edu/w2020/front-end-form-3.jsp?exp=RU/JF/tht/exp2&prefix=RU-JF-&dev=false. (Change the host name and the experiment plan name as appropriate).
  Note that using this kind of launch form has a major disadvantage: every time you click on this URL, you'll get a new player ID!
- GUI play (standard client) for UW students
- Board builder (dev)

## Special launch pages

- Launch pages for staff and students

Software Copyright University Wisconsin-Madison, under Apache License, Version 2.0