│

Exploring Quality, Complexity, and Creation

Tag: Quality

  • Power to Life, Power to Death – Power in Complex Systems

    Power to Life, Power to Death – Power in Complex Systems

    Lately there has been much talk about power. From social justice warriors to company middle managers, power is and always has been much deliberated. Usually the big question is “who has power?” But the bigger question is “who should have power?” 

    But what is power? Do we all have a good understanding of what power is? Do we all agree on what it means? What I would like to propose is that, by looking at complex systems, there are two distinct types of power. One type leads to new qualities (life) while the other leads a system to destruction and chaos (death).

    Definition of Power

    Before we can look at the two different types of power, we first have to define what power means. What can get confusing is that there are some that use the words “authority” and “control” interchangeably with the word “power.”  Especially those who talk about “leadership.” These words do not mean the same thing. Authority and control are about force, power is about change.

    Let’s define what power is within the context of a complex system:

    Power is the ability of a domain within a complex system to exert change in another domain.

    Power is all about making change. Think about everyday examples of power within a system. Your car, for instance, is powerful because it can get up to speed quicker than most other cars. The power of the car is encapsulated within an accelerator pedal.  Pressing down on the pedal in one car is more/less powerful than pressing the pedal on another. The pedal is a domain in a complex system. It is powerful due to the amount of change in motion it influences in the complex system of the car.

    The term “domain” represent the different interdependent parts within a complex system. The car has many domains within its system: the pedal, engine, drivetrain and wheels are a few. A domain has a responsibility. The engine’s responsibility is to convert fuel to energy, the drivetrain’s responsibility is to transfer the energy to the wheels, and the wheel’s responsibility is to convert that energy into motion. A more powerful car can convert more fuel within the engine into quicker motion through the wheels. 

    More abstractly, power is about the ability to bring about significant changes with a complex system. With that in mind, there are 2 different ways in which change can be produced within a system.

    Influencing Change Through Responsibilities

    The first type of power is influencing change through responsibilities. True power cannot exist without domains fully executing their responsibilities within a system. Domain responsibilities are fundamental to power. This, I believe, is why personal responsibility has always been an important part of western culture. Western culture would not have produced the most advanced social systems in the world without personal responsibility.

    Proper power in a complex system is energy or data that influences change within the responsibilities of other domains within the system.

    With our example of the car, the large amount of energy that is produced by the engine flows through the drivetrain system to the wheels. The wheels produced the desired change (motion) by using the energy from the engine that flowed through the drivetrain. If any of the different domains within the car do not fulfill their responsibility, the car will not move. No amount of energy produced by the engine matters if the wheels can’t turn.

    Domains are not powerful by themselves. Take the engine out of the car and turn it on. Converting fuel to energy without a drivetrain and wheels to convert that energy to motion makes the engine worthless. The true power comes from chaining the multiple domains within the system together to create new qualities. This is why a federal government is meaningless without the state, county and local governments. Or your super “powerful” database is worthless without an API and graphical interface in your computer system.

    Similarly, all domains must be relatively robust with regard to the amount of energy/data that flows through the system. If a car has a diesel engine, but the drivetrain and wheels of a moped, one would not consider the car “powerful”. They would consider the engine “powerful”, but not the car. The drivetrain would simply crumble from the large amounts of energy produced by the diesel engine. A system is only as powerful as its weakest link. This is a central concept of both Lean (production line system development philosophy) and Agile (software system development philosophy).

    This type of power can be seen in all forms of complex systems:

    • Data through a computer system
    • Energy through a biological system
    • Value through an economic system
    • Order through a government system

    The power in all of these systems is the ability to exert change through the system. The power has to be exerted through domain responsibilities. If it’s not, then responsibilities start to accumulate within a domain. This leads us to the other type of power.

    Usurping Responsibilities

    The other form of power is the use of usurping responsibilities to produce change. Each domain contains a responsibility, but if some domains are not properly fulfilling their responsibilities, then there is a natural reaction of other domains to usurp the responsibilities of the failing domains. 

    A sociological example is totalitarianism. Totalitarianism is about centralization of control. In order to have centralization, complexity is usurped into a single domain. An example of this is communism in the former Soviet Union.

    The centralization of the Soviet economy under Stalin was central to the communists scheme of economic and political viability. State ownership of industries eliminated private control, while the party forced collectivization of agriculture bringing farms under state authority. Central planning committees, such as Gosplan, coordinated economic activities, and the government controlled prices, labor, and resource allocation. Investment decisions were directed by the state toward specific industries outlined in the plans.

    While centralization led to rapid industrialization, the usurping of responsibilities from the lower domains in the economy into the central government resulted in inefficiencies, resource misallocation, and a lack of adaptability, contributing to long-term economic challenges for the Soviet Union.

    I have found this to be true within technology: large, multi-purpose frameworks provide quick/rapid development at first, only to quickly crumble over time. Several of my past jobs were to rebuild a centralized architected system into a distributed hierarchical system.

    Another form of usurping responsibilities within the real world is micromanagement. The excessive control over employees may provide results within the short term, but it hurts employee and company morale over time. If employees feel that they are not contributing to the mission or vision of the company, the employee will be stressed until they are either provided a responsibility or leave the company. This is due to our inherit tribal nature which is a source of purpose and motivation. You can read more about tribalism, purpose and motivation by reading my article The Two Laws Of Tribalism: Biological Laws for Purpose and Motivation.

    There doesn’t seem to be any examples of usurping responsibilities at a biological level that isn’t just a form of redundancy. The closest is compensation mechanisms, but it only involves adjacent organs or tissues assuming additional functions.

    Back to our car example: let’s imagine giving the engine the responsibilities of the drivetrain and wheels. The engine would have to not only produce energy from fuels, but also convert that energy into motion. Just imagine your car being propelled forward by the engine rolling on the ground. I don’t think that would be a comfortable ride.

    Am I Usurping or Am I Flowing?

    At this point you’re probably asking yourself: am I usurping power or am I letting power flow through my responsibilities? Yoda sums it up brilliantly: “you know when you’re at peace.” In my experience in the software industry, when everybody is properly fulfilling their responsibilities, people tend to describe their experience as being “part of a family”.

    Go on LinkedIn and you will see all the posts about how your fellow workers are not “Family”, but I think they’re missing the point. Qualitatively, what I believe people mean when they say they’re part of a “Family” is what Christians call the “fruits of the Holy Spirit.” Charity, joy, peace, patience, kindness, goodness, generosity, gentleness, faithfulness, modesty, and self-control. When everybody is focusing on their responsibility, and together everyone’s responsibilities produce qualities, then all the fruits of the Holy Spirit are present.

    When there is usurping of power with in a system, that is usually manifested through anxiety. Particularly, anxiety about responsibilities. Do you fear losing any of your responsibilities? Do you feel the need to take over somebody else’s responsibilities? I find the first question/thought produces the most anxiety. We are a tribal species and we must feel that we are contributing to the tribe. If any domain is no longer contributing to the overall mission, it’s usually cut out of the system. If you feel you’re no longer contributing to the companies mission, you’ll most likely get fired. Nobody wants that.

    However, being apart of teams or companies where power is flowing through them is truly a wonderful experience. I’ve been apart of 2 companies that I would say I was part of a “Family”. But, the irony is that to get people into a proper state, one might actually have to usurp some responsibilities.

    Parenting

    Viewed from the above context, one would think that power through usurping responsibilities should be considered an absolute evil. However, there is another form of power by usurping responsibilities that is incredibly important: parenting. Parents wield power by temporarily usurping responsibilities from their children, a vital aspect in early life. This dynamic is essential for the protection and guidance of children who, lacking the mental capacity for independent functioning within complex systems, require parental authority. The act of usurping responsibilities is not seen as an absolute evil in this case but rather as a necessary and constructive aspect of parenting, ensuring the well-being and development of children in their early stages of life.

    The job of parenting is to protect the children while also teaching them to become good members of society. From a complex system perspective: the child is considered a proper member when they are balanced with being a consumer and a provider. The only way for the parent to do this is to usurp the child’s responsibilities in our social complex system until they are ready to be proper contributors.

    Apprenticeship is also a scheme for usurping responsibilities until the apprentice is ready to be a balanced consumer/provider. Not only is this good, but it’s vital for the proper passing of skills in any industry. I’m concerned that this practice is slowly dying in most industries, including my own (software).

    Overview

    Power is relative change within a complex system. There are two types of power: Influencing change through responsibilities and forcing change through the usurping of responsibilities. The first leads to new qualities while the other leads to the destruction of the system. Understanding that you are a complex system, and that you are a part of many complex systems will help you focus on what’s important: fulfilling your responsibilities and feeling the power that will flow through you within the system that you are a part of.

  • Tyranny in Software Code

    Tyranny in Software Code

    Proper software development is complex. Some software engineers are creating complex systems without un

    Proper software development is complex. Some software engineers are creating complex systems without understanding the abstract hierarchy of dependencies between different pieces of software code. This can create what is known in complex social systems as tyranny.

    Tyranny in Complex Systems

    When people hear the word tyranny, they think of corrupt oppressive government rule. Particularly government actors that force arbitrary choices upon individual citizens. These choices, or actions, that are forced upon the individual might be arbitrary to the individual, but perceived to makes sense to the higher system domain (the government).

    An obvious example of tyranny is slavery. Governments or powerful citizens forcing back breaking labor upon a subset of individuals in society. Individual freedom, which is important and the lower level of dependencies within the social complex system, is abandoned or ignored by the government for perceived efficiency in the production of material goods or services.

    These systems that force higher level concepts onto lower level dependencies become fragile over time. Southern American states that relied on slavery for many decades are still recovering from the fragile state that the tyranny of slavery caused. Slavery weakened or destroyed individual growth and motivation. It violates the rules of tribalism which is vital for social cohesion. All of this leads to a fragile complex system.

    Tyranny is forcing concepts or actions at the wrong hierarchy of dependencies in a complex system.

    However, social systems that do not force concepts or actions at the wrong hierarchy of dependencies will be robust over time and will have higher probabilities of flourishing in harder times. The federal system is a great example of a social hierarchy of dependencies that has been robust over the years.

    Software Tyranny

    So if tyranny is forcing concepts or actions at the wrong hierarchy of dependencies, how does this relate to software code?

    Below I will provide an example of software code tyranny.

    Example Software System Overview

    The system is an article system, like Medium, that provides the ability for consumers to create articles and share them.

    The Problem

    We needed to enhance the system to use a caching system when users outside of the system read the articles, since there are way more users reading articles then editing. But we can’t use the caching system when users are editing the article since we want the current data available as quickly as possible.

    The Solution

    The article rendering system needs to use a separate cache system for retrieving the data needed to render the article.

    The system at the highest level knows about “editing” and “viewing” when a request comes in to render the article via a query parameter. If it is in an editor, the URL will look like this:https://articleservice.com/article?editMode=true.

    Below is the server code:

    const express = require('express')
    const app = express()
    const articleStorage = require('articleStorage');
    const renderEngine = require('articleRenderingEngine');
    
    app.get('/:articleId', (req, res) => {
      //get article data from storage
      let articleData = await articleStorage.getArticle(req.articleId);
    
      //convert the article data into HTML for rendering 
      let html = await renderEngine.renderArticle(articleData);
    
      //send the HTML back to the browser
      res.send(html);
    })
    

    This is the code of the server for rendering the article. It fetches the data from storage, converts the data to HTML and then sends it back to the browser for rendering.

    Solution by Tyranny

    Now we have our app, we need to update it to use the cache system. Below I will show you how to use tyranny to update the system to do what needs to be done.

    app.get('/:articleId', (req, res) => {
      //get article data from storage
      let articleData = await articleStorage.getArticle(req.articleId, req.params);
    

    We pass in the params from the request to the ArticleStorage (the ?editMode=true that was discussed above).

    Now we will update the dependency code to fetch the article data from the cache system when we are rendering for view mode vs edit mode:

    const cacheSystem = require(‘cacheSystem’);
    const databaseSystem = require(‘databaseSystem’);
    
    export class ArticleStorage {
      async getArticle(articleId, options){
        let articleData;
        
        if(options.editMode !== "true"){
          articleData = await cacheSystem.getCacheForArticleId(articleId);
        }else{
          articleData = await databaseSystem.getArticleByID(articleId);
        }
    
        return articleData
      }
    }

    Can you spot where the tyranny is happening? It’s the if statement

    if(options.editMode !== "true"){
    

    This is a concept (edit mode) that is being forced at the wrong dependency hierarchy. In Domain-Driven Design, the ArticleStorage is in a different domain and the concept of whether to use the cache system should not be coupled to the concept of “editMode”.

    “EditMode” is a higher level concept that does not make sense at the storage level code in the system.

    The High Quality Systems Solution

    The proper solution will look pretty similar, but will have a major impact for the future of the system.

    Since the ArticleStorage is in a different domain, the concept needs to be translated.

    export class ArticleStorage {
      async getArticle(articleId, options){
        let articleData;
        
        if(options.useCacheSystem == true){
          articleData = await cacheSystem.getCacheForArticleId(articleId);
        }else{
          articleData = await databaseSystem.getArticleByID(articleId);
        }

    The ArticleStorage should have an option to useCacheSystem . Now reading the ArticleStorage makes more sense.

    The article rendering route should translate the concept of “editMode=true” to “useCacheSystem=true”

    ...
    app.get('/:articleId', (req, res) => {
      //create article options
      let articleStorageOptions = {
        useCacheSystem: (req.params?.editMode == "true")
      };
    
      //get article data from storage
      let articleData = await articleStorage.getArticle(req.articleId, articleStorageOptions);
    ...

    Now we have a solution that does not force concepts at the wrong hierarchy of dependency.

    A Bright Future

    The pragmatist will argue that our argument above adds additional code that one will have to support in the future, which will make the future worse for maintaining and enhancing the application.

    However, forcing concepts like this in the wrong abstraction layer will only cause issues in the future. What if we want to use the ArticleStorage to retrieve article data for a different part of the system that doesn’t have the concept of “edit mode”? That other part of the system will have to have to translate what “editMode” means, which will add confusion when supporting the code at a later time. Where as the domain translation we introduced is logical and readable, which is more maintainable.

    This form of tyranny limits optionality in the future. It also limits the freedom of responsibility that dependencies need in order to create high quality systems (more on both of these points in future articles).

    Overview

    Tyranny is forcing concepts or actions at the wrong hierarchy of dependencies in a complex system. We have seen this over and over again in complex social systems, but this also takes place in complex software systems. Tyranny should be avoided in any system if that system is to endure the test of time.

  • Goals – Aiming for Subjective Value

    Goals – Aiming for Subjective Value

    People are taught that when you want to achieve something, you must first set goals. And those goals must be measurable. If you wanna lose weight, set a goal of losing so many pounds in a certain amount of time. If you wanna get good at the piano, you must practice so many hours for so many days a week.

    What I’d like to argue is that your goals should be based on something that isn’t measurable. If you wanna lose weight, adjust your life style. If you wanna learn to play the piano, find something fun to play. By setting your goals on something that isn’t measurable, you will shift your focus from gaining an objective value (quantity) to a subjective value (quality) in which only the subjective value will bring true contentment.

    Goals and Quality

    The difference between goals and outcomes is tied to the difference between quality and quantity. Quality is subjective, quantity is objective. If you ask somebody how they would improve the quality of the system, what they would give you is subjective opinions like “improve the interface”, or “make the code more readable”.

    If somebody tells you that in order to increase the quality of a system you must increase a number of something, then they are not talking about quality: they are talking about outcomes or strategy.

    Quality Isn’t Measurable

    Trying to measure quality is impossible. The only thing you can measure is outcomes from the improved quality of the system.

    In the software industry, one measurement of “quality” is code coverage. I’ve already gone over why measuring code coverage is a bad idea in When To Stop Looking at Code Coverage – Goodhart’s Law. However, high code coverage is usually an outcome of a system that has high quality.

    Our software team uses Test Driven Development (TDD) to help ensure that we don’t add bugs into the system over time. The tests don’t improve the quality of the system. We use them to assert that certain expectations on the system don’t change. We could be writing very bad code that is very inefficient, but at least we know we haven’t introduce any bugs.

    So code coverage isn’t a measurement of quality. It’s a measurement of something we did to help maintain/improve quality. Our goal is to make highly usable/scalable/maintainable/extensible software and code coverage is a strategy to do just that.

    Nomological Networks

    Should we still measure anything when trying to achieve a goal? Absolutely! Just remember, any measurement by itself should not be used to validate your goal. For example, measuring how much time one practices piano is a useless measurement if the only thing that was practiced was scales.

    One way to use measurements to help assess quality is by building a nomological network of cumulative evidence.

    A nomological network (or nomological net) is a representation of the concepts (constructs) of interest in a study, their observable manifestations, and the interrelationships between these.

    Wikipedia

    When creating a goal, like learning to play piano, a nomological network is a collection of observable manifestations (like total time practicing scales per day, total time practicing songs, ability to read notes in different clefs, etc…) and how these together help achieve your quality based goal. In his book The Parasitic Mind, Gad Saad introduces the concept of building a nomological network to build a bullet proof case for a truth:

    “The objective would be to build a network of cumulative evidence stemming from widely different sources, all of which serve to construct the final jigsaw puzzle”

    Gad Saad, The Parasitic Mind

    Once you create your quality based goal, create a list of measurable actions or to/dos that you think will get you to your goal. Make the list as big as you can. This is your nomological network. Once you start on your goal, keep reassessing you list. Over time you’ll find that some measurements that you have in your list aren’t helping you achieve your goal. One will have to keep accessing the construct validity of each item in your nomological network. You will have to continually judge your nomological network items.

    Human Judgement

    The best way to really assess your goals is by human judgment. No machine or measurement can tell you quality, yet. The only entity on earth can can assess quality is a human.

    In software development, the best way to achieve quality is by peer review. For our team, code that is checked in, is reviewed by at least two people. This is true for everybody, even our most senior developers have their code reviewed. We’re all human and humans make mistakes. We’re also a lazy species and self discipline can be difficult in the best of times. Having other people review your work is the best way to improve/achieve a higher quality.

    I believe America’s founding fathers knew this when building our judicial system. Judgements in court are not made by measurements but by humans. A smoking gun doesn’t always prove guilt.

    Only a nomological network of cumulative evidence with human judgement can bring us the best quality outcome within court.

    Overview

    Goals should be quality based. Since quality can’t be measured, one will have to use techniques like nomological networks and human judgement to gauge if one is achieving their goal.