> 2022年01月01日信息消化 ### Commitment Phobia origin: [Commitment Phobia](https://perell.com/essay/hugging-the-x-axis/) Where does our culture of commitment phobia come from? I have hypotheses, but no firm conclusions. Here, I’ll present three theories: a cultural one, a technological one, and a sociological one. For a cultural explanation, I look at the rise of **liberalism**. In *Why Liberalism Failed*, Patrick Deneen argues that the project of liberalism seeks to detach us from the constraints that once tied us down — family, culture, place, identity, tradition. As liberalism grew more popular, the circumstances of kin and place became more malleable. Thus, today’s Westerners are increasingly free to shape their identity. I don’t think liberalism is inherently a bad thing, but like anything else, it has its tradeoffs. Freed from the ties of kin and place, people aren’t bound by the traditional virtues of honor and loyalty, which are two of the defining pillars of a commitment-heavy culture. For a technological explanation, I look at our culture of **abundance**. The “so muchness” of modern life has given us commitment anxiety. It’s a version of the Paradox of Choice, which argues that people can reduce anxiety by eliminating choice. **The more options surround you, the less likely you are to make long-term commitments.** That’s why I can read a book on a Kindle, but not on my iPhone Kindle app. The words are the same, but the context isn’t — and easy access to the Internet reduces my attention span to that of a sidewalk pigeon. I contrast them with the buy-and-hold style of Warren Buffett, who is famous for sitting in his office and reading all day. Though he’s been investing for decades, his strategy’s never really changed: buy good companies at an under-valued price and hold them for a long time. Though his life is certainly more hectic than the one he projects, Buffett reminds us that a long-term outlook will narrow your emotional amplitude. **The cadence of your work shapes your temperament**. When you’re a day trader, every phone notification matters. But when you’re a committed buy-and-hold investor, you can mostly ignore them. **The longer your time horizon, the calmer life becomes.** Zoom out far enough and once-gargantuan hurdles turn into tiny speed bumps on the road of life. 你工作的节奏会塑造你的气质。当您是日内交易者时,每条电话通知都很重要。但是,当您是坚定的买入并持有投资者时,您几乎可以忽略它们。你的时间跨度越长,生活就会变得越平静。缩小足够远,曾经巨大的障碍变成了人生道路上的微小减速带。 **[Doing anything meaningful](https://perell.com/essay/saving-the-liberal-arts/) starts with a long time horizon.** That’s one reason why the Romans allowed only the land-owner class to vote. When you can’t just pack up your bags and move to a new property, you have to consider the long-term implications of your actions. Though the spirit of this ancient law can’t be replicated today because the real estate market is so liquid, it’s fun to consider how society would change if only people who committed to owning land for the next 100 years could vote. Long time horizons change our incentives, usually in good ways. This is one of the core findings of [game theory](https://perell.com/essay/why-people-cooperate/): **people treat each other better when they intend to interact repeatedly in the future.** #### Hugging the X-Axis As a result of these convergent trends — the rise of liberalism, technological abundance, and short time horizons — we’ve been overvaluing optionality at the expense of commitment. The genesis of my realization goes back to a Harvard commencement speech called *The* *Trouble with Optionality*.**2** In it, professor Aman Desi defines optionality as “**the state of enjoying possibilities without being on the hook to do anything.**” With enough optionality, you can always change what you’re doing in order to pursue something better. Desi critiques students for [seeing optionality as an end in itself](https://perell.com/essay/peter-thiel/). Instead of trying to work towards a meaningful goal they can commit to, they try to accumulate options in order to delay making a firm commitment. The result is that we’re under-committed as a society (with the curious exception of tattoos, which are everywhere now). People think they’ll be happy if they don’t have any obligations. In actuality, total optionality is a recipe for emptiness — and hugging the X-axis — because opportunity and optionality are often inversely correlated. The challenge is that the greatest rewards generally go to people who are tied down in certain ways. A real lifelong marriage is the deepest relationship you’ll ever have because you’ve committed to a lifetime of faithfulness.**3** Likewise, you only get to raise money for a startup when investors are confident you’re committed for the long haul. The challenge is that people who treat their lives like a game of hot potato, always moving from thing to thing, can’t take advantage of [exponential curves](https://perell.com/essay/audience-first-products/) — and **climb the Y-axis.** 人们认为,如果他们没有任何义务,他们会很高兴。实际上,完全可选性是空虚的秘诀——并拥抱 X 轴——因为机会和可选性通常成反比。挑战在于,最大的回报通常会流向以某种方式受到束缚的人。真正的终生婚姻是你所拥有的最深厚的关系,因为你已经承诺一生忠诚。挑战在于,那些把自己的生活当作烫手山芋游戏的人,总是从一件事到另一件事,不能利用指数曲线——并爬上 Y 轴。 Though the point of having options is to eventually commit to something, having too many options can prevent us from committing to anything at all. When the going gets tough, **people with a litany of options are more likely to jump ship than navigate the rocky waters.** No, I’m not saying you should commit to everything right away. Committing to everything is an oxymoron because attention is zero-sum, and committing too early and for too long at the get-go is foolish (don’t get married after your first date). Commitment also has opportunity costs. You can only commit to things that matter to you if you’re discerning about those that don’t. **Once I committed to running [Write of Passage](https://writeofpassage.school/) for the long term, my FOMO disappeared and I felt calmer.** Though I classified my first few cohorts as an experiment until I proved out the business model, I committed to it in perpetuity long before my friends thought it was reasonable.**4** I’ve seen how surface-level experimentation at the beginning can lead to deeper commitments down the road. Part of the reason I’m so tied to online writing is that I’ve explored many other paths in the past. I’ve dabbled in cryptocurrencies, consulting, advertising, broadcasting, and sports. Taken together, I’ve learned that the commitments you make in the present are made possible by the experiments you’ve tried in the past.**5** We spend so much time thinking about squeezing juice from the fruit that we forget to ask what kinds of fruits are worth planting in the first place. Even if you’re just inching towards your goal, working on the correct thing is the most productivity enhancing thing you can do. Side hustle culture is the opposite of commitment culture because you have to grind when you can’t prioritize. Most hustlers would benefit from slowing down and committing to a small number of projects instead. **Problems arise when people associate freedom with a lack of commitments.** The kind of freedom that ultimately fulfills and uplifts us comes from making [the right kinds of commitments](https://perell.com/essay/one-big-idea/). Only once these commitments are in place can we climb the Y-Axis. In business, **if you want the freedom that comes with wealth, you have to commit to a company by investing your time or money.** **If you invest your time, you can no longer frolic from passion project to passion project.** The benefits of building a company — purpose, financial security, and the sense of worth that comes from doing something important in the world — are granted only to people who show up day after day, especially when they aren’t in the mood. 7 #### Why We Should Commit To illustrate the point, Chesterton distinguishes between the optimist and the patriot. The optimist loves their country because it’s on an upward trajectory, while the patriot loves something simply because it’s worthy of their love — and the trajectory is irrelevant. Being an optimist is easy. Being a patriot is hard. But with patriotism comes wisdom. Patriots know things can be worth caring for even when they’re imperfect. Often, their love *expands* in moments of difficulty. Think of the mother who kisses her son’s bleeding finger or the citizen who sees the brokenness of their country and runs for political office. A world without patriots is a world without perseverance, and when there’s no perseverance, there’s no meaning. 为了说明这一点,切斯特顿区分了乐观主义者和爱国者。乐观者爱他们的国家,因为它在上升的轨道上,而爱国者爱某事只是因为它值得他们爱——而这个轨道是无关紧要的。做一个乐观主义者很容易。做一个爱国者是很难的。但爱国会带来智慧。爱国者知道即使事物不完美也值得关心。通常,他们的爱会在困难时刻扩大。想想亲吻儿子流血的手指的母亲,或者看到国家崩溃并竞选政治职务的公民。没有爱国者的世界是没有毅力的世界,没有毅力就没有意义。 Chesterton argues that people are ultimately fulfilled not by riding the bandwagon but by acts of commitment — loving, working, and tending to things worthy of care and affection, often [without rational justification](https://perell.com/essay/the-microwave-economy/). He writes: “**The man who is most likely to ruin the place he loves is exactly the man who loves it with a reason. The man who will improve the place is the man who loves it without a reason.**”If Chesterton is right, then the impetus to love things as deeply as they need to be loved is [beyond the calculus of rationality](https://perell.com/essay/why-youre-christian/). I see how love transcends logic in the ways parents talk about their children. They’ll do just about anything for them, even if they aren’t able to articulate why. The second we demand reasons to love something, we descend into a sphere of utilitarian self-interest. But that’s not love. That’s a transaction. A society can’t thrive when people use a double-entry accounting system for love because intending to give more than you receive is the only way to truly love something. #### Raising Your Bar for Commitment The bottom line is commitment is undervalued. If you have commitment phobia, you’re not taking control of your own life. You’re taking your hands off the wheel of reality and letting [happenstance](https://perell.com/essay/dont-kill-time/) define your life. And yeah, you take a stand whenever you make a commitment and expose yourself to the potential for pain and criticism. In matters of the heart, commitment brings meaning. In matters of the [mind](https://perell.com/essay/how-philosophers-think/), commitment brings knowledge. And in matters of the material [world](https://perell.com/essay/peter-thiel/), running towards the responsibility that comes with commitment takes courage — and with courage comes achievement. People can only become world-class at things they commit to. Ultimately, the more hesitant people are about making commitments, the higher the rewards are for people who do. The alternative is empty hedonism and hard work [without the rewards](https://perell.com/essay/the-microwave-economy/) to show for it. If today you’re comfortable committing to something for two hours, try committing for a weekend. If you’re comfortable committing for two weeks, then raise it to two months; once you’re comfortable with two months, raise it to two years; and once you’re comfortable with two years, raise it to two decades. It’s okay to start small. All big things do. But they have to start somehow and with commitment comes momentum. Commitment happens in stages, and only by embracing it can you stop hugging the X-Axis and climb the compounding curve. ### Protocol Buffer Basics: Go > MEMO > 开始看的 [Go Protocol Buffer Tutorial](https://tutorialedge.net/golang/go-protocol-buffer-tutorial/), 2018年的教程...outdated > Google的例子中,add_person与list_people..这两个程序数据利用proto处理数据的添加与显示。保存则直接用文件的形式。 > > The whole purpose of using protocol buffers is **to serialize** your **data** so that it **can be parsed elsewhere**: `proto.Marshal(book)` > > `.proto`用来定义数据结构。`protoc` 从`.proto`生成指定语言的数据访问类。 gRPC的服务 `service`, 参数类型/返回类型`message`都在 `proto` 文件中定义 > > ref. [ gRPC+Protobuf vs HTTP+JSON in Go - Pliutau](https://pliutau.com/benchmark-grpc-protobuf-vs-http-json/) #### Go Protocol Buffer Tutorial (outdated) Protocol buffers, are essentially a data format, much like JSON or XML in the sense that they store structured data which can be serialized or de-serialized by a wide number of different languages. The main advantage of this format is that it’s a hell of **a lot smaller** when compared to the likes of XML or even JSON. It was a format that was originally developed by Google, who are fairly well known company that are at such a size, that every byte they can save makes a difference. Imagine we had a person, who’s data we wanted to represent in the 3 separate data formats: ```xml Elliot 24 ``` We could represent this data in a far smaller size footprint in JSON: ```json { "name": "Elliot", "age": 24 } ``` And if we were to represent this same data using the protocol buffer data format: ```c [10 6 69 108 108 105 111 116 16 24] ``` #### Protocol Buffer Basics: Go origin: [Protocol Buffer Basics: Go](https://developers.google.com/protocol-buffers/docs/gotutorial) With protocol buffers, you write a `.proto` description of the data structure you wish to store. From that, the protocol buffer compiler creates a class that implements automatic encoding and parsing of the protocol buffer data with an efficient binary format. The generated class provides getters and setters for the fields that make up a protocol buffer and takes care of the details of reading and writing the protocol buffer as a unit. Importantly, the protocol buffer format supports the idea of extending the format over time in such a way that the code can still read data encoded with the old format. - Define message formats in a `.proto` file. - Use the protocol buffer compiler. - Use the Go protocol buffer API to write and read messages. ##### Examples You can find the complete example in the [examples directory](https://github.com/protocolbuffers/protobuf/tree/master/examples) of the GitHub repository. [Protocol Buffer Compiler Installation](https://grpc.io/docs/protoc-installation/) ```sh apt install -y protobuf-compiler # Linux brew install protobuf # MacOS protoc -- version ``` ```bash # install the Go protoc plugin (protoc-gen-go): go install google.golang.org/protobuf/cmd/protoc-gen-go@latest ``` The "go install" command will install protoc-gen-go into the GOBIN directory. You can set the `$GOBIN` environment variable before running "go install" to change the install location. Make sure the install directory is in your shell `$PATH`. ##### Defining your protocol format To create your address book application, you'll need to start with a `.proto` file. The definitions in a `.proto` file are simple: you add a *message* for each data structure you want to serialize, then specify a name and a type for each field in the message. In our example, the `.proto` file that defines the messages is [`addressbook.proto`](https://github.com/protocolbuffers/protobuf/blob/master/examples/addressbook.proto). The `.proto` file starts with a package declaration, which helps to prevent naming conflicts between different projects. The `go_package` option defines the import path of the package which will contain all the generated code for this file. The Go package name will be the last path component of the import path. For example, our example will use a package name of "tutorialpb". ```protobuf // [START declaration] syntax = "proto3"; package tutorial; import "google/protobuf/timestamp.proto"; // [END declaration] // [START csharp_declaration] option csharp_namespace = "Google.Protobuf.Examples.AddressBook"; // [END csharp_declaration] // [START go_declaration] option go_package = "github.com/protocolbuffers/protobuf/examples/go/tutorialpb"; // [END go_declaration] // [START messages] message Person { string name = 1; int32 id = 2; // Unique ID number for this person. string email = 3; enum PhoneType { MOBILE = 0; HOME = 1; WORK = 2; } message PhoneNumber { string number = 1; PhoneType type = 2; } repeated PhoneNumber phones = 4; google.protobuf.Timestamp last_updated = 5; } // Our address book file is just one of these. message AddressBook { repeated Person people = 1; } // [END messages] ``` - [Makefile](https://github.com/protocolbuffers/protobuf/blob/master/examples/Makefile) ```makefile .PHONY: all cpp java python clean clean: rm -f go/tutorialpb/*.pb.go add_person_go list_people_go rmdir tutorial 2>/dev/null || true rmdir com/example/tutorial 2>/dev/null || true rmdir com/example 2>/dev/null || true rmdir com 2>/dev/null || true go: add_person_go list_people_go gotest: add_person_gotest list_people_gotest go/tutorialpb/addressbook.pb.go: addressbook.proto mkdir -p go/tutorialpb # make directory for go package protoc $$PROTO_PATH --go_opt=paths=source_relative --go_out=go/tutorialpb addressbook.proto add_person_go: go/cmd/add_person/add_person.go go/tutorialpb/addressbook.pb.go cd go && go build -o ../add_person_go ./cmd/add_person add_person_gotest: go/tutorialpb/addressbook.pb.go cd go && go test ./cmd/add_person list_people_go: go/cmd/list_people/list_people.go go/tutorialpb/addressbook.pb.go cd go && go build -o ../list_people_go ./cmd/list_people list_people_gotest: go/tutorialpb/addressbook.pb.go cd go && go test ./cmd/list_people ``` #### Practice ``` ├── addressbook.proto ├── go │ ├── cmd │ │ ├── add_person │ │ │ ├── add_person.go │ │ │ └── add_person_test.go │ │ └── list_people │ │ ├── list_people.go │ │ └── list_people_test.go │ └── go.mod ├── Makefile └── person.proto ``` - [add_person.go](https://github.com/protocolbuffers/protobuf/blob/master/examples/go/cmd/add_person/add_person.go) - [add_person_test.go](https://github.com/protocolbuffers/protobuf/blob/master/examples/go/cmd/add_person/add_person_test.go) ```bash # install protobuf compiler brew install protobuf-compiler # install protoc go plugin go install google.golang.org/protobuf/cmd/protoc-gen-go@latest # prepare directory mkdir -p go/cmd/{add_person,list_people} vi Makefile vi addressbook.proto # prepare go programs cd go go mod init github.com/protocolbuffers/protobuf/examples/go cd cmd/add_person touch add_person.go add_person_test.go touch list_people.go list_people_test.go # required module cd go go mod download # creates executable files cd ../ make go # run examples ./add_person_go addressbook.data ./list_people_go addressbook.data # clean data make clean ``` simple protoc r/w flow of add_person & list_people > The whole purpose of using protocol buffers is to serialize your data so that it can be parsed elsewhere. In Go, you use the `proto` library's [Marshal](https://pkg.go.dev/google.golang.org/protobuf/proto?tab=doc#Marshal) function to serialize your protocol buffer data. A pointer to a protocol buffer message's `struct` implements the `proto.Message` interface. Calling `proto.Marshal` returns the protocol buffer, encoded in its wire format. For example, we use this function in the [`add_person` command](https://github.com/protocolbuffers/protobuf/blob/master/examples/add_person.go) > > 使用协议缓冲区的全部目的是序列化您的数据,以便它可以在其他地方进行解析。在 Go 中,您使用 proto 库的 Marshal 函数来序列化您的协议缓冲区数据。指向协议缓冲区消息结构的指针实现了 proto.Message 接口。调用 proto.Marshal 返回以有线格式编码的协议缓冲区。例如,我们在 add_person 命令中使用这个函数: ```go // Common: Read file fname := os.Args[1] in, err := ioutil.ReadFile(fname) // Add book := &pb.AddressBook{} // addressbook.pb.go structure proto.Unmarshal(in, book) addr, err := promptForAddress(os.Stdin) // CLI prompt book.People = append(book.People, addr) out, err := proto.Marshal(book) // Write back to disk. ioutil.WriteFile(fname, out, 0644) // List fname := os.Args[1] in, err := ioutil.ReadFile(fname) book := &pb.AddressBook{} for _, p := range book.People { fmt.Fprintln(os.Stdout, "Person ID:", p.Id) fmt.Fprintln(os.Stdout, " Name:", p.Name) } ``` ### MISC - web3 与 加密货币的消极观点 - [Web3 is centralized (wesleyac.com)](https://news.ycombinator.com/item?id=29766497): Cryptocurrencies are the ultimate example of this and are **an absolute boon to tax collectors, forensic accountants and fraudsters**. In our current economy financial transactions are recorded in millions of individual ledgers that are kept private, or in the case of cash transactions are often not recorded at all, or are not linked to an individual. There is no central ledger.对税务员、法务会计师和欺诈者来说绝对是福音。 - [Bitcoin consumed 134 TWh in total during 2021 (twitter.com/digieconomist)](https://news.ycombinator.com/item?id=29769892): With a climate crisis the last thing we needed was to **make the most effective energy consumption** system ever constructed. The whole thing literally works on competing on consuming more energy. No other system works so efficiently towards such goal.