Communication - Game Theory and Team Collaboration



Introduction

This page provides a documentation of my journey in the fourth fortnight. The fortnight's reflection highlights my growth in communicating abstract concepts to diverse audience through conscious team strategizing and ideating, to developing tic tac toe algorithms and translating the algorithms to programs that teach tic tac toe to computer agents. Prior to this fortnight, I had always played tic tac toe but had never really thought of explaining the strategy to agents with no experience and some language barriers. The activities helped me reflect on and built my documentation and communication skills, especially to groups with absolutely different backgrounds from mine.

Learning Resources

The skills session was preceded with learning about intelligent agents - their attributes, kinds and environments, versions control, and open-source community code of conduct from these resources:
  • Chapter 2 of Artificial Intelligence: A Modern Approach by Russell and Norvig, 2016
  • An introduction to version control with git material
  • Python developers community code of conduct

Key Skills

  • Problem Solving
  • Algorithm Design
  • Documentation
  • Communication
  • Git and Version control
  • Python

Activities

Study and Define Tic Tac Toe strategy

For this activity, I was paired with Ned. This activity involved playing tic tac toe repeatedly with Ned while consciously noting his and my moves and deciphering our strategies for winning the game. We took turns in playing first and paid attention to the moves we make as the first player, as the second player, and how we try to win the games and prevent the opponent from winning. Tic Tac Toe is a game I have been playing since I was a child, and this activity was rather an interesting one. In trying to formalize my best winning strategy against my opponent, I studied our playing patterns, tried to infer our thoughts process and how our moves influenced each other's decisions. Trying to represent/document to how I reason, strategize and restrategize based on my opponent's move, and how I figure out his strategies and predict his next move was an eye-opener on just how much processes go "unnoticed" when we do things intuitively.

At the end of this activity, we both had our strategies defined and we discussed and compared what we had individually documented based on our observation as we played the game. It made us reflect on what we might want to think about when we document or communicate abstract concepts.

Representing the Strategy in a Flowchart

For us to codify the defined strategy, we needed it to be in a more explicit and logical form. In this activity, we redefined the strategy using algorithms and flowcharts. Unlike what we previously had, algorithms and flowcharts represents solutions as step-by-step processes - our strategy didn't fully capture the steps.

To achieve this, we simulated every possible scenario, observing our decision processes, now paying attention to our moves as we progress (steps). Our attempt to represent it in a flowchart made us realize the complexity and dynamics of the decision process; flowchart was quite limiting in representing that. Unlike other step-by-step processes, an agent can take many different decisions given the same condition, having this in a flowchart was tricky. Pseudocode was more flexible in capturing these as shown in the image below.

Before representing our strategy in a flowchart, we tried redefining the strategy for audiences with no experience or intuition for playing tic tac toe; it was interesting to see how much assumptions we had about our audience prior knowledge. Just when I think my strategy is explicit enough, iterating over it exposes some implicitness in it based on some assumptions I had (but didn't know I did). The key lesson here is, our audiences shape the language we use in communicating.

A snapshot of the tic tac toe pseudocode

Coding a Tic Tac Toe Agent

Building on a provided sample code, we are now to codify our algorithm in python to create a tic tac toe agent. Coding the tic tac toe agent involved:

  • Defining 2 states for each player: X and O
  • Defining all possible win combination in a list
  • Getting the tic tac toe board current state in a string format
  • Determine who is playing next based on the board state
  • Writing a function that compare the board state with the win combination to detect potential wins
  • Writing a function that occupy the corner that is best to create a win opportunity
  • If there are potential wins, the agent makes its move there - it makes the agent win or block its opponent from winning
  • If no wins, it makes its move on the next available corner
  • If all corners are occupied, its makes its some other random space on the board
The images below shows the progress of the game from making its move on just the next available space on the board, to making strategic moves based on the board state.

Agent only occupies the next empty space on the board
Agent making move strategically

My thoughts on this activity is best described by the quote "If you can't explain it simply, you don't understand it well enough."

Version Control with a Diverse Team

For this activity, I was grouped with Ned and Rachel to collaboratively build a tic tac toe agent over git. Our group was made of people with entirely different career backgrounds, which made it quite interesting. The experience made me realize how difficult it can be to collaborate with people with diverse background remotely. Before now, I had assumed working collaboratively remotely especially on git is usually smooth, which was mostly because I had only used git collaboratively with programmers who are also familiar with git.

Additionally, I learned to be a better communicator, especially with my code documentation. I usually don't write detailed comments or description in my code because I and my teammates have just enough knowledge of the code-base to understand what is going on. Now, I document my code not just for me and my teammates, but for anyone interested in understanding what the code does.

Challenges and Solutions

  • Communicating in the Right Language: working on the tic tac toe agent made me understand just how much effort one need to put when describing a process to an audience with no or little background knowledge. It took a lot of efforts for me to be able to describe these abstract ideas in really simple terms. It made me think of my past works and how little I had thought about my audience when documenting (I used to think I had no assumptions and it was simple enough).

    Solution: I realized I need to pay more attention to my audience and understand their language. I also iterated my communication strategy over and over until the level I believe is simple enough for my audience (there might still be some assumptions I won’t notice I made because of my level of familiarity with the concepts I am communicating).

    Influence from my Experience: Initially, my codes documentations were not so detailed which I think is due to the fact that I assume most of my codes will only be seen or revisited by me or my team (for group projects). My past audience are people that have the necessary knowledge needed to understand my codes, hence I grew the habit of documenting just few tips in my codes that is enough for them to understand what a code section does.

    Solution: Documenting not just what a code session is doing, but also why it is there - my thoughts and decisions as I code.

Takeaway Lessons

  • AI and Machine learning: Machine learning is just one of the many ways to teach AI systems. AI agents are not limited to learning and taking decisions using machine learning algorithms
  • Team work is important - especially with diverse groups, they bring in multiple perspective.
  • When sharing knowledge especially on abstract ideas, I need to put my audience first! Understand them, their language and background. It helps with getting the message across to the audience.
  • Having zero assumptions about my audience background knowledge of the concept I intend to communicate; I should try to know just how much they know about the concept. It helps set boundaries on how much of the details of the concept I need to share.
  • Revising the document or story I want to share repeatedly. The more I iterate over it, the better it is for me and the audience.
  • Detailed and proper documentation of my work is important. Detailed documentation of programs and progress makes one's work more appreciated and easily understood.

Achievement

At the end of the activities, I:
  • Created an intelligent agents from ideating to programming
  • Collaboratively contributed to a project of diverse team
  • Now understand what goes into creating a simple agent from idea to executable code - understand how human assumptions, intuition, and strategic thinking get translated into computational agents
  • Wrote a detailed algorithm for a complex problem
  • Learned the act of active and detailed documentation of my journey, experience, decision, assumptions when developing algorithms and systems whether personal or shared.
These exercises equipped me with communication skills which I think are essential for every individual, especially those that will be contributing technically to social problems. Detailed and proper documentation makes it easier for me or any other person to pick up my project, understand my thoughts and design process, and modify it accordingly - it is like a letter to someone in the future (it can be oneself). As I go on to tackling social problems, I see myself applying this in my algorithm design process, when coding, communicating or sharing my work with others.