Collab-Anno 6/16/2020

Written by: Rajen Tandel

Yesterday I finished refactoring the React code to use conditional rendering instead of so much React Router. React Router is still useful for displaying the pdf based on a URL. I was trying to use it to distinguish between the logged in and not logged in portions of the application. It was clearly not the right way to go. Luckily I fixed that early since I don’t have too many components yet.

Today I’m going to implement the PDF search component. I already have this component working fine, but fitting it into the application as it stands is a little different. Currently, searching for a PDF takes the user to the annotation screen and Socket.IO creates a room for that PDF. I will definitely have to allow the user (the teacher) to define rooms. Otherwise each of his/her students will be annotating the same document. That would be very messy.

I’ll try that today. I’ll just put a checkbox with a label that says “Create New Room”. The workflow isn’t completely defined yet but having this working will help.

Collab-Anno 6–15–2020

Written by: Rajen Tandel

Today I’m going to clean up some of the components I built last week. I was trying to work a little fast and that was a slight mistake. My state management is completely off and I’ll need to rethink it. While reading a book on React, the author suggests writing up the HTML/CSS before adding state to the components. I should’ve done something similar. Refactoring is the goal for today.

Collab-Anno 6–14–2020

Written by: Rajen Tandel

Today I’m going to take a step back from directly working on the project and read a little more into React. I need to learn how to style components in an effective way. SASS has been recommended quite a few times so I’m going to give that a try. The app is coming along well though. I built a lot of the critical components this week. For the coming week, I will rethink the state management and begin styling some of the components. This week is more about learning than developing the app. As I learn about using SASS within a React application, I will try to implement the techniques. I’ve found that if I don’t work like this, I forget a lot of what I read.

In addition to styling, I’ve been learning about Jest and testing React apps. This week I’ll be implementing Jest tests with all of the existing components to make sure everything is functional. The app is small enough that I can click around and input the data myself but the automated tests will help in the long run.

Collab-Anno 6–13–2020

Written by: Rajen Tandel

The RegisterUser component was implemented yesterday. It can now send data back to the dashboard page. This is not how the workflow of the application will work once the backend and database are attached.

For now, the app allows a user to register, login and add courses. The plan is to rename classes to courses. Calling the classes courses will fix some annoying name clashing later.

The next step is to make it look nice.

Plan for today:

  1. Sketch a few designs.
  2. Learn the basics of SASS and implement some styles on the Landing Page.
  3. Build the PDF List page.

The plan for tomorrow is to create the PDF List component. This will be arbitrary local PDF documents for now. It will eventually allow the user to upload his or her own PDFs.

Hey thanks a lot for this. This was so helpful.

Written by: Rajen Tandel

Hey thanks a lot for this. This was so helpful.

I was trying to implement a login/register component. I’m using React router so I was trying to figure out how to send the data back to the landing page. The app will use a database for these things later.

Thanks again

Collab-Anno 6–12–2020

Written by: Rajen Tandel

Yesterday I got the round trip of a teacher logging in and logging out. This will have to use data from a database and have some string parsing to validate inputs. Implementing the back end will be for another day. The piece of advice I liked from the React book, to start with with basic HTML/CSS and add state in later. I’m still just learning React so deciding where to place the application state seems to be a complicated matter. For now, the app simply manages whether somebody is logged in or not.

Today I am going to build a functional registration component. There is a button that takes the user to this page. It isn’t connected to a database or anything so it is just a static form for now. I’m going to have it update an array with the new user. Then use that array to compare the login page credentials against.

Collab-Anno 6–11–2020

Written by: Rajen Tandel

Yesterday, I implemented an input field and an add button to allow the teacher to add a class to his/her list. Today, I’m going to implement conditional rendering to check if somebody is logged in and act accordingly.

This may be a matter of passing props around.

If somebody is logged in, the person will see his or her dashboard. I will also need to add the logout button

Collab-Anno 6/10/2020

Written by: Rajen Tandel

Today I am going to plan out a portion of the “Logged in as Teacher” page. For now, it only contains a list of classes. Maybe I should add an AddClass Component next. That’d be helpful for when the teacher is creating a new class. I’ll go ahead and do that today. Ran a little late on this one.

What is Web Development? Important Points and Takeaways

Written by: Reece Adkins

Disclaimer The following is a reflection on my reading from Chapter 1 of Fundamentals of Web Development (2nd Edition) by Randy Connolly and Ricardo Hoar. All credit for illustrations and "Key Point" bullet points go to the authors of this book. Bullet points labeled "Takeaway" are my own thoughts and are in my own words. This post is serves as a commentary and reflection on the chapter, not as a summary or a publishing of the contents of the book. It is meant to help other JMU CS students by highlighting what I thought was important so that they can reflect after they read the chapter themselves.

Disclaimer Fair use is a legal doctrine that promotes freedom of expression by permitting the unlicensed use of copyright-protected works in certain circumstances. Section 107 of the Copyright Act provides the statutory framework for determining whether something is a fair use and identifies certain types of uses—such as criticism, comment, news reporting, teaching, scholarship, and research—as examples of activities that may qualify as fair use.

Figure 1.1 The web development ecosystem
  • What does web development consist of?
    • Key Point Figure 1.1 imagines web development as a building with three levels.
      • The basement has the foundational components that are necessary to make everything work, but operate out of sight
        • Networking, Protocols, Servers, Configuration
      • The main level has components that we traditionally understand as being web development
        • HTML, CSS, JavaScript, Server-side languages, etc.
      • The upper level has more advanced topics of web development
        • Algorithms, Security threats, Advanced programming design, etc.
    • Takeaway While the topics on all three of these "floors" may fall under the umbrella of web development, it's not necessary to understand them all to be a successful web developer. Understanding the topics on the main floor is my goal; if I am able to gain an understanding of any top floor or basement topics along the way, then that will be in addition to my core web development skills.

  • How can two computers communicate with one another? How does one computer know what format to deliver a message to another computer in? What does the internet consist of?
    • Key Point Bandwidth is a measurement of how much data can (maximally) be transmitted along a communication channel.
      • Measured in bits per second (bps)
      • A 10-gbps fiber optic connection has far more bandwidth than a dial-up 56-kbps modem
    • Key Point Messages can be split in to small chunks called packets and then be routed to a destination address.
      • Packets can take multiple routes to a destination
      • Not reliant on a single pathway that could fail
    • Key Point A protocol is a formal set of publicly available rules that manage data exchange between two points.
      • Communications protocols allow two computers to communicate with each other so long as they implement the protocol
    • Key Point TCP/IP stands for Transmission Control Protocol/Internet Protocol
      • The internet protocol suite provides end-to-end communication
      • Specifies how data should be packetized, addressed, transmitted, routed, and received.
    • Takeaway Networking allows us to link two computers together and allow them to communicate. Two computers can connect to a network and communicate if they follow the correct protocol. TCP/IP networking is a protocol that has been widely adopted. A message from one computer can be split in to packages. These packages are addressed, then transmitted and routed to the destination address, which is the computer receiving the message.
    • Takeaway The four main layers of the internet are the link layer, the internet layer, the transport layer, and the application layer. All four layers play important roles in establishing end-to-end communication under the TCP/IP protocol.
    • Takeaway The World Wide Web, or just the Web (WWW) is only one part of the internet. Email (via SMTP) or file transfer (via FTP) are examples of uses of the internet that do not include the world wide web.

  • What comprises the world wide web?
    • Key Point Five essential elements of the world wide web were created in the 90s:
      • A Uniform Resource Locator (URL) uniquely identifies a resource on the world wide web
      • The Hypertext Transfer Protocol (HTTP) describes how requests and responses operate.
      • A software program (later called web server software) that can respond to HTTP requests.
      • Hypertext Markup Language (HTML) to publish documents.
      • A program (later called a browser) that can make HTTP requests to URLs and that can display the HTML it receives.
    • Key Point The Request for Comments (RFC) archive lists all of the Internet and WWW protocols, concepts, and standards.
    • Takeaway HTTP tells me how I can request something from a particular location and receive a response from it. A URL tells me where something is located on the web. A web server can receive and respond to my request for information. HTML is a language that allows me to create documents that will later be viewed on a web browser. A browser makes an HTTP request to a URL then shows me the HTML that it gets in response to the request.
    • Takeaway Web apps are accessible from any computer that's connected to the internet. Web apps work across various operating systems and browsers.
    • Takeaway Concerns about the internet include security issues when transmitting private information across the internet, web apps not appearing the same way on different browsers, the need to have a reliable internet connection to use a web app, and many others

  • What is the difference between static and dynamic web pages? What is Web 2.0?
    • Key Point Static websites consist only of HTML pages that look identical for all users at all times.
    • Key Point A dynamic server-side website has page content that is being created at run time by a program created by a programmer.
      • This page content can vary from user to user
    • Key Point Web 2.0 refers to participatory websites that emphasize user-generated content.
      • For users, this referred to an interactive experience where users could contribute and consume web content
      • For software developers, this meant that programming logic had to migrate to the browser. This required learning the programming language JavaScript.
      • Popular websites today that fall in to the Web 2.0 category include Facebook, Youtube, and Wikipedia.
    • Takeaway If a web page is static, it is just an unchanging document that is displayed in my browser. When a web page is dynamic, that means that the actions of the end user are changing the web page. This requires programming logic, which can either happen on the server side of the web application, or on the client's side of the web application. Server-side programming can be done in any server-side language, such as PHP. Programming logic done on the client-side is often done with JavaScript, which will be documented heavily in later posts on this website.

Illustration by Michael Kirkpatrick
  • What is Client-Server Architecture? What is the difference between a client and a server? How do clients communicate with a server? What is Peer-to-Peer architecture?
    • Key Point A server is a computer agent that is normally active 24/7 and is ready to respond to requests from clients.
      • Central hub of the client-server model. "Command center"
      •  Hosts or stores web applications and data; performs tasks related to security
      • One server could service thousands or millions of clients, can have high demand
    • Key Point A client is a computer agent that makes requests and receives responses from the server, in the form of response codes.
      • Desktops, laptops, and phones that we often see in our normal lives
      • Can make requests to certain servers for resources and wait for a response
      Illustration by Michael Kirkpatrick
      • A server could act as a client, by requesting resources from another server
    • Key Point In the request-response loop, the client initiates a request to a server and gets a response that could include some resource, like an HTML file or an image.
    • Key Point In a peer-to-peer model, each computer acts as both a client and a server, so each computer is able to send and receive data directly from one another.
    • Takeaway Many clients can connect to the same server. A client-server architecture allows one server to provide resources to a high volume of clients. Imagine a restaurant where one waiter or waitress is serving five tables at the same time. The tables are the clients, while the waiter or waitress is the server. The request-response loop describes how a server requests data, and waits for a response, then can request data again, and wait for a response again. A peer-to-peer connection is very different, where multiple computers can request resources from one another. This type of connection does not even necessarily require the internet.

  • The internet is not magic: what are the hardware components that make up the internet? What is the difference between a router and a modem?
    • Key Point The internet is implemented using millions of miles of copper wires and fiber-optic cables connecting millions of server computers and probably an equal number of routers, switches, and other networked devices.
    • Note Book to consider reading
    • Key Point An Internet Service Provider (ISP) is an organization that provides services for accessing, using, or participating, in the Internet.
    • Key Point A broadband modem (or cable modem or DSL modem) is a bridge between the network hardware outside the house (typically controlled by a phone or cable company) and the network hardware inside the house.
    • Key Point A router is a hardware device that forwards data packets from one network to another network.
      • Routers are one of the most important and ubiquitous hardware devices that make the internet work.
    • Key Point A routing table is used by a router to determine where a package should be sent.
      • Table of connections between target addresses and the destination (typically another router) to which the router can deliver the packet.
    • Takeaway Above I've defined what I believe to be some of the more important hardware components of the internet for us web developers to understand. An ISP sells access to the internet to homes or businesses and maintains wiring and hardware components outside of that home or business that facilitate connection to the internet. A broadband modem bridges this hardware outside of the home with devices inside of the home that can be connected to the internet. The modem is like the doorway to the internet, while the router is distributing that connection to different devices. Chances are if you're connected to the internet in your home, you're using both a modem and a router.

  • What is the difference between back-end web development and front-end web development? Do I need to know how to do both to be a web developer?
    • Key Point Web Development job roles today often include a distinction between front-end development (JavaScript) and back-end development (PHP, ASP.NET, etc.)
    • Key Point Building and maintaining a website is a team effort. The world of web development requires a team of people with various complementary skill sets as well as some areas of overlap and cooperation.
    • Takeaway Back-end web developers and front-end web developers may work on different sides of a web application, but they are still collaborating and working together to create one experience. Web development involves programmers, UI/UX designers, product managers, and many other roles. No one person needs to understand everything or be involved at every level. Web application development is a collaboration between a group of people with complementary skill sets.

Figure 1.23 Web development roles and skills
  • What types of jobs can I do with my web development knowledge? Are their other skills required for those positions?
    • Key Point The following is a list of job titles in web development and the skills that are required for them.
      • Hardware Architect/Network Architect/Systems Engineer
        • Design and manage the the layout of the physical and logical network.
        • Design specifications for servers in a data center
        • Requires networking and operating systems knowledge
      • System Administrator
        • Choose and install network operating system, manage the shared operating system environments for other users
      • Database Administrator/Data Architect
        • In larger companies, there may be many databases from various divisions that need to be managed, secured, and backed up.
        • Performs maintenance on databases and manages access for user and software accounts
        • Requires knowledge of database design
        • Data architect is more focused on the design and integration of data
      • Security Specialist/Consultant/Expert
        • Test for vulnerabilities, implement security best practices, protect website to threats, etc.
        • Requires insight in to security/cyber security. Some companies will outsource this position.
      • Developer/Programmer
        • Positions often begin at the entry level
        • Higher-level decisions left to software engineers and senior developers
        • Typically used to refer to a job more focused on server-side development
      • Front-End Developer/UX Developer
        • For software developers skilled at GUI design and with an understanding of human-computer interaction.
        • Requires in-depth JavaScript skills, good CSS skills
      • Software Engineer
        • Uses established best practices in the development of software
        • Knowledge of software development life cycle (Agile, Waterfall)
      • Tester/Quality Assurance
        • Identifying flaws in software
        • Some test roles are for non-experts, but experts may write automated test suites or develop testing plans
      • Search Engine Optimization (SEO) Specialist
        • Improving discoverability of web content by search engines
        • See Chapter 23 in the book
        • Should be familiar with analytics, testing approaches, social networking APIs, content creation strategies
      • Content Strategists/Marketing Technologist
        • Merge knowledge of new or old web tech with knowledge about audience to create engaging web content
        • Should have writing/marketing skills, knowledge of content management systems, email services, and social networking interfaces
      • Project Manager/Product Manager
        • Web development requires the talent of many different people. PMs communicate between people to get them to work together in an effective manner
        • Knowledge of planning and estimation methodologies, people management skills
      • Business Analyst
        • Speaks to clients and gathers requirements
        • Speaks to other members of a company and creates requirements that software engineers then work on.
      • Other Nontechnical Roles
        • Analytics manager, motion designer, social media analyst, cloud architect, hacker, etc.
    • Takeaway More information about each of these positions is included in the book, but I thought it was important to include every position listed in the book here. Web development is a very large and diverse area of computer science. There are endless possibilities with this part of CS, and you can gain web development skills and apply them to other areas that you are interested in. If you are interested in cyber security, software engineering, or database design, gaining web development skills can gain you a huge advantage in these areas. There are so many different directions you can go in with web development knowledge, so taking time to learn the basics can really add a lot to your résumé and open a lot of possibilities for you.

  • Do all companies hire web developers? What types of companies can I work for?
    • Key Point Consider which type of web development company you may want to work for.
    • Key Point Types of web development companies include hosting companies, design companies, website solution companies, vertically integrated companies, start-up companies, internal web development
    • Takeaway Yes, every company has a website, but consider how massive the internet space actually is. There are a massive range of companies that operate in this space, and the book only lists a few.

Assignments

Draw the Internet

Sketch a representation of the internet on paper.
If it's not obvious, I am not an artist :P



Chapter 1 Review Questions

1. What are the advantages of packet switching in comparison to circuit switching?
  • Circuit switching requires a physical connection to be made between the communicating parties, which must remain for the duration of the connection. This makes it difficult to have multiple connections simultaneously. A packet switched connection does not require a continuous connection, as it splits the message in to smaller packets which do not have to take the same route to their destination. This is more robust than circuit switching because it is not reliant on a single pathway that could fail, and it's a more efficient use of network resources.
2. What are the five essential elements of the early web that are still the core features of the modern web?
  •  URL, HTTP, Web Server Software, HTML, and Internet Browsers
3. Describe the relative advantages and disadvantages of web-based applications in comparison to traditional desktop applications.
  • Web applications are accessible via any computer connected to the internet, while desktop applications require the application to be installed on the computer's hard disk. Web applications are able to be used on different operating systems without any additional work (usually), while desktop applications have to be ported to run natively on different operating systems. Web applications are easier to update because you only need to update the software on the server, whereas with desktop applications every user must download an update to their copy of the software. Centralized storage on the server allows for more secure storage of sensitive data as opposed to storing a lot of sensitive data locally on someone's desktop application and having to send it over the internet every time another computer needs to access it.
4. What is an intranet?
  • An intranet refers to an internal network using internet protocols that is local to an organization or business.
5.  What is a dynamic web page? How does it differ from a static web page?
  • A dynamic web page has content that is being created at runtime by programming logic that was written by a programmer. It has content on it that changes from client to client. A static web page is exactly the same for every client that requests it; it is simply an HTML page that is unchanging, unless the "webmaster" updates the webpage on the server.
6. What does Web 2.0 refer to?
  • Web 2.0 refers to participatory websites that emphasize user-generated content.
7.  What is the client-server model of communications? How does it differ from peer-to-peer?
  • Client-server architecture consists of a server that responds to requests from multiple clients. A client requests information from the server, and the server responds with the requested resources. A peer-to-peer connection is when two computers are connected directly, and either computer can act as a client or a server. Both computers can request and respond to each other.
8. Discuss the relationship between server farms, data centers, and Internet exchange points. Be sure to provide a definition for each.
  • Server farms consists of clusters of machines (clusters of servers), and incoming requests are dispersed between them so that no one web or data server is overloaded. These server farms are housed within data centers, which will not only contain many computers and hard drives, but also sophisticated air conditioning systems to keep them cool, redundancy power systems in case of power outage, fire suppression systems, and security personnel on site. Internet exchange points are housed in one or more data centers, which allow one or more internet service providers to interconnect with one another in a shared facility.
9. What kinds of jobs are available in web development? That is, describe the broad job categories within web development.
  • There are jobs that involve designing and maintaining the systems that support web development, such as designing physical networking layers, database systems, or installing and managing network operating systems. There are programming positions that involve solving problems and writing back end code, such as software engineer, software developer, or tester/QA. There are also front-end positions that involve creating the client-side of a web application, such as front-end developer, UI developer, or UI/UX designer. There are also a variety of non-technical positions that involve communication and planning, such as business analyst, product manager, social media analyst, and more.
10. What sorts of service can a company offer in the web development world?
  • Hosting companies can host websites for web developers; these companies maintain servers and allow people to pay to host their websites on them. Design companies can design a user interface mock-up that will later be implemented by a software engineer. Web solution companies can build and deploy a website for their clients. Vertically integrated companies are doing all parts of web development in-house for a client; designing a UI, building the website, and hosting it on their servers.
11. What is a full-stack web developer? What kinds of companies typically hire full-stack developers?
  • A full-stack developer is a web developer who can work on all sides of a web application. This includes the client-facing front end, the server-side back end, and the database portion of the application. Full-stack development is like a hybrid of front-end and back-end development. Many companies are looking to create web pages with dynamic front-ends, server-side code in languages like PHP or C#, and database persistence that stores user information between sessions. Companies who are creating products like this want to hire full-stack developers because they are flexible and can work on both the front-end and back-end of a web application.

    Reflecting on MIT’s Moral Machine

    Written by: Reece Adkins


    Several weeks ago I wrote a walk-through of MIT's Moral Machine, which aims to gain a human perspective on the decisions that self driving cars may have to make in the future. You should read that post here before you read this post. This reflection contains my thoughts on the moral machine, and what I would change about it.

    What is the Moral Machine?

    An example scenario from MIT's Moral Machine
    The website presents us with a scenario where the brakes on a self driving car have gone bad. The vehicle is careening towards a crosswalk of pedestrians, and the car has a decision to make - to switch lanes, or not to switch lanes. You are presented with 13 different scenarios in this context, but there are various parameters that will change between them. Each scenario has different numbers of people in the car and pedestrians on the crosswalk. In some scenarios, you have to choose whether the car will crash in to a concrete barrier, which would kill all passengers in the vehicle. In some scenarios the pedestrians are jaywalking past a red light, bringing obeying the law in to play. We are also presented with various types of people - old, young, fat, fit, male, female, doctor, criminal, and more. After deciding on 13 of these scenarios, the website analyses our responses and gives us details on what we seemed to base our decisions on. These statistics are then compared against the averages of everyone who has ever completed the simulation, so we can see how our responses compare to everyone else's.

    Dr. Iyad Rahwan's Ted Talk

    Dr. Iyad Rahwan
    Iyad Rahwan is the director of the Max Planck Institute for Human Development, and an associate professor at MIT. He is credited for helping to develop the concept for MIT's moral machine. In 2017, he gave a ted talk where he discussed the moral decisions that self driving cars will have to make, what the purpose of the moral machine is, and what their research with the simulation has found. I am going to quote and respond to some points he made in this ted talk, so you may want to watch it before you read the following portion of this blog post.

    Dr. Rahwan begins this talk by discussing the decisions that self driving cars will be required to make. He suggests that while some may believe that the scenarios presented in the moral machine are unrealistic, they are still important. Rahwan states that while self driving cars will eliminate 90% of traffic accidents due to the lack of human error in robotic vehicles, there will still be a small percentage of accidents remaining. How much research will it take to eliminate the remaining accidents? I believe that this is a very important point to acknowledge. While self driving cars will eliminate most traffic accidents, the ones that remain will be the most difficult ones to address. Autonomous cars will have to make trade-offs, and we must think about and discuss these trade-offs and decisions.

    The scenario presented in the moral machine is based on the trolley problem, which prompts individuals to make a decision based on two traditional ethical frameworks. Jeremy Bentham was a 16th to 17th century philosopher who is regarded as being the founder of utilitarianism. Promote the most good, do the least harm. Immanuel Kant was a 16th century philosopher whose ideology surrounded duty bound principles. Kantianism falls under the umbrella of the Deontological ethical framework, which bases right or wrong on a set of rules, not on the consequences of the action. In the moral machine simulation, Bentham would choose the action whose consequence is the least harmful to all parties involved. Kant would make his decision on the rule of thou shalt not kill. Swerving the car means making the choice to kill someone, which Kant believes is wrong, so the car should be left to run it's course. Both the trolley problem and the moral machine are variations on applying one of these ethical frameworks over the other.

    Dr. Rahwan says that most people who complete the moral machine side with Bentham. They tend to make decisions that favor the least harm. This means that people think autonomous cars should make decisions that save the most lives, even if that means sacrificing the passengers of the vehicle. Rahwan goes on to say that when people are surveyed about buying an autonomous vehicle that makes decisions this way, they say they would "absolutely not" purchase them. People want to buy cars that will protect them at all costs, even if that cost is against the common good of all people, which is the least overall harm. This is when Dr. Rahwan begins to set up the real conversation that is to be had surrounding the moral machine: we believe that other people's autonomous vehicles should protect the common good and do the least harm, but I want my vehicle to protect my life at all costs, and I won't buy a vehicle that doesn't protect me.

    So if people don't think an autonomous vehicle protects them at all costs, they won't buy one. If people don't buy autonomous cars, then automobile accidents will not decrease at all. So how should regulators and lawmakers go about solving this catch-22? Do we want vehicles that increase the common good that nobody buys, or vehicles that protect their passengers and may sacrifice pedestrians in the process? Is the former actually even protecting the common good since it may result in more overall deaths?

    This brings us to the heart of what the moral machine is really all about. Yes, the simulation seeks to "form an early picture of what trade-offs people are comfortable with". But Dr. Rahwan even says that the more important goal of the machine is to help participants recognize the difficulty of the decisions that autonomous vehicles, the companies that program them, and the regulators of these companies have to make. This tool is educational. The main benefit the moral machine has to us is to educate us on how difficult these decisions actually are. Which trade-offs are we comfortable with? How can we better understand the decisions that regulators are already making?

    At one point in the Ted Talk (at timestamp 11:50), Dr. Rahwan seems to make light of a certain participant's responses which show that this person tends to punish jaywalking. Their results show that they favor pedestrians who are obeying the law 100% of the time. If you read my first post, you'll remember my result on "obeying the law" was the same as this person's. I made an argument and justification for this result that is, in my opinion, an ethical approach to the decisions that are having to be made. When Dr. Rahwan and the audience laugh at this person's response, I can't help but wonder how this person came to this result? Was this some internet troll, or did this person have logical and ethical arguments for the decisions they made? We will never know, because the moral machine does not collect any data on why any individual participant made the decisions they did. I will discuss this later in this post (see What didn't they ask? What did I want to say? below). I believe this is a big problem with the moral machine.

    So my belief after completing the moral machine and listening to Dr. Rahwan's talk is that this is mainly an educational tool meant to create conversation on the types of decisions that regulators will have to make and the questions we should be asking of our autonomous vehicles. This makes me seriously question several design decisions that were made on the moral machine website and the simulation. Why are they not collecting data on the rationale behind people's decisions? Why do the results of the simulation not promote discussion between yourself and people who made different decisions than you did? Because of the limited scope of the moral machine simulation, I believe it's ability to educate it's participants and create meaningful conversation are limited. I will discuss how I would change the machine to address these concerns below.

    What would I change about MIT's Moral Machine?

    What did I want to know?

    At the end of the simulation, I was presented with a page of statistics about my responses which measures which parameters I valued more during the simulation. It also compares my data to the averages of everyone who has completed the moral machine simulation.

    While I guess that it's interesting that other people value higher "social value preference" than me, or that I value "upholding the law" more than the average person, I don't know what any of this data means. What is the context of this data? What do my responses tell me about my ethics, or how they compare to everyone else? The usefulness of this data is not clear to me. The actual simulation itself is a thought provoking experiment, but the data feels like a missed opportunity. I feel like they could've done more with participant reflection after completing the simulation, which leads me to my next point.

    What do others say about the specific scenarios?

    I know how I justified each choice I made during the simulation, but I don't know how anyone else justified their choices. Am I right or wrong? How did others differ from me? I would like to hear the perspective of people who answered differently than me so that I can evaluate the ethics of my decisions. The moral machine website itself is not facilitating any sort of conversation - you only complete the simulation, see your own data, and see the average person's data. I want to see who agrees and disagrees with me. I want to hear input from others. There needs to be more conversation here.

    What didn't they ask? What did I want to say?

    While each scenario in the simulation gives you a binary choice of swerving the self-driving car or not, the simulation does not ask for any additional information in that choice. Are they only interested in what I would do, and not my justification of my decision? Even the about page on the moral machine website says that the automation of vehicles "calls for not just a clearer understanding of how humans make [decisions on human life and limb], but also a clearer understanding of how humans perceive machine intelligence making such choices." I feel that acting ethically is not always instinctual - it is aided by forethought, conversation, and reflection. The thought process that brought me to my decision is more interesting than my decision itself; therefore, the simulation should ask me to document that. Did people who made the same choice as me have the same justification that I did? Why are people making the decisions that they are making?

    Are there interesting demographic factors that divide people on given scenarios?

    While the results of the simulation evaluate my preference on gender, social value, age, and fitness of the fictional characters in the simulation, it does not ask me any identifying characteristics about myself. Would it be interesting to see if men and women differed on certain scenarios? Or would it be interesting to see if older people seemed to value different things during the simulation than young people did? These seem like they could be valuable data points for research purposes, but they are not being collected.

    What would I improve about the moral machine?

    Before the Simulation

    Not a lot of context or information is given by the website before starting. To ensure the user fully understands what their task is, a short briefing before the simulation on what is going on would be helpful. Collecting data about the gender or age of each participant could be useful for research purposes.

    During the Simulation

    The moral machine hides useful data to the participant unless "show description" is clicked. The mobile version makes it even less clear that there is additional information to be read on each scenario. Some users may not notice all of the parameters in each scenario. This information should not be hidden when the page loads. The simulation should ask for additional written information from the participant on why they made the decision they did.

    After the Simulation

    The data presented after completing the simulation does not facilitate any sort of conversation because you are not able to compare your decision process with anyone else's. You are only able to compare the average of your responses with the average of everyone else's averages. I believe that more information on how I differed from other people, what kinds of people I differed from, and why I differed from them would've made the simulation a more educating experience for me.