alvrod / blog

Seven Chunks of Wonder

Overview

In this article I will map a few results of cognitive science to typical phases of growth as a software engineer.

While I will mention the main scientific papers, I am not a scientist and we could think of this article as a metaphor built on those results to build an evocative idea, rather than a scientific theory.

The Magical Number Seven, Plus or Minus Two

This finding by Miller is so famous that it has its own wikipedia page! The way I interpret it - one can only hold so many concepts in their head at one time; in fact, around seven concepts.

Further results by Baddeley and Hitch connect this limit with language. Because to think of a concept, we must name it (and verbalizing or rehearsing the names actually helps with recall), they found that the limit could maybe not be seven concepts, but rather two seconds worth of syllables describing those concepts. To quote from this this paper:

To cut the arguments of Baddeley et al. short: constant is nothing but the duration of about 2 sec, not the number of any “chunks” or any better identifiable units such as words or syllables. If measured in terms of the number of items (syllables, words), the span of immediate memory depends on the articulation rate, i.e. the number of syllables or words that a person can articulate within about 2 sec.

This could be related to how much we like to use acronyms and technical jargon. By reducing the number of syllables it allows us to talk about more things at once. Acronyms are one way to stretch the “magical number seven”.

Chunking

However, what are these concepts that one is remembering around seven of? They could be anything. Miller called them “chunks”, and the process by which we create them, chunking. in this post I want to talk about chunks which are conceptual abstractions. But it is worth mentioning some of the classic ways in which we take advantage of chunking in our everyday life.

Phone numbers

While recalling a mobile phone number such as 9849523450, we might break this into 98 495 234 50. Thus, instead of remembering 10 separate digits that is beyond the “seven plus-or-minus two” memory span, we are remembering four groups of numbers.

Chess

Chess masters can look at a chess board for a second and accurately reproduce it from memory. But a chess board has 32 pieces, which is a lot more than seven. So how do they do it? It is understood to be an example of chunking. By their experience and skill, chess masters do not need to remember the position of each individual piece. They recognize patterns in the layout, which are common and describe the whole position of the board. This way the whole layout is chunked into “around seven” parts and they can remember those.
Anecdatally, as a mediocre chess player who dabbles in Blitz (where most moves are played within 1-2 seconds) I can personally relate to identifying common positional patterns and taking action based on that without looking at each piece on the board.

Moreover, to further support the chunking theory, this chunking ability only works with actual boards which could happen in a real chess games. When presented with randomized boards, chess masters are not able to recall them any better than someone who doesn’t play chess at all.

For a detailed paper on the matter, Recall of Briefly Presented Chess Positions and Its Relation to Chess Skill is a good reference.

“Two Pizza” team size

“We try to create teams that are no larger than can be fed by two pizzas,” said Bezos. “We call that the two-pizza team rule.”

So, Bezos’s two-pizza rule works out to at most six or seven non-ravenous people, and we are finding a nice coincidence. It is hard to manage large teams while keeping everyone in mind; so from a manager point of view it also makes sense to keep their number of reports within what one can hold in their mind at one time.
This article is based on Hackman’s n(n-1)/2 formula for communication lines in a group of people, which is definitely a strong factor here as well.

Otherwise we start treating people as cells in a spreadsheet, or points in a four quadrant box, and nothing good ever comes out of that1.

To-do lists

Because we forget things after about seven items, to-do list apps, spreadsheets or ticketing systems are commonly used to prevent forgetting things.

Chunking and Abstractions

In software engineering we are constantly dealing with abstractions. Interestingly, from linguistics:

chunking is sometimes known as “levels of abstraction”, because the higher up the Hierarchy of Ideas you go, the more abstract the concepts you are dealing with

So now we come to the main point of this post: by the acquisition of experience and skill, we grow as software engineers by gaining the ability to reason about systems at increasingly larger levels of abstraction, therefore being able to work effectively with more pieces of the system at once in our mind.

As a junior engineer one works with small code units. A block of code in a function (perhaps around seven lines of code). One unit test.

Later we can think about entire services.

Later still about whole systems.

Even later about the machinery of organizational structure and incentives that cause those systems to be created.

By the recognition of these layers of abstraction, we can exert our influence at the right level depending on the outcomes that we seek.

Thanks to the increased chunking, we are able to reason about an increasingly larger scope.

References


  1. I realize that the scientific evidence around chunking is about working memory, or recall of information which has not been committed to long term memory. Hopefully any manager has committed their team to long term memory and I am making sort of a stretch, based on personal experience, that the magical number seven also makes sense when thinking or making decisions about well known information. ↩︎