0% found this document useful (0 votes)
7 views6 pages

Paper

The document outlines the requirements for implementing an autonomous agent to play the 'Two Flags' game using search algorithms like Minimax, Alpha-Beta Pruning, and MCTS. The agent must be able to play against human and autonomous opponents, start from a specific board position, and operate within a time limit. Additionally, it details the game rules, winning conditions, move representation, and the necessary documentation and submission requirements for the project.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views6 pages

Paper

The document outlines the requirements for implementing an autonomous agent to play the 'Two Flags' game using search algorithms like Minimax, Alpha-Beta Pruning, and MCTS. The agent must be able to play against human and autonomous opponents, start from a specific board position, and operate within a time limit. Additionally, it details the game rules, winning conditions, move representation, and the necessary documentation and submission requirements for the project.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 6

Requirements

• The task involves implementing an autonomous agent that can play the "Two Flags"
game using search algorithms like Minimax, Alpha-Beta Pruning, and MCTS
(Monte Carlo Tree Search).

• The agent must be able to play the game at a high level within a given time limit.

Agent Requirements

The agent should be able to:

1. Play against a human opponent.

2. Start playing from a given board position (SETUP command).

3. Play against another autonomous agent.

Game Description: "Two Flags"

• The game is played on an 8x8 chessboard with two players: White and Black.

• The White player starts first.

• Each player has 8 pawns, positioned initially on the second row for White and the
seventh row for Black.

• Each player must move a pawn on their turn.

• The movement rules for pawns are the same as in chess:

o Pawns move one step forward.

o Pawns can capture diagonally.

o If an opponent's pawn is directly in front, the pawn is blocked.

o On their first move, pawns can advance two squares forward if both
squares are unoccupied.
o An opponent's pawn located in a square adjacent horizontally to a pawn that
has just moved two squares forward is allowed to be captured as if it had
moved only one square. This right is retained only for one turn (en passant -
capture in passing).

Winning Conditions

A player wins if:

1. A pawn reaches the opponent’s last row.

2. All the opponent's pawns are captured.

3. The opponent has no valid moves left.

Game Move Representation

1. Moves are recorded in algebraic notation.

2. The board's bottom-left square is "a1", and the bottom-right square is "h1".

3. Moves are represented by source and destination squares (e.g., h2h4, h7h5).

Game Protocol for AI Agents

• A tournament will be held where agents compete against each other.

• Performance against other agents will significantly impact the final score.

• The game will be managed using a dedicated server that follows the protocol:

1. The agent connects to the server via a TCP/IP socket.

2. Upon connection, the agent receives "Connected to the server!" message.

3. The agent sends "OK" in response.

4. The server sends a Time X command specifying the game’s time limit in
minutes.

5. The agent responds with "OK".

6. The server then sends "Begin", signaling the start of the game.

7. The agent alternates move with the opponent.

8. If the agent wishes to forfeit, it sends the "exit" command.

9. The agent must support the "Setup" command to initialize a board position.
Example
Documentation and Explanation Requirements

In this section, you must answer all questions related to your implementation and provide
reasoning for your choices. Include code snippets when relevant.

Section A: Data Representation and Structures

1. What data structure did you use to represent the game board?
2. What data structures were used for the agent’s decision-making?

3. How does the algorithm generate moves?

4. How does the algorithm detect terminal states?

5. How does the algorithm manage time constraints?

6. Does the agent compute moves while waiting for the opponent’s move?

Section B: Evaluation Function

1. Describe your static evaluation function.

2. What game features does it consider?

3. How does it extract these features from the current board?

4. How does it weigh them?

5. What is the function's evaluation range?

6. What value does it assign to terminal positions?

7. How did you test its accuracy?

8. Demonstrate the function’s evaluation for several key game states.

9. Do you use it for only leaf nodes or also for pruning or/and also for inner nodes?

Section C: Search Algorithm

1. Which search algorithm did you use?

2. Did you use heuristic search techniques?

3. Did you use transposition tables?

o If yes, how were they generated?

o What data was stored in them?

o How did you utilize them in the search?

4. What were the minimum, average, and maximum expected search depths from
the algorithm?

5. What is the branching factor of the game?

6. What is the effective branching factor of the agent?

7. Did you use forward or backward pruning? If yes what is the effect of the pruning
on the algorithm’s effectiveness.

8. Did you implement search extensions?


o If so, under what conditions?

o What was the criterion for stopping the extension?

Section D: Learning and Optimization

1. Did you use learning or optimization algorithms to improve your agent?

o If yes, describe them.

o What were the stopping criteria?

2. How did you evaluate performance improvements during development?

o Did you use different versions in order to examine your algorithm?

o How did you determine which version was better?

Section E: General Questions

1. Describe your development process.

2. What general principles regarding the “Two Flag” game did you learn from this
project?

3. What conclusions did you draw from the project?

4. What improvements would you suggest for future versions?

Submission Requirements

The following must be submitted:

1. Project Documentation answering all required questions.

2. Source Code in any programming language (properly documented).

3. Executable Files (EXE) or compiled versions.

4. Instructions for Running the Agent:

o How to start a game against the agent.

o How to interpret the agent’s output.

o How to initialize a game from a specific setup (SETUP command).

5. At least one example of a game where the agent won in an interesting way.

You might also like