View and Build Government Organization like a Software

 

Background

Recently I read several books on software architecture. I also read some books about politics and government such as The Logic of Governance in China (Zhou, Xueguang)  and America against America (Wang, Huning). I feel software and government do have many similarities. For example, both of them are created to execute tasks based on some stable business logic,  to satisfy human needs, to serve a large user base, have a topological structure etc. Software system is more like a simplified version of government organizations. In science, a theory is usually created by studying some simple model with a lot of  assumptions and then applied to a more complicated context. I’m thinking maybe we can do the same thing from software architecture to government organization. 

The goal of this article is to inspire people on different ways of building government organizations based on software development principles and test them in practice. This is more of a collection of my own thoughts on this topic rather than an exhaustive and rigorous research. But I’m also happy to hear other people’s thoughts and suggestions on this article.     


TL;DR

  • Human are less reliable, more flexible, more creative, more complicated and more expensive than computers

  • We should write law and policy like writing well structured code

  • High coupling over large government should be avoided as much as possible though some extent of coupling is helpful 

  • Government organization is like service coordination which is asynchronous and eventual consistent. 

  • The ideal organizational structure should allow any small task to be completed within a lower-level department whenever possible. 

  • Design Principles for a good government organization structure, 

    • Build a good information collecting system

    • Make the organization structure adaptive

    • Scale organization structure

    • Promote engineering culture and mindset

  • A good policy creation and execution chain should have a stable management team at high level while low level employees execute daily tasks and interact with users directly

  • Combine top down and bottom up approach to create policy and determine priorities

  • Another solution for the long execution chain challenge is to split the organization and limit the length of the chain. 

  • Reform is a competition among reformers, other government departments and interest groups. The one who is more coupled with others and has more resources wins the competition. 

  • The 2 challenges of reforming a government are coupling and a government department which is too strong to be reformed. 

  • Reforming Solutions

    • Timely cut it down before it becomes too large.

    • Gradually build a new department that can replace existing ones.

    • Spur creativity from inside the bureaucratic system

  • Tradeoff between reformability and granular control in democratic countries

  • Quality control of the government is important because government departments are not under market competition.

  • Solutions:

    • Build monitoring infrastructure

    • Test policies and laws in some regions

    • Rollback policies when appropriate

    • Fit the policy terms with lawmakers terms

  • Measure productivity and improve with better task planning tool

Terminologies

This section explains terminologies in both software and government organization areas mentioned in the following sections so that people with either a software development background or a government related background could better understand this article. 


Social science related

Max Weber’s 3 types of authority: traditional, charismatic, and legal–rational. 

不完全契约 Incomplete contract

This line of argument is predicated on the premise that when contracts are incomplete and not all uses of an asset can be specified in advance, any contract negotiated in advance must leave some discretion over the use of the assets to the “owner” who has the residual rights of control over the assets. In this conceptualization, a firm is a collection of assets over which the owner has residual rights of control. Different allocations of the control rights give rise to different incentives and powers to the various involved parties.

Zhou, Xueguang. The Logic of Governance in China (p. 57). Cambridge University Press. Kindle Edition. 


非正式制度 informal institutions

Social relations are not only derived from formal authority relationships, but they also stem from informal, social interactions or from other arenas, such as alumni relations, hometown origins, or kinship ties.

Zhou, Xueguang. The Logic of Governance in China (p. 25). Cambridge University Press. Kindle Edition. 


逆向软预算约束 Inverted soft budget constraint

In the meantime, along with the hardening of the government’s budget from above, a new trend has emerged, whereby local governments today look downward to extract extra-budgetary resources from producers (firms), subordinate agencies, or residents under their administrative control. this extra-budgetary resource-seeking behavior resembles the traditional SBC syndrome, but the targets toward which this behavior is directed are in the opposite direction.

Zhou, Xueguang. The Logic of Governance in China (p. 192). Cambridge University Press. Kindle Edition. 


共谋行为 The Collusive Phenomenon in the Chinese Bureaucracy 

A salient organizational phenomenon in the Chinese bureaucracy is that officials in local governments have a tendency to form strategic alliances (Heberer and Schubert 2012, Zhou 2010a) and develop coping strategies in ways that often sidetrack or sabotage state policies or impose their own interpretations of the implementation process, leading to systematic deviation from the original intention of these policies. This

Zhou, Xueguang. The Logic of Governance in China (p. 132). Cambridge University Press. Kindle Edition. 


一统体制与治理规模之间的紧张 a tension between the centralization of authority and effective, local governance

In contemporary China, the fundamental tension between the two can be depicted as follows: The centralized authority has a tendency to move upward the decision rights and resources, away from those local administrations (e.g., the county and township offices) that have richer and better information, thus weakening their problem-solving capacity at the local levels, and therefore incurring the loss of initiative (Qian 1994). Conversely, the strengthening of local-governance capacities implies the expansion of local authority, which often leads to – or is interpreted as – deviations from the center and incurs a loss of control, thereby undermining the legitimacy of the central authority and presenting an acute threat to the latter.

Zhou, Xueguang. The Logic of Governance in China (p. 8). Cambridge University Press. Kindle Edition. 


委托—代理模型 Principal - agent model 

In this model, the principal has ultimate authority in policymaking and in organization design, such as incentive provisions and performance evaluations, among others. The agent is responsible for following administrative fiats and for implementing top-down policies. The principal assigns certain aspects of his authority to the supervisor, whose primary responsibility is to supervise the agent’s implementation of the directives established by the principal. In a concrete setting of the Chinese bureaucracy, in this model one may consider the central government as a principal, the provincial government as a supervisor, and the municipal (or prefectural) government as an agent.

Zhou, Xueguang. The Logic of Governance in China (pp. 55-56). Cambridge University Press. Kindle Edition. 


高度关联型组织与松散关联型组织(tight-coupling vs. loose-coupling)

The tight-coupling mode. The principal retains all three control rights for goal setting, evaluation, and incentive provision, and enforces his directives through supervisors, resulting in a mode of tight-coupling and hence high responsiveness, among the three layers of the bureaucracy. In the Chinese bureaucracy, this is often accompanied by a heightened mobilizational state of policy implementation.

The loose-coupling mode, in which the principal retains the control rights for goal setting, or the goals may be negotiated between the principal and the agents. Both the right of inspection and the right of incentive provision are allocated to the supervisor. In this scenario, the principal becomes a figurehead, his authority is formal or symbolic, and the supervisor retains real authority for both inspection and incentive provision.

Zhou, Xueguang. The Logic of Governance in China (p. 61). Cambridge University Press. Kindle Edition. 


集体无组织行为 collective action based on unorganized interests

How can we explain collective action based on unorganized interests in the state socialist context? My central theme is that the formation and outbreak of collective action are rooted in the particular institutional structure of the state–society relationship. I argue that collective action in China is less a process of purposive and rational organizing than an aggregation of large numbers of spontaneous individual behaviors produced by the particular state–society relationship. Although individuals are unorganized, their actions in pursuit of their own self-interests tend to convey similar claims, share similar patterns, and point to the state, that is, they “converge” into collective action. 

Zhou, Xueguang. The Logic of Governance in China (p. 275). Cambridge University Press. Kindle Edition. 


运动型治理 Campaign-Style Mobilization (CSM)

CSM arises in response to the tensions and challenges in the governance of China. In the face of the large scale and huge diversity in governance, a routine-based bureaucratic mechanism is often ineffective, overburdened, and results in a loss of control by the higher authority. CSM plays the role of (temporarily) disrupting and suspending these routine processes and reorienting the course of action at the will of the top leaders.

Zhou, Xueguang. The Logic of Governance in China (p. 84). Cambridge University Press. Kindle Edition. 


私有信息

McAfee and McMillan (1995) point out that members of organizations have private information due to their specific roles and positions, and they tend to use that information advantage for rent seeking and bargaining.

Zhou, Xueguang. The Logic of Governance in China (p. 7). Cambridge University Press. Kindle Edition. 


层层加码 downward acceleration of the implementation pressures

This explains the commonly observed phenomenon that the intermediate governments adopt a strategy of “downward acceleration of the implementation pressures” by adopting more stringent policy targets for their subordinates in order to minimize the risk of falling short in terms of accomplishment of the tasks.

Zhou, Xueguang. The Logic of Governance in China (p. 77). Cambridge University Press. Kindle Edition. 


拼凑应对 muddling through

“muddling through” in policy implementation – adopting ad hoc, improvised strategies; exhibiting a course of action that focuses on short-term, incremental gains; and sequential adjustments in strategy as conditions change, leading to patterns of shifting courses of action over time.

Zhou, Xueguang. The Logic of Governance in China (p. 164). Cambridge University Press. Kindle Edition. 


锦标赛模式  “tournament” model 

the “tournament” model of promotion in organizations has the following rules: The candidates start to compete at the lower levels for promotion, progressively moving to the next higher level. If one loses in a round of competition, the person is out of the promotion game and is no longer eligible to participate in the next round of competition for promotion (Lazear and Rosen 1981, Rosenbaum 1984).

Zhou, Xueguang. The Logic of Governance in China (p. 198). Cambridge University Press. Kindle Edition. 






Computer science related

Computer opcode: is the portion of a machine language instruction that specifies the operation to be performed.

Continuous integration

Domain-driven continuous integration implies not only an integration of the implementation, using an automated merge/build/test pipeline, but also an integration of model concepts. Concepts can be integrated by the constant exercise of the ubiquitous language in discussions between team members about the model and the application.


Single point of failure

CAP theorem

Orchestration vs Choreography 

Database transaction

In a database management system, a transaction is a single unit of logic or work, sometimes made up of multiple operations. A database transaction, by definition, must be atomic (it must either be complete in its entirety or have no effect whatsoever), consistent (it must conform to existing constraints in the database), isolated (it must not affect other transactions) and durable (it must get written to persistent storage).

Distributed transaction

A distributed transaction is a database transaction in which two or more network hosts are involved. 

OKR: Objectives and key results

Elasticity

the ability of a system to remain responsive during significantly high instantaneous and erratic spikes in user load.


Goal of Government

Note that the government here can be any type of government including federal government, state government and down to the community board. 


Government could have different goals based on different people’s needs. The following goals are the most important ones generated from common sense. 

  1. Provide public services

  2. Keep the society stable and resolve conflicts among people

    1. This requires building a good consensus such as law among the people it governs

    2. The more coupled a group of people are, the fewer conflicts inside the group.

    3. However high coupling usually causes wide error propagation and single point of failure problems. 

  3. Adapt itself to the change of the society

  4. Spur the development of the society to make the governed entity more competitive among other competitors and bring more benefits to people

For example, Max Weber proposed 3 types of authorities:  traditional, charismatic, and legal–rational. I think they satisfy the different goals above. Traditional and legal-rational authorities offer stability and charismatic authority offers society development. 


Some unrelated extended thoughts

Liberty has different meanings in different areas. From an individual person’s perspective, it means more of a level of autonomy. In On Liberty (John Stuart Mill), it prefers liberty to conformity in the society. He holds that a person should be left as free to pursue his own interests as long as this does not harm the interests of others. This can be interpreted in different ways depending on different people’s needs for proportion of autonomy vs relatedness. Some people demand low relatedness among people so that they have higher autonomy and vice versa.  

The history of evolution tells us that creatures adapt to the environment in 2 directions. One direction is that one creature keeps itself as simple as possible like bacteria and virus so that it can propagate quickly. The other direction is that different creatures combine into one by sacrificing some level of autonomy. Each old creature performs a different function in the new single creature so that it is more adaptable to different environments.    

Combining the idea of evolution and liberty mentioned above, I think from the society development’s perspective, liberty is to maximize every individual’s, including minorities such as LGBTQ, opportunity to be coupled into the society with least sacrifice of an individual’s autonomy so that the whole society has larger capability.  This means offering opportunities to allow each individual to contribute their value to the society at their own will instead of limiting their freedom with culture, identity or religion.   

The Differences

Although I listed a couple of similarities between softwares and government organizations in the previous section, I believe clarifying the differences is also very important and helpful.  


Human beings are less reliable but more flexible and creative than computer machine

Computer is more deterministic, follows all rules and executes all commands accurately.

On the other hand humans are less deterministic. They could conduct corruption. They might not execute the command carefully. They might not follow the rule. And they might fake the result etc. This difference lies in the fact that a computer is built to execute commands while a human is born to survive, propagate its genes and pursue different desires. 

A human’s desires are like opcodes of a chip. A command needs to be translated into incentive and punishment on different desires in order to be executed. The more directly a command is translated and the stronger desire it is translated to, the more reliable and efficient the command is.  

A micro service is designed and optimized for a particular purpose. It can execute the same tasks for as many times as possible very stably. But it can’t be run for other purposes unless it is replaced by a different version or new service. 

On the other hand, a human is more flexible and capable of executing different types of tasks. But the capability is still limited to human nature. A human is also less reliable than a microservice. And it is very hard to “redesign” a  human for different purposes. 

Therefore, we can design a special micro service to fulfill a particular coordination requirement. But we can only adapt coordination policies to human nature.  

Humans are often shortsighted because they evolved from a harsh environment and were struggling to survive. The advantage of shortsightedness is that humans are more flexible to adapt to new changes. The disadvantage is that once a human find a comfort zone, he rarely comes out of that and finds a better comfort zone.  

On the other hand, an algorithm can be designed and stably executed to achieve a long term goal. But it couldn’t adapt to new environments and cases which weren’t considered when designing it. 

Therefore humans could overcome shortsightedness by developing a software to achieve a long term goal.   


Human needs are diverse, complicated and deeply coupled together

A software usually only serves a simple set of human needs such as information collection, traveling and documentation. It is deployed to similar computers which is easy to manage at a large scale. 

On the other hand, even the smallest government like human organization such as HOA has a very complicated job. Different residents have different needs which the HOA needs to satisfy. They also have different backgrounds which HOA board members would be elected from. Different neighborhoods have different conditions and special issues which HOA needs to handle. Therefore, it is much harder for a government organization to scale in large physical regions and diverse populations. 


The coupling among micro services is lower than human organizations. Because it is to satisfy only a small set of user needs. And the dependencies among micro services are intentionally limited during design. Most micro service communications are allowlist based. The developer usually needs to specifically allowlist an action or a sub service in a micro service to be called by another micro service. Negotiation process is rarely needed between micro services because the contract is usually well designed in advance. And the information in both sides is usually transparent enough to find a fair solution for both sides. 

On the other hand, the coupling among human organizations can be very high. Because it satisfies a larger set of human needs. Many dependencies between one organization and another, or government and citizens are blocklist based. For example, in history, many laws rarely limited the governments or authorities’ power. As long as an action was not prohibited by a law, the government could conduct that action. So it is easier for human organization to increase coupling to a very high level. The informal institutions and Inverted soft budget constraint phenomenon mentioned in Zhou’s book are both good examples. 

Negotiation process is common among human organizations. Because a lot of resources, interests and solutions are involved in 2 human organizations’ contract. And humans can find creative ways to build connections and contract. This results in higher coupling among human organizations.



Human resource is expensive for an organization 

In a distributed system, a worker can switch among different tasks based on priority quickly and reliably run for most of time from day to night. When it is idle, its maintenance  cost is very low.  And the cost of switching between idle and busy states is also very low. Communication among micro services also has low cost because of simple interfaces and protocols. 

On the other hand, humans are more expensive in doing the above things. Humans have inertia. They cannot quickly switch between multiple tasks and prefer doing the same task for as long as possible. Humans can’t work day and night either and need more time to rest. Though a company can be more flexible on human resources and hires more contractors, the hiring and training cost is still high. And communication among humans is usually conducted through email or by scheduling a meeting which is much slower. 


Government is more of a monopoly while softwares are in market competition

In a market economy, a user can usually easily replace one software with other alternatives. Thus, he only needs to care about which software’s features satisfy him best. He doesn’t need to care about whether the software company runs efficiently without any corruption. 

On the other hand, though some officials like congressmen, senators and presidents can be replaced by periodic elections, it is harder to replace them and it is even much harder to replace any government institution. So the government is more like a monopoly company in a market. To improve its service quality and efficiency, a high transparency level is required to allow more monitoring and feedback. 

Rule making and consensus reaching

Rule consistency

In software, many business logics are based on the same concept while developed for development for different features. Their interpretation of the same concept might be different because of different feature requirements and contexts. Such inconsistency could cause many inefficiencies. For example, it might cause communication friction among different features’ users on different understanding of the same concept. It might cause negotiation between different features’ owners about whose interpretation of a concept is the correct one. It will be hard to develop common logics on shared concepts for all related features.  In software engineering, such inconsistency can be averted by developing shared and abstract business logic for common concepts and incorporating them into implementation of different features.  

Human laws are like business logic in a software. Human laws need some abstract meta rules to prevent contradictions and conflicts. The constitution serves a similar function. Every new law must be tested against the meta rules. The Supreme Court can play the role of constitutional review in this regard. Of course, specific cases can also be brought to the Supreme Court to be arbitrated directly by meta rule if there is no corresponding legal provision. 

The meta rule should be as simple as possible. Otherwise, over time, the domain model of different political factions will become increasingly divided, leading to different interpretations of the constitution. For example, in some cases where the number of majority and minority decisions of the Supreme Court is very close, the legislative part, that is, the parliament, needs to carry out continuous integration at this time on the laws by finding new consensus and amending the laws. 

Ideally the parliament should regularly carry out continuous integration from time to time. However, the members of parliament are busy vying for the interests they represent and usually have no incentive to do this. Only when a crisis occurs, such as a social campaign or a deadlock between the two parties in parliament or a tie in supreme court ruling, will they think of seeking consensus. This is similar to the situation where software development only focuses on feature development and not on architecture quality and tech debt. 

One solution is to promote an engineering culture. Legislators with an engineering mind should pay more attention to technical infrastructure aspects of the laws in the legislative process such as law readability, simplicity, consistency, coupling and so on. They should also improve the laws by adding small consensus and doing small refactoring in the laws from time to time. 


How to make rule satisfy as many people as possible

A common complaint in the current legislative system is that laws are more controlled by small lobbying groups and couldn’t fully reflect the desires of constituents. However voters have a way to supervise and provide feedback by deciding whether to re-elect a particular lawmaker in the next election. Perhaps a better approach would involve blockchain and smart contracts, such as providing bonuses to lawmakers only when they achieve specific tasks.

Laws and contracts are analogous to product requirements in software development. The ideal feedback mechanism would be market-driven, where the government, as a product, could be abandoned and replaced if it doesn't perform well. However, due to the sheer scale of government institutions, comparable to infrastructure like power grids and railways, they are not easily replaceable. So replacing lawmakers, the product managers, becomes the primary option.


Another challenge is that government and legal affairs are very complex, and it's challenging for voters to oversee every vote and ensure lawmakers prioritize correctly. Voters can only focus on major needs, while other requirements might be influenced by lobbyists or ads. Similar to software product managers, lawmakers also face the challenge of choosing the laws which satisfy their users’ interest while balancing with law implementation feasibility, efficiency, economic and political factors, and personal interests. Sometimes, product managers cannot fully grasp user demands and must rely on a general strategy. This creates a trade-off between consistency and latency. High consistency means new laws highly align with the composite expectations of all constituents, perhaps even requiring nationwide referendums for every matter and its priority. However, reaching consensus can be time-consuming and inefficient, resulting in low efficiency and high latency. Delegating most affairs to lawmakers for representative voting and only auditing their overall performance can improve efficiency. The advantage of lobbyists is their ability to efficiently translate certain demands into executable product requirements, as voters might not know what is feasible or what they truly need, similar to app users.


To achieve both consistency and reduced latency, it is necessary to enhance infrastructure, such as a more transparent and easy to use information reporting system and more tracking metrics. However, it ultimately depends on each constituent’s time, capability, and efficiency in processing information and evaluating lawmakers’ decisions. Increasing productivity and creating more leisure time could grant people more opportunities to engage in politics, which is another form of infrastructure improvement. Additionally, clearer categorization of national affairs can aid people in understanding information better. Finally, just like many user engagement tricks in software, the government can use similar tricks to increase constituent engagement.


Nevertheless, the government lacks the incentive to implement these improvements as it might not secure more benefits for them. Therefore, technical bureaucrats, akin to architects, need to strive for this. Similar to app development, while there is constant pressure from stakeholders to add more features, a good architect should resist such pressure and spend more time on reducing technical debt and enhancing tech infrastructure. Another incentive for lawmakers to improve infrastructure might be creating metrics of how many infrastructure improvements a lawmaker did and ranking all lawmakers. 



Strategy to make rules and policy quick to develop, easy to change and implement.

In software development, it is very important to make a software quick to develop and easy to change so that it can quickly adapt to changing requirements with minimum cost. Governments also face a rapid changing public opinion and struggle to adapt to them quickly. So software development principles for quick development speed and ease of change might also benefit government rule and policy making. The followings are some principles inspired from software development principles. 

Essentials for law and policy design decision making

  1. Decision must reach entire government with good communication

  2. Absorb feedback from low level government officers

  3. Policy must not be too restrictive and allow for evolution with feedback otherwise, it will be too expensive to enforce

  4. Best people should be evenly distributed among policy making team and policy executing team

Government policy making should be data driven. Decisions should be backed by data. And decisions can be corrected if the new data shows a changing pattern.

Being data driven is a good start, but in reality, most decisions are based on a mix of data, assumption, precedent, and argument. It’s best when objective data makes up the majority of those inputs, but it can rarely be all of them.

Also it is better to have a rule and policy design doc to document the data used, assumption made, precedent and argument etc. so that other policy implementers can comment on it efficiently and reach consensus on how to implement the rule and policy. 

Good transparency in the policy making process is needed so that the government could collect early feedback from the public because detecting problems early in the development workflow will lower the cost of solving it significantly.


It is better to fail fast and iterate. Failure is a process to learn lessons.

In government, law and policy are driven by citizen’s support. But popular policy doesn’t always have good results. So it is better to make simple policies or laws first. Then test if they can be effectively implemented with current government departments structure and if they could obtain enough resources and face least push back from other interest groups in the society. 


Leave as many options open as possible, for as long as possible.

For law, leave as many conflicts open as possible for as long as possible. Don’t try to solve the conflicts by finding a fake consensus that both sides aren’t happy with.


An effective architecture is one in which the most common changes are local, and hence easy to make. Therefore frequent law change is easier to implement if it only affects one department.


A good law and regulation should minimize the human resources (government officers) to implement and enforce it.


Rule making for small community

This video shows some common dark sides of HOA. In summary, they are

  • They charge fees and impose fines indiscriminately. They might even use Google Maps to inspect the backyard of your home and issue fines based on that. 

  • Most newly-built neighborhoods are compelled to establish HOAs, which allows the government to privatize certain functions, such as road maintenance and park facilities upkeep.

  • The majority of HOAs are contracted out to management companies, which frequently send personnel to patrol the community and find various reasons to impose fines. They hire expensive lawyers to pressure residents into paying the fines and then make the fined residents bear the legal costs. If the fines are not paid, they can foreclose on the property without informing the homeowner. In the most outrageous case, a property was sold for $3, and all of these actions are considered legal.

  • In some instances, HOA terms and conditions are not even visible before signing the property purchase agreement."

I think the root cause for these problems are

  • There are many complicated community affairs. 

  • Many communities lack a good project management and prioritization tool.

  • Residents’ needs are diverse and it is hard to build consensus among all residents. 

  • Some residents are more willing to and have more time to deal with community affairs while others don’t. 


The followings are a couple of principles which can help to fix the above root causes

Make it easy to collect feedback and improve

Rules need to be simple and have good readability so that residents with less time can also read and understand them.

Setup minimal rules at the very beginning and then do small changes every time with multiple random reviewers. This is inspired from code change review principles. 

For less engaging user, allow them to file feedback and frequently review feedback

Increase hoa board members election frequency so that residents feedback can take effect. 


Reduce coupling with community management company so that it would be easy to change companies in the future.


Release new rule only when previous rules become stable and well tested


Avoid long term master plan or big decision

A long term master plan requires a powerful and excellent leader staying in the position for a long time. But it is very hard to pick out such a powerful and excellent leader. So evolution and principles are preferred over master plan.

Long term master plans and big decisions can easily go wrong. In government, long term development projects have many risks. The plan might be based on wrong assumptions in environment and context. The context which backed the plan might have changed in the middle. So avoid making long term and large decisions as much as possible. Make small decision which is adaptable for long term potential plan


Coupling, consistency and efficiency in Government organization

Coupling, consistency and efficiency are all very important quality attributes of a software. The following part will examine these concepts and their relationship in government organization. 

In human organization coupling means the number of communications, coordination, interest exchange among different groups. The higher the number is, the higher the coupling is. Consistency means the number of common attributes different groups share which reduce friction and conflict in coordination. 

An example of high coupling government style is monarchical government mentioned in ‘Ancient Society’ by Lewis H Morgan. Such governments were established to fight against other countries or tribes and protect its citizens’ properties. In order to win a war, the government needs to have a strong mobilization system so that it can enlist new soldiers and other resources quickly. This requires a high coupling society structure so that the emperor’s command can reach citizens quickly and be executed efficiently with very few objections which entails high consistency among citizens. Such a government is more like a master than a service provider. And citizens are more like slaves than service users. 

A final version of high coupling government is the centralized and large unified government in Chinese history.  I think the chinese centralized government was more of maintaining order among different internal regions rather than handling warfare. It was the product of the Warring States period which consisted of many monarchical states. Its actual war mobilization cost was too high to sustain because it had to extract resources evenly from large regions of China. 


High coupling usually requires high consistency among small groups and groups with high consistency and few feedback or monitoring on government tend to become more and more coupled with each other.  For example, Zhou’s book’s chapter 8, ‘Inverted soft budget constraint’, described a government behavior that under budget pressure, local governments can extract extra-budgetary resources from producers (firms), subordinate agencies, or residents under their administrative control. This is analogous to Hyrum’s law that

With a sufficient number of users of an API, it does not matter what you promise in the contract: all observable behaviors of your system will be depended on by somebody

Another example of coupling increasing tendency is the collusive phenomenon in the Chinese bureaucracy mentioned in Zhou’s book. 

A salient organizational phenomenon in the Chinese bureaucracy is that officials in local governments have a tendency to form strategic alliances and develop coping strategies in ways that often sidetrack or sabotage state policies or impose their own interpretations of the implementation process, leading to systematic deviation from the original intention of these policies. 

The ancient Chinese centralized government operates as a closed system, leading to more collusive phenomena than in the open market because it is easier for organizations to find public and legal alliances in the open market. Zhou proposed several explanations for this difference. I think the root cause is the coupling increasing tendency in a highly consistent and closed system when the number of demands and tasks increases. Higher coupling does not necessarily lead to higher efficiency. It simply increases the connections between nodes, which could lead to both efficient and inefficient connections. While more connections increase possibilities, too many may not be ideal. For instance, in a society, if coupling between individuals is low, one person's death doesn't affect the whole society. However, if a person's heart fails, the entire individual dies.


A good amount of consistency is beneficial. It could connect different groups, such as groups by race or region, together to avoid conflicts or fights among them. Too low consistency is usually reflected in isolation of some minority groups from major society. For example, many campaigns and riots happened in countries with isolated minor racial groups. 

A good amount of consistency could also keep a large country stable and unified. 

For example, as mentioned in Zhou’s book, in Chinese centralized government history, the imperial system has a series of constraints on bureaucratic power. Firstly, the human resource system is highly centralized, with significant appointments made directly by the emperor based on political loyalty, forming the core of the upward accountability system. This is complemented by a system of frequent rotations of officials to weaken potential local power. Secondly, the resource allocation system centralizes considerable resources in the hands of the central government, distributed through various channels to strengthen its control and limit the size and capability of local bureaucrats. Thirdly, territorial management is divided into separate administrative, supervisory and military powers, mutually restraining each other. These constraints greatly enhanced the central government’s power and increased the country’s consistency. 

From a distributed system’s perspective, these constraints are more like replacing local transactions with distributed transactions. Coordination of different powers such as administrative, supervisory and military has to go through central government which is a longer and less reliable path than local government path. The goal is to prevent local governments from insurrection. In a distributed system, local transactions are always preferred because it is more efficient and simpler. The Chinese bureaucratic constraints are actually a tradeoff which trades efficiency for overall stability and security.

One way to ensure security while maximizing efficiency might be to establish broad trust and consensus among all parties.


Note that the efficiency lowered here is actually problem solving efficiency in local government since it restricts the ability to adapt to local conditions. High consistency and coupling level actually increase administration efficiency. High level command can be passed down and executed quickly because of consistent government infrastructure. But it might not utilize much more human and physical resources. 

The essence of efficiency is to achieve more with fewer resources. It is less related to coupling and consistency. Efficiency can be improved through market competition. In a distributed system, if the system is flexible enough, one old less efficient micro service can be easily replaced with a new more efficient micro service. The larger one micro service is, the more difficult to be deprecated and replaced. So we should prevent one micro service from becoming too large by creating a new micro service from the beginning. Here a micro service is analogous to a government department. 

The tension between a unified system and the size of governance, as well as the efficiency significantly reduced to maintain unity, can be seen from a domain-driven design perspective. As a model grows larger, it naturally diverges into many smaller models, with similar terms but different meanings. Applying continuous integration is expensive. It requires frequent communication and adjusting. It will result in limiting the child model's capability to solve their own problems which will reduce efficiency. However, models diverging too much will lead to high communication costs among models, such as model translation. One child submodel might grow to become the dominant model and replace the main model. Similar processes can also be found in human history. For example, one local government kept growing and expanding and finally replaced the original central government. And human society is even more complex, containing various elements such as desires, rebellions, and more.

Therefore high coupling and consistency are expensive to maintain. To maintain them, there must be a centralized controller. But the centralized controller’s capacity is limited and couldn’t cover every edge case without large incentives. So many edge cases are usually left not supported or poorly supported. 


High coupling could cause wide error propagation.

In software, error propagation among micro services is fine as long as the error only handicaps the user action which triggered it where user action fails while there is no other side effect. On the other hand, bad error propagation makes system state inconsistent or fully crashes several micro services. Bad error propagation could be caused by high coupling among micro services. If one micro service has an unchecked business logic bug which corrupts stored data or states. It could also be caused by infrastructure bugs in databases, server framework, programming language etc. If all micro services use the same infrastructure technology which means high consistency, then a tiny bug in one infrastructure library could cause widespread bugs. 

Similarly, if the government is highly coupled with citizens and the whole society, small friction like riots and campaigns in one region can quickly trigger similar activity in other regions, widespread to the whole nation and disrupt the country. For example, as Zhou mentioned in his book, 

the formation and outbreak of collective action based on unorganized interests is an aggregation of large numbers of spontaneous individual behaviors produced by the particular state–society relationship. Although individuals are unorganized, their actions in pursuit of their own self-interests tend to convey similar claims, share similar patterns, and point to the state, that is, they “converge” into collective action. 


High coupling governments are not partitioning tolerant. 

In computer science, partitioning tolerance means the system continues to operate despite an arbitrary number of messages being dropped (or delayed) by the network between nodes.


In a high coupling government like a monarchical government and centralized government, low level officers rely on commands from the emperor. If the emperor died or the message can’t be delivered timely, then local officers couldn’t do anything because of many constraints on them. 


This is analogous to the CAP theorem. Only two of Consistency, availability and partitioning tolerance can be achieved at the same time. In a centralized government, resident consistency and their availability as labor or soldiers are prioritized while the system is not partitioning tolerant. 


Split before coupling is too high

Since high coupling has so many disadvantages as mentioned above, we want to limit the coupling level. The best way is to split a big government department into multiple small self contained departments similar to the progress of splitting monolith to micro services in computer science. Note that the higher a system’s coupling is, the more difficult splitting is. Therefore, we should make a split before coupling reaches an unmaintainable level to prevent further coupling issues that may arise when the system scales up. Once coupling becomes too high, it becomes challenging to replace a bad child component. And the only option is to replace the whole monolith which happened a lot in Chinese history during changes of dynasty. 

The Principal - agent model Zhou proposed in his book is actually a good example of splitting. In this model,  the principal gives fiats and determines incentives while doesn’t restrict on how to implement the fiats. The agent is responsible for following administrative fiats and for implementing top-down policies. The benefits of this model is that it decouples central government from local governments. It gives more freedom to local governments and hides implementation complexity from the central government which is more flexible.  It also reduces the cost to maintain consistency.


Organization structure

As stated previously, humans are less reliable and more flexible. They have their own desires and incentives and it is hard to force them to follow any commands 100%. However, some organization structures could make human workers more reliable. For example, in a Foxconn factory, workers are strictly managed and expected to execute commands 100%. The key factor is whether the monitoring cost is sufficiently low and monitoring accuracy is high. If a person's job is simple and easily observable, then the monitoring cost is low which makes it easier to apply pressure and provide timely feedback such as immediate warning for slacking off. 

In higher organization layers (such as headquarter vs local center) and more complicated jobs (such as scientist, manager, engineer), it is hard to monitor the performance either efficiently or accurately or timely. Thus the dependency among higher organization layers and complicated jobs is more like micro service coordination than simple function calls in a small piece of code. This applies to the relationship among central government and local governments. 

The central government can be modeled as the orchestration layer in micro service architecture. In computer science, there are 2 types of micro service coordination. One is orchestration where all service coordination logics are centralized in a single orchestration service. The other is choreography where coordination logics are scattered in each service and there is no centralized controller. 

And less reliable service coordination between central government and local government result in asynchronous communication and eventual consistency. Asynchronous communication means the local government doesn’t finish the command timely and the central government doesn’t wait for a local government to finish the command before sending another command. Eventual consistency means local governments don’t finish commands at the same pace and in the same way. 

The two system attributes will cause policy making more complicated and harder to scale. For example, when making a new policy which depends on the result of an old policy, the central government has to accommodate for different local governments’ execution state on the old policy.  To simplify policy making, one option is Campaign-Style Mobilization (CSM) mentioned in Zhou’s book which temporarily disrupts and suspends routine processes and reorienting the course of action at the will of the top leaders so that all local governments will finish the command more quickly and consistently. This approach trades local government availability on other tasks for consistent state for the most important task.  

Another type of coordination in human organizations is choreography which coordinates work between peer departments that are far apart in the organizational hierarchy. Generally, tasks in choreography have lower priority, which makes them slower to be completed, unless a temporary leadership group is established at a higher level. However, each department still has its own tasks under its larger parent department, which may hinder efficiency unless direct oversight by higher-level leaders is in place.

Therefore, the ideal organizational structure should allow any small task to be completed within a lower-level department whenever possible. This applies even to tasks that require coordination among multiple departments, such as citizen-related matters like obtaining identification cards or driver's licenses. It would be best if these departments are all part of the same lower-level parent department.


Government organization design

I found two government organization related challenges from Zhou’s book.

  1. The evolution of organizations do not always follow the blueprint of their rational design. Instead, organizations are often constrained by processes and conditions in the larger environment. 

  2. To meet excessive expectations and the demands of the supervising agencies, the local government must maintain a mobilizational structure in its internal organization, with duplicated roles, redundant offices, and flexible boundaries among organizational agencies, so that it can mobilize organizational capacities to extract resources from below when the occasion arises. As a consequence, the government is always passively dealing with various resource pressures, making it difficult to implement long-term plans and achieve specialization while maintaining stability.

  3. Information is not efficiently and correctly passed around the big organization especially when there are too many organization layers from top to bottom. Low level organization might report biased or filtered or faked information to higher level for its own benefits


Design Principles to address above challenges

Build a good information collecting system

Too many layers of the information dissemination process can potentially distort the original information because each layer is a transformation. Especially in human organizations, information is often altered during transmission based on their desires and needs, leading to a bias towards their own interests when higher levels make decisions on resource allocation. However, in software development, signal collections from each micro service can be trusted because all related code is transparent and visible to most of the big organization. 

Therefore the solutions are

  • Collect information from a reliable and known source 

  • Minimize the layers the information is passed through to minimize information distortion

  • Make the collection and signal transmission process transparent so that the information is easily verifiable

One concrete example is to set up independent information gathering mechanisms. But some information can only be detected during the execution process, similar to the uncertainty principle. So another option is to let low level employees conduct surveys on users directly and send the result directly to the target level of manager instead of passing through each manager level.  

In a big organization, high level leaders might be overwhelmed with too much information in decision making. Some information is reliable while others are not. But in reality, an excessive amount of information sometimes might even result in a bad decision. Therefore the communication protocol between different layers should be well designed so that low level always passes the simplest, most reliable and necessary information to higher levels. This approach will also reduce information collection cost. 


Make the organization structure adaptive

As stated in the challenge part, the evolution of organizations do not always follow the blueprint of their rational design because it is hard to get a good overview of the complicated environment until the organization really interacts with it. The environment could consist of different categories including physical environment such as natural environment and human environment such as how local communities coordinate with each other. A special type of environment is informal institutions as mentioned in Zhou’s book which are the social relations that are not only derived from formal authority relationships, but they also stem from informal, social interactions or from other arenas, such as alumni relations, hometown origins, or kinship ties. Some informal institutions are good which increase government capability, some might cause corruption while others are a mix of the two. 

Adapting government organization to the environment means deciding what set of functions should be bundled together and executed by the same team and how each department interacts with different parts of society. In order to adapt to the complicated environment, the government organization should have following properties:

Flexibility

Be flexible so that the organization can be changed based on new observations of the environment. To achieve flexibility, it needs to be minimalistic because it is always hard to change large things. For example, we can start from minimal rules, make small decisions, defer hard decisions as much as possible, prefer principles over master plan and frequently make small changes to org structure.

Interaction between Bottom up and Top down

Give low level organizations freedom to form small teams and departments by themselves based on practical experience interacting with the environment. And then high level management can confirm or regulate (forbid bad parts) these new government structures. 

Note that the bottom up and top down process should be an ongoing interactive effort. Otherwise, it will be very hard to regulate the low level organization when it has well evolved and deeply coupled with the society in some bad manners.

There are several ideas to achieve this:

  1. Build a general large government organization without any specialized individual role at the beginning and allow each government worker to evolve to be specialized through execution of daily tasks and establish communication protocol with other workers and the society. 

  2. Start from small detailed policies.  Humans like stable rules because they are easy to understand and execute. With more and more different scenarios coming in, abstract policy can be distilled from these concrete scenarios.

  3. Create a stable policy on how to reorg, merge or divide 2 organizations e.g. based on user feedback. Because frequent and unpredictable reorg can confuse employees on their goals and disrupt their passion for their work.

  4. Summarize common practices from a low level and make them a standard across the whole large organization. Some bottom up results might be the ways an officer executes the task rather than an organization structure. Promoting these task execution methodologies to be general and standard can scale the organization structure and make it easier to manage because when any change is needed, you only need to adjust that single standard. 

  5. Make government department structure communicate its limitations and operational needs based on the environment so that new high level lawmakers can easily understand and make top down adjustment to it. 


Scale organization structure

To make something scalable, we need to make different parts of it similar or consistent so that they can be managed by a simple and efficient procedure. 

One pattern is to divide and extract common service from central and local government into an individual department. For example, instead of letting the local government collect tax on behalf of the central government, we can divide the tax collection department into a local branch and central branch which the USA uses. Local branch collects tax which will only be used by the local government while the central branch collects tax from different local governments’ precincts. Some other services might not need a local branch such as foreign relationships.  

Some other services might not need a central branch such as the police department and motor vehicle department. But consistency might still be needed over the whole country for these services. For example, we want a consistent car registration system so that a car can be legally driven across different states.  And we want a consistent criminal information system so that crime information can be shared across different local police offices so that cross state crimes are easier to investigate. 

For such cases, the central government could develop basic policies and allow local governments to add their own extension. The extensions should not modify the basic policy so that local governments won’t deviate from central government’s policies too much. To make the basic policy more extensible, it should be minimal. For example, the central police office makes their incident handling guideline and each local police office extends to have their own version.


Engineering culture and mindset

No matter what design principles are, they are applied by human beings. Many software architecture books talk about important qualities of a good software architect. So the mindset of lawmakers and government officers is also very important. 


I think the most important mindset for lawmakers and officers is an engineering mind which is the willingness to recognize and accept trade off knowing that nothing is perfect or satisfy everyone’s needs. Also as stated in one book, 

Software architects should resist non urgent feature requests and focus on long term system health and architecture quality. The company needs to value and respect technology so that a software architect’s long term technical improvement request can be prioritized by management. 

Technocratic bureaucrat is like the software architect role in the government. They should resist non urgent requests from lawmakers and focus on long term government organization structure health and quality. The lawmakers and citizens should respect these technocratic bureaucrats and promote an engineering culture in the society. 


Policy execution

Some challenges of policy execution are that

1. Humans are far more flexible and less reliable than software. Softwares are designed for simple purposes and they don’t have any alternative option beside executing commands. But humans have plenty of options beyond the commands given by other people or contracts. So the more possibilities and flexibility one creature has, the less reliable and stable it is.

2. In centralized government, the chain from policy creation to execution might be too long which could cause a lot of problems

For example, the longer the chain is, the more distorted the policy is where different layers mix their own interest into the policy. Also, since humans are less stable, the longer the chain is, the more humans are involved in the vertical hierarchy, the less stable the whole chain is. 

Another example is the `downward acceleration of the implementation pressures` phenomenon  mentioned in Zhou’s book. The intermediate governments adopt more stringent policy targets for their subordinates in order to minimize the risk of falling short in terms of accomplishment of the tasks.

A third example is “muddling through” in policy implementation as mentioned in Zhou’s book : adopting ad hoc, improvised strategies; exhibiting a course of action that focuses on short-term, incremental gains; and sequential adjustments in strategy as conditions change, leading to patterns of shifting courses of action over time.  

This is caused by unclear priorities in multiple tasks from different higher levels. Some tasks from different higher levels might even compete with each other for resources and priorities of execution. 


The chain from high level management to low level employee is similar to the dependency chain in software. According to software development best practice, the dependency chain should have a single direction where the less stable components depend on more stable components so that frequent changes in some components won’t affect stable components. In software development, the user interface is the least stable component because it is changed based on different user interaction frequently. The core business strategy’s code is the most stable component which is the company’s core business model and shouldn’t change frequently. In human organizations, especially the government, the low level employees such as sales and software engineers who serve and interact with users directly are comparable to the user interface. The high level management which decides core policies is comparable to the core business strategy. Low level employees “call” their managers for policy and resources to execute things and propagate user input up to the managers. 

So a good policy creation and execution chain should have a stable management team at high level which creates and maintains a stable core organization business strategy, rule and policy and whose team members rarely change positions while low level employees execute daily tasks and interact with users directly and can be hired and fired or leave the position much more often. Though humans are less stable and not good at strictly executing commands, humans also have inertia. If one person sticks to one position, then he will follow the rule and be unwilling to break the rule. For example, in Weber's theory, bureaucracy always pursues procedural and stabilization. 

Since low level employees execute tasks directly, they have more practical information about the organization’s business. Instead of high level deciding tasks for low level to execute, low level employees should also have discourse power and impact when determining their tasks. This is a combination approach of top down and bottom up. There is already a popular goal setting framework using this pattern called OKR (Objectives and key results) where objectives are determined through negotiation between high level management and low level employees. 

I think ideally, low level employees should take leadership to create tasks and priorities for themselves based on their frontline experience with the latest environment. Then high level management could adjust and arbitrate the goals and priorities based on core business strategy and the organization’s overall state and goal. With a clearly arbitrated priority list and voices from low level employees, the challenge of downward acceleration of the implementation pressures and muddling through will be reduced. 

Another solution for the long execution chain challenge is to split the organization and limit the length of the chain. For example, like the USA government, instead of delegating its responsibility and power to the local government, the central government can set up and lead related departments to execute tasks directly such as the IRS and FBI. 

However, though some functions can be divided into the central government part and local government part, the central government might still want to maintain some level of consistency in local government’s parts across the whole nation such as guidelines for public health, police and building highways. 

For a highly coupled centralized government, this goal can be approached using the “tournament model” as mentioned in Zhou’s book where local governors’ promotions are determined by the central government so that they have to execute the central government’s task as well as possible to win the competition over other local governors.  This is like introducing market competition into local governors groups. 

For a loosely coupled democratic government, a short feedback loop should be helpful. If local government can be monitored by local people directly, then it is easier to enforce central rules. But this is based on the assumption that local people have consensus on the central government's rule and are willing to follow it. But that’s not always the case. The law is contracts among people. If two regions’ people agreed on a law (contract) and they both made some compromise, then how to enforce both parties to execute the contract is a challenge. The deeper a consensus is across the whole nation, the easier it is to enforce law from the central government.  


Another challenge is elasticity.

In computer science, elasticity means the ability of a system to remain responsive during significantly high instantaneous and erratic spikes in user load.

Government doesn’t have elasticity because government officers are very slow to train compared to a server instance which can be quickly deployed. For example, in COVID pandemic, the government approved subsidies to poor people but this needs application. And there is a huge load of applications which makes it very slow to process. So to process policy which could have potential large spike of load effectively, it is better to make the policy as simple as possible for existing officers to process quickly though many cheaters could get through


How to reform the government?

Principles of reforming from software development perspective 

Reformers, central governments, local governments and different government organizations can be modeled as separate microservices. High level governments or reformers cannot fully control low level government organizations’  behavior. They can only send commands to low levels as defined in low levels’ microservice communication protocol. Reforming is equivalent to refactoring the entire micro service architecture. It is a process where the micro service of the central government or reformer adjusts the relationships between the various low level microservices, creating and cutting off certain connections. But in this case, the central government microservice initiates the process by sending commands to other microservices. For this to work, other microservices must have interfaces for reforming tasks. 

In the meantime, microservices of low level government organizations also interact with each other, influencing each other or competing for resources. When one microservice has more resources or is more deeply coupled with other services, it can rally other microservices to resist the central government's initiatives or even replace the central government. 

This is more like a competition between reformers’ micro services and other low level government organizations’ micro services whose interest is hurted in the reform. The competition process can be viewed as the process of some algorithms determining winners and losers, with the losers being deprecated entirely. 


Challenges of reform:

1. Coupling

If different government institutions are highly coupled together, it is hard to change their relationship and they will resist the change together. If some government institutions are highly coupled with some interest group, when the reform hurts these interest groups, they will have high influence in resisting the reform and advocating for their own interest.

2. Some institutions like the army have grown so strong to threaten the central government’s power. Sometimes they might have more resources than the central government and can utilize these resources to ally with other government institutions and fight against the central government’s reform policy. 


Solutions:

The larger a service grows and the more it becomes coupled with other services, the harder it is to refactor that service. Therefore, it's important to timely cut it down before it becomes too large. Even if there is a genuine need for a large service to efficiently handle certain tasks, clear component boundaries should be established within the large service to make future splitting easier. The same applies to government departments. After defining clear boundaries for smaller departments, it becomes easier to split them later. And the founder should even prepare for deprecation or refactoring when establishing the department. For example, the founder could set up a deprecation or refactor command in the department when establishing it. 

Another approach is to gradually build a new department that can replace existing ones, allocate interest groups’ resources to the new one and establish connections with other microservices. After the new department grows larger and is more coupled with other services, the old ones can be eventually easily deprecated. 

One example is the reforms of the Imperial Guard in the Ottoman Empire. The Imperial Guard used to have strong power and could even replace the Sultan. And it is very conservative, resisting any kind of political or economical reform.  After several failed trial of reforming the Imperial Guard, one Sultan succeeded by gradually establishing a new army which is more modernized and finally replaced the Imperial Guard with the new army. 

A third approach is to spur creativity from inside the bureaucratic system. In Weber's theory, bureaucrats prefer procedural and institutional stability which is coupled with their own interests. Therefore they resist changes to organization. But bureaucrats are best positioned to propose and implement a reform because they have first hand government running experience. To encourage bureaucrats to innovate and suppress their resistance, we can put them in a more dynamic environment.  For example, we can create policies to encourage and reward them to spend some time every week working on different tasks aside from their regular work together with people from different teams similar to some tech companies’ 20% project culture. The higher government can also do small reorganization more frequently which makes it easier for the bureaucrats to adapt to and embrace change.

Note that although it is ideal to take gradual steps to reform, sometimes due to competition between nations or the limited lifespan of reformers, reforms need to be completed as quickly as possible. It's akin to balancing development time and technical debt in software development. This requires a good vision and insight in the reformers. A long-term bonding between the reformers’ interest and the nation’s interest is also critical so that reformers can focus on long-term value. It's similar to how a company might prioritize short-term gains after going public but emphasizes long-term value when it's private.



Reformability tradeoff in democratic country

In democratic countries like the U.S.A, powers are separated into legislative, executive and judicial branches so as to check and balance each other. Both legislative power and executive power branches are elected by voters directly. In U.S federal government executive branch, only the president is elected by voters directly. But in some state government’s executive branches, multiple government officers are elected directly such as state governor, treasurer, attorney general and so on. More governors being directly elected means more coupled the executive branch is with voters. Since these governors’ power comes directly from voters, the relationship among them is more equal than hierarchical. In such a case, if a state governor wants to do a reform inside the executive branch, he needs to spare more effort in obtaining other directly elected officers’ consensus instead of giving them commands. This is a tradeoff for reformability. The more government officers are directly elected, the more granular control voters have over the government to achieve their detailed goals while the less flexible the government organization structure is.  


Quality control of government

Quality control of the government is important because government departments are not under market competition. 

In software development, even if a micro service owner team distorts something which benefits that team only but harms the whole software’s quality, the software will be punished by the market competition by losing users quickly.  But government departments are not under market competition. Therefore, quality control for government departments is far more important than it is for software which means government departments need more monitoring and testing exposure. 


Monitoring infrastructure

To control quality, it is important to monitor different metrics such as user feedback, user data and if the resource is used correctly and efficiently. For the government, both high level governors and citizens want to monitor a local government or a government department. But the monitoring is done badly in many countries.

It is easy to monitor software. Since most softwares uses common and standard technologies such as programming language, database and cloud platform, it is easy to build a common and efficient metric collection library on these technologies which can be shared by different micro services and cloud platforms. It is hard for a single micro service owner to hack such a library to return metrics that are biased to the team’s interest. User data stored in the database is also accessible to everyone as long as he has permission. Micro service owner team cannot fake the data. 

Governments can learn from software monitoring. The government tasks and procedures should be digitized. For example, store documents, citizen data and resource usage log in daily work into a standard database so that the department’s work and its efficiency is transparent to high level governors or citizens.  Establish a common metric collection process for government employees to follow. Government employees might still be able to distort the data before they report the data through the metric collection process. But the collection process can be well designed so that it is much easier to report correct data rather than fake data and reporting fake data will be severely punished. 

In software, when a user event needs to be processed across multiple micro services, a global tracking id is bundled with that user event data so that each micro service’s related processing log can be correlated to that global id and more comparison and performance analysis can be made among different micro services. 

The government should also track citizen affairs handling performance such as tax refund, new business registration, house refurbish plan approval in the same way. Have a global id on each case to track it through different departments and log processing time for each department and make these metrics transparent.


Testing

Software can be easily tested. We can always develop automatic tests which run periodically. And a software’s all features are well tested before each release and continuously tested after release. These tests guarantee that the software is stably running and functions correctly all the time. 

Software tests are usually run in a separate test environment which real users don’t have access to while it is similar to a real environment. For example, the test environment has the same machine production code running on, uses the same library version and sometimes user input in the real environment is captured and sent to the test environment.

Software developers can test a new feature in a test environment or even in a real environment by making the new feature partially available to a small set of users.  

It is almost impossible to set up a test environment for the government and run automated tests every day. But it is possible to test a new policy in a limited scope. For example, the government can make a small policy change each time and apply it only in several counties to check the policy’s effect. But nobody wants to be lab mice. The government can issue some compensation to the citizens to whom the new policy is applied. The central government could also allow deviation of its policy to some extent in different counties and states so that different variation of the same policies can be tested in parallel which is helpful to find a best policy variation.  


Rollback

One common pattern in software is rollback. If a new change is found to be problematic, it can be rolled back by either reverting the product code to a previous version or disabling it if the new change is guarded by a flag so that the negative impact can be quickly mitigated.  

We should also establish a standard rollback mechanism for law and policy. Each law and policy should have a trial period such as x years. Within the trial period, if any red sign occurs, the law and policy can be rolled back. After the trial period, if some metric is met, then the law can only be overridden rather than rolled back. Because rollback requires backward compatibility which is expensive to keep. We can have all laws rollbackable forever. If the metric is not met, the law can be permanently abandoned.  

However, some large decisions are hard to roll back or split to small pieces or test such as initiating a war against another country. We should avoid such large decisions as much as possible or find and learn from precedent before we make such decisions. 


Fit the policy terms with lawmakers terms

Many governors only care about a policy’s effect during their terms. They may sacrifice the region’s long term benefit for a short term fancy metric to demonstrate their performance and seek promotion unless they are bound to the region for long term e.g. grown up in the region or having business in the region. 

Therefore, a new policy’s designed lifespan should not extend beyond the official's term. A governor of an executive branch such as the president has too much power so that they shouldn’t be allowed for long term. However, voters do need long term policies for a country or a state because it is the place most of them reside for their whole life. The long term policies can be a broad consensus among all voters and monitored by all voters. But voters still need representatives to make the policy similar to the board member role in a company. We can allow legislators to be elected for multiple terms because their power is much more limited than governor’s. And these long-serving legislators who deeply involve themselves in a specific region can play a supervisory role and make long term policy. And they can break down long term policies into short term result measurable tasks for the governor to execute in his term. Note that we should avoid creating long term master plans because the environment is changing so frequently and non deterministically that no one can predict a long term future. We should create more abstract strategies and principles as long term policies.  


Productivity

One specific software engineering role is EngProd role which focuses on creating tools to measure and improve other engineers’ productivity. 

We also need a way to measure government productivity and have a team like EngProd to improve productivity for both policy makers and executors. For example, we can enhance the government’s information system so that documents and information can be passed around more timely. We can adopt better task planning and tracking tools, which are widely used in software development, for rule makers to discuss and negotiate new policies orderly and efficiently. 


References:

5 architecture books. Summary 


‘The Logic of Governance in China An Organizational Approach’ by Zhou, Xueguang https://web.stanford.edu/~xgzhou/zhou_book2017.pdf 


‘Discipline and Punish’ by Michel Foucault


https://youtu.be/qrizmAo17Os about HOA


‘Ancient Society’ by Lewis H Morgan


‘ Radical Focus: Achieving Your Most Important Goals with Objectives and Key Results’ by Christina Wodtke


‘Ottoman Centuries: The Rise and Fall of the Turkish Empire’ by  Lord Kinross


Popular posts from this blog

Does Free Consciousness exist ?

Software Architecture Books Summary And Highlights -- Part 1 Goal, Introduction And Index