# https://iio.ie old posts backup
2017 entries:
2018 entries:
2019 entries:
2020 entries:
2021 entries:
2022 entries:
# about: short intro about this site
i'm a random guy born late 1980s currently working at a random tech megacorp as a software developer in zürich. this blog started with me wanting to rant about some annoyances with computers. but after some writing and reflection that well ran quickly dry so i just started writing about some very personal struggles and random ideas.
i found that writing things down helps me put things into order. so i write about all stuff my brain keeps spinlooping about. most of those things don't make much sense even after writing them down but at least i spinloop about them less. this site is for myself, don't expect any quality posts here.
the name "iio" doesn't mean anything. it happens to be easy to type and it was available so i went with that. if it needs a meaning then consider its vocalization being me screaming into the void.
and in case you want to contact me privately, send an email to qxp2fs8j at anonaddy.me.
published on 2017-12-01, last modified on 2023-12-12
# htmlized: you can read this site in html
# this post is now irrelevant, see latest update.
the problem with plain text is that it does not really have a standard on how to rewrap it to other column sizes. i do not mind this, i just assume 80 columns as the universal width. however that does not play nice with kindle. it wraps plaintext quite awfully. there is not much it can do with plaintext. it can do a much better job with html. i quite dislike html but it is a widely used and supported format so it will do for this purpose. i have the full contents of this blog available in html at html.iio.ie. i host this on a separate server (github) because my little server only works for small, <100k byte long files. this limitation prevents me from creating overly long documents.
html.iio.ie contains the whole blog on one large site with minimal formatting so it is very easy to either open on kindle's browser or just download and convert it to a .mobi file. i wish more blogs and sites would allow easy binge reading.
i also publish the last 4 articles to https://iio.ie/latest so followers can still catch up in html without downloading everything on every visit. since this always fits my arbitrary <100k byte length limit, i am happy to host it myself.
note that i do not limit document width in the generated html because i think that is rude. making the text narrower is always easier. i can make the browser window narrower, use firefox's responsive design mode or its reading view, or just open the javascript console and enter "document.body.style.width = '30em';". making a document wider needs a phd in css.
update from 2020: i read a tutorial about css which is almost the same as a phd. on desktop the bottom right corner now has a small, draggable widget. you can use that to make the text narrower or wider to your preference.
update from 2021: i gave up on the draggable widget, it didn't really work well in some cases. i now just set body's max-width to 50em and call it a day. hopefully that's reasonable and not too narrow. yes, i'm rude now. :(
update 2 from 2021: this site is now all html. this whole post is void. see @/redesign about the change.
published on 2017-12-02, last modified on 2021-09-06
# simulation: my answer to the meaning life
when i was a little kid, i always wondered where the christmas gifts come from. people told me that jesus puts all the presents under the christmas tree. since the gifts were there and i was not a particularly bright person (still not), i accepted this explanation. they also told me that a god created the world and that i will live forever in the heaven or hell after i die. but then i noticed that one of toys i got was not new. so i pestered my parents about it and they admitted that the gifts do not come from jesus but from them. so then i questioned people about the rest of the story and most of them admitted that it is just a story, it is not something that i can verify with my own eyes. i have to "believe". ummm. right. i think i will look around first, thanks.
so then i read about the people who claim that there is absolutely nothing after death. there are no supernatural beings, there are no souls. we are just simple biological meatbags that completely vanish after their expiration. there is not much point to life other than just to "experience" and "enjoy" it while it lasts. i will not get another chance. there is nothing happening after death, just like nothing happened before birth.
i found this quite an agreeable position. it is quite practical, its explanation does not seem to require concepts that we cannot experience. however since i went through one big disillusion before, i was trying to be more open minded just in case i see even more convincing newer theories. however as i was reading discussions around the topic, this biological-only camp seemed just as convinced about their truth as their religious counterparts. i understand that believing in mystical entities is not practical but flat out stating that things cannot possibly exist seemed presumptuous. so i kept a "i do not know" stance instead.
later i came across the simulation argument. it says that assuming a civilization can reach the technological point where it can run complex simulations, it is possible that it has already happened. if one civilization can reach it then probably many others can too. if that is the case then there are many simulations running in the world. in fact it is quite likely that most living organisms are in a simulation, including us.
i quite liked this train of thought. it does not try to explain what the world is, it just a shows one possibility. it just says there we cannot be sure but there is a chance that this is happening. at this point this did not look any more practical than the complete denial of supernaturalism but the idea was nevertheless interesting.
so i began thinking about simulations in general. how would i implement them? how would i play in them? thinking like this opened my eyes. this simulation assumption actually gives me practical ways on how to approach the "what is the meaning of life", "what is the point", "how should i live my life" sort of questions. all i need to do is just to apply my thoughts about the implementation and simulation playing to this simulation (my life). so true or not, it is practical for me.
one could argue that religion is also practical and beneficial. in fact it is quite likely if we consider it from evolutionary standpoint. there are many religions in the world. the ones that are overly harmful probably died out and the ones that survived probably contain many beneficial practices. the problem is that to pick up a religion's practices, one also has to pick up its way of thinking which is usually "stop thinking". but i quite like some of the ideas religion has like
and probably more. however i think all this is achievable without the need to stop thinking and blindly believing in mystical stories.
my foray into the simulation hypothesis will not rise to as mature way of life as a religion but at least it is based on logic that i agree with. and eventually little by little i can build up a similarly practical life based on the observations from this hypothesis. so let me talk aobut what implications i found from this.
the first way i think about the simulation hypothesis is how would i implement it. there are two main ways to do it: i can make it static or i can make it interactive.
by static simulation i mean something like a movie. the story is given, i can replay it many times, the same thing happens every time. perhaps i can replay the same events from a different person's perspective. i write a story i like then i can "join and live through" the characters. this assumption leads to observations like "there is no free will", "everybody has an importance" or "there will be a grand ending".
by interactive simulation i mean something like a video game. there is no real story given. all i have is this big sandbox where everybody is to themselves. this leads to observations like "there is not much meaning to all of this" or "just have fun while it lasts".
my personal take on this is that we live in an interactive simulation. i take this view solely from practical point of view. if the simulation is like a movie then it does not matter what i do so i might become unmotivated. however if it is interactive then what i do matters in the long haul.
then i also have to think about how complex the simulation can be. if i had to implement it, i would probably go with the simplest implementation. this means earth is the only planet in the entire universe with life on it. i would also make arbitrary constants that make my implementation simpler like limiting the maximum speed matter or effects can travel so that the supercomputers simulating all this have an easier time chomping through all the data.
the other way to think about all this is to think about why and how would i participate in the simulation. similarly i can ask why would i want to watch a movie or why would i want to play a video game. there are usually two primary reasons to do either of those. i play because i am bored. it is entirely possible that the outside world is so boring that i am looking for more fulfillment in the simulation. if i look at it this way, then i am in this for the fun. just make sure the fun lasts long. alternatively i might be playing the game or watching the movie because i want to feel challenged and want to feel that i overcame the challenges. the world is full of challenges. it is up to me take a chunk of it and complete them.
my take is on that i play this because i am bored in the outside world. compare single and multiplayer games. in single player games there is a challenge i have to overcome. however if i do not follow the game's campaign, the game does not progress. also note that the characters in the game have usually different roles, each helping me towards the goal or being the challenge i have to overcome. the single player games usually have a beginning and end. once i overcome the challenge, the game loses its appeal. on the other hand in multiplayer games i usually play with other players. most challenges in multiplayer games would be meaningless without the other players. i play the game with others, me playing the game makes the game in some sense. most players have the same roles and the game does not lose its appeal over time as long as the player base is good. i play this game because it is fun, which means not playing the game is a more boring activity.
the world i observe feels more like the multiplayer game where each player plays for themselves rather than the single player game where each other entity is there only for me. this is why i think that i am here out of boredom.
my biggest epiphany came when i considered to look at how i watch movies or play video games. would it be a fun movie if the movie consisted of just other people watching movies? or would it be fun if the video game consisted of playing other video games? let me phrase it this way. suppose i want to play a shooter game. in the shooter game i find an arcade machine on which i can play, say, pacman. would i play pacman on it? for a few minutes, sure. but would i invest a lot of time into playing pacman? if i like pacman so much, why not play a game that is pacman and therefore is probably better designed? why would i invest a large chunk of resources into a complex simulation in which i play a simpler simulation?
this led me to my first practical observation: watching movies or playing videogames is silly! to play now and then is fine but i must avoid sinking hours daily into these activities.
and then many other observations started pouring in.
if this is a multiplayer game for fun, i should not ruin the game for others. in fact, it is best if i can improve it for others. i should make the world a better place to live in. ugh, tough order. but not ruining the game is a good start.
if i am playing a multiplayer game then it is the other players that make the game fun. it means that i am meant to live among others. i am meant to interact with others.
if i am in this complex simulation with all these rich sensors in my body, i am probably meant to use them. for instance in person interaction and communication always feels richer thanks to all these sensors than the low bandwidth messaging or videochat solutions. messaging is very good for coordination but i should not use it to maintain long distance relationships. i should build new ones so that i can the use the rich communication channel again.
players come and go. i should not stress too much about particular players. if a player goes away forever, i shall seek other players to have fun with.
i should not stress too much about the past or lost opportunities. i can probably always respawn and play again if i did not feel fully satisfied.
there is no end goal other than being happy. once i reach the point where we can sustain ourselves with little work indefinitely, i should free up any unneeded resources we use (e.g. a job) and help others achieve a similar state. with this hypothesis, it is the other people rather than one's material possessions that makes one happy.
and i could probably go on. but the general gist is that based on that the meaning of life for me is to be happy, achieve happiness through personal relationships, and help others be happy. this is a generally well accepted meaning to life. but the nice thing about this is that i do not need to blindly accept this because people in authority told me so. i devised this conclusion from concepts i am familiar with via reasoning that i agree with. it does not really matter if simulation hypothesis is true or not, it is a mental tool for me that helps me make sense of the world. if i cannot understand something in the world, i can use this tool to ask myself how and why would i implement such a thing. sometimes things make a little more sense when looked that way. so therefore my current stance about world is "we probably live in a simulation" just because it is a practical assumption.
published on 2017-12-03
# uppercase: i don't like uppercase letters
why are there two glyphs for each english letter? why are there bunch of random rules to decide which glyph to use in various situations? i honestly have no idea. i suspect this might have been their history:
this is nonsense. there is zero difference how you pronounce uppercase letters versus lowercase letters therefore there should not be two separate cases. "oh but it helps me find the sentence's start". boohoo. you will get used to it. that is why punctuation exists. if uppercase letters would not exist and somebody would want to invent it, people would laugh them off. say i invent a middle case with completely different glyphs for each letter and the rule is to use middle case at the end of sentences or names. does that sound ridiculous? well, uppercase sounds just as ridiculous to me. most non-western languages do not have this idiocracy.
why keep lowercase instead of uppercase? because lowercase is much easier on eyes. it has larger variety in height. you see a word like "apple" and you can see two spikes down before the middle and one spike up after the middle. chances are you can still better guess the word after applying extreme blur levels compared to its uppercase version where all letters have the same size.
and just imagine how significantly easier writing would become. no more effort wasted about thinking or discussing the capitalization of titles, names, lists and so on. less effort typing the uppercase letters. less computer logic to compare words. if you want to make the world a better place then stop using uppercase letters. please spread the word to make this revolution reach a critical mass.
# edit 2021-06: i've posted this to r/changemyview to challenge this idea.
here's the thread: https://old.reddit.com/r/changemyview/comments/oaqzcz/cmv_writing_doesnt_inherently_need_uppercase
i have to add that by this time i was already a bit softened with regards to uppercase letters. i started programming in go. it gives uppercase letters a meaningful function: it means a symbol is exported. since i like go in general, i got used to it and embraced this meaning.
however capitalization of sentence beginnings and names still didn't make sense to me. that's what most people argued for as the reason for these letters but i didn't really find them convincing. while i acknowledge they provide some minor benefits in terms of speed and clarity, i still find the effect not big enough to warrant them. it's just much simpler for me to write like this in my hidden little corner of the internet.
but in general i see some value in having separate letter case when it's used for emphasis just like how you would use bold and italics. but that's pretty much it.
if i wanted to dig deeper into the arguments, i'd need to split the issue into three key points:
the function of the last two is different. arguing about all of them in a single thread is just too exhausting.
the most reasonable answers told me that it's fine in informal writing. for formal writing it's just as it is but that's not necessarily set in stone. if all lowercase gets common enough, maybe that could get formalized. this means i should totally continue doing this if i want to get all lowercaps more accepted in formal writing.
published on 2017-12-04, last modified on 2021-07-12
# autocompletion: i prefer using my brain to autocompletion
there are two sorts of autocompletion. the first is where the autocompletion just lists all possible syntaxically correct options, like path completion for the cd command in bash. the other autocompletion is where a black box tells me the most likely ending for whatever i am typing. over time i learned to loathe both.
syntax completion is usually quite straightforward, predictable and generally understood how it works. however it is often flaky and invoking the completion then choosing the right option takes more time than what it would have taken if i just typed in the option myself completely. it also allows complexity to stay, it does not intrinsically motivate me to fix my environment such that autocompletion is not necessary.
let me explain through the path completion example. suppose i have a bash open, i am in a network file system directory with many files in it. i press tab tab. now bash has to stat every file and the whole shell just locks up. when the autocompletion is not instant, it is super annoying. do i just wait longer or shall i try to kill the botched autocomplete or shall i type further and hope for the best? all i wanted to spare typing 2 keyspresses and now i am involved in a complex decision making process. the other issue is when i press autocomplete too early, i get many choices and now i find myself reading through all the choices and have to make a choice whether to continue typing or take the first suggestion. again, in most cases i already know what i want and i could have finished typing but now instead of doing that i am reading words on the screen, eating up precious cache space in my small brain. the third problem is that if i have deeply nested directory hierarchies, i just keep tabbing through them. i never actually take action to fix them. "it is not so bad" i keep telling myself.
so without syntax or path autocompletion, my editor will never lock up. i will never need to think about whether to wait for autocompletion or not. no more pondering whether i should debug or improve the autocompletion or not. no more contemplation about the ideal autocompletion system. i just type the identifiers naturally. the screen is not jumping around with random unrelated information while i type. the only thing appearing is what i typed in, leading to a very distraction free experience. this is a blessing since have a very easily distractible personality. the other nice thing is that if i am forced to type in long identifiers or deep path hierarchies regularly, i will have some motivation to refactor the environment or structure so that such typing is unnecessary. basically no autocompletion intrinsically helps me maintain simplicity in my projects.
so these days i do not use any sort autocompletion. i even disabled path completion in bash. it was very odd at first. but eventually i got used to and i no longer miss autocompletion. and whenever people are complaining about an autocompletion failure, i just smirk under my nose, and feel happy that i no longer have such problems.
the other type of autocompletion is this machine learning based "let me finish what you started" sort of machinery. basically it wants to finish my sentences instead of letting me do so. i find this very misguided. i take pride that i am able to formulate full sentences without external help. i do not want help in writing. i do not use smartphones or other toys so i always have the ability to comfortably type in any word or sentence i wish. if i do not type the words myself, i do not learn how to spell them correctly. i am a kinesthetic learner. if i do not practice something, i do not learn. similarly if the computer finishes my thoughts, it is much harder for me to think. if i do not need to think then why am i even here? thinking and formulating full sentences is fun for me, i do not want computers to take that away. the implementation is usually also quite distracting. say i start typing a list of keywords i am interested in and then the search box starts suggesting others. the problem with this is that sometimes the suggested keyword has absolutely zero relevance to my query, yet i find it interesting so i am likely to search for that instead of what i originally wanted. basically the search box is taking away control of my interests and telling me what to look for instead. i am weak against temptations so i find it manipulative if things take advantage of this. so i do not want this either. i made sure that i see no completion on my machine when i use it. i can think and type for myself, thank you very much.
published on 2017-12-05
# history: i don't keep shell and browser history
tracking every minute detail of my daily failings is pointless. i am talking about collecting the history of every command i execute in bash, every url i visit in a browser, or every gps coordinate i ever visited. this is a lot of data. most of it is just noise. whenever i wanted to look up some data in history, it actually took very long time browsing through all the data and sometimes i did not find what i was seeking. i found it is actually more efficient to reconstruct the command or url from scratch. it also helps me exercise my memory so it dwindles away slower. i often relied on bash history to find the right parameterization for a command i remembered using. without history i cannot do this. but i am better off this way. i am no longer relying on an external, private, somewhat volatile database to interact with the computers. it forces me to familiarize with the documentation. if that is lacking, it motivates me to improve said documentation. better documentation makes the environment nicer for others too. since i have to type out the arguments myself, i get more acquainted with the commands themselves from which i often pick up clever, out of the box ideas. in the urls' case it forces to learn the url structure of the websites, and to come up with succinct urls for my own work. sharing urls is very easy and natural when urls are sane.
maintaining this history database is also quite the pain. i am not comfortable keeping my bash, browsing or gps history in some non-personal device or an external device not encrypted by me. when i use multiple computers, shells, browsers then maintaining this history becomes quite complicated. i value my sanity so i would need elaborate bash hacks to keep the history in sync across computers. perhaps i would consider even more elaborate hacks if i wanted to inject new history into an already running bash process. or when i use multiple browsers then they have separate histories and i usually do not remember what history is in which browser. i could probably set up some sort of elaborate syncing scheme between them too if i would care enough.
the history database might not contain everything. it will not contain entries from my incognito browsing. i might be remembering that i visited a website, then i would try to look it up in the history but i will not find there. i would spend a lot of time before i would realize i used incognito so the history will not have it. the bash process can also suddenly die and lose precious history in it which i would then feel bad about.
the history does not have good availability guarantees. i might accidentally truncate all my bash history. i would then feel very sad. or i might decide that i want to use a different computer and now the history is gone and i have hard time using it. or if i store my history on a network service, my workflow depends on that network being available. it is just another unnecessary dependency.
keeping all the history slows down the application. bash now needs to read in all history before it shows its prompt. not only i have a slower startup, but now i also have less memory available for other work too. bash and the browsers need to keep some history in the memory too to keep lookups fast. and in bash's case it probably does not even share history between the processes so i would be paying this cost multiple times.
the history might have chance of leaking. suppose somebody sits down to my computer and starts browsing. now they could easily see all my naughty sites i visit or the naughty data i have. if it is on a networked service, then there is a chance that there will be a global leak at some point and then everybody will have access to everybody else's history. that might contain some things i would not be comfortable with others seeing.
and do not even get me started on the idea of tracking gps location history. that is wrong on so many levels that i will not even bother trying to explain it. i do not use gps nor smartphones so i do not have this problem. but i suspect smartphones have this feature enabled by default. it is just something to be aware of. i understand that my carrier probably tracks my brick phone's whereabouts but at least i do not have to worry that 7 independent services also tracking it via their preinstalled spyware.
so i stopped caring about my tracking my history. i find that this leads to much healthier practices, better memory, less work and less worrying about losing or leaking said history. therefore i disabled history where i could: bash and the browsers. note that i still keep per session history in bash because otherwise correcting typos in commands would be super annoying. but i never write out the history to disk. i actually use a raspberry pi as my primary hobby computer so i get less wear on my sd disks this way which is a nice plus. besides, forgetting is a feature. if i forget something, then 99% of the cases it is a good riddance. no need to carry on the past forever.
published on 2017-12-06
# simplicity: you need strict limits to maintain simplicity
i really dislike maintaining and debugging complex systems. i suspect nobody likes them. yet no matter how hard people try, we always end up in a mess. however i do not think this has to be the case. we should be able to create simple systems. all we need is a set of healthy practices and an agreement from all parties participating in the system that we want to avoid ending up in a complex system. everything starts simple but it is actually quite hard to keep a system simple especially if said system grows in number of features, components or participants. but here is one of the key observations: growth is what starts making systems complex. usually growth results in weird new interactions between the system's components. the system's original design might not be a good fit for the new, larger usecase.
so here is a lesson from that observation. if everything starts out simple but then growth makes systems complex then all we need to do is stop the growth. easier said than done. this is especially hard if the sole goal of our system is to replace other more complex systems. but if we allow growth, our system will grow into the same complex system we were trying to replace. my take from this is that we ought not to replace existing systems with new systems entirely. in fact the new system should explicitly forbid to grow into the same proportions as the larger system.
one way to achieve growth limitation is to set explicit limits for the features in the system. when a limit is reached then do not just bump the limit but either move the misfit component out of the system or restructure said component so that it works in the system. growth in such a system is going to be super frustrating. but it is that growth that the system is set up to prevent. people usually do not like systems that make them frustrated so such system cannot become a popular system. that is the downside. on the other hand the participants who accept the limits willingly will stay happy because they will not get bogged down with all the unnecessary complexity.
allow me to demonstrate these concepts with an example. my ideal computing environment is where every component of the stack from the operating system to all the user space applications is super simple, easily understandable, reviewable, perhaps tweakable. this environment might not as efficient as a hand optimized mainstream stack but i would not mind that because i can then understand my tools with less expertise. it would be easier to customize the system to my usecase.
one component of this stack would be the text editor. suppose i can decide its implementation. i could use fancy linked lists to manipulate large chunks of text efficiently. or i could impose terrible limits on my text. i could say this editor will not support lines longer than 100 columns and 10_000 lines. such draconian limits would significantly simplify the implementation because i will no longer need to think about efficient ways to handle large files or files with long lines. using such editor will be quite terrible too. most people would hate these arbitrary limitations. i would not mind though. i suspect there would be a handful of other people who would also embrace this. first of all, people can get used to limitations. early computers had tiny amounts of memory, yet most things still worked out finely. secondly, if my system has an arbitrary limit of 100 columns per line, then writing other tools are much easier too. they do not need to have complex logic to handle arbitrary length strings or concern about algorithms that do not scale well to long strings. the simplicity of this arbitrary constraint cascades through the whole system.
arbitrary limits or constraints are not only useful to keep the system simple. they force me to become creative. suppose i am writing some complex software. i keep writing the whole shebang into one file and after some time i reach the 10_000 line mark. on a contemporary system i do not even notice that this happened. however in this limited system i suddenly become painfully aware that i hit the system's limit. i am now forced to step back and perhaps split my project into smaller modules at that stage. at that line count that is probably a good idea anyways. so the constraints keep me on my toes and keep my activity in check. these constraints are not just something to keep some parts of the system's implementation easy but also to signal to the system's components what are the expected behavior and resource usage they have to work with. keeping the overall system simple is not something to graze over though. it is no coincidence that even these days people still make commodore or amiga demos just because working in a limited, fully learnable environment is so refreshing.
but note that if i am paid to write software for others, i am often not terribly excited about the projects i am supposed to do. if i run into some frustration stemming from arbitrary constraints of a tool, i might be tempted to simply switch to a tool that does not have said limitation. the resource costs, inefficiencies, the bugs of that tool or the complexity debt i add due to using a more complex tool is not my problem, my employer can pay others to deal with it. and this is actually nice because this way my employer can pay others to make faster and larger computer chips or ready software bundled with many features and thus the world does not stop progressing. though note that if i am solely on the hook for said tool then i would start looking into refactoring my use of the tool instead.
however in my hobby environment i really the idea of simplicity stemming from a constrained environment. so when i am writing my little tools in c i do not shy away from just using a few large arrays and returning an error if i try to use them on a larger input. this way they do not become slower over time as the input grows unboundedly. i know the input limits at the time of writing so every decision i made in its code is based on that assumption. if the input outgrows my tool, i usually need to rearchitect my tool anyways. i usually do not know in which dimension will my tool grow. does my text editor need to handle longer lines or more lines? making the tool scale in every dimension makes its code super complicated. at first i will assume no scalability and then if the need really arises, i might think a little bit about it.
it is not just my computing environment i like simplicity and predictability. this is also why i do not own a smartphone. it is such a complicated device. but everything can be done on a desktop computer too. with a desktop computer i am physically constrained to be in front of the computer to use it. i actually like this constraint otherwise i might just keep checking my smartphone all the time, even when i would be better off just looking at the nature or listen to the chatter of others. another example would be the fact that i very much dislike spending money which has many ramifications. for instance i try to avoid spending money on transportation and therefore i walk everywhere if i can. at the time of writing this my commute to work takes 1 hour by walking. this arbitrary constraint of being a cheapskate actually keeps me somewhat fit and gives me 2 hours daily just to meditate and think things through. my life gets simpler and i actually feel happier because of the workarounds i need to do due to these voluntary limitations. and this is why i like voluntary constraints.
published on 2017-12-07
# markup: simple markup for simple posts
i hate most markup languages because of their feature creep. it all started with html. it is the most popular markup language since most web is in that format. i am not sure if it was ever meant for humans to write though. probably not. however it is not so bad if you do so and only use the basic features. but most sites i visit generate their html from other sources of truth so browsing the internet without a html parser is impossible. this is quite sad though. i think its original goal was to mark up plaintext document with "links" and that is why it was called hypertext markup language. and while at it they added some extra markup to separate individual paragraphs and to insert headings, emphasis, simple lists, tables and images. then based on the capabilities and the settings of the client's computer, a browser rendered the document as nice as it could.
but html today is not what it used to be. i do not consider it as a markup language anymore. i consider it as a file format to render resizable "content" in a browser. it is a programming language. as such i am no longer in control how the computer renders the document for me. even worse, some sites go as moronic as to use their own crappy font from the internet rather than the fonts i specifically set. i have preference for specific fonts and i prefer to read in those. or set a maximum width for their document. have these people not considered that there exist people on this planet that are able to read more than 2 words per line? making lines shorter is easy since i can just make the browser window smaller or go into the browser's reader mode. making lines longer is much trickier. oh, i could disable css. but then often the document becomes tangled in the sense that all the content and non-content bits are interspersed in one giant blob of text. website owners really should really consider ensuring that their site still works without css and javascript. basically make sure the site is browsable in the links terminal browser.
on the other hand crappy site usually also means crappy content. so if the site tries to force a specific "viewing experience" then chances are it is trying to compensate for low quality content that i would not really want to read if it were to presented in, say, plaintext format. therefore i rather avoid such websites. visiting fancy websites actually reminds me that i probably should be doing something better instead. so thanks for doing that.
the other markup popular markup language is markdown. it started out simple and with the explicit goal that the plaintext version of the document remains just as readable. it added a little bit too many features in my opinion though. but that would not have been too much of a problem had it stayed that way. but when i look at the newest versions it is utterly nonsensical. for instance i open the commonmark's specification and i am presented gazillions of features and then long discussion about all the corner cases of those misdesigned features. and i suspect it will get much worse over time. when a person starts using all those fancy features it is again a smell that the author is spending way too much time on the presentation which suggest that the underlying content might not be as interesting as they wanted it to be.
really there should be only a handful of features needed. all the markup language for simple documents is supposed to do is to make it resizeable so the readers can read it on various devices with various font sizes. here is the list of features that ought to be enough for everyone:
and this is all what is needed. stop at that and i am happy. those features are quite straightforward to implement and do not have corner cases. in fact this website is written in a markup language that only uses those features. look at my @/htmlized article to see how this site gets transformed into a nice html page in a few lines of awk code. it does not support headings though because i just use different files to organize different sections. the generator creates the headings based on the filenames.
and here is what is not needed in a markup language for simple documents:
if somebody has something interesting to say, they do not need formatting. they can just tell it plainly. if a text is trying to explain a complex concept, fancy formatting will not make it easier. it will just give it an appearance of simplicity but not actually help. i recommend improving the text instead so that it explains the concept more vividly or with more examples.
as for my markup the rules are simple. the document is considered in paragraphs where paragraphs are separated with empty lines. the paragraph's first line determines what sort of paragraph it will be. if it begins with space, i wrap the whole thing into a <pre>. if it begins with a "- ", i treat is as an unordered list and each line starting with "- " starts another element. if none of the above matches, i wrap the paragraph into an ordinary <p> tag. and that is all there is. no corner cases, no complicated implementation needed. if i cannot express something with the above rules then that just means i am not challenging myself enough. i then go and think hard and come up with a way that can fit those rules. the result is then much simpler and i am then usually more pleased with it and thus i am happier. simple, constraining rules lead to better documents.
example in case you are viewing this in the html version:
test paragraph - unordered list with multiple lines - and entries - 1. simulated ordered list - 2. entry two pre formatted content table example: id | name | age | weight ---+--------+-----+-------- 13 | james | 37 | 88 kg 27 | sophia | 42 | 70 kg 39 | john | 30 | 123 kg
gets translated to this:
test paragraph
pre formatted content table example: id | name | age | weight ---+--------+-----+-------- 13 | james | 37 | 88 kg 27 | sophia | 42 | 70 kg 39 | john | 30 | 123 kg
and that demonstrated all the features i need and support. it is not necessary the nicest but it is functional enough for me.
# edit from 2021 after @/redesign
maybe some special syntax for common links would be nice after all. i still maintain that most links to external sites should be done with raw links simply to reduce surprises. but what about local or very common links? e.g. if you are an online forum, how would you link user posts, user profiles, user communities?
the "@" is such an internet specific symbol and is available. it's a symbol that you don't ordinarily use in text. i think it would be great to use it for links! in my markup i use "@ + /postname" to link to other posts on this site. but a community site could use "@u/alice" to refer to the alice user's profile, "@g/hikers" to refer to a hiking group, "@p/123" to link a specific post, "@yt/dQw4w9WgXcQ" to refer to a youtube video, and so on. as an added usability feature some additional information (e.g. the post or the video's title) could appear whenever the user hovers over such a link. i think this form is pretty short and has few false positives so i'd totally use this on my sites.
published on 2017-12-08, last modified on 2021-09-06
# gps: gps makes us lazy
the global positioning system is a marvel of human engineering, no doubt at that. however i really wish it would not exist. my personal beef with the gps is sucks the fun out of the exploration. i owned a smartphone for about a year before i threw it away so i do have some experience with gps and navigation. in those days whenever i wanted to go to any place, i just simply put in the destination into the device and then followed the path it devised. rather than looking up and learning about my environment, i was looking down to my phone, following the arrow and only looked up occasionally to check which street i have to turn onto. basically i felt that my phone reduced me to a mindless drone. i was completely fine before the gps, never felt that i was missing it but after the phone ditch event i felt some withdrawal effect from it. i was even a bit afraid to venture outside just because i might get lost. however i feel much happier without it. whenever i want to go to a place i have not been yet, i have to plan ahead. i have to study the map. i have to learn about large landmarks that can guide my path. i can perhaps walk through the path virtually through a street view application. i even draw myself a minimap just in case i do not remember all the details. then i can execute the journey. during the journey i am very attentive to my environment. i am sort of in the csíkszentmihályi like flow where my mind is quietly alert and focused on one thing. i am also very confident because i know what i expect at every corner. and when i successfully get to my journey i am quite happy that i planned well and managed to execute that plan successfully. or maybe i feel happy because of the flow state i was in for long time. so having no gps, makes my life more fun.
okay so i do not need gps but then why do i say it should not even exist? my problem is that i do know that it is very easy to get hooked on it. once hooked it is very hard to imagine life without it. people will forget that there are others who do not have access to gps devices. they will not learn to give directions in an effective way. they will not create landmarks that simplify navigation. so my problem is that if society gets overly dependent on gps then that society will be harder to navigate through without the gps because there will be no intrinsic motivation to make it simple. basically it will make the towns and other places less accessible.
it even ruins videogames. when i play an open world game, it usually has some sort of waypoint system so i am just reduced to mindlessly following the waypoint there too. i do not even look at all the nice scenes the game artists created for me to enjoy. there is no exploration required. sure, i could turn off the navigation system but then the game becomes unplayable because the quests in the game do not fully explain the destination and often there is no good way to look up a route to the destination and then following that route without constantly checking the minimap if i am at the place i am supposed to be or not. this is the effect i was talking about: if people assume that gps exists, they will not make the place accessible for non-gps users.
what i would really wish instead that we would make navigating the world so simple that a gps is just not needed. suppose a city is organized into a grid of roads and all the roads are just numbered sequentially. such city would be boring. but navigating would be super simple because you only need two numbers to specify a location in it. you can get to that location from any given location without a map. we should have more like that. so whenever you are coming up with organization scheme for physical space, try to come up with a way that does not require navigation tools. make it boring. boring structures make me happy. please make me happy.
and the other problem with universal gps access is the privacy violations it leads to. large organizations or family might want to know where each member is at any given moment which usually does not lead to trusting relationships. it is a silly idea at this point but as technology proliferates it might become more and more accepted. i might only want to track track my children at first for their own "safety". when i fully make terms with that arrangement, i start thinking of tracking a spouse for their "safety". then when i get terms with that arrangement, i might want start tracking more and more family members and so they want track me in exchange. now everybody is tracking everybody's movements. then when governments want to track me for my own own "safety", i might not be objecting to it because it is now "normal" to track people. the situation is horrible at this point. the whole thing escalates in baby steps. it is better to stop the whole thing in its roots and just live in a way that does not require the knowledge of one's position on this planet.
published on 2017-12-09
# cars: my annoyances with cars in cities
i currently live in a high density area and i learned to despise cars. they are noisy, inefficient and take up way too much space. there is no place for cars in inner cities. in fact allowing cars makes a few things more inefficient:
i understand that cars are very practical tools but i believe over the long term they lead to less efficient cities. and no matter how technologically advanced we make cars, city dwellers simply should not require cars. but as long as we allow cars in the cities, a lot of people will not be able to imagine existing without them. there is a quick way to teach people living without cars though. just ban all cars except the public transportation, ambulances and other licensed infrastructure supporting vehicles. perhaps the transition should be slower than an overnight ban but the endgoal should be the complete ban. maybe start with a small inner circle for the ban and then slowly extend the ban with more and more nearby streets every year until after a decade or two the whole city is car free. this would be a shock for a lot of people. they will get used to it though and find creative alternatives to whatever things they required cars for. if a population is forced to evolve, it will evolve. if some people still miss sitting in cars, they can always go live on the countryside. in exchange city dwellers can enjoy the efficiencies and benefits of car-free living.
published on 2017-12-10
# money: it's bad to rely too much on money
money can be practical tool or a cause of big stress in life. it depends how much you have. have less than what you need then you are causing problems to yourself, having more than you need then you are making your future self happier. it would be nicer if the stressing part could go away. does humanity even need money? as a kid, i did not really need it. my family provided for everything. even neighbors, relatives often brought gifts or cooked food without expecting anything in return. i only needed money when i was interacting with strangers. those strangers did not know me, did not trust me so they needed an alternative way of giving their goods without feeling bad about themselves. so i used money there. i guess i could say money is an alternative to trust. it is not as powerful but still, a simple, one dimensional tool. however i much preferred the world where things were not reduced to this one dimension. in fact if i am doing a small favor to someone, i refuse to accept money. that would just convert this rich sense of trust i acquired into numbers. i would rather keep the trust than the money. often it is unclear how much money should actions convert into. even if you assign a value, it changes over time. in the meantime trust remains constant.
i often wonder if such moneyless living is still possible in adulthood. i could imagine a community of people who live together and agree to share the costs of living in exchange to not deal with the costs individually. for instance this group of people might live in a large, multi bedroom shared house with a single, shared bank account. each person makes a periodic fixed contribution to the bank account. then the "finance person" pays the bills and rents from that said bank account. the kitchen is also shared and somebody always fills it up from the shared bank account. somebody might cook something nice for everybody every day. maybe group would share bus passes, swimming pool passes or access rights to other luxuries. the point is that the everyday life does not depend money. the community members do not need to take their your purse or credit card for rents, bills or food. that would be quite nice way of living. i am prone to obsess about spending. i see almost all spending of mine as some sort of inefficiency and then i start researching and thinking how can i optimize my behavior so that my spending goes nearer to zero. however if i do not see the bills, i do fine, blissfully ignorant. the missus already learned that she is better off if she hides the bills away from me.
such shared living does not scale infinitely though. to maintain harmony all members have to be in sync with each other. they have to have shared values, house rules and matching personality. maybe it scales up to a dozen of people tops although i think 4 adults is about the ideal number. finding the right people is really important. i lived in a few environments and i learned that if i leave my roommates or living mates up to chance, i will not like it. however if i pick people i like, it actually enhances my quality of life compared to living alone or just with a partner. i am really conscious how my words affect other people so i usually withdraw from conversations just to be safe. i just listen to others talk. however if i know every person well enough in my immediate vicinity, i feel more free to talk. so living among friends gives more opportunity for idle chit chat and other activities which can often be quite entertaining and fun that i otherwise would not enjoy among strangers or other acquaintances. the problem is i have not found a good way to easily find the right people. but that and shared living is a different can of worms.
in such arrangements i do not need to think about buying my own food anymore. if kitchen is always stocked, i can grab some food from there anytime. no more obsessing about bills. i outsourced my worries to "my tribe". even if i am thinking about an expensive purchase of a luxury, like buying a used fixie bike because i suddenly want to go on a bike tour, i can ask the help of my tribe. they can verify if this is a sane reason for spending the money, and if so they can help me with the purchase. they can help negotiate prices, do the financial transactions and so on. i do not even have to personally think about money. i trade with trust within my tribe members and on a higher level the tribes trade with money between each other.
maybe a very limited form of the above thoughts could scale up to a larger community as well. imagine a small but densely occupied town. this town could have provide cheap free food for whoever that wants it (within limits, e.g. you have eat everything right at serving). if it serves cheap porridge or just stale bread every day, that is fine too. maybe it could even have a nearby facility with clean water and warm rooms. maybe even allow sleeping there. think of nothing fancy, just mattresses on the floor, rooms perhaps shared with others. the barest minimum to satisfy the lowest level in the maslow's hierarchy of needs. i think keeping up such a facility would not cost a lot of money. most of the cost would be the salaries of people running the facility. and probably nobody would want to use such facilities willingly (i guess i would be an exception). however having such facility available would mean that no matter what you have or not have, simple living is available for everyone for free. i think having free, no questions asked access to the facilities for the basic needs should be the marker of advanced society. money, trading and access to luxuries can come after that. i feel just simply giving a lot of money to people (basic income) is less effective way to a prosperous civilization. i am not against it, it is just i think we should not base our pillars of society on money but rather on infrastructure. once the latter is in place, money can flow freely. let me demonstrate on a few examples why i think infrastructure would be a better solution over the long term:
and the ideal way to design such "living infrastructure" is to have the designers actually live in the infrastructure they designed. they would have an intrinsic motivation to ensure it works well. i am sure they could come up with a long list of reasons why it would not suit them but so would anyone else. this is why this requirement is needed: to design something that actually works.
note that i do not advocate against money or even against giving people free money. i think that is all fine. what i argue for is that one should not require money just to co-exist happily on this planet. it is useful for trading, building new things. but humanity should have a minimum standard of living that is not based on the fictional money but rather on the actual needs of the planet's inhabitants. once most people have access to that, money can be seen as a tool for the extra benefits society provides. until that happens, i will see money as something to stress about.
published on 2017-12-11, last modified on 2018-01-17
# hierarchies: shallow hiearchies are convenient
file hierarchies are an effective way to organize a large set of documents, like, source code trees, personal files, photos or music collections. however i often see quite deep hierarchies for these files. i think that is a bad idea. the nesting should be quite shallow. most projects or organizations do not need more than 2 levels. anything on top of that probably is not adding a lot of value and is just making it harder to navigate said files.
if i need more than two levels then chances are i am better off with some sort of database to categorize the files. let me take the hypothetical example of organizing photos into a directory structure. you might start out with a structure like this:
photos/[year]/[name of the event]/[device]/0001.jpg ... 9999.jpg
so when i go skying and make one photo with a phone then two photos with a camera, i would have these three files:
photos/2018/skying/phone/0001.jpg photos/2018/skying/camera/0001.jpg photos/2018/skying/camera/0002.jpg
but would such organization give me any value? whenever i organize something into directory, i ask myself: will i ever do an operation on all the files under this directory but not on others? if the answer is no, then clearly i do not need the extra directory. if the answer "all the time", then a directory is a good choice for the organization. if the answer is "sometimes" then it is a tradeoff. how much annoyance am i adding to my day to day life by putting this under a directory? i will need extra keypresses, clicks and mental effort whenever i want to navigate to a set of pictures. it is a small extra cost but over time it adds up so it is worth to consider.
in the above example i do not think that organizing based on the device matters at all. why should care what device i used after 10 years? i probably long forgotten about them. so i would get rid of the device directory. on the other hand the name of the event does matter. i might often want to check out a specific event i feel nostalgic about. the year is a bit trickier. i probably will not care about it 99% of the times. i occasionally might want check what events happened in a specific year but i do not think that i should organize my files according to that use case. so in this case my structure would look like this:
photos/[name of the event]/[timestamp].jpg
so the listing of those 3 files would be the following:
photos/firstskying/20180112223456.jpg photos/firstskying/20180113144455.jpg photos/firstskying/20180113144523.jpg
notice that since i can no longer rely on year to separate similar event, i had to change the name of the event to something more memorable. i went for "firstskying" in this example since it could represent the photos from my first skying vacation. on linux i can still easily look up what vacations i went in a specific year:
$ ls photos/*/2018* | cut -d2 -f2 | sort -u
and the common task of "look at all the photos from an event" is also very easy:
$ [pictureapp] photos/firstskying/*
if i were very fancy, i could even add additional tags to the photos (e.g. the device that made the photo) and store all that in a lightweight database. then i can use a rich query language to get a list of files for arbitrary conditions. this solution still does not require directories and easily scales to arbitrary number of tag types. suppose i add some tags to each photo and then store that it a text file like this:
$ cat photodb photos/firstskying/20180112223456.jpg night friday phone skying ... photos/firstskying/20180113144455.jpg day saturday camera skying ... photos/firstskying/20180113144523.jpg day saturday camera skying ...
then it is very easy to query for specific tags and then display just those. e.g. i remember that i have a funny photo from one of the skying events that happened on a friday night. then i can search for it like this:
[pictureapp] $(grep skying photodb | grep friday | grep night | cut -d' ' -f1)
probably i could make this a lot smarter and easier to use but the point stands that if i have lots of documents, then i should not use the directory hierarchy to over-organize them but rather use a specialized organizing tool or database.
in this example i went from 3 levels to 1 level. i find the one level organization more helpful. it is much simpler, memorable and more accessible. all it required is some active thought about organization.
reorganizing multi-person projects is a little bit trickier though. as an individual project member i probably do not have a good insight how others use the project. however we can use conway's law to help us. it states the following:
at first it sounds as something bad. but when i thought a little bit more about this, i think this law is something i should embrace rather than work against. suppose i have a news site and i want to track its source and content in a monolithic version control system. this might be the hypothetical history of the company:
so i ended up with this hierarchy:
with such a hierarchy a significant portion of the project members have to deal with the /webserver prefix daily completely unnecessary. so instead of subdividing the project among the lines what sounds logical, i would divide it along the team boundaries. that is what conway's law suggests if i twist it hard enough. so i would have this:
each team has its own top level directory under which they can do anything they wish. most teams do not suffer the unnecessary burden of extra hierarchy. in such situation if i get annoyed with an overly long path, it is only my team who i need to convince to refactor the files. the changes under my team's directory would not affect other teams too much. i can freely create directories under my team's name, i do not need to concern about the fact whether it sounds logical or not, or seek approvals from other teams. the hierarchy is not really getting into my way, it is just a tool to divide the land of the shared file tree.
this approach leads to a very shallow directories with many entries. that sounds like a nightmare to manage. but once i am over the initial shock, i actually find it very efficient. i do not spend ages contemplating whether i should put the logger.c file under the code/util directory or the code/system directory. and i do not need remember where i put it either. if i am looking for it, i can just do a "ls *log*" and find it quite quickly. no need for fancy recursive searching.
a word of warning. i think symlinks should be avoided if possible. there is a lot of value of every file having a unique path to it. if i start using symlinks, i might start referring to some files through the symlink and that would lead to bad habits. having unique paths to files makes referring to the files clearer. if i use a symlink, i really want it to be obvious. maybe its name should contain the fact that the file is a symlink, e.g. a .lnk extension. this way there will be less confusion about the canonicality of a file. it will be obvious from "/runscripts.lnk/start.sh" that this start.sh does not belong to a "runscripts" team, it is just a shortened filename.
benefits of shallow hierarchies is not restricted to filesystems only. url structures for websites should be quite shallow too. if i were to operate an online store then i would keep my products at urls like myshop.com/1234578. non-numbers would trigger searches. e.g. myshop.com/leather+shoe would search for leather shoes. i think that is more usable than a url like myshop.com/search?lang=en&location=us&num=20&query=leather+shoes. the former is easily to remember and share while the latter is a nightmare. i could type out shareable links for that site without even needing to visit my url to verify because its structure so simple. you can still create custom, non-search pages if you put a slash at the end to indicate you are not trying to search. e.g. myshop.com/login/ could go to the login page without confusing it with a search query.
to sum all the above up: i prefer shallower directory structures because once i am familiar with the environment, shallow structures make navigation easier for me. if i find the shallow structure hard to navigate, i try to use a search tool instead of making overly deep, hierarchical structures.
edit: i found nice motivational quote related to this article: "in his 1970 classic work the feynman lectures on physics, feynman covered all of physics — from celestial mechanics to quantum electrodynamics — with only two levels of hierarchy." - think of this every time you create a system with deep hierarchies.
published on 2017-12-12, last modified on 2020-01-19
# challenges: a way to test one's programming skills
i really liked puzzles and challenges as a kid. i participated in programming competitions and some easier math ones as well. the problem with competitions was that whenever i lost, i felt quite sad. especially if the competition had a form of direct elimination. e.g. if i was not in the top n then i did not pass to the next round. when i was eliminated then i felt dumb, i was not part of the "elite", i did not have the "smarts" to enter the next round. it was a very discouraging feeling. however winning such competitions was an awesome feeling. i felt proud of myself and even got prizes to boot.
interestingly, i had similar feelings about school exams. there too i felt the dread and stress of failure. it might have been even worse a bit because even though the bar was lower, the stakes were higher: if i fail, bad things will happen to me. e.g. i get exposed to even more exams unvoluntarily. i tried to ignore grades but i did felt pressure for good grades. so bad grades also made me sad.
another frustrating part of these exercises is their randomness factor. i never knew what to expect. especially bad were the ones where the examiner gave me a random subject and then i had to talk just about that subject. what fascinates me is that in such cases i always managed to get a subject i happened to know. as my studies progressed, i even started to rely on this more and more and learn less and less. this was very risky, yet my luck persisted.
now that school is over, i am no longer subject to these experiences. i miss them a bit though. it is not the dread and stress i miss. it is not even the sense of achievement i miss. if that would be the case then just competing and succeeding in online programming competitions would give me the same dopamine shot i am missing. yet they do not. i tried doing them but i simply did not have the same motivation. i did not find them that much interesting. i do not think i just "grew up". i sort of feel the same as i was a kid. it is just my environment and my interaction with it that completely changed. however if i would get back into the same environment, i would probably enjoy the same things as i enjoyed as a kid.
my childhood competitions and exams were in an environment of friends and family. these people knew whenever i attended these exams and competitions. they always asked about the results. when i got good results, i felt good about myself because i understood that it meant something for these people. they might have felt proud of me. i never bragged though. i just let people be naturally curious (where were you yesterday?) and ask questions (oh really? how did you fare?). i never liked to talk about myself so i tried to dismiss questions but after enough nagging or some other ways (e.g. teacher announcing everyone's results) people found out. i had this "thing" where i preferred that people find out stuff about me from other ways than me talking about it. maybe this is a form of signal that said person was so interested in me that they looked up or asked information about me, remembered it and then asked me about it. a sort of honest, non-fakeable flattery. it felt good. i guess i am a narcissist. but i am digressing.
so achievements of exams and competitions felt good because i felt that i impressed nearby friends and family. it was important that i impressed people i knew. impressing strangers is boring. i mean just compare the following two statements: "a random korean guy won a starcraft competition" vs "your friend won the bowling nationals". which one is more exciting? the latter excites me more because then i want my friend to talk about it. the former i just simply do not care about. now that i grew up, it is very hard to impress people, i do not usually get such feedback. if i had some friends with whom i would continue to do programming competitions, i think i would find it fun. but i am not a person with many friends. it is not that people run away from me, it is more that i do not even try acquire or meet people. anyways, digressing again.
even though this game is over for me, it does not mean i cannot create an environment where people can acquire such experiences. however if i am going to do this, i want to remove the elements of dread, stress, randomness, lost opportunities and so on. at some point in my life (maybe when i am retired) i would like to try creating a particular "challenge". let me describe the rules and then i will explain why i like the idea:
i have not fully thought out the challenge but i think those rules achieve most of the features i want the challenge to have. here are my reasons why i would like this challenge as a taker:
so that would be my idea. the challenge itself is not very practical. but i do not think everything in life must be strictly practical. it is a game. no need to play if it does not sound interesting.
ideally when i retire, i will do so in a small city and could run such a challenge from my home mostly for the nearby kids. maybe i could present multiple challenges with varying difficulties and then advertise the challenge in the local school. it would be completely optional, i would not expect too many kids to try. however i can play with the prizes. if nobody attempts, i can just keep raising the prize until a few kids get so obsessed with it that they will start training for the challenge. it is an easy way to get some people motivated to do something i want. there is not much point to this other than getting onto the hall of fame. however if they manage to get there, they might get interested in other, more mature competitions and this might kickstart their interest in computer science.
since i think i would be pretty comfortable with such challenges, i wonder if similar conditions could apply to school exams. i could split school exams into two categories: the mandatory exams and the extracurricular exams. both types would be binary: pass or fail. there is no grading. however there would be no punishment for failing. they could just retry 3 months later. the mandatory exams would be super basic: it is just to confirm that they can read, write, count, know the basics of ethics (do not hurt others), know some basic stuff about everyday life (monetary skills like avoiding credit or the concept of interest rates), some basic life skills (cooking an egg). the extracurricular exams would be about history, algebra, literature, programming, sewing, cooking, woodworking and others (each subject would have multiple exams with varying difficulties). kids could do the exams any time they want, in any order (as long as they take at least 1 each month for instance). the nice thing is that then the kids can direct their knowledge intake as they wish. if they do not have preference, others can suggest them exams to take. the learning part of the studies is left to the kids to figure out. sure, they can attend classes but if they feel they can go faster than the rest, they can just take the exams sooner and not bother with the classes. and just to make sure kids have an incentive for collaborating, they could have random study groups where all members have to pass a specific exam. the study group members now have to branch out subjects outside their interest. if a member is not interested in the subject at all, the other study group members must somehow work with the disinterested kid to convince and teach the kid about the subject for the greater good. they have to do so because the rule would be to not allow the study members take more exams until they get everyone on their group to pass the random exam. anyways, i am just rambling random ideas. the point is, rather than forcing a very strict curriculum and punishing failure, i would much prefer to give more choice for kids to pursue education in the areas they like and at the pace they want, have easier and less stressful exams (they are kids afterall) and avoid punishment for failing exams but rather teach to keep trying, regardless of failures.
published on 2018-01-23
# efficiency: focusing on efficiency leads to complexity
it is very easy for me to fall into the trap of obsessing about efficiency. efficiency can mean many things: in software i might be optimizing for minimal ram usage, minimal time use, or in real world i might be optimizing to spend as little money as possible. however achieving peak efficiency has downsides. the principle of pareto efficiency suggests that the more efficient i make something, i lose optimality in other dimensions. the principle introduces the concept of pareto frontier: when i am on the frontier any improvement in my preferred dimension will result in decline in some other dimension. examples:
i am not saying that i should embrace inefficiency but rather just to avoid the obsession to be at the frontier. it is much easier to adapt to the changing world when i have a lot of wiggle room. this leads me to the next question: why the obsession about the efficiency?
suppose i am a big company. i make 100 million dollars yearly. if i hire a person that can make 1% improvement to my processes then that means i can now make 101 million dollars yearly. that is 1 million dollars worth of extra money in exchange for one person's salary. sure, it adds complexity to my processes but that person can deal with it so it is a sound tradeoff.
other examples: i am a farmer and improving crop efficiency means i can feed more people. or improving fuel efficiency means less pollution. in many the other cases like these the benefits do outweigh the downsides. but it is important to be aware of those downsides.
the common theme i see is that efficiency starts to matter mostly in large systems where even the smallest improvements lead to large, quantifiable differences. the same system can also afford the kafkaesque complexity stemming from all the small efficiency "improvements". but when other people try to use or rely on the output of that system then they are inadvertently exposed to the risks stemming from all that complexity.
although i enjoy the efficiencies of the modern world but when it comes to my own projects, i stopped caring about efficiency and optimality. my new focus is to not let things grow unbounded. i set arbitrary limits on myself or on the software i write and i adhere to them. when i reach a limit somewhere, i take a deep look to see if i can solve the problem in a different way so that i do not need to increase the limit. this approach lets me avoid being stuck in some local minima and reach much higher efficiencies in total. for example if i have a simple software that only solves 80% of my usecase, i will try changing my usecase rather than grabbing a more complex software. usually my environment gets simpler in exchange. for instance if all i want to have a blog with some text in it, i can just write simple text files rather than html or other complicated markup that needs various postprocessing before i can serve them. this way i do not need to deal with fonts, css, hyperlinks and whatnot. only the important bit, the text itself, remains. and most important observation from this is that when i avoid the unnecessary fluff, things get miraculously efficient. for instance this website loads quite fast without any effort on my side. no need to set up compression or use fancy protocols to make it fast.
i am pretty sure the efficiency stemming from limits extends to other cases too. if we did not have that much cars available, people would be more dependent on public transportation so the planet in total would be more efficient. or if less food would be available, we would have also less waste so probably we would try to be more conscious about food. of course we would have harder, less convenient life but potentially more efficient in exchange. this might not sound appealing for everyone but i think applying some limits on ourselves might get us some improvements and efficiencies in exchange without an explicit focus on efficiency itself.
published on 2018-04-27
# motivation: i'm way too lazy
some days i struggle to get myself to do anything at all. i wake up, do my daily routines but then i spend most of my time with work related stuff like reading and responding to emails. when i get home i play with family and afterwards i go to bed and sleep until tomorrow. i do not spend time on hobby projects or on learning new stuff. weekends are not more productive either. when i was a kid, i found computer programming quite fun and exciting. i enjoyed solving project euler puzzles, acm style programming competition problems and writing small tools here and there. in order to do those i needed to learn about math, algorithms, programming languages and best practices, operating systems, english language and many other topics. but today? i feel like i am not learning new things. that would be fine as long as i would be working on something meaningful instead, harvesting all the knowledge. that is not happening either. it is like my time is flying by and i do not have anything to show up in exchange. i am not investing my time into anything.
there are a few differences in my current life compared to my kid life though. when i was a kid i had a lot more free time. i was much earlier home compared to my typical work day. when i was home, i had private room where people left me alone so i could do anything without disturbances. today i do not have any privacy. at work i am in an open plan office and at home i have my computer in the living room so that i do not isolate myself too much from others. this makes concentration harder especially if others are doing distracting activities. this somewhat explains why i feel i have little free time and the easier distractability but it does not explain the lack of motivation i am feeling.
to clarify this lack of motivation is not depression. i do not feel depressed. it is more like i feel that everything that is important already exists so i do not see the need to create more software. now that i grew up and got a broad enough overview about the software field, i feel like the software world hit a plateau in the late 1980s as people finished implementing all the obvious software and today's software and computing is just mostly fluff. i feel like we are over-softwarizing our environment where all we would need is just saner practices or solutions and then we would not need said software. it is probably better to leave this topic for a separate blog entry in the future for now as it is off topic.
it is not only software i am not that much interested though. achieving anything for me is a burden. let it be exercise, cooking, cleaning. to compensate i just avoid having bad habits and thus i do not have problems with health or messiness. i walk to the office, i keep a super clean desk, i do not smoke, i do not drink alcohol or sugary drinks, i do not buy crap i do not need, i do not even have money on me most of the time and so on.
yet i still function. i can still keep my job, i still occasionally make a tool for myself, clean the house, or just generally keep myself alive. how so? i am definitely not intrinsically motivated to do these things. the motivation comes from external sources. it is either something annoying me or somebody nagging me. if i am annoyed with a flaky or inflexible tool, i am somewhat inclined to write my own version of it. if somebody is pestering me about something, i am somewhat inclined to do what they want to stop them from pestering me. the latter has a quite a strong effect on me. if somebody sends me a message, i have this very strong urge to always have the last word. it is almost and ocd like tick. if that message has a simple request or a question, i have an urge to do whatever it asked me or come up with a very good reason why i cannot do it. these two things get me through my life these days. if the toilet is so dirty that i am annoyed then i clean it. if at work somebody assigns me a small bug to fix, i fix it.
on the other hand if the floor is only a little dirty, i will probably not do anything about it. i am not annoyed so it is fine as it is. as for the second case: if at work somebody assigns me a big project that needs a lot of consideration and coordination, i am at a loss. driving such work requires a lot of inner motivation which i lack. in such cases i rely on having management aiding me. talking through a project with another person, splitting it into smaller pieces and then having a manager pestering me about it really does help me. it is no wonder rubber duck debugging is a thing, it is just that a rubber duck is not as motivating as a human could be.
i recently came across the concept of "accountability partner". once you find a partner, both of you agree to a set of goals, you keep periodically reporting to each other about the progress of your goals and keep each other accountable for those goals. it is similar to coaching. i think the difference is that while a coach coaches you, you do not really give anything in return while you do provide value for your accountability partner. the latter does not feel too much of a one sided burden. if i were to stop adhering to my goals, that might make the partner also stop adhering which would make me feel guilty so i am personally incentivized to adhere to my goals. basically this is setting up the nagging feeling for myself. i have not really tried this. if i ever find myself wanting to do a small project, i would totally try this. now if only i had friends for this. maybe acquiring more friends should be one project. oh well, something to think about.
so to sum up: i am no longer motivated intrinsically about things like when i was a kid. i can get around this by having an environment that still motivates me extrinsically to do things that i really need to get done. however it does not really lead to working on original, novel things. for that i have no solution.
edit on 2023-08-05: i no longer feel this way. i have my own private room again and @/imtasks keeps me motivated thorough the day.
published on 2018-05-26, last modified on 2023-08-05
# boy: a story about growing up
boy's life started out quite simple. he lived in a small farming town, he was surrounded by loving and supporting family. he spent most of his early days either fooling around with neighbor's grandchildren outside whenever they were around or just watching television. he liked watching sci-fi shows. as time passed, he started nagging his parents for a computer because that is what he has seen a lot in the tv shows. the parents were financially strapped so it took them a while but they eventually found someone with a very old computer that they wanted to throw out. boy got his first second hand computer. he fell in love with it. he spent a lot of time with it. he was playing video games and also learning programming in the hopes creating new games. as time went on he grew apart from the neighbor's grandchildren since they started to spend less and less time around. to understand the computers better boy started attending a extracurricular computer class. he managed to find a friend there who also liked to play video games. he befriended him and they visited each other often to play games.
boy spent most of his teenage years in a single school. for 8 years he studied with the same set of roughly 20 people. his classmates were nice people, they liked each other. boy was friendly and a relatively good student. he liked attending school. he liked its relatively rigid structure. he went in the morning, attended the classes and then went home. he was a person of habits so this worked well. nothing extraordinary happened in his life and he was happy like that. he kept learning about computers privately. he wanted to become the best programmer in the world. he thought that when he reaches the ultimate computer mastery then fame and fortune will follow and everything will be okay. he spent most of his afterschool time alone in his private room fooling around with his computer.
he started noticing something during his late teenager years. more and more of his classmates started hating school. some of them even skipped some of the classes. some of them started going to pubs or just generally hang around after the school. this was odd to him but he kept enjoying school and always went home to his computer afterwards. on some occassions he went along with others into pubs to see what was it all about. every time he did so he found himself in a completely new environment with many strangers all talking. he did not like the situation. all he could think of is going back to his more familiar places. the topics people talked about were all sorts of things boy had no experience with. music, dating, talking about other people. people drank alcohol and smoked cigarettes. boy completely refused to do those things since he was afraid those acts might interfere with his goal of infallible mental acuity needed for being the best programmer. he completely avoided going to such places. he continued to stay at home outside school.
during his teenager years he continued the playdates with his video game friend. when they got a bit older, that friend introduced porn to boy. friend brought some porn pictures on a floppy disk. boy did not understand it first. so friend decided to do something that really surprised boy: he started masturbating in front of him. he finished with an ejaculation which was also a completely new thing he knew nothing about. friend then said that boy should try this too, it will be fun. boy got curious and said sure and asked for instructions. there they were, two adolescent boys, showing their penises to each other and trying to masturbate. this was the first time boy remembers seeing another penis. he might have glanced one or two in the past but this was the first time he had a chance to actually take a more detailed look. boy had his own penis right there to compare. it looked different. the foreskin on boy's penis did not cover his glans. friend's foreskin could stretch long enough to cover that part. boy then suddenly remembered that he had a surgery on his penis when he was a kid. his parents were sometimes questioning him whether he can "pull off his skin" there or not. he was quite shy person so when the parents insisted on showing it, he just quickly showed that no, he cannot do that. they took him to a doctor who signed him up for a surgery. boy did not really understand the whole thing that is happening around him. he noticed that his penis looks a bit different after the surgery but he did not think of it much and soon has forgotten about it. as boy explains this to friend, boy gets a bit scared about it. did the doctors actually mutilate his penis? friend immediately calms him down that this is nothing to worry about, it is not that important part of the penis. then he instructs boy that he should start stroking itself. boy does but nothing much happens. he does not feel much. his friend plays videogames in the meantime. boy keeps stroking penis as his friend recommends. nothing happened at that point so after a while boy stopped and continued playing video games as if nothing happened.
the penis difference kept bugging him. around that time his school got internet access so he picked a quiet, private corner machine in the computer lab and started researching penises. he learned that the operation he had was a circumcision. he learned that while it is common in some cultures, it is not common where he is coming from. the feeling he got is that circumcision is associated with a stigma. the idea was that it was something that only an unrespected ethnic group did to their babies so if people were to figure out that he is circumcised then they would make fun out of him and would outcast him. boy felt ashamed about this part of him. he felt that this is something he must hide from others.
as most teenager boys, boy kept playing with his penis now and then. eventually he managed to get his first ejaculation. then porn started getting more and more interesting. friend brought even more porn for him. they even masturbated together. porn was exciting for boy. after a while it was not really the sexual act that he found most interesting in it. it was the fact that the people in porn could completely disrobe in front of each other without any shame. it was something he could not imagine comfortable doing himself due to his fear of shame. being naked became a symbol of power for him. he wanted to be able to do what people in porn do. being naked in front of others, being comfortable with the raw human bodies and let him explore other people's bodies and let others explore his. his porn taste was quite soft compared to what was available. all he was interested in was casual nudity. his environment was quite conservative, he did not experience much nudity which made him even more thirstier. in reality he spent most of his time at home, he did not even have the chance to see others in nude, and he did not have the chance to show off himself. though he did not want to show off himself due to his inhibitions. he did not talk about this to anyone. he managed to get through high school keeping all this to himself without ever satisfying his curiosity.
years passed and boy finished his high school and off he went to a big city to study computers in a prestigious university and to experience new adventures. boy entered the real world. he did not really knew anyone in this new place. the university classes were differently structured than his high school. no longer was the case that a specific group is glued together for long hours and are forced to work together every day. it was the wild west, everyone was for themselves. the only thing that saved him was his interest in computer competitions that he started doing in his high school times. he always done well in them. he wanted to continue them in his university. the most prestigious contest required teams with 3 members. he managed to find two other people for this. during his high school years boy was active on a computer forum where he liked to help people. by luck he managed to befriend one person there who happened to start university at the same time as he was. he found another one by looking at past high school competitions to see if there are high achievers in his classes. boy then took the strength and asked one of them to join his team. and so he found a few friends with whom he continued to attend competitions and classes. later they even became roommates in the university's cheap dormitories.
the first three years of the university were quite busy, much busier than high school so that kept boy quite occupied. since dormitories offered 4 person rooms, he did not have much privacy either. he got through these years quite quickly. his fantasies and inhibitions did not change. he was still super shy so avoided anything that might expose him. much like in high school he also avoided all social gatherings. he did not really miss them since he got plenty social interactions from university and roommates. by the end of the third year he also realized that becoming the best programmer was not realistic. in this place he was not the brightest person anymore. this demotivated him. he started caring about grades an his studies even less. he was still a good student but became a lazy one. this and the unfulfilled fantasies made life look bleak to him.
since boy was already quite familiar with computers by the time he got to the university, he managed to find a summer internship place in a nearby big, multinational company. he worked there each summer since his first university break. the company quite liked him so boy agreed to start working part time when he started his fourth year at university. he got disillusioned with the university so he liked this offer. at the same time that year he did not get a place in the dormitory. he was now on his own. when he got the rejection letter from the dormitory, he got a bit scared. he thought maybe he should rent a place since he is now making money anyways. he started looking at rentals, picked the first nearby, nice looking studio apartment and quickly moved in. he did not give it much thought but it worked out well. he got a nice place. he liked it. he was alone. he got back his privacy. he could do anything without anyone looking. the shared living at a dormitory started bugging him anyways due to the incompatible waking hours some roommates lived by.
his daily habit was to go to university for a few classes, then go to work for a few hours and then go home. as weeks passed his disillusion with life and the unfulfilled fantasies started growing. since boy was not spending much time in university anymore, he grew apart from his friends. whenever he got home he started wondering what is he doing with his life. interests in computers started fading. there was not much point to it since he felt that there was not much that he could contribute to the world anymore. there are smarter people around for that and that is fine. most people around that time also had girlfriends, were having fun and yet here he was as a virgin, he had not even seen real naked woman in his life. he did not like the idea of visiting escorts because he was still ashamed of himself. he felt like he could only share himself with a person he knows well. he wanted a girlfriend, a person with whom he could share anything, he wanted a family around himself. some days he went home, to his lonely studio and he went straight to bed and cried himself into sleep because nothing made sense for him, he could not see a future for himself.
boy was quite the lucky person. he had an easy life. parents provided well for him. they did not give him everything he wanted but he got the things he really wanted. he lucked out schools too. he was not bullied, he was around friendly people. he lucked out exams too. he never studied very thoroughly but during exams he always managed to randomly pick a topic he knew well so he managed to slide through high schools and university exams without ever failing an exam. his sheer luck also helped to meet the right person at the right time. on one random day at his second university year he was sitting in the university's lounge area with a concerned look on his face. a girl classmate was sitting next to him. she keenly observed the distress and asked boy what is nagging him. boy explained that last summer he worked in a summer internship and now he is expected to file tax reports. boy had no idea what to do and he was not sure who to ask about it. the girl in question, luckily for boy, happened to have an accountant degree already. girl volunteered to help boy out. boy got super happy about this. girl also happened to live in the same dormitory as boy. all he had to do is go down a few floors in the evening, hand over the necessary documents and let girl figure out the rest. life could not be easier. since she was the first girl he talked to since he came to university, he wanted to have more interactions with her. boy took a big breath and told girl that if she ever needs help with her classes, he is happy to help out. it took a lot of courage for boy to say this since he feared rejection. girl said thanks, she might get back to boy later. she did so eventually. boy went over to her room quite a few times to help with homework. girl had a boyfriend already in her hometown so boy did not think of this relationship much. he really liked the fact that he can be around a girl. boy also liked a roommate of girl's since she had qualities boy could empathize with. roommate was smart, quiet, shy and friendly sounding. boy felt the same about himself so she liked roommate. boy did not meet roommate a lot though since girl and boy usually went to a more private areas to not disturb the other two roommates and that they do not disturb them. boy was quite shy in front of others anyways so he preferred it this way. not much more happened between between girl and boy during those early years. boy happened to hang around girl whenever she needed some help and girl helped out with boy's tax documents once every year.
this relationship persisted even in the fourth academic year during boy's depression. since neither of them were in dormitory anymore, they did their occasional meetings in university lounges. girl was living at her relatives. boy was reluctant to invite girl to his apartment to avoid looking like a creep who is trying to hit on girls with boyfriends. eventually the topic came up, boy told girl he is now renting a studio, and after another courage gathering session he asked that she might as well come over there. to boy's surprise girl agreed. girl started to come over to boy's place every few evening to study together. some evenings she went home quite late. since she was already over to boy's place and did not feel like going home, boy and girl watched movies together or boy was showing off some magic tricks he learned on the internet. what boy did not realize at that time is that girl dumped his boyfriend a few months back. she even told this to boy once but it flew past boy's ears. one day boy was chatting with girl on instant messaging. in that conversation girl got tired and asked to have sex already. this request came when boy was deepest in his depression. girl did not know about boy's depression. that day boy did not cry. all he could think of is girl's message, seeing an actual woman naked, a woman seeing him naked, and the fact that he can have his first sexual experience. when boy got back his senses from the message, his body shame jumped right back into his mind. after a few confirmational queries about his understanding of the original message, he told girl he is circumcised and asked how big of a deal that is. girl told him that such things do not bother her. she then carefully asked if the circumcision was due to medical or other reasons. this question did not bother boy, nor would any answer bother girl but it confirmed for boy that indeed people in his area do associate circumcision with ethnic rituals.
next time girl came over to boy's place, they did not bother with the studies. they just lied on the bed. boy asked if he could kiss girl. she said yes. they kissed. boy asked girl if she could take off her shirt. girl was a bit uncomfortable with this but she agreed. boy asked the same about her bra. girl was even more uncomfortable with this but eventually she agreed. boy could see and touch real boobs the first time in his life. he was very happy. he enjoyed the moment. boy asked about taking off the pants. girl said no. then they just continued lying next to each other. boy was curious, he continued to pester girl. he asked if he could at least touch her vulva. girl reluctantly agreed. boy slided his hand into girl's pants. he touched it. he explored the vulva. it was moist. he then pulled his hand back and put his fingers to his nose. he examined it carefully. he even tasted it just to be sure since he was not sure if opportunity will last or not. his hand then wandered back into the pants. boy continued his blind vulva exploration. his curiosity grew. he asked again about taking off the pants. girl agreed this time. boy did not hesitate, he took it off. he liked what he was seeing. he examined his discovery from a very close perspective. he immediately felt the need to use more senses for this exploration like taste. he slowly started approached his target, and felt it all around. he continued this exploration. girl was not objecting. after a few minutes girl came. girl pushed away boy's face to stop boy's eagerness. she had to rest. the fun was over for boy. hugging and silence followed the fun. girl thanked boy and said that it is getting late, she should go home. she then slowly got dressed and boy escorted her home.
boy was super happy. he now had a friend who fully trusted him with her body. he felt like his fantasy came true. though it was not the full experience for him since his penis had to remain at its dark place last time. however he knew that the time is close. he will get to show off, use his penis and experience sex too. boy walked around satisfied and excited about the future. he knew that more adventure is around the corner. soon, girl was at boy's studio again. over instant messaging boy convinced girl that they should have real sex next time. he also asked girl to have low expectations, he never did such things, he will probably utterly fail. this time both were ready to have sex. boy quickly undressed girl. he played around her body again since boy's fascination with bodies did not diminish. after a while boy also decided to undress, put on a condom, and try to fumble his penis into girls vulva. he went in and minutes if not seconds later he came. he had his first sex. he was a bit underwhelmed though. partly because of his premature ejaculation, partly because of his expectations. boy thought having his penis in a vulva will make the orgasm a completely different, more extraordinary feeling. it was the same bodily feeling as the old ejaculations he had. the difference this time was that he was with another person. he still very much enjoyed it but in a different way. his penis, his erect penis, the ejaculation to boy were increasingly more and more private aspects of life. but here it was happening next to, inside another person's most private body part. to boy this represented a very deep, trusting bond with the other person. he did not care about the orgasm much, he cared about the intimacy he managed experience that day. that is what he felt most satisfied about. sex was a way to achieve that deep intimacy boy was longing for. hugging and relaxation followed.
girl kept going to boy's place and they kept having sex in similar ways. boy tried experimenting a little bit to see what differences are there to the experience. boy was elated. after a short while he asked girl to have a shared shower. boy wanted this so that he can show his body fully girl. so far girl did not really see boy's body. while girl was lying on the bed, boy had to do everything himself. he undressed himself, put his penis inside her, then later cleaned up himself. during these acts girl did not stare at boy's crotch much. he wanted to make himself easier to observe. they had their shower. boy proudly showed presented himself to girl. girl was a bit shy but otherwise acted completely casual. boy was completely mesmerized with girl's body. he could not keep of his eyes of girl's body, he was mentally trying to crystallize the experience into his memory. they showered together all right but to boy it did not feel like girl is giving him as much attention as he is giving her. boy felt the lack of interest but the possibility of being fearlessly naked and having the possibility of freely explore girl's body overshadowed the lack of the reciprocal feeling.
as boy got more experience in sex, his performance improved, sex was great. everything worked like in the movies. girl continued to show generally less lustful interest in boy's body. slowly boy understood that this was not due to his body not being attractive but it was due to girl not as interested in nudity itself. she had a different love language. boy did not feel fully satisfied. he did not even fully stop with his porn addiction. his fantasies continued. he did not hide this fact from girl. boy was super honest. girl did not really mind that boy still looks at porn after boy fully explained how he thought. boy really liked the fact that he can share any uncomfortable thoughts with girl and that the girl accepts those without judgment. such unconditional acceptance was part of his fantasy after all. even without the fully satisfied fantasies boy no longer felt depressed. boy was happy. future was now full of possibilities.
girl started spending more and more time at boy's place. she even started sleeping there overnight. boy liked girl and he liked that she spends so much time with him. boy even fantasized growing old and having a family with girl. after a while they wanted move together but girl did not really like boy's studio because she did not like having everything in one big room. boy's rent was quite high too. girl was thinking about renting a bigger and cheaper apartment. meanwhile girl asked if her former roommate boy liked could sleep one night there. roommate was also rejected from dormitory so she was sharing a flat with 3 other girls. suddenly their landlords decided that they do not want to rent their flat out anymore. she needed a new place quickly and she needed a place to stay until she found a new place. boy immediately agreed. sleeping next to two girls he really liked sounded like a dream coming true. boy had his sleepover pajama party at its place. it was not terribly exciting since nothing happened but the fact that both girl and roommate trusted him enough to sleep in the same bed as him was a very comforting experience. girl slept in the middle so there was no chance for funny business. this way girl did not really mind the setup for a day. next day roommate explained that she needs to find a place not only for herself but also for her sister so she was not sure what she is going to do. boy, girl, and roommate knew each other for a while now and they liked each other. girl proposed that maybe they should band together and rent a place together. everybody agreed. girl and roommate hit the internets to find places and started visiting apartments. boy did not really care much where he lived so he let them do whatever they wanted. he had to go to university and then to work anyways. the girls quickly found a nice 2 bedroom place and the next day all four of them, sister included, visited and agreed to their new place where they planned to spend most of their upcoming days.
the apartment was long and narrow. it had 4 rooms next to each other. bathroom, bedroom 1, bedroom 2, kitchen. flatmate and sister lived in bedroom 1. in order to get from bedroom 1 to kitchen, one had to go through bedroom 2. boy and girl lived in bedroom 2. in order to go from bedroom 2 to bathroom, one had to go through bedroom 1. unless one was alone, there was no real privacy for anyone. girl's former roommate now became flatmate. boy did not really know flatmate's sister until they actually moved in. he worried about this a bit. flatmate previously explained sister is like her but younger so if he likes flatmate, he will like sister too. this turned out to be true. boy noticed minor differences though. sister was a bit less shy, more confident, she looked like she knew what she wanted, like she had her whole life planned out. boy and sister liked each other but boy liked flatmate better since he felt more commonality with her. boy felt that flatmate is also a little bit lost and misunderstood in life so they exchanged banter about who is more clueless in life.
everybody was happy with the arrangement, everybody liked each other. there were no quarrels, group members did not annoy each other. nobody was the party type person so everyone had sane waking hours. days, weeks, months passed. boy continued to have great relationship with girl along with great sex life. however boy still did not really feel that his fantasies were fully met. he was still in his first love's high, he was happy enough so he did not mind that much. he kept consuming porn to make up the void. as summer approached, the outside temperature kept rising. the apartment was cheap because it lacked a few things like air conditioning. it was quite hot inside as well. everyone was sweating like pigs. boy started hanging out in his underwear. flatmate started hanging out in a bikini swimming suit too. girl and sister did not really like dressing down so they kept themselves fully clothed. they did not mind others hanging out half naked. boy liked the lack of air conditioning because he liked what he was seeing: a barely covered body of a close friend. boy was confused though. he was looking at forbidden fruit. he did not know what to do so he just discretely feasted his eyes on flatmate's body. as the rapport between boy and flatmate grew, they became more playful with each other. boy's favorite game was a tickling battle. boy could touch flatmate's in a playful matter. it was exciting for him. at the same time this was not sexual so there was no anxiety about doing the wrong thing in this play.
a year passed, boy liked his situation but he still felt unfulfilled. he wanted more intimacy. he wanted to show and see more. boy learned from flatmate that she did not really like to be nude. she does not have a problem with others being naked around her although she is not that keen into being around naked people. boy asked girl if he can hang around naked around flatmate. girl was not comfortable with that so she said that he should not. boy respected her request. this bugged boy. he really wanted to open up his body to flatmate. he wanted the flatmate to validate his imperfect body. out of desperation he started to act in a very creepish ways. he tried to sit in ways where his underwear does not fully cover his crotch area, to make it look like his penis accidentally slipped out. he wanted flatmate to catch his wardrobe malfunction. it was not terribly effective. he was not even sure what he was trying to achieve. the tickling battles and other games did continue, especially when only two of them were at home. this started to became harder and harder for boy. boy was so obsessed about flatmate that whenever they started playing, boy got an erection. boy was super shy about this. he felt that he has to hide this from flatmate lest she thinks boy wants sex and then she distances herself from boy. boy often had to hold back in the games until his erection passed and only then continue playing. hiding his thoughts, his body and his bodily reactions from flatmate felt wrong but he did not want to make the whole thing weirder as it was already. he had it way too good, did not want to risk pushing his relationship with flatmate further.
boy finished his university studies at the end of his fifth university year. he went working full time. his workplace insisted that he goes for a 3 month training at a very far away place, a different continent even. he did not want to go because he was not keen on going to strange places alone. he did not want to leave his group either. workplace insisted that boy goes. he also worried that this will worsen his relationship with girl. however girl assured boy that 3 months is not so much time, they will be fine as a long distance couple, the job is probably worth it in the long run. boy reluctantly agreed to the training. he packed up, said his goodbye, hopped on a plane and flew away. workplace arranged a private hotel room for accommodation. although around this time internet was already ubiquitous but not smartphones, the time difference between his new place and his old place was quite a lot so synchronous communication methods like instant messaging and videochats were not convenient. he relied on emails for communication. he started one thread with girl and one thread with flatmate. his work training was quite boring and boy was not interested in sightseeing either. outside work he just spent his time alone in the hotel room. he did not have much to say to girl. the email exchanges they had were quite short and to the point. mostly just status updates and long distance word hugs. that is how the email thread with flatmate started too. however in flatmate's case he had a lot of undisclosed thoughts. now that boy was far away and the fact he had started working professionally, started his adult life, he thought maybe he has not much to lose. at worst he could just not go home at all. he wanted to dump all his thoughts on unsuspecting flatmate in email. boy found the email medium much easier to deal with. he can slowly think through what he wants, write it down and then just press a button when he is ready. things he would not have guts to say in person was now possible to communicate through email. this was his fantasy after all. to completely open up to another person. boy wrote an email and sent it. he messed it up.
boy did not thought his emotions and thoughts through. he dumped them on flatmate in raw, undigested form. flatmate had no chance making sense of them. he made flatmate deal with his feelings. she was angry at boy about this irresponsible way of communication. she was was fine with boy feeling emotions and working through them with her but he should take responsibility for them. she tried explaining this to boy repeatedly but boy did not get the message. in the emails boy explained that he is attracted to flatmate and would like to be with her but he also liked what he had with girl. he did not understand what this feeling was and what should he do now. he was sort of expecting flatmate to come up with a solution for his dilemma. for him everything, including his emotions had to have rational explanations. he went on trying to come up with all sorts of silly rationalizations of his feelings, cost benefit analysis of the various solutions, all sprinkled with many self depreciation comments. he presented all this like if flatmate and girl were just pawns in boy's calculations for maximizing his life happiness. all this was unfair and insulting to flatmate. he wrote long walls of nonsensical text and thus made flatmate angry. eventually boy apologized in his own, nonsensical way of writing which flatmate accepted after she realized she cannot talk much sense into boy. they did not talk much about this topic afterwards.
the 3 months slowly passed and boy was back in apartment. he did not like keeping secrets so he explained girl what he did without going into too much details. girl was not amused but since he did not actually do anything sinful, she did not get angry, she appreciated the honesty. girl always trusted flatmate, she knew flatmate was also just a victim to boy's craziness, she did not get angry at her either. the relationship between boy and flatmate got a bit colder but they remained friends. they did not talk about the emails afterwards as if they wished they never happened.
another year passed. boy had a good job. he did not like it very much but he understood that he would like other places even less. nevertheless boy interviewed at another prestigious multinational company in a far away, western country. he did not think much of it at first but he managed to get an offer to work there. boy heard only good things about this company and the offered salary was also much higher than his current one. but it also meant leaving behind the apartment. girl was a little bit reluctant to go too. the prestige, money and the experience of a foreign country was attractive. boy was leaning on going. girl asked boy to marry her already and then she will go with him.
boy understood girl wanted marriage for a while now. for boy marriage was just a technicality but he understood it meant a lot for girl. he wanted to have family with girl so he did not really have objections against it except for one thing. he felt that he had way too little part of his fantasies fulfilled and with girl he will not ever be able to fulfill those. he feared that later he might get a chance or find a way to fulfill some of those fantasies in ways girl would not fully approve of. he might even want to have sex with others. he was feeling a big void in his life and he could not bear the idea of locking away the full human experience forever. he cannot marry girl if he is kept on a leash. girl was sad to hear this. girl's heart was limitless though. he heard boy. girl said he does not want boy unhappy. if he is honest with her, they can work through this even if it meant boy having his crazy adventures. boy was happy to hear this and agreed to the marriage. they quickly married privately without any pompous ceremonies. then they packed up and left for the greener fields.
in the new city boy and girl rented a nice two bedroom apartment and the two of them lived alone. boy was spending most of his time at work, girl was learning the new language. during evenings and weekends they spent their time at home watching movies or just generally being lazy since boy continued to show complete lack of interest in leaving his home. boy was missing their previous arrangement. he suggested that they should get flatmates again in the hopes things will get more fun again. they understood that their relationship with their previous flatmates was very good and it is unlikely that any new roommate will be the same. the previous flatmates were not picked randomly, they knew them well, girl even lived with one of them for a while. they wanted the new, stranger flatmates only for short stays just to be on the safe side. girl was quite the social butterfly. she quickly managed to build up a small social network for herself mostly consisting of expats from her country living in their new city. she could find roommates through her social network, she never needed to formally advertise the free room. their new apartment was more modern. each bedroom had its own bathroom and shower room and the bedrooms connected to the living room directly. no longer was the case that people had to go through each other's private room multiple times per day. each person could have its own undisturbed privacy if they wanted to.
many years passed. boy and girl lived more or less happily. they had many short term flatmates, men, women, couples. for boy none of them felt like what he before. he socialized very little with any of the new flatmates. boy spent most of his time in the living room where he installed his computer. a lot of the flatmates spent their time in their private room. boy had very little contact with them. he could not really connect with anyone. it turned out that there were more benefits for boy in their previous arrangement than boy initially suspected. in the old apartment the door between the two bedrooms was always open. anybody could enter the other room any time and they even had to do so occasionally just to move around in the house. everyone trusted each other so well that this was not a problem. if someone needed more privacy, they went into the bathroom. boy and girl had a curtain around their bed. though boy did not really care, girl felt comfortable like that, especially during sexy times. the other magical part was that each bedroom had two inhabitants who talked a lot with each other. boy and girl heard what flatmate and sister are talking and vice versa. as boy listened in on these conversations, he learned a lot about each person's personalities without actually having to participate. he could even tune out any time without repercussions in case he did not feel like listening to others. through this boy felt more connected to his flatmates and as such he felt it easier to have small talk with them later on. with the constant back and forth walking through the apartment he was even forced to have the occasional small chat. this tremendously improved boy's social skills. all this was unavailable in his new environment. he could not connect with the new flatmates. nevertheless boy still wanted to keep trying new flatmates.
boy was not happy. to escape his sadness he doubled down on his porn. his porn continued to be softcore. all he cared is looking casual nudity and imagining himself in situations where he can share his casual nudity with others and be accepted like he is. whenever nobody was at home, he was looking at porn and masturbating. he masturbated a lot. like most addictive behaviors, it did not help. he became sadder and just masturbated more. he did not think much of this at first. as the addiction spiraled and as he was spending all his time on masturbation he started to get more introspective. maybe all this sadness of his is due to porn. he never really liked the fact that he is masturbating. he tried to wean himself off of it in the past but he never succeeded. he decided to quit it for real this time. it was hard. he had many false starts. eventually he succeeded. he managed to wean off porn and stay free of it for almost a year. he did not even masturbate, all he had is the sex with girl. boy's mood recovered. during that time he was not depressed anymore but he still felt a void in his life. he still felt that he needs more to be fully happy. eventually he did not see much benefit of being fully off porn, so he started looking at it occasionally again. however he learned to have self control. he consumed it rarely and he appreciated it like an expensive fine wine.
time passed. a new flatmate was coming. it was girl's childhood bestie. she was coming for a few months to study language. boy was looking forward to this new roommate because he already knew her. girl forced boy to meet her a long time ago. boy knew that bestie is quite a friendly and easygoing person. maybe he can connect a little bit better with her. bestie started living them. girl and bestie talked a lot with each other. passively listening to these conservations helped boy get to know bestie. she spent a lot of time in the living room, or when she went to her bedroom to study, she left her door open. boy had a lot of chances to practice small talk which he did. he got comfortable around bestie.
it was summer. summers in the new country were quite cold, people were not really sweating. boy's living room had large windows instead of walls. when sun shined, it could get quite hot nevertheless. to compensate boy tried to wear as little clothes as allowed. when alone or only in girl's presence he was often completely nude. he liked being nude because he did not want to hide himself. on the contrary, he wanted to show off himself so that the world accepts him as he is even if it meant sometimes feeling a bit cold. boy was comfortable around bestie so he told her he likes to be nude. he then asked if he can be nude around. bestie said she does not mind nudity but maybe he should not. girl said the same thing. this time had the courage to understand this as a yes. he thought they might be uncomfortable with this but they will survive if he does this. this was big step for boy. this meant bestie would be the second trusted person on earth to whom he could show himself fully naked. he always wanted to do this even with others but this was the first time he gained enough courage over time to actually act on his desires. before this time he was also concerned about his circumcision. by this time he learned that it was not a big deal. in fact, it made him wanted to show his penis even more. accepting his imperfect body would have meant even greater respect than accepting a perfect one. boy started out hanging out nude in front of his computer. one day he acquired the courage to walk to the kitchen nude for a glass of water in front of bestie. bestie was very casual about it. she did not even flinch, mind or even give him much attention. boy started walking around naked even more. bestie continued to act casually. girl was a little bit uncomfortable with this but she let boy live his fantasy out. this was exciting for boy. there he was, naked, and people accepting him. sometimes it was a little bit too exciting him. in those cases he had to go back to his computer corner and wait a bit to cool down. he wanted to show off his erection too so people accept his even more private and shameful aroused state too. that would mean even deeper acceptance. however he was not comfortable with that yet. although it was exciting for boy to be naked in bestie's presence, bestie never acknowledged him the way boy wanted. she never visibly looked at his penis, she never made any comments or questions about his penis. boy wanted to know if bestie noticed his circumcision and if she accepts him even like that. boy did not push the conversation further since bestie had a fiancé at home. he did not want to create any drama due to misunderstandings. one afternoon bestie had a terrible headache. boy offered a back massage. bestie gladly accepted, she loved massages. she lied down on the sofa, took off her shirt and bra in a private manner so boy had an access to bestie's fully exposed back. boy knew that if he is nude he would not be able to go through this without an erection so he put his underwear back on before working on bestie. all this happened in girl's presence so boy did not feel dirty doing this. boy massaged until girl finished cooking their dinner, about 15 minutes. afterwards bestie said she quite liked the massage, boy had good hands. as time went on, boy was getting more and more comfortable around her. however bestie's planned return slowly approached. boy continued to hang out nude to get his fantasy fix until bestie leaves. the time came. bestie packed up, said her goodbye and left without ever acknowledging boy's penis. boy and girl was alone again.
boy was a bit happier than before. he had the chance to physically open up to another person. however this time he missed the emotional openness. boy remained unsatisfied. one experience remained in his mind. bestie complimented him on the massage. he was wondering that if he could massage people he might have more chance to fulfill his fantasies. he wanted to see flatmate's and bestie's naked bodies. he never had the chance. he did not only want a glance, he wanted to study them, really immerse himself in their bodies not sexually but with curiosity. he thought that through massage he could study other bodies and maybe connect with others. he talked through this with girl who liked the idea of boy learning massage and even found a nice class for him to learn relaxation massage. boy signed up and started attending the sessions. it was different from what boy expected. about a dozen of people attended the class and most were women. there was only one other man. first half of each session was a classroom study of anatomy. the instructor talked through a slideshow while the students made notes. she was teaching muscles, bones, skin structure, various diseases, indications and contraindications of massage. the second half was more exciting since it was about practicing the massage on each other. this is what boy was excited about. the excitement flattened when he learned how the instructor massaged. she always told the clients to keep the pants and bras on, she only did back and legs, she avoided massaging the chest and stomach area because that's more sexual to her than relaxing, and she draped aggressively. the students had to follow her teaching. when some girls went to the changing room to dress off and took their bras off so that people do not need to fuss around with their bras, the instructor asked them to put them back on. this way the sessions were quite boring for boy. there was not the slightest chance that he will see anything exciting. he liked the touch, he just did not find the intimacy he was looking for. the massage course consisted of 8 sessions, one session every other saturday. one of the requirements for the massage certificate was to do case studies. he needed to find clients, massage them and then write a report about the session. since he did not know anybody, he asked girl to arrange clients from her social circle. she did so. boy did not want to stray off the protocol, he did the massage the way he was taught. clients kept the underwear on and boy draped them well. he did not mind doing the massages but he did not get his fix from it. he did not know most of his clients either. boy was not good at small talk so he let girl talk with them before and after the massage, boy just did the massaging. boy never asked anything in exchange. he did them for free with the story that he needs them for his case studies. clients reported that they liked the massage. he even had a handful of repeat clients. it was hard for boy to justify why clients should come again. he had his case study about them the first time they came. if they were to come again, there was no easy way for clients to feel that they paid for the service. boy did not want to ask for money because seeing and touching bodies was all the payment he needed.
there was one lady who really liked the massage. she came back many times. boy did not want money so she usually brought cookies. one day boy suggested that he wants to do stomach side as well. lady did not object so boy started massaging that part too. boy also came up with the idea that a massage should cover the buttock area too since there are many muscle endings there. lady did not object to that either. whenever boy was massaging the back, he also pushed down the pants a bit so that he better access that part of her body. one day her adult daughter came for a massage too since she was curious to see what this massage was like given her mother went to boy so often. both lady and daughter had attended some massage courses in their past but neither of them was actively massaging. after the massage daughter gave some tips to boy how to improve his game. she showed him improved draping techniques and she suggested that boy could massage the whole chest area too, even for ladies since that is how she learned. boy really liked this tip. boy hoped that daughter will return so that he can practice on him. she never did but lady did. boy told what daughter said and lady did not object. he told lady she might as well be naked, boy will drape her well. lady was naked under the sheets. boy was happy. an exposed lady was under her hands, covered by the sheets, trusting boy that he will not abuse his position. boy did everything the way he learnt. he followed the draping technique meticulously, lady was never exposed. when boy got to chest area, he uncovered lady, fully exposing her bare chest. boy was even happier. there was lady in front of him with even more trust in him. boy massaged the chest but avoided the breast area because he was not sure he can touch that area or not. when the massage was over, the magic ended. he covered her up and left the room. lady reported that she enjoyed the massage. she came back many times afterwards. boy enjoyed working on her. boy wanted a bit more so he tried pushing his luck. he asked if he could use looser draping in her crotch area in the private hopes that he can catch a glimpse of her private area. to boy's dismay lady said she preferred the ordinary draping. boy continued doing the same massage the same way and lady continued coming back for a while. then the frequency of visits started dropping, eventually she stopped coming. in the early sessions when lady was still a bit uncomfortable about what is expected in return, boy suggested that she does the massage she learned on him. lady said it was long time passed since she done it last time but she agreed. when the time came, she said that this massage is done naked. boy was happy to hear that. he was expecting that he can fully expose himself to someone. she draped well so boy did not had the chance to show his penis off. boy liked the massage nevertheless. she did a quite involved massage, requiring a lot of strength, boy understood why she stopped doing it. boy was doing his massage on the floor but lady's massage required a massage table which was a bit involved to transport over. a while later boy asked for this massage again but lady refused, she really did not want to do these massages so she kept just bringing cookies.
time passed. boy kept thinking about satisfying his curiosity. one thing that he remembered sometimes is his experience with friend. he liked the trust he had there. boy realized since he is not really looking for sex, he does not necessarily need women to have deep connections with. he expanded what he is looking for. he found a male nude yoga group. it sounded weird but it might worth a shot, he thought. he signed up for a class and went there. there were dozen of other guys. everybody disrobed, so did boy. he liked the feeling of being nude in front of others. he took a quick glances at other people but he did not feel comfortable staring so he did not. the yoga itself was in a darkened room, the exercises were quite rapid, so he did not spend a lot of time staring at others, nor did others visibly stare him. after the exercises there was a communal shower. there were two shower rooms. one fit three people, the other only two. boy was one of the last people showering in the two people room. the thought of boy was showering fully exposed in the presence of another person was somewhat exciting for boy. he got anxious that he might get an erection and how embarrassing that would be. to be safe, he quickly finished his shower, left the shower room, dressed up and went home. he did like the experience but it was not as satisfying as he expected. he did not connect with other people. for that he needs to repeatedly expose himself to the experience. however the group is quite far away from his place, quite late, and requires payment, all giving an obstacle for boy. he never went again. not because he did not want to but rather it required way more effort and planning than he was comfortable with.
time passed again. there was not much excitement in boy's life. over time he thought of many ideas but he never really acted on any of them. he always had some excuses. he thought of going to a nudist beach. his problem with this was the same as with the naked yoga. he did not really like the idea of going to beach on its own. he could not even recall when was he last time on any beach. passively staring at nude people would not give boy his fix. it might make him even more annoyed having everyone exposed, yet not being able to connect with people due to his social anxieties and general lack of ability to talk with people. he would need to repeatedly go before he finds the right set of people he can connect and hang out with naked. repeatedly going to a nude beach was infeasible for him because he lived in a cold and very religious country that did not have public nudist groups. he did not want to go alone either. girl did not really like the idea of going to nudist beaches. she was not opposed to clothing optional resorts but she preferred not to if she had a chance. boy never pushed this idea further. boy also thought of using escort services. even with girl's approval, he could not do it. he does not like going to a stranger's place, paying large sums of money for connection. he would not feel it genuine. the temporary connection he would get would be over after the session. boy wants a lasting connection. a friend with who he could talk for hours, maybe through email. he then thought of finding email penpals. he found a few people on online forums with whom he started talking. he started threads with more people but only a few of them had a style and content resonating with boy. he slowly opened up with those and started sharing very personal thoughts. as the length of the letters grew, the email threads he had slowly died off. he did not want to push others to keep the discussion since he did not even know who the others were. although he did not talk about it, boy wanted to know the people in real life even if he only talked to them through emails. he wanted to be sure that in case he fully opened to the other person emotionally, he had the chance to open up physically. for boy talking with distant strangers on the internet meant that there was a very little chance for the latter. he thought of using dating sites instead. he did sign up for a free site in the past but the fact that he had to start discussions was quite daunting for him. he never felt comfortable initiating. he always closed his accounts after long periods of inactivity.
time passed again. boy and girl started approaching their thirties. girl wanted children. boy was not that keen on the idea since that meant giving up a lot of his freedom. he feared the amount of time and effort the child will need. he feared the chance of having a high attention child. girl insisted. nevertheless boy wanted to keep girl happy. boy agreed to the idea of children and a year later they had their son. boy wanted to avoid being a bad father. he wanted to ensure when he is at home, he never ignored son. son turned out requiring a lot of attention. boy had to hold and carry son a lot to calm son down, to stop him from crying. boy was happy to do that. he started spending less time on his computer. he did not mind that, since he was mindlessly consuming the internet most of the time anyways. when the initial shock of the new baby subsided, boy's desire for more connection and sexuality in his life was back on his mind.
[to be continued, maybe.]
edit 2024-06-26: the ending is in @/tame.
published on 2018-06-10, last modified on 2024-07-08
# blogging: people should blog
i guess almost all bloggers write a meta post about blogging where they either explain why they blog or why others should be blogging. well, better not to stick out of the crowd.
sometimes a thought or idea gets into my mind and unless i talk or write about it, it keeps pestering me. writing about my thoughts really helps me organize them a little bit. it calms my mind. having them outside my brain means that i do not need to worry about losing a thought so i can calmly forget about it. it is important to have an audience though. without it i would not be motivated to keep the sentences even remotely coherent. it forces me to think really hard on how to express some of these pesky thoughts in somewhat sane way. but often i do not really have an audience. or even if i did have one the thought is so long that it would be rude to send someone an unsolicited wall of text. so i thought i write to an imaginary audience, in a somewhat secret place on the internet that nobody reads. the possibility that someone will read this forces me to write in a somewhat clear way.
most of the stuff i write is just crappy ideas or silly thoughts. better out than in as the saying goes, no need to take my writing seriously. i do not think that on my deathbed i will be agonizing over the fact that i was stupid on the internet. more likely scenario is that i did not dump everything from my brain, i still feel like there is some unfinished business i have to do. dumping everything here helps me achieve my little nirvana sooner. now all i need to do is to gather the courage and start writing. i have more than enough silliness to write about, i just get overly anxious what my non-existent audience will think of me. not forcing myself to reserve time for this is not helping either.
so that is about me. why should others blog? i do not follow many blogs but i would be super interested in reading blogs of some of the people around me i personally know. i am very reluctant to initiate towards people but i could learn more about the person through their words. i could learn how they think, what do they think about the world, what do they do in general and so on. i will see a personality behind the face. i am not interested in reshares or likes though. that is very low quality signal about the person. i really wish for short article format, not twitter sized thought bites. if people want to point to an article, i would much prefer if they would rewrite articles in their own words rather than linking to an existing article saying "hey follower, read this". there are a lot of rotten links on the internet so such posts consisting only of a link would be worthless after a while. the blogger's personality will flow into the rewrite so even if something is not an original idea, i will still see the issue from the blogger's point of view. it also demonstrates that the blogger actually read the article not just blindly resharing something they have seen on the internet.
i also prefer if bloggers did not have any tracking, commenting or other popularity counting widgets on their blog. this is why it is better to run one's own blog rather than relying on shared services like facebook and whatnot where one cannot even turn off these features. the problem is that if the blog starts to get popular the blogger will start to care about popularity. they will be more likely to write posts that get the most attention rather than what they actually think. they will either moderate themselves, become less radical, more mainstream, more boring or they will swing into the opposite direction where they will get super radical and all their posts will be about outrage. if one does not have any analytics at all, they are less likely to fall into this trap.
a comment about publicly visible comments: it is very easy to get demotivated or get argumentative when posting very controversial or unpopular thoughts and then reading the comments. i think it is easier to open up if one does not need to spend rest of their energy on arguing with others after posting something personal. if a post generates significant response then i would rather see a followup post summarizing the private response than wade through all the comments. this really helps to keep the content of the blog linear. it should be possible to read a blog just like a book. i think it is best to keep discussions on sites that are specialized for this and as such have moderation and other means of maintaining civility.
published on 2019-01-23
# space: weird fantasies about owning a big empty space in a city
i like to daydream about stuff i would do in particular situations. that does not mean that actually want to do said stuff though. i just want to play with the thought. today's topic is what would i do if i owned a big, enclosed, private, empty space in the middle of a city? something like a 20 person conference room. an apartment with a huge living room but no kitchen or bedrooms. this would be at a different place from what i call home. i could rent it, sure. but that is boring. what would i do if i had to make use of it myself? what events would i organize in it?
there are many crazy ideas to choose from! the first idea that pops into my mind is to create a place for videogame lan parties. i do not like the modern, isolating online gameplay but lan parties can be pretty fun because you know the people you frag, you can see their face when you frag them. i could even install a projector and play crew or bridge simulators like artemis. but maybe i would restrict the games we can play to the ones that run on a raspberry pi. all the gaming machines would be only raspberry pi machines. i guess not many people would be interested in playing but the ones that would be interested are probably somewhat similarly crazy as me so i would find it more fun this way.
it would be also fun to build something together with a small team (also only working on raspberry pies just for the sake of it). we could gather every now and then and build random game or website in a hackathlon style. the projects could be about reimplementing modern tools and games to be super efficient so that they are so fast that you could use them on a raspberry pies.
hmm, let me go full crazy mode while at this. as i hinted in a previous post i have some issues around sexual expression, intimacy and so on. although i keep searching for it, i cannot find events in this area that would spike my interest. maybe i could start organizing events in this space. i have bunch of ideas. i do not necessarily like them all the same but i would totally try some of them.
my first idea would be to create a nude gym. is it not the case that the ancient greeks used to train and compete completely nude? there is some sort of magic to this. in my fantasy these events have a relatively stable set of people rather than different set of strangers showing up in every session. i think nudity boosts the intimacy between people which deepens friendships and respect between ourselves. being in a friendly and respectful environment can be very motivating in achieving our goals. also i just like to look at naked bodies, especially if they are well and fit. if the cost of this is that i have to train next to them then i think that is a cost i can gladly pay. by myself i have zero motivation to do any physical exercises.
my next crazy idea is a "grooming exchange". i like to be clean and shaved most of the time. but shaving is such a boring activity. what if i had to shave other people and other people would shave me? i do not have problems with seeing or touching bare bodies. i think doing such things together would be quite fun. people can chat and bond while shaving or whatever special grooming the other person requires. and i would even feel some sense of accomplishment that i managed to make someone else's life a little bit easier.
i feel that there is a lot of shame in people around their bodies. they feel that it is something to be ashamed of, something to hide. i think that is nonsense and in fact i swing way too much into the other direction: the bodies should be actively shared and exhibited. so my next idea is about trying to reduce the shame around nudity and help with the body acceptance. this would be a group activity. each participant goes in front of the group and completely disrobes. then each audience member describes the person's body in a very neutral and objective manner. the point of the exercise is to disassociate ourselves with our body features and body flaws. it does not matter how our body looks like. having others objectify our body helps us treat our body as a tool to for achieving our goals rather than an end in itself. hmm. i am not entirely sure about this one. it might be a useless exercise. but i think it would be still interesting to give this idea a try.
or how about a masturbation club? it is pretty clear to me that there is a lot of private masturbation going on in a lot of folks lives. but why does this have to be such a private thing? what is it about it that makes it so disgusting that we do not do it together? i think once we accept our bodies, our feelings and the fact that we are not all that different from each other, this activity can become an okay thing to do together. sure, the first few sessions would be totally weird but once the initial shock wears off, it becomes a normal thing. there are several ways to do this, i think it really depends on the folks involved how they want to do it. the participants just can sit in a circle and have a go at it. maybe they want to watch some videos on a phone or laptop during session, that is okay. maybe they just want to watch others, that is okay too. the other benefit of doing this regularly is that this can defuse the obsessiveness of this act. one of the reasons for all the uncontrolled masturbation is that sexual gratification is pretty much random: you might or might not get some gratification based on other people's mood and your luck. masturbation is just a coping mechanism against this randomness. i think if i can get gratification regularly, the need for the constant gratification disappears. if i can get myself to masturbate only with others, i cannot go overboard with it since i would be limited to doing it only during the encounters.
there is this thing called orgasmic meditation. i do not actually know much about it so let me reinvent it from scratch. this activity is done in pairs. one person lies down on the floor and the other person is stroking or otherwise stimulating the first person's genitals in a very simplistic manner for a long time without any changes in the stimulation pattern. i quite like this picture. the stimulator's job is very simple: just keep doing what they are doing. there is no performance expectation. the person on the floor can relax, daydream. orgasm is not the point here. i can compare this against a massage. for instance an ordinary back massage can get boring after a while, especially if it is the same movement over and over again. massage requires constant adjustments, changes in stimulation and so on so it is hard to get fully relax into it. and even if one relaxes into it, they might fall asleep which somewhat suggests that it was boring. but i can imagine it is somewhat different with genitals: in general i think genital stimulation takes much much longer time to get to the boring stage. more importantly genital stimulation sort of turns on one's mind (it fills it with sexual thoughts) so they will not simply phase out but can actually consciously enjoy the quiet time. i think doing this in a group is beneficial because then because the people can swap partners all the time so the novelty factor keeps people interested in the activity.
now let me fantasize about more sexually explicit activities. i do not have much sexual experience outside my primary relationship but i am not particularly seeking such activity either. that is mostly because of a combination of me being lazy and shy. however i do yearn for some extra experience. so i am thinking of a "guided sexual encounter". this would be ideal for super shy, non-communicative and submissive people like myself. in this activity you bring or are matched with a sexual partner. each person writes some preferences, no-nos and other notes onto a slice of paper and gives it to the guide. the guide reads the preferences, thinks of a scenario and starts suggesting actions to do for the participants. all the participants have to do is just simply follow the instructions. instructions could be something along the lines of touch here, massage that part, stroke faster and so on. there is no performance anxiety since the participants can project that onto the guide. this activity does not really require a group unless the activity guided is a group sex itself. but still, i suspect doing stuff together, even if it is silly stuff, can be a great fun.
in fact i could go further with this "guided sexual encounter" thing. how about something like a drama or acting club? there would be a script where all members have a role to play and they have to act out the story. i am envisioning acting out favourite sex or porn scenes (mild ones that contain more interaction rather than sex). the nice thing is that this allows anxious people acquire sexual experiences in a very controlled manner. since there is a script, everyone knows what will happen, there will not be surprises. one can mentally prepare well ahead for the event. i am not fully sure how fun this would be or if there are even scripts that make sense but i think there is some potential in this and would be fun to explore it a bit.
and the most explicit fantasy is just having a sex club. i am not thinking of a free for all group sex here but something more akin to the masturbation club. couples or groups would come and just have their sex next to the other couples or groups. or people can join just to watch and masturbate. at this stage this might be a little bit intimidating even for me. but it does not sound a boring activity.
so those would be the activities i would be thinking of organizing. couple of notes. first, i would totally ban any food and drink consumption in this place. food and drinks create a lot of waste, it is just simply less maintenance this way. and besides, food and drinks is often just a passive, pure consumption activity and i would rather avoid having such activities take place there. i would especially prohibit alcohol and other drugs in this place. primarily because i do not like alcohol, secondly i think it is healthier if we can blast through our insecurities without the help of drugs. drugs can alter people's personality, make them less controllable which is something i do not want to deal with at my place either.
there is also a problem of where would i find people interested in such activities. from all i can see is that most people find sex, nudity and intimacy with strangers disgusting to even talk about. my craziest idea about this is to create a special social network for this if one does not already exist. anyone can join the network but in order to establish a connection with another person ("become friends") both people need to: a) have seen the other person's genitals in person, and b) know what the other person's sexual fantasies are. the goal for the individuals in the network would be to gather as many friends as possible. i ask only for genitals rather than full nudity because the latter can be hard to arrange while the former can be done in a form of a flash almost anywhere. so people meaning to become friends can have a date, talk about sex, flash to each other and then become friends on the network. what i want to encourage in this network to make sexuality a normal thing to talk about. when sex is a normal topic, people would be more comfortable telling what they like, where their boundaries are, ask for advice and so on. i do not like the fact that this topic feels very taboo in our society. i think being part of such a community would then make it easier for me to find like minded people. by "like minded people" i mean people who do not take life way too seriously, who are non-monogamous, non-judging, open sexually and so on.
but obviously i am way too lazy to set up something like that. actually i would much prefer if such clubs existed somewhere else where i could just go. although i suspect i would be way too anxious to go to such place anyways. maybe when i am old and retired, i might set up a club like this for the new generation. all this remains a daydream for now.
published on 2019-01-24
# timestamping: i don't timestamp my posts
i am somewhat on the fence with regards adding timestamps to my posts. i want my posts to contain only the content and nothing else. i want my posts to stand on their own with no regards to posting time. when i wrote a post is usually irrelevant anyways. on the other hand it is nice to see a rough indication of the age of the post. hah, this reminds me of some weirdness i used to see on some blogger.com sites. the posts and comments would have a timestamp in the month, day, hour:minute:second format. awesome. a timestamp accurate to the second. the only part missing? the year. because obviously that was not as important as the seconds. i actually seen this in a lot of such blogs. super weird. fortunately i have not encountered this recently so i am assuming this got fixed or i managed to avoid blogger.com blogs.
anyways, this leads me to the idea that perhaps just stamping the posts with the year they were written would be useful. i write only a couple posts per year so i think the year granularity is more than enough. but still, i do not want to put this metadata spam into my post contents. i have decided to just put it onto the frontpage. so instead of:
i would have this:
2019 entries:
2018 entries:
looks a bit ugly but it does the job so i will go with it for now.
# edit from 2021 after @/redesign
i realized that i do need to track when i wrote a post so that i can sort the posts on the frontpage. otherwise i need to maintain the order myself and that's more work than adding a timestamp.
i decided i might as well show this info in the posts so now each post has a footer with the timestamp. but i still keep the frontpage clear of this spam for now.
published on 2019-01-25, last modified on 2021-09-06
# binding: keeping books open is hard
i really like reading books. i do not do it often though. it mostly happens in batches where i read many books over a few days when i have a few days of calmness available around me. these days i usually read on kindle. it is very convenient, light and there is the benefit that i do not need to physically store the books. i do not like the idea of having a bookcase of the all the books i ever read: it takes space, maintenance (ugh, i hate cleaning) and i do not really want others see what i read. having said all that i do occassionally run across a physical book. usually someone loans one to me, or i just pick one up randomly when i am at a place which has books and i have time. my problem is that the book usability is quite bad due to the way the pages are bound together!
for instance i cannot just open the typical book in the middle and put it onto the desk and read it from there. it would just close itself like a spring. i have to keep holding the pages to keep the book from closing. if i want to hold the book in air, i often need two hands. for one hand holding, i have to roll over one side of the book. reading the rolled side is quite annoying if even possible. it is also very easy to break the binding. once i do that, the book becomes more brittle, the individual papers might fall out much easier. also i have to hold the book slightly differently depending i am reading the beginning, the middle or the end of it.
what annoys me the most is that all those problems go away with coil or spiral binding. one downside i can think of is that maybe books do not stack well if bound that way. that is however not a problem for me because i do not care about how nice a books look when stacked but about its content and ease of consuming that content. all my notebooks are coil bound and they are convenient to use. why is it then that most modern books are still bound with that annoying method? i tried searching the web for an explanation and i could not find any. my only guess is that people are so used to this horribleness that they do not even realize things could be better. this is so annoying that if i wanted a printed version of a book, i would try to get the ebook version, print that and coil bind it myself. why is this so hard to do in the printing press in the first place?
the other downside i can think of is that this way it might be harder to search for a specific book in a bookcase since the book might not have a side with a title on it. i am not convinced that this is a problem though. i am pretty sure you could slide a long piece of cardboard or a plastic marker into the coil that contains the title when you look at it from side. think of this like sliding a pen into the coil and clipping it to it. when reading the book you pull this marker out. whenever you finished a reading session you slide the marker back and put the book back onto the bookcase. you can easily clip other random stuff to the coil.
and more importantly there is no need to "close" the book. no need for bookmarks or remembering page numbers. next time you pick up the book, you can start reading where you left off. in fact all this is pretty awesome! i should totally start my own book printing business.
# edit from 2021: i've posted this to r/changemyview.
since after 2 years i was still holding this view, i decided to ask reddit about it at https://old.reddit.com/r/changemyview/comments/o0z5jj/cmv_books_should_be_wirebound/.
here are the common counterarguments:
it was a nice discussion. i learned some nuance from it but didn't really make me like ordinarily bound books better. if anything, it made me like my kindle more.
published on 2019-01-26, last modified on 2021-07-12
# typeshooter: a silly typing fps game idea
there is this old rail shooter called "the house of the dead". it is about shooting zombies, the game takes care of moving. there is a mod to it called "the typing of the dead" where the player has a keyboard instead of a gun and has to eliminate the zombies via writing the words or sentences above the zombies' head. it sounds quite silly but it is a super fun game. just look up a gameplay video about it to get the idea.
unfortunately there are not many typing games like that. i wonder what would i create if i had infinite time, willpower, patience, and resources. first i would totally create a real life version of the game. the player would need to stand on a roomba-like moving platform. whenever the player clears an area, the roomba would start moving to the next area. this way the game stays a rail shooter. the zombies would also have their own roombas that would be moving towards the player's roomba and the player has to eliminate the zombies standing on them before they reach the player's roomba. instead of a gun, the player would have a keyboard on themselves just like in the games and each zombie would contain a magical killphrase that kills them when the player types it. the player's roomba would be big enough to hold two people so even the coop part could be recreated. this should totally exist! for extra difficulty and realism myopic people could take off their glasses and see if they can beat the game that way!
i also wonder if one could create a competitive videogame out of this. take an ordinary fps like quake3, would it be possible to create a typing game out of it? in typing of the dead there is no need for movement, it is only about typing. a game like quake3 would not be a quake game without movement and guns. i would retain those elements. in my game idea you can freely move around. on top of the "keyboard" you even have two guns that you can attack with. you cannot kill with the guns. to kill you need to equip the keyboard and type the enemy's killphrase where the enemy is just another player. both guns have limited ammo but they slowly recharge over time so there is no need to pick up ammo and such. the first gun is a shotgun and you can use this to push enemies away so that they do not get close and or to unequip the keyboard of the enemy. on a shotgun pellet hit the game would force a switch away from the keyboard so that the enemy needs to start typing from the beginning again. use this gun to create distance or to keep the enemy from typing. the other gun is a projectile weapon. when you hit the enemy with the projectile, the game reveals their killphrase to you. now your goal is to equip the keyboard and type it. there are several strategies: you try to escape and gain large enough gap from them so that they cannot attack you while you type their killphrase. strategy b is to give up your passphrase them (allow them to shoot you) and let them start typing your killphrase. once they start, you start typing too and you just beat them at typing. strategy c is to get very close to them and shotgun blast them. i would make the shotgun super effective at very close range. this would push them very far away, allowing you to gain enough time to type their killphrase but also very risky since they could easily hit you with the projectile from such a short range. maybe other strategies would emerge through gameplay. note that every enemy sees a different killphrase for you so they cannot just shout it out in real life and have someone else kill you. also if you kill your enemy, they will get a different killphrase for you upon respawn.
is this fun? i am not sure but i would definitely try a round. and it is probably would not even hard to implement it as a quake3 mod. keep the shotgun and rocket launchers and reuse them as describe above. as for the "keyboard gun" i could use the built in chat mechanism. the engine would watch the messages and if a valid killphrase appears, it kills the associated player if the killer had the keyboard gun equipped. the fact that quake3 does not let you change weapon while chatting is a feature in this case. upon a shotgun hit i can make the mod switch back your weapon to the primary gun so you will need to quit typing, change to the keyboard and start typing again. once you learn a killphrase, i would always show it on your screen so you can mentally prepare to type them on any given moment.
even this could be reimplemented in real life: put a big barcode on every player's head, arms, legs, back, torso. give each player a barcode reader. i propose barcodes since they can scan pretty fast, work well with noise, and all you need to do is to scan a line from the other people's body. if you manage to get close to the enemy and scan their barcode, then you grab your keyboard and type the killphrase while hoping that you are faster than the other person. having different barcodes for different body parts could be used to grant different scores even. if you kill someone then that person cannot attack until they go back to a spawnzone, scan the barcode there and enter the killphrase to respawn. or if it is a round based game then they just leave the arena completely until the next round. to make it apparent what is the killphrase and who is alive and who is dead, players would mount a smartphone onto their arms which would display killphrases and the avatars of the enemy players and mark dead players with a cross. this way you can easily ignore dead players, they cannot pretend to be alive and ruin the game. i assume that modern barcode readers are wireless and can tell the smartphone the scan results so the phone can immediately display the passphrase upon scanning.
it is not only deathmatch that could be played with this. capture the flag would work too. get to the enemy base, scan the barcode at their base and then head back and scan the local base's barcode to get a score. obviously this needs to be done without a death and only one player can carry the flag at any given moment.
keep in mind that these ideas are quite raw and need a lot of polishing. but i think they do have a potential. it just needs a lot of playtesting to find the fun. well, at least i cannot say i have nothing to do when i ever get to my retirement.
published on 2019-01-27
# cb: an idea for a weird twist on facebook
so the other day i was thinking about all these nudity and exhibitionism fantasies again. i am not sure what to do with this. i have been nude with other people but there is always something lacking which i cannot really put my finger on. i have not actually tried this but even if i were to upload pictures about myself naked, i think i would not feel any satisfaction either or it would be temporary. i think it is the same with other explicit fantasies as well. even if one could get some satisfaction, it is usually temporary and then they need to do something again. i think maybe if one could gamify this whole thing, it would keep people busy enough to trick them into satisfaction. so i have an idea. and obviously as a tech person my idea is to use more tech. and it only applies to this niche section of sexuality, the exhibitonism.
a sidenote first: i do not think the nudist lifestyle is an answer to this. for a nudist being nude is normal. with exhibitionism some of the kick stems from the fact that this is something forbidden or something that society disapproves of. there is not much sexual energy in pure nudism. also, one could get easily banned from most places for flaunting an erection.
so exhibitionism is about flaunting yourself in front of others potentially with some innocent sexual connotations. and i think one gets more kick out of it in real life than doing it online. however we shall not dismiss the power of putting oneself online too. there are two problems: where would one find a safe place for flaunting and what would be the point of flaunting?
my idea is to create a gamified social network site just for this! anyone can register there. the point of the game is to connect with the most people you can. there is a rule for establishing a connection with another member though: the two people must upload a picture of them flashing their genitals to each other. if they have the picture, they can become friends. in other words the goal of the game is to meet locally with as many people as possible and take genital pictures together! once they have a connection, they can chat with each other. as a bonus, all uploaded photos and the member graph would totally public for an extra kick. i'm thinking of naming this as "crotchbook". it would be a pun on facebook since instead of face you use your crotch as your profile picture.
totally crazy idea, right? who would ever play this game? probably not many people. i would totally think about trying it though in order to help myself to get rid of any shame that society imposes on us about our bodies and sexuality. to help me learn to ignore what other people think about me (writing stuff like this into this blog really helps with that though). to accept my body as it is and not to be ashamed about it (i already managed to do this though). i just assume there might be other people like this and as such i want a little corner on the internet for us.
i have seen some dating sites, hookup sites, nudist connection sites but usually they are very open ended and require a lot of effort to communicate what exactly you want and then find the right people. crotchbook would be laser focused on: 1. arrange a quick meeting, 2. pull down trousers and underwear, 3. snap a pic, 4. upload, 5. optionally put clothes back on. when the other person approves the pic, the pic and the connection goes public. 2 and 3 can be done in a secluded corner of a public place. there is not much place to second guess intentions or for worrying about what will happen because there is a script and it is very simple. one does the deed and it is over. it has a beginning and an end. one can feel some after satisfaction establishing a connection. the connection appearing publicly is the stimulating feedback one might yearn for.
it motivates reclusive people like myself to get out of the house because there is very little string attached to acquiring a connection. it also helps me build connections since in order to do this i need to meet with other, new people. as i explained above, one can only talk to people they already have a connection to. i would need to reach out to my existing connections in order to arrange meetups with new people. even this can be motivating in itself: if i arrange a meeting for someone else i feel like i am useful, that i am providing some value to someone else. i would probably add a helpful metadata for this though: i would allow tagging the pictures with "weak tie" vs "strong tie". one would have weak ties with people they do not know, they only met for the pic. strong ties mean that the other party is a friend, they talk and stuff. when browsing profiles, i could then see who could arrange a meeting with my target person: i would be looking for a 3rd party that has a strong tie with both me and the target rather than a weak tie.
a social network is worth nothing if there are no people on it. but i think it would be super easy to seed this site compared to other social networks. this site is not intended for building relationships or creating perfect profiles. it is solely about uploading semi-naked group pictures. crypto geeks have their "key signing parties", exhibitionists could have their "flashing parties". suppose there are several folks interested in the site, all living in the same city. i could find a small place for them where they could come to, snap a couple group photos and then upload the pics afterwards. now the network is seeded in that city and the members can start expanding the network via word of mouth.
and this would be even super cheap to run. i would only allow 1 pic per profile and 1 pic per connection. i would even aggressively downsize pics in order to fit like 200kb since hosting high definition pictures is not the goal of the site. furthermore i would delete all messages after 30 days so that i do not keep stuff forever. maybe i would even delete pics after 2 years so people do reconnect now and then. i would even delete profiles after 3 years of inactivity so that the site is not a ghost town. i think the data for all this would be peanuts, i could even run it on a free tier of a hosting provider. i should totally create such a site. or even better: someone should beat me to it so i do not have to deal with this all. this why i put all my ideas onto my blog but i do not think anybody would ever bother with my crazy ideas.
one more observation: i think i really like this idea because there is a script in it. i know what the game is about. i wonder if this could be generalized. have a website that contains all sorts of weird sexual scripts that could be acted out in a safe place. i am mostly talking about stuff that requires multiple people since otherwise it would be about dating and hookups for which there are a lot of sites. i talked about this in previous post but let me recap some ideas:
the website would contain various such activities in which the members can express interest. if there are physically close members with common interests, the site would match them. it would also offer a venue for the activity that the members could pay together in case they do not have one. something like meetup.com but for sex stuff.
maybe there is such a website but i did not find anything like that. i think there would be a dime a dozen of such websites if sexuality would not be such a big deal. things are getting better over time but i think there is still a lot of room for improvement.
edit: i was thinking a little bit about the usability of the website. one annoying thing is annotating the uploaded pictures. suppose a group of friends get together and they want to snap nudes of each other. now for each upload you need to tell the system which two users are on the pic.
to make this convenient, i'd use qr codes. each user would have a code associated that they can view on their smartphone or simply print it. whenever they are making photos, the code has to be visible next to their genitals.
now suppose you want to upload two people being on the same pic. in the pic upload page the site would split the image into two halves and run the qr code detection logic in the client on each halves. if it can find a registered user on both halves, it will allow an upload along with the metadata it collected. the pic doesn't necessary have to be of yourself, it can be of other users. that's handy when snapping pics of others, e.g. in a group. and when both parties approve the pic, the link is established between them.
this mechanism would allow the group of people in a meetup just keep snapping pics and all the annotation would happen automatically. such meetup could then be very efficient.
published on 2019-02-17, last modified on 2021-08-17
# thecook: a story about learning to ignore people
i love my mom's fried chicken with fries! i want to cook my own. i know! i will become a chef and prepare fried chicken with fries all day long!
alright, let me start immediately. the book says i need batter, oil, chicken, potatoes. potatoes must be fried for a while so let me start cutting that! ouch i cut my finger and there is blood everywhere. no matter, i apply a bandage a keep cutting. i now put the potatoes into the fryer and off it goes. i prepare the batter, cut the chicken fillets, coat them with batter, and start frying them too. oh, the fries are ready. let me take them out of the fryer, and pour them onto a plate. i salt them too. what is this smoke i smell? oh god, the chicken is on fire! i did not set the gas stove correctly and it started burning while i was preoccupied with the fries. quick let me put out the fire. i grab a 0.5 liter glass, fill it with water and pour it onto the frying pan.
my first attempt did not go well. at least i can do my next attempt in a new kitchen. before doing that i decide to learn about this cooking more. i read books, watch cooking shows and so on. one of the common advice i have seen is "separation of concerns". it says that i should not try to do too many things at the same time because i will be overloaded and i will not be able to follow what is going on. that sounds reasonable.
okay, so now i have some experience: both practical and theoretical. let me try this again. this time i do the chicken frying first. i prepare the batter, cut the chicken fillets, coat them with batter, and start frying them. as i am frying i watch the stove, adjust the settings. the chickens now seem the right color so i take them out the fryer. my fried chicken is ready! now i can do the fries. i start cleaning so that there is nothing else on my working table that could distract me. i cut the potatoes. no finger cutting this time. i fry them too. i wait, i take them out, and pour them onto a plate. yay, i am done, this will be awesome. i serve both my chicken and fries onto a plate and start eating. ugh. the chicken is cold.
not too bad but i see there is more to learn in the world. so i study more. i even attend a culinary course. they show me fancy tools and methods to follow. i learn to be more efficient. there is not much benefit of cutting my own fries. i can buy it frozen and it will be roughly the same. i can buy pre-battered fries. and if i am very careful i can fry both of them at the same. i still need to separate the concerns so i make sure that i fry in the opposite corners of the kitchen so that i do not accidentally mix up the two. feels a bit weird but sounds totally reasonable. after the frying is done, i serve the meal and everything is fine! i can finally enjoy the fruits of my studies.
it is time for me to enter the big world. i start working at a big company among many other chefs. we all prepare fried chicken and chips all day long together. i learn lot from my colleagues. they even show me more advanced tools and methods. i can now prepare this meal even more efficiently. i can see other people also enjoying all the chicken and fries. life is wonderful.
time goes on. i feel a change in myself. something is not right. there is no excitement anymore. is it because i do not like chicken and fries? no, that is not it. i clearly like it still. then how come i do not want to do this all day long? where did all the feeling of fulfillment from cooking go?
i start looking. i look at the cooking shows. they are all the same, do not create any change in me and they seem boring. then one of the shows catches my eyes. it has a special guest cook. a well renowned one. it piqued my interest because this person seemed to be full of positive energy. it turns out people find his meals masterpieces. yet people hate his guts for a reason still unclear to me. i watch his cooking. then watch other people's reaction to his meal. i feel excited again simply by watching him. but why? what is he doing differently? i watch closely. after many hours analyzing the footage i distill two observations. first he is like a barbarian. does not use most modern tools he could use. he is not using the robopeeler, nor the robocutter for his potatoes, he does all that by hand. this is silly but oh well. after the judges start eating his meal, he continues to make adjustments and suggestions how to consume the meal! he asks questions, suggests using a little bit of salt here, a little bit of mustard there. he is quite eccentric. it went against everything i learned: using tools and that my job ends when i serve the food. it is odd but i want to be like him.
okay, but not use tools? this is silly but well, let me try it. this is painful. i am cutting my potato and i just cut my finger again. i am frying my chicken from my own batter without a timer and i overcooked it a bit again. and the taste is quite meh. and my kitchen is a mess again. i have to clean it. but this is odd. i feel calmness. i actually feel good now. i made the overcooked chicken myself. i made it with my own hands. i did not need help from the robots. it was me who put that chicken there. without me that overcooked chicken would have been some other generic fried chicken again. i had a deep connection with that chicken. this is fun!
the next day i do this again. this time i feel like i should go eccentric even more and use crisps instead of breadcrumbs in the batter. this time i did not cut my finger nor overcook my chicken. the chicken was really special, extra crunchy. it was awesome! how come this is not the normal way to cook this? i tell about this to some people and i get crazy looks. they never even bother to try it. am i just imagining that this is that good? i continue experimenting with various other tweaks. some work, some do not but i find a lot of joy in the process.
so far all i did is the do stuff by hand. i want to try the second observation i have noticed. the part where i actually serve my meal to others and see them consume it. but where could i do this? i know! at my company!
i go to my coworkers and ask if they would mind if, when nobody is around, i would use the kitchen to create a small dish for a few interested folks after work hours. they say nice idea, go ahead. i am happy. i decide to create something special that i cannot create at home because i lack a special ingredient available only at work: cheese. so instead of fried chicken, i want to create fried cheese. people still like the idea.
one of the company policies that whenever someone is in the kitchen, they must have a coworker there for safety reasons. the coworker buddy is ought to stop that someone from doing bad stuff and help out if accidents happen. there is a guy i know who is really interested in all this cooking, i talk with him a lot about cooking, i think he will be ideal as my buddy. i warn him i will be a bit unconventional and then grab a potato and start peeling by hand. he immediately stops me. i am doing this wrong. i should be using the robopeeler, have i gone mad? i explain that this is really important. we start arguing about this. we keep arguing until i actually manage to manually peel and cut the potatoes. i start frying them. he is quite disappointed in me by this time. then i start frying the chicken as well. he goes insane when he noticed that i did not start the timer. "frying without the timer is bad! it is very hard to know how long to cook without the timer. and besides, it is company policy to always use the timer!". then he grabs my frying pan, throws out my cheese out of it and gets his own battered cheese, starts frying it but also starts the timer. "see? this is how it is done.".
on one hand he is correct. that is how this thing should be done. on the other hand he managed to completely kill my mood and interest in this food. it should not matter to me if the timer is going on for my chicken yet it does. simply the timer being there annoys me. i do not get the "i made this without robohelp" feeling anymore. i am getting back to the "this is no fun, this is just plain work" state. what also annoys me that he also tells me how to do *my* stuff even though he is completely uninterested in the end product, only in the cooking process itself. i try to to explain that this is part of the magic i need in order to make this meal but he does not budge. i get angry, do a super quick cleanup and leave the kitchen because i do not see any point in continuing.
i keep thinking about the next step. i could leave the whole thing and just not try make an interesting meal for a few folks. however i cannot let one person get to me. i think i just need to change my buddy. there is this other guy. he is pretty busy all the time just because he actually gets work done in the company. he does not have time for petty arguments. but i will not get any feedback or suggestions from him either. i ask him to be my buddy and he comes. as expected, he does not give much attention to me, he is doing his own job. on the other hand i can finish my meal in the way i want. my guests come. i do not tell them how i made this food other than it was a labour of love. i do not want them to run away from me when they learn that i hand peeled and hand cut my potatoes as in all the previous cases. i sit down next to the people who will consume it. they like it. i feel happy about this. i recommend some salt here, some mayonnaise there. i feel the fulfillment again.
people started liking what i create but at the same time people started hating my guts. i am no longer pleasing all the people but in exchange i feel fulfillment in my life again. i accept this tradeoff. all i need is to have the courage to be disliked.
published on 2019-02-28
# pain: some pains can be embraced rather than drugged away
pain is a signaling system. it signals that something is not right. there are two types of pain: sudden spike and chronic pain. if you suddenly feel pain then most of the time something changed around you suddenly and you probably even know the reason. in this case pain is a useful signal but it can get into the way of resolving the underlying issue. e.g. if a bear is eating my leg then i might just give up everything because it is too painful. maybe i would fight or run more if the missing leg would not be bothering me. so in this case making the pain go away might be very useful.
the chronic pain is different. and by chronic i mean the one that last for very long time. i do not mean physiological pain only but mental too. inconvenience might be a better term for the latter. we cannot simply wish the chronic pain away. so what do we do? we medicate ourselves with painkillers. in the inconvenience's case we start using various tools and gadgets to make things more comfortable. this indeed makes the pain go away so it is a reasonable solution.
however you could look at this differently. pain is something that you are intrinsically motivated to alleviate. what if rather numbing the pain, you alter your lifestyle in a way that the pain is manageable? with this approach you do not feel at mercy of your doctors and drugs anymore. you feel that you are in charge of life. you start researching your pain. you start experimenting with things. basically you get a goal and start living. all your actions start to have a meaning. the "why am i doing this?" feeling is not around. it is not an easy life. every day you wake up, the pain greets you. it does not allow you to slack off. you remain passionate about alleviating your pain.
and the nice about this is that you can always inflict pain on yourself. depressed because you are invisible and there is no point in life? start walking barefoot on the streets. you will immediately notice trash or dog poo on the ground. you will start moaning how all this trash and dog poo is bad for us all. you might start picking up the trash in your immediate vicinity in order to make it habitable for yourself or at least arrange a daily cleaning service on your street. you start fighting for clean streets. you now matter because you want to achieve something. and that something is only about fixing your inconvenience: making sure you can walk around barefoot without getting too dirty.
others will think you are crazy. they will try to talk some "sense" into you. get shoes or else all sorts of bad thinks will happen to you. some people will even get angry at you. do not let them to get to you or otherwise discourage you. do not take naysayers seriously. ignore them. you cannot achieve something without making some people angry. let them have their boring life. yours is now full of excitement and possibilities. focus on that. after a while you will not even notice the pain anymore. your body adapted to it naturally. it learned that this pain might be okay after all and decided to not to bother you anymore. all you need to survive is the initial period of the pain. do not underestimate your body's and mind's adapting capability.
this does not mean that you should go all out and do all sorts of crazy stuff. it works only up to a point anyways (yerkes-dodson law). and this takes a very special personality. most people are not up to this. there are two lessons you can take away: 1. if you ever feel uncomfortable, maybe keep yourself in that state just a little longer just to see what happens, 2. if you see other people doing crazy things despite the apparent pain, do not feel superior to them. all the nice things we have today is thanks to crazy visionaries who went against the establishment, made a lot of people angry and sometimes even suffered a lot in exchange. try to understand their motivations instead. try to not obsess about what and how they are doing things but rather what they are achieving. after all, do not we all want clean streets?
published on 2019-03-01
# complexity: avoid abstractions and things stay manageable
everybody hates complexity. yet at the same time msdp ("modern software development practices"):
it is not done purposefully. complexity is painful. people do not want to experience pain. so as long as people do not feel pain things are good. msdp are like painkillers. they definitely do help not feeling the pain of complexity, no argument there. but just because people do not feel it, it does not mean it is not there. eventually people get so much painkiller into their system that they cannot live without it anymore. and the eventual consequence of all this is mental breakdown or burnout.
all software is a solution to a problem rather than an end in itself. what is a "problem"? problem is a pair of states: input state and output state. there are many sorts of problems:
software is that tiny "->" bit between the two states. in fact, the software part is completely irrelevant! yet for complexity reduction msdp focus on that tiny irrelevant part. this is what happens when people consider the software as an end in itself. the focus should be on the problems instead.
take the first problem. it is quite abstract but for a programmer it is super clear what it means. one can even mentally fill how the software works because it is just that obvious. now take the last problem. it is very fuzzy and subjective. it is unclear what the software will be between them. do we create an online shop where people enter their feelings and we send the appropriate item for said feeling? or do we create a software for mixing ice cream based on how much sugar the human wants? it is super unclear what are we trying to solve here. usually this fact does not stop people from firing up their editor and start furiously developing stuff.
what is the difference between the two problems? the first one expresses a problem via well known computer science terms: numbers, strings, lists. the last problem expresses it via abstract terms that try to clearly identify the concepts in question.
why is the software trivial in the first case, complex in the latter? in the first case the two states are very objective. everybody agrees on what the two states mean and can reliably tell what and what not matches those descriptions. as such when people think how to solve the problem, they pretty much arrive at the same solution so there are not many creative differences in its software development process. in the latter case people cannot fully agree what "craving", "ice cream" or "in my hand" means. every person will have a different understanding. they will have different assumptions. they will want to implement different things. and in the middle of the development process they realize that one team meant something completely different for "in my hand" than the other team and now they are creating even more problems and software to bridge this misunderstanding.
what is the solution? the job of the software engineer is to reduce the subjective states into the objective realm of numbers, strings and lists.
what does msdp recommend? numbers, strings and lists are unintuitive and hard, we should abstract and create new terms. instead of "list of numbers" you have "grades" of "students". instead of "average" you have "grade average". when you define things like this, they start getting muddy. what is a grade? is it a number? is it a letter? what is the grade average of "a a a b"? the more abstract terms one introduces, the more muddy the problem and its software will be. this is what i meant under "msdp encourage adding complexity".
and to top it off, all the tooling msdp create are further exacerbate the problem. it is all about object orientation, genericity and even type hiding so that you have even less chance to understand what is going on. people are having harder and harder time to communicate with each other just because of the sheer amount of unclear concepts one has to hold in their head.
following this practice leads to very very long problem descriptions with many many types of lists, strings and numbers for the various aspects of the problem. yes. but the key observation here is that if you write all this out, then you will see the problem's essential complexity in its natural form. it will be ugly. it will be painful. but just because something is ugly or painful, does not mean you should hide it. what you need to do is to learn to not mind that ugliness. keep working with it and over time you will gain all the necessary experience to spot and mentally chunk patterns just like professional chess players can take a quick look at a chessboard and instantly understand the full state (and if not then they know that things are messy and should be cleaned up). if you are a doctor then it would be a quite weird if you would be uncomfortable looking at dicks. no, instead the expectation would be that you learn a lot about dicks so that you can look at any dick without problems because that is the human body in its natural form. yet msdp recommend that you do your best to hide all those dicks so that nobody gets uncomfortable. the developer novices do not even have the chance to learn to recognize patterns. they must work with new abstractions all the time. and if they break down something too much, they are scolded that they are not following msdp. this is what i meant by "msdp discourage people from gaining expertise".
the next important task after breaking down the problem into numbers, strings and lists is to document the mapping between the subjective and the objective representations of the problem. even though msdp recommend doing this with all that object oriented madness, this cannot be done formally. the only way to do this is by writing informal prose. the writer of such mapping must meticulously explain what each number and list represent in the subjective world. in other words a software developer's task is not really to write software but to write text!
this is no easy task. and why would people bother writing documentation anyways. all the structure is super clear in their mind so the mapping between the subjective and objective world should be super clear to everyone else too. interestingly when most developers look back to their own code written in the past, they think it is ugly and unnecessarily complex. in such cases the assumption is that this is because they got smarter but that is not the case. they would write the same code today too. the only thing they are lacking is the context of their code. and the reason they lack it is because they did not clearly document the input and output in simple terms. the other characteristic of most developers is the feeling that they should refactor all the time. they write something and they are very proud of it. then they try to actually extend it they realize that what they wrote is not any good and they want to start from scratch. they constantly want to reimplement things. as such their productivity is pretty low. if you are thinking in terms of input and output then understanding code is not hard and you do not get the feeling that your old code is bad nor do you feel the inclination to refactor all the time.
suppose you are using linux every day. you get curious about the kernel. you want to learn more. you download and open its source code. you barf. it looks unnecessarily complex and think this is crazy. you even think maybe you should write a new operating system from scratch just to show them how is it done. see the problem? this is the "software as an end in itself" approach. if you open a piece of code and say "i want to understand this" then you are doing it wrong.
what you need instead is a problem. you could say "i have all these processes; i want to know how can they run simultaneously". if you phrase it like this then your first step is not to download the linux kernel source code and get frustrated about its complexity. instead you first open the wikipedia and start learning about processes. if you know everything about them then you start learning about the schedulers. once you know about those, you start searching about linux specific schedulers and you learn how do they work. at no point did you need to open the linux kernel source to answer your curiosity. but suppose no one is around to tell you what linux is doing. then you must download and inspect the code. however in this case you already have the context: you know the technical terms around both processes and schedulers. you know that you are looking for a specific thing. you also know that this is a very core thing in an operating system so "drivers" will not be the right directory. you can pretty much tell what does and what does not look relevant to this. you find the corresponding file and it tells you the name of the scheduler and even points to docs. you got your curiosity satisfied without any complexity getting into your way. all you really needed is to get accustomed to some objective terms and concepts and then understand the problem in those terms.
software does not exist in vacuum though. it is used in a domain. if the domain has well specified, objective terms for concepts, then using those when reducing problems is fine. in the domain of computer system administration i work with the following concepts:
if a state is expressed in these terms then i can probably understand it pretty quickly. it is very easy for me to "visualize" the state in my mind. when i visualize both the input and output state, i can sort of get a "feel" for what is happening in between. if i start seeing "tasks", "channels", "configs", "objects" then things start getting muddy for me. people try to be nice and "hide the complexity" but all it achieves that i am no longer able to see all the pieces the software is working with. all i see is fog.
it might seem that some problems cannot be reduced to such simple terms. e.g. i want to write a videogame but i do not really know what exactly the end result will be since it will require a lot of iterations to get everything right. even so, you still have a rough idea what you want. in a shooter you want a 3d environment, players, enemies, weapons. you can break down those concepts into their corresponding data structures, find some common problems that you are sure you will encounter (moving around, collision detection), implement those, and then go from there. the idea is that you should have a clear, objective mapping between the concepts and their data representation in simple types.
another reason people are afraid of deconstructing things into their base forms is that if they write out the full state like that in such simplistic terms then it will be way too long and unhelpful. however length should not be an indicator that you need an abstraction but rather that you need to think more to come up with a simpler system. sometimes this is impossible: you want efficiency or good usability and for that you need all those pieces. that is okay. in such case it will be clear that we are trading simplicity for features. it will be also clear when are we having way too much features and maybe start thinking in different terms of approaching the problem.
take the case of long functions. msdp suggest that you should break down long functions if it makes sense. this then reduces the number of local variables you need and thus you reduce the state the "poor reader" has to keep in head. but that makes no sense if you consider things from the input output perspective. you are not reading a function for entertainment. if you are reading a function then that means you are either trying to extend it or you are trying to find a bug in it. in both cases what you really need is a good understanding of what the function does. if all you see is just invocations to other opaque functions then it will not be clearer what is happening. what you really need is a human telling you what the function does in high level terms. when you have that understanding, then you will also have a feeling where to put the missing piece or where the faulty line might be. where are you going to get this if you do not see any human around? you will get this from the comments. in other words what you are really looking for are human comments in functions. and you need good quality comments. how do you get that?
there is this phenomenon in in-person human communication: suppose someone is explaining something to you. when they finish the explanation, they are looking at you, waiting for a reaction. if you do not provide any reaction, the other person will assume that you lost the thread and they will start explaining in more detail. this also works with code! if you write a large chunk of code then you will feel bad if you do not give a summary commentary in front of the chunk. however small chunks feel obvious and as such they are left undocumented. if you split up a large functions into many small functions, it is pretty much expected that you will have less documentation and your code will be much harder to understand.
good rule is this: when you see the same logic in 3 places then consider factoring them into a function but no sooner. below 3 you simply do not know if the abstraction you are creating is good. 3 and above it means that there is a common concept hiding there, it might worth naming it. this process is called semantic compression. note that this process applies when deconstructing state too: if there are common structures (4 floats representing a vector) then it is okay to define a structure for them (struct vector). but this structure is just for naming a common concept, it is not meant to hide its elements or assign functionality to them like you would do in object oriented programming.
since poor functions are one big source of complexity, let me elaborate a bit further on them. you should treat a long function like you would treat a book. it should start with an introduction what the function is about, what the inputs and outputs are and then a table of contents of its logic for quick navigation. do not use numbers for the sections because the numbers might get invalidated quickly. make sure the heading names are unique so that the reader can quickly navigate by text search. this does not really look nice in small examples but as a quick demo a small example will do:
// return a solution to a^2*x + b*x + c = 0 (unspecified which one in case of // multiple results). x is an output-only variable (must be non-null). the // function returns true on success, false in case there is no solution. bool solvequadeq(double *x, double a, double b, double c) { // solve the equation using the following steps: // basecases: handle the base case. // discsqrt: calculate the square root of the discriminant. // returnres: calculate x and return it. // basecases: handle the base case. if (a == 0) { *x = -c / b; return true; } // discsqrt: calculate the square root of the discriminant. this platform // lacks sqrt so we implement our own approximation via newton's method. double disc = b * b - 4 * a * c; if (disc < 0) return false; double discroot = 1; for (int i = 0; i < 20; i++) { discroot = discroot - ((discroot * discroot) - disc) / (2 * discroot); } // returnres: calculate x and return it. *x = -b + discroot / (2 * a); return true; }
as you can see i inlined a sqrt (with the assumption that sqrt() was not available). sqrt is a pretty well known and understood concept so it would be okay to grant its own function. but there was nothing of value lost by just simply inlining it given that it is only used from one place. you could argue that this way somebody might add another sqrt or that when the platform gets its sqrt support, nobody will replace this piece of code. now this might be true for simplistic example, but for a more complicated example somebody would totally reimplement frobnicate() even if a frobnicate() would have existed already (they would call it dofrobnicate() so the compiler cannot point out this mistake to them). and the second concern is not addressed by decomposition either. you will still have identical pieces of code all around. and even if msdp would address the issue of duplication, it is a moot point. remember, complexity does not stem from duplication. complexity stems from the fact the concepts the code works with are subjective and unclear. obsessing about duplication will not reduce the complexity.
by the way, another trait of msdp is that they always demonstrate their points using simple examples and for that they all seem convincing. demonstrating complex examples is cumbersome so they never get to the point where they would see their systems crumbling down under their own self-inflicted complexity.
some comments look superfluous in this small example just like having too many subheadings in a small book is superfluous. i would not give this many comments for a function like this. but for longer functions they can really help the navigation. free form comments are much easier to read than handle_the_base_case(). from such function name you do not know that it is related to quadratic equations even.
if you squint enough, this is very similar to knuth's literate programming. the difference is that in this case we do not generate a separate document for consumption.
what would happen if you started breaking down a long function into short functions and/or approach the problem in an object oriented programming way? the essential complexity would still be present, you cannot eliminate that. however it would add a lot of accidental complexity. you will get bunch of new problems. you have to pass around state. things will look quite okay initially but it will be a maintenance and debugging nightmare. when requirements change and you have to tweak some functionality here and there, you will realize that you need to pass around even more state. your function prototypes start growing bulky (and the function names will be obsolete just as well as comments can become obsolete). eventually you will end up in a codebase where the function splitting look pretty much arbitrary and does not make any sense. or suppose you want to speed up the above function. when you look at it like this, it is pretty obvious that you can trade speed for accuracy just by decreasing the number of iterations in the loop. you have immediately seen that. had everything been abstracted away, such observation would have taken quite a while to arrive at. or suppose you are trying to debug this function. you want to add print statements here and there to dump state. if all state is available in this single function, adding such print statements at a few tactical places is super easy. doing the same in a heavily abstracted code is painful. the point if you have a lot of abstractions then you spend a lot of time fighting against those abstractions and this fighting is called the accidental complexity. this is why all those abstraction fanboys want to refactor their codebase all the time. you can avoid all this pain just by not abstracting at all until there is a clear, objective benefit to it (you have at least 3 cases that you can replace with a single concept).
another observation of the whole input output approach is that if the code does not matter, then the choice of platform and programming language does not matter much either. this is one of the reasons why c got very popular. it was not trying push any methodology on people (other than the const correctness nonsense). it implemented the basic features that people needed for structured programming and it turned out that was enough for almost everything so it spread like a virus.
this is getting already way too long so let me wrap up. if you disagree everything written in this post, i ask you this: there are people who manage complexity like this and it works really well for them. give them some space. do not disregard their approach completely just because you do not agree. if something is unclear when approached like this, just ask for better comments.
published on 2019-03-02
# codeswap: an experiment idea to compare coding style efficiencies
i am really curious how effective my "avoid creating types" approach would be compared to the object oriented approach. i am thinking of creating an experiment for it. not that i would ever conduct such an experiment but thinking about it is fun. i am not even sure where would i get people for this experiment but suppose that problem is solved. now imagine i have a room full workstations next to each other like in a typical open plan office. the experiment would involve having the participants solve a series of related programming challenges on these machines under a time constraint. then they would need to swap their solutions and continue working on other people's code. the swap also changes the problem the participants are supposed to solve. there are two problems, the swap is done a way that it changes the problem for everyone. to make sure there is no language barrier, i would ask each participant to use the same language. something simple, e.g. c, go or python. i would ask the participants to brush up their language skills before coming to my test. i would also make the environment equally bad for each participant so that the environment has very little effect on the results. to be specific: all i would give them is just a terminal that is split into two windows: left side runs the nano text editor, right side runs a terminal app that shows how correct their solution is. every time they hit save in nano, it updates the right hand side with the results. i would split the experiment itself into the following phases:
i am not sure how to implement the swapping phase yet: i can either ask the participants to swap desks, or i can make the computers shuffle the code around. either one works. if the latter, i need to be careful to prevent participants from saving utility functions somewhere for reuse. they should completely lose everything they have written so far.
the two problems would be very similar when reduced to the core but they would be phrased differently and put into different context so that it is not obvious that it is the same thing. but at the same time the two problems must be different enough so that the participant cannot just simply delete everything and rewrite stuff from memory.
the motivational text would have 2 dimensions, totaling in 4 different texts:
after the experiment is done, i would ask them to fill a survey. for each phase it would ask the following binary questions:
my hunch is that in the design/impl phase the nocomments+abstraction group will feel the most fun, ease and productivity but the comments+noabstraction group will get more stuff done. in the continuation phase:
in other words: the continuation phase is not fun since people do not really like to work on other people's code. working on non-abstract code will be much easier and people will feel more productive afterwards. the "comment+noabstraction continues on comments+noabstractions" group will have an advantage though: if they followed the recommendation, they should have come up with roughly the same structure so they should be more familiar with the new codebase.
and if it turns out that is the case then i will be vindicated. most software is just a different configuration of the same underlying concepts. there is no need to abstract away all this but rather what is needed is learning to recognize patterns. the professional chess example is very apt: pro chess players can instantly recognize very complex state in the middle of a pro match. even though they might even give some states a name (an abstraction), it is not the name that helps them recognize the state but rather the fact that they worked with so many different chess states so long. it is the experience that matters rather than ensuring every little concept has its own name. in fact, take two random pro chess players: if they talk different languages they will not be able to talk with each other much. but show both of them the same chess board and it is very likely that both of them will make the same next step. this next step is obvious from the abstraction-free chessboard. yet if they cannot see the chessboard, they will pretty much not be able to agree what should be the next step solely because they do not know what the other person is talking about.
when working with code, all we can do is to project the code's concepts into concepts we already know. for instance as part of my sysadmin work i often project the software into the realm of linux system calls. i am very familiar with those and as long as i can understand the code in terms of syscalls, i can pretty much have a rough idea what it is trying to achieve and how. a code feels complex when i cannot do this projection. so my recommendation is to stay on this level, avoid creating concepts that have unclear projections onto the well known concepts. and i am not saying to completely avoid creating new concepts. rather only create a new concept if you have a handful of usecases (at least three): then i can see the concept from various angles and i can learn why is it an useful concept. otherwise it is just a like a useless signpost saying "this is a signpost".
anyways.
as for the problem: i am not sure about this yet. it needs a theme and a bunch of small and easy problems related to that theme so the participants can solve some of them. maybe something like this: you are managing a garden. your task is to read the garden description and help the farmers answer a few questions:
obviously i need to think more about this part but that is the rough idea. the other problem could be very similar but it would be zoo themed. you would have animals and zookeepers instead. or maybe school themed where you would have teachers, students and grades. dunno, this is just an implementation detail.
thinking about this even gives me an idea on how to approach learning the ways of software development if you have access to a buddy: both should start a project each but nearing the end have the other person finish it. iterate this (while occassionally changing buddies) until you feel confident in coding. every time you do a swap, there is a lot of context that needs exchanging. but if you do this often enough, over time it will be clear what sort of documentation or coding styles you need to write or use to make your code easy to pick up. i wish more people would be better experienced in this area of software development. oh well. might be a silly idea but still interesting to me.
maybe if i were a university professor with lots of time on his hand, i could conduct such experiments on my students. hmm.
published on 2019-03-03
# fsbuf: buffering filesystem changes to avoid rw mounts
i'm thinking of keeping my filesystems mounted read only on some of my linux computers. i sometimes do stupid stuff and not touching disk by default sounds like a sensible way to prevent accidents. what i would prefer instead is that the operating system keeps my changes in memory and then i can review them and once happy, commit them to disk. this mode also ensures that my disks are always in a cleanly unmounted state, i can just simply turn off or restart the computer anytime without bothering with proper shutdown procedures. i'm not fully confident that i want this because it also means that i'm now forcing myself to do an additional manual sync after each piece of work. but at least i want to know how to do it. i haven't found any good tutorial on the internet so i thought i'll write down my findings for my own future reference.
note that i am aware that i could just use git for everything, and perhaps copy the whole homedir to a tmpfs and then just copy back the commited files. that's one way, but i'm wondering if it's possible to solve this problem in a more general and transparent way.
by the way, that wouldn't be the only usecase you would consider this for. maybe you want to continue using your disk as is, but occasionally you want to make send the changes over to a slower, backup storage. there are probably some better solutions for this, but the solution described here would work with any underlying filesystem without too much of a hassle and performance loss.
i'll use unionfs-fuse for this. don't confuse that with unionfs which is a kernel module implementing the same thing, and don't confuse it with overlayfs either which is another newer and fancier kernel module implementing similar things. only unionfs-fuse allows modifying the underlying filesystems directly without breaking its internal structures so it's the only system i can do online merging without too much of a fuss. sure, there are some caveats and edge cases where it wouldn't work, but i'm pretty sure that's rare enough to not bother caring. and i'll call unionfs-fuse as unionfs from now on for simplicy.
and for example's simplicity let's suppose the following directory structure:
also note that most commands here assume root as runner. it is possible to avoid using root for most mount commands using clever /etc/fstab config but that's a bit outside the scope of this tutorial so i'll leave it out.
make sure all 4 directories exist:
dirs="/home /homedisk /homebuf /homebufrw" mkdir $dirs chown 1000:100 $dirs
user:gid of 1000:100 usually means the default user and the default users group. if you already have a /home directory, just rename it to /homedisk instead. ideally you would set this up when you are not using said home directory. e.g. you are logged out and setting this up as root, or setting the disk up from a different system.
i'll assume /homedisk is already mounted, preferably as read only. it might be just a vanilla dir on / in which case i'll assume / is mounted read-only.
next, mount a rw tmpfs on /homebufrw and bind /homebuf:
mount -o mode=0755,uid=1000,gid=100 -t tmpfs tmpfs /homebuf mount -o bind,rw /homebuf /homebufrw
now, mount the unionfs. run the unionfs command as your own user otherwise you unionsfs will create its helper files as root and that's not ideal. you won't be able to run setuid binaries from this directory, unfortunately.
modprobe fuse cd / # to ensure we can unmount /home no matter where we ran the command. # note at this point / must be mounted as read-write in order to mount fuse. unionfs -o allow_other,cow,hide_meta_files /homebuf=RW:/homedisk=RO /home
you should now see the contents of /homedisk under /home. feel free to make changes to /home. all the changes will be persisted in /homebuf.
now comes the interesthing part: how to commit changes from /homebuf to /homedisk? first, as a matter of good hygiene, remount /homebuf as read only (and for some reason this remount propagates to /homebufrw too so mount that back as rw which then doesn't propagate back):
mount -o remount,ro /homebuf mount -o remount,rw /homebufrw
you can only do this if there are no open writers. you list the writers like this:
fuser -vMm /home 2>&1 | grep F
if you are very careful, you could do the merge even if you keep /homebuf open for writing as long as you avoid deleting the files it has open for writing. i won't support this case though in my usync utility.
next, remount /homedisk or / as read-write:
mount -o remount,rw /homedisk
now all you need to do is to move the contents from /homebufrw to /homedisk. i wrote a small script for this called usync (see @/usync.sh). run that.
usync /homebufrw /homedisk
after that's done, you can simply restore the mounts and continue editing /home:
mount -o remount,ro /homedisk mount -o remount,rw /homebuf
and that's all to it.
to make things even more convenient for myself, i made the following "bsync" script for myself:
#!/bin/bash set -ex wmount disk usync /homebufrw /homedisk wmount buf
wmount (see @/wmount.c) a setuid script that lets me switch between rw mounting either the disk or the buffer but not both. the point is that my disk is mounted rw only during running the bsync command. and i also see what files changed since the last sync.
there's one annoyance with the current set of scripts though: they don't handle fuse's interpretation of deleted but still open files well. fuse handles such deletion via a simple rename. it renames a deleted file into ".fuse_hiddenXXX" file. this shouldn't be sync'd to backing store and it also means that after a sync, i cannot delete everything from /homebufrw. however this is not super common scenario so my usync tries to detect this and bails out if it's the case. it also prints out which processes are keeping such files open. in such cases it's up to the user to make the tasks release their open file descriptors.
in any case, i'm using this setup for a few days now and it seems to be working well. it's a bit annoying way to use a computer but it definitely works.
edit: oops, looks like unionfs-fuse still has some rough edges. i found a bug in it: https://github.com/rpodgorny/unionfs-fuse/issues/91.
edit from 2022-02: i ended up using this for 2 years. worked fine. but i got tired manually running a sync script every day, so instead i beefed up my backup system and got rid of fsbuf. see @/gdsnap for my new backup system.
published on 2019-12-21, last modified on 2022-02-13
# liquid: an idea about how to implement liquid democracy
i always had problems with politics and voting. my problem with today's form is that the system is way too simplistic and rigid. in the end the choice usually boils down to choosing between two parties, the one you hate less. then wait and hope things do not go way too bad. this is a false choice to me. i feel completely disconnected from the process and therefore i feel like abstaining until i see a better alternative.
i came across the liquid democracy idea which is pretty neat. i will not go too deep into the details or merits of the idea but the main idea is that people can vote on directly on the issues or appoint delegates that can vote on their behalf in issues related to specific topics. people can change these delegations at any moment. this makes campaign circus every 4 years somewhat obsolete which is also a nice benefit.
it is also important to note that it is actually quite easy to migrate to a democracy like this if people wish so. one can create party that provides the above system and then commits to vote in the office according to the people's wishes. if a person wants to vote for party x, they could still vote for this proxy party and in the system they would set their preferences to follow party x's votes. i understand politics is more than just voting but for the sake of brevity i only want to focus on this part for now.
there is only one problem with this idea: it is not obvious how to maintain anonymity in this system. i did a quick internet search but did not find much discussion around the topic. i did find a lot of blockchain mumbo jumbo as if it would solve anything in this aspect of the problem. or the other things i found was questioning this feature of democracy which is also quite absurd. i am sure there are lot of good solutions to this but before searching deeper, i like to give it a thought of my own: how would i reinvent things with zero practical knowledge. writing down just helps me make the ideas more concrete. i will get everything wrong but at i might learn something out of this when i am reading about serious solutions.
my system would have couple important concepts:
had i a website for this, i would not allow much discussion to happen on the site other than casting the votes. this way there is no need for moderation which can avoid a lot of problems and makes the site lightweight. as to where the votable issues coming from: that is a bit outside scope of this brainfart but the general gist is that it would go through formal channels and the only people that can suggest votable issues are the people who then agree to be held accountable for the outcomes.
one familiar with the concepts of liquid democracy can probably already imagine how one could create a system using the above concepts: after people log in, they can see issues, cast their votes directly, or set up delegations to public profiles for specific topics (e.g. healthcare, education, or just education/highschoolers). they also see their historical votes, and what delegation chain led to that vote if any.
however two issues remain: how to ensure one person can have only one account and how can someone verify that their vote counted.
i assume that the country already has a way to uniquely identify its citizens with some sort of official id card. i imagine this algorithm after i decided that i want to participate in the voting anonymously:
my main goal here is to ensure the fact that there is no computer system that somehow associates my identity to my profile in the voting site. in order to achieve this my idea is to split the registration into two steps done at a different time by different organizations.
for simplicity let's assume the registration part happens in january (no voting during that time) and voting happens during the rest of the year, from february until december.
in january the first organization checks my identity and then it records this fact into their database. this registration fails if i am already in the database. the only thing the database records is the unique identifier on my id card (e.g. social security number). then as a proof they (or some other trusted organization) issue me a ticket which is a pair of public and private keys which i can use as a proof that i correctly proved my identity. the ticket's public key goes into a separate database so that the ticket is not linked to my id number. the organization throws ticket's private key away, only the voter keeps it.
on the 1st of february this organization would release the list of people who registered for voting and the list of public keys of the tickets the system generated. the two lists are not connected but they should have the same number of elements. this way people could check who registered for voting and also ensure that there are no invalid tickets maliciously generated (or if there are, it's obvious). though the only way to audit the lack of invalid registrations would be to confirm with every registered voter that they indeed registered. independent auditors can probably use some statistical methods to estimate the number of invalid registrations.
the second organization is the one that runs the voting site. in order to register here you need a valid ticket from the first organization. you need the private key for the registration and one ticket gives one registration only. this way no person can register as another person unless they stole their private key but in that case the former person cannot register. again, this error is detectable even if not correctible. this system also does not collect anything other than a (perhaps randomly generated) username and password. no email address even to avoid the possibility of linking data after a leak (again: users should use separate sites to keep informed about what is going on; i am imagining an infrastructure service, not a social networking site). even the ticket's public key is not linked to a specific user other than marked as used in a separate table.
the registration is valid only for a year. people will lose passwords or have their accounts hacked. since the system itself does not link accounts to the real people, those accounts will be lost until their expiration. this would be the cost of people not being careful with their password (a sort of perverse democratic darwin award). however the damage is only temporary because next year people can re-register.
the other problem is accountability of the votes. i think the solution for that is just public dumps of the actual votes. after each vote the system releases a big file that contains a row with 2 elements: random unique number identifying the voter and the actual votes (the delegation chain would not be public, the system resolves those automatically, only the final votes remain). the unique id for the voters would change after each vote so that it is impossible for anyone to track voters over time yet each voter can independently verify that their vote is in the official dump.
and that would be the gist of it. obviously as it stands there are a lot of rough edges that need careful thought. it does not rely on any wasteful blockchain crap though. sure, it requires a trusted central authority running this but as long as that authority is transparent, i do not see a problem with this. if a society cannot arrange this, then no amount of blockchain technology can save it. if it can then the blockchain tech is not really needed.
i can see a bunch of parties starting up. the only sad part of it that although most of them embrace blockchain as the savior of earth, they do not care much about anonymity. or at least they are not doing good job explaining why they ask for my name and other data and how can i be sure that it will never leak away: linking my votes and my identity. not that i particularly care about my votes being public or not, i just want to make sure the system gets this aspect right. i will look out for stuff like this and see how it goes.
by the way, speaking of blockchain. one of my annoyances with blockchains is that they unnecessarily burn lot of computation away. it's wasteful. i'm using a fully central solution here. i think that's a fair tradeoff in exchange for greater efficiency. the whole system i'm describing here could run on a single raspberry pi even for multi-million users. usually centralization happens for saving resources. i don't have much qualms about this as long as centralized component's scope and features are very limited.
and the actual decisionmaking might slow down, one won't be able to make unpopular things into law since people won't vote on it. i think that's fair compromise. if someone wants to make an unpopular change affecting the whole population, i think it's fair that they should first convince the whole population to want it rather than forcing it down their throat (as opposed to convincing only a few politicians). or maybe try to convince smaller communities to willingly canary some changes and only try for the global change if the canary was successful. in any case, it might not be perfect, but i think it would make people more interested in the whole political process.
update from 2021: ha! such parties actually exist just as i suspected! examples:
published on 2019-12-22, last modified on 2021-05-09
# task: my task management habits
like most folks i also have a barrage of ideas, requests, commitments, chores and so on that i just need to do. since i don't have perfect memory, i need a system for managing them. every person manages this differently: some just rely on their memory, some use sticky notes, some use elaborate software, some use bullet journaling, and so on. there's no system that works for everyone. i'll now share what works for me.
first it's important to define what your end goal is. a typical goal is "to be productive". that doesn't work for me. i don't care much about productivity. my primary goal is to become "free" - free of the tasks. ideally my todo list is completely empty. if it's empty then it means i'm pretty much free to do whatever i feel like doing. that is usually daydreaming which usually leads to bunch of new ideas which then fills todo list again. so even though the todo list doesn't stay empty for long, it's super important to be able to occasionally achieve 0 outstanding todo items. if i can't achieve that, then that is a signal to me that i'm doing something wrong and i need to sit down and holistically reevaluate my priorities. keeping the todo list near empty means you can be more flexible, can easily change directions, try new things, be super responsive to people without feeling much dread about all the tasks you need to do. but near 0 outstanding tasks is super hard to achieve regularly. however one can create the illusion of low task load simply by hiding majority of the tasks! not all tasks are the same. i'm not really fond of hierarchies or labeling things but i do have 4 categories for my tasks:
conditional tasks are the best! those are tasks that you want to do but you can't. suppose you need to talk to a person about a topic but that person is traveling. you can't talk to him until they come back. it means this "talk to person x" task has a date condition. you just need to hide the task until a specific date. or you want to remember that you need to do a regular, yearly maintenance on your car. you can just add a task that is triggered on a certain day of the year. you'll see the task in your todo list from that day on until you clear the task. once you complete that task, you readd the condition to the task but with the year bumped.
one might use a calendar for this. however that is wrong! the problem with the calendar is that you'll see all the upcoming tasks if you look at a weekly or monthly view of the calendar. if you see the task, you'll remember that you'll need to do it at some point and you might start stressing about the upcoming burden. and it's all pointless because you might not be able to act on the task since its trigger date has not passed yet. it's really important to keep the conditional task hidden until it's triggered. surprisingly many tasks can be hidden simply behind a date.
on my personal computer i have a ".rems" file standing for "reminders". each line in it has the format of "yyyy-mm-dd some arbitrary text". you might notice that the filename starts with a dot which means it's a hidden file. i don't want to be aware of this file. most of the entries from it shouldn't be triggering, so i shouldn't care or know about them at all anyways. i also have a "todo" script which prints a portion of this reminders file (among other things like checking my email). it prints the lines whose date is in the past. i run my todo script occasionally, yet most of the tasks from the reminders file stay hidden until they are actionable by me. i can completely forget about those tasks and still remain calm that i'll see them in time (unlike the calendar where i'd see the tasks all the time).
furthermore in certain environments one can be even smarter about this. at work we have a relatively simple issue tracking system. each issue can have an assignee field. if you have an issue assigned to you, you are expected to do something about it. fortunately we have a nice robot to which you can reassign these issues with a condition. you can tell it "please assign this back to me once that other issue is fixed" or "please mark this as fixed once that commit is pushed" or "please assign this to person foo when person bar is back from vacation" and gazillion other actions and conditions. if you use this robot well, you can hide a lot of your unactionable tasks. suppose you have an issue assigned about a bug to you and you already created a commit to fix it and sent it to review. at this point you can't do much about the issue, you are waiting for the other person. so you tell the robot to keep the issue hidden until the bugfix is pushed. after the review you push the commit. at that point the issue reappears and you can, say, send out an announcement that you fixed the bug and close the issue. having the issue hidden means cleaner dashboards, smaller todo lists, and simply less mental tax. i love this tool at work and use it to keep my work task count quite small compared to the rest of my colleagues.
you can also use conditionality to spread out tasks. one example is when you have multiple issues that you have to solve in order. you can use the above robot just to chain them up and in any given moment you'll only see the first issue that you need to work on. once you close that, the next one appears immediately. it makes work much streamlined - you always know what to work on. this trick also works for unrelated tasks. there's only so many things you can do at any given moment. you can decide that you create some sort of order over the tasks based on importance and chain them based on that. for instance there's a person i like to chat with and i always come across topics or ideas that i'd like to talk about or just get their general opinion on. but if they are traveling i can't talk to them. at the same time i don't want to forget the topics. i also can't talk about all the topics with them at the same time when they come back. so in such cases i just chain the topics. i mark the first topic to appear in my todo list once they are back and keep it there until i managed have a talk about it. after the talk i go back to my machine and cross it out and the next one appears - which i'll remember the next time i meet them. it's a pretty simple way to keep many things in your todo list without being overloaded by them.
there's one additional benefit of the conditional tasks. the conditions themselves also serve as a communicational tool. it communicates what a task is waiting on. so if somebody is getting impatient with a task's state, they don't need to bug you, but they can look and challenge the condition directly. e.g. if an issue is waiting on a commit and the commit is waiting for a reviewer, then they can ask the reviewer directly when are they going to finish the review.
my next big category is the "stashed tasks" one. some people call these the iceboxed issues. a lot of times a random idea comes to my mind that i'd really like to do, investigate, experiment with further. however often such tasks are not super urgent or important. i just want to be sure i don't forget about them until i completed said task. sometimes i want to keep a thread of thought open somewhere until i make my mind up about something. basically these are tasks that i want to track but not to be reminded about. since i don't look at this list proactively, this list tends to contain a huge number of tasks. but that's fine. i encounter many ideas day to day. if i don't write them down into a safe place, i tend to obsess about the idea a bit because my brain doesn't want to let go of it until it senses some sort of closure. writing it down to my stashed tasks lists gives it that closure.
ideally this list shouldn't be growing unbounded. it would be only consulted when the primary todo list becomes empty just to find new things to do or when i left some notes about some particular topic which i now want to look up. if i'm looking at it because i don't have better things to do then i can either do some of the tasks i always wanted, or just clean up old, irrelevant entries from the stashed tasklist. one always feels pretty good after such a cleanup.
i implement this by having a simple ".ideas" free-form text file on my computer. i just randomly add stuff to it whenever i think of something. it's also a hidden file since i want to keep it out of sight. i do have a little structure to this file since it is quite long. each task has a title and i prepend a "#" sign for those titles. the subsequent lines are the notes related to the task. the nice thing is that this way i can have a quick overview of all my stashed tasks simply by running "grep ^# .ideas". i don't use more structure than this.
at my work there are several ways to achieve stashed tasks. the issue tracking system actually supports two levels of assignments: "assigned" and "accepted". in theory you can assign any issue to anyone and the other person should mark the bug as accepted once they plan to work on it. so technically you could use "assigned" for the stashed work and "accepted" for the work you actually want to work on immediately. however this distinction is not well understood, recognized or used so even though i could use it personally, i don't do it. in fact, i try to avoid stashed tasks at work completely. if i have such work related unimportant idea, i write it to my personal .ideas file. at work i'd just simply close or unassign such an issue. this clearly and unambiguously signals to other people that i do not plan to work on an issue. you can also add issues to a "hotlist". basically it's like twitter hashtagging but for issues. you can add arbitrary issues into arbitrary hotlists. e.g. you could create a "my stashed issues" or "icebox" hotlist, and just add issues of interest into that. you can keep the issues unassigned so people who want to see the status of an issue can clearly see that nobody is working on it. this approach also works on a team level. if a team wants to track some issues but not work on them, they can hoard them in such an icebox hotlist. generally speaking such hoarding is not very healthy but it can make people feel calmer due to having a place to gather thoughts about certain issues.
when one works with documents or source code, they can also leave todo comments in the middle of the document. it's a very low overhead way of tracking tasks. at my work they have the form "todo(username): some text" or "todo(issue/12345): some text". i'd treat "todo(username)" as a queued task (will explain shortly) however "todo(issue/12345)" is less clear. if issue/12345 is a stashed task then that todo comment task can be treated pretty much as stashed as well. you can think of these as mini-issues that block the main issue. at my work we even have a cronjob that periodically crawles the whole source tree looking for such comments and marks such occurrences in the linked issue. for each issue people can see all the outstanding blocking issues and todo comments as well. they shouldn't close the issue until they clean those up. in fact they receive a warning notification if they close an issue nevertheless. but the point is that you can keep tasks right in your primary work documents as long as you have the tooling to manage them.
next up are the queued tasks or active tasks. these are the tasks that you think you'll be able to work on in the next few days. you really should keep this very short. in a perfect environment without disruptions you should be able to finish all of them within a week. if you can't because you have so much or so big items on this list, then the list is pretty much useless. it's useless because then there are tasks on it that will be never addressed, basically tasks that should be stashed. however just because they are in your active tasks you'll see them every day. you very quickly start to ignore those items. if you ignore one item, you'll very quickly start to ignore other items. this then snowballs: you pretty much don't even use this list to guide what you should be working on next. it just drags you down mentally, reminding you that you'll never be able to reach the nirvana of 0 tasks. this is why i prefer the term "queued" tasks. it means you can't allow things to linger in this list. if possible, you should go through the tasks in fifo manner - first in, first out, no matter what the task is. even though it might not sound a super productive strategy but it builds a good habit of not hoarding tasks. i often have some very small idea i want to try. before i forced myself to use the fifo rule, i pretty much procrastinated on such ideas and eventually even dropped them because i got bored by hoarding them in my todo list. with the fifo rule, i'm forced to be more exploratory and i actually learn ton of new stuff this way. simply because i force myself to work on or explore the random unrelated ideas i queue up in my active tasklist.
it's super important to keep this list realistic. only put stuff into that you'll actually get to in the order of days. there's on exception: if your task is big, then it's okay to keep an entry about it in there as long as you chip away at the task every day. you can also put untriaged items into this list. for example you can treat reading your unread email as your queued tasks. some emails might prompt for additional investigation, you might keep this email in your queued tasks until you figure out how to respond to it. the task itself is the fact that you have to figure out the response.
you can even try some psychological tricks to reduce the number of tasks. a lot of my personally generated tasks are just ideas that i really want to explore and experiment with. you could save some time yourself if rather than just jumping right into implementing the demo, you talk about the idea with someone first. this means the task now is not implementing stuff which can take long time and requires a lot of motivation to start, but rather just having a chat about it with your buddy. basically transform the task to scheduling a meeting with your buddy. the original task becomes conditional - the condition is a date that is after your meeting. this is also a great way to get out of your comfort zone and make yourself talk to other people. all being motivated from the fact that you want to keep your queued tasklist small. and not only that, you might even learn new things. your buddy might point to an already existing thing, give you tips on how to simplify things and so on. there's not much to lose from this trick.
management of these tasks should be relatively low overhead. different kinds of tasks need different tools for optimal maintenance. my first tool is an unstructured "todo" file on my computer. i just queue stuff to the end, and pop stuff from the top. popping the top is not a strict rule, but just an ambition. most of my own ideas land in this file. often i write an idea down there, and once i'm done with the initial brainstorming, i just move it to the stashed tasks. however i might not always have an access to my machine. in those case i'll open a draft email in my gmail. gmail adds a quite visible marker if you have a draft so i'm always aware of my drafts. however i strive to move my drafts to my todo file from above once i get back to my personal computer. i do this just to reduce the amount of places i have my tasks.
note that this "todo" file doesn't start with a dot - it's not hidden. making this file present in my home directory reminds me that i have stuff to do. if it were empty, i could just delete it. actually all non-hidden files and directories in my home directory mean some form of outstanding item for me. if i start working on a demo or experiment, i just create a directory for it in my home directory and keep it there until i'm finished with it. then i just either delete it or move it to my ".d" hidden directory which contains all sorts of random stuff. stuff that i need to keep around (e.g. a checkout of my dotfiles git repo) or various random stashed things. "d" stands for "drive" or "disk" suggesting i archive most large things under that directory. if i want to keep something around for later work, i make a note of it in my stashed tasklist, and move it to my ".d" dir. if i want to pick it up again, i can just either move it back or simply symlink the directory from my home.
the next big source of active tasks are the email messages. email management is a huge topic on its own, i probably can't do much justice to it. but let me try to give it a short summary. there are 4 kinds of emails:
the first two categories are fine with me, i'm happy to receive them since they usually mean that i have to act on them. i don't have the 4th item at all. i unsubscribe for all unnecessary updates and alerts. if i don't read it, i won't know i can search for it anyways. at work usually such mails go to google groups archives too so i can just use google groups search to find such emails. i'm quite strict about the third category. i subscribe only to a very few and relevant feeds. if the feed only has an occasional post then it's not bothering me. if it's high volume then i try to make it less high volume by trying to eliminate unnecessary spam from it right at the source (e.g. i ask the robots to stop spamming). if that doesn't work, i just change google groups to send updates in bulk (so my inbox can remain clean) or just unsubscribe entirely and remind myself to check on the group occasionally. i either just rely on my memory to check on the feed - if i forget then it's probably not that interesting anyways, so it's a good riddance and i can enjoy the additional free time i got by not reading the feed. or i might add a date conditioned task to check back on the group - usually for work related stuff i ought to know about. but i try to keep these to the minimum. but it's all a moot discussion since these don't generate tasks for me unless it's a list that i'm supposed to give support on.
anyways, let's get back to the main topic. whenever i see something in my inbox that needs some further action or thought from me, i just simply star it. starred emails are also part of my queued tasks. it might be the case that such an email is either just good but long thread that i don't have the time to read now, or it's blocked on something. in those case my action for that starred email is to make a note of it in either my stashed or in my conditional tasklists and then simply unstar it. that's pretty much my workflow: i read all my email, i star the things i need to something about, and then when i have time, i address the starred items. again, i actually follow up on those emails quite quickly, i don't hoard them.
i also consider issues assigned to me as my active tasks. i either actively work on them, or just reassign them either to someone more knowledgeable or to the robot in case it's blocked on something. one annoyance with the issue tracking system that most updates generate an email to every person cc'd on the issue. however fortunately my work's issue tracking system allows editing some of the comment updates: you can edit your own comments and the issue's first comment. these edits don't generate an email notification. so you can pretty much keep updating an issue's first commit to match the "explain the issue; explain the status; make note of outstanding tasks" format there. and then you make it a personal habit to check and update the first comment before closing an issue.
the next tool i use is our internal code review tool. each commit has an author and a set of reviewers. usually the author and the reviewers exchange comments and changes until everybody is happy with the commit which is then pushed. the tool itself has a very handy "attention tag" feature to manage whose turn it is to respond. it's a boolean flag on the author and each reviewer. when the author sends out the review request, the attention is on the reviewers. when the reviewers respond, the attention moves to the author. people can flip the attention on the individuals manually but by default the tool is quite smart with managing it automatically. whenever i have the attention for a commit, a small browser extension starts glowing. by default it is gray so when it switches to a bright color, i notice that quite quickly but doesn't interrupt me in any way in case i'm in the flow. if a commit has my attention, i treat it as my active task and my goal is to review the commit or respond to the comments depending whether i'm the author or a reviewer. even when i'm the author of a commit, once i send it out for review, it pretty much disappears from my active tasks and i can immediately focus on other things. note that i can send the review request to a robot along with a condition here too. the robot will keep the attention tag on itself until the condition is true. then it assigns back the attention and leaves the review thread. this gamified workflow of attention tag ping-ponging makes it very gratifying to stay on top of the review workflow.
so those are my main channels for the active tasks. again, it's super important to ensure you treat them in timely manner. in fact, it's best if you commit that every day you'll start your day by addressing or making progress on your oldest item from your queued tasks. the benefit of doing this is that you always have a clear task to start the day with. once you do that, you'll feel that you achieved something, and you'll be even more motivated to do more things rather than just procrastinating all day on the internet. however in order for this to work, your tasks in this list must be crystal clear rather than vague. if you have a task which is unclear on how to solve, then your task is to figure out how to solve it. most of the time it means writing to a support list or just scheduling a meeting with your mentor or buddy to give you guidance. reaching out to a person is always relatively easy, so you should always be able to do at least that, no matter what the task is.
next up is the archival of tasks. i neglect this most of the time. however now and then i want to be able to remember that i did something and how i did something. i want to be able to refer back to my old notes. i don't worry about this at work because the issue tracking system will keep all the notes and comments around viewable by anyone. the more interesting question is what to do with the completed personal tasks. the simplest thing to do this is just to have a private journal. every time something comes up, you just append a note to the end. in fact, i hear that doing daily journaling is quite healthy for one's wellbeing. sometimes if i'm in the mood, i do write some notes about every day. but i quickly run out of steam. but if some important happens, i usually always add it to my journal. i keep a ".notes" file in my machine and just write to it. every new year i rotate this notes file. i just put the contents of the journal into an email and send it to my email address. this way i don't have an ever growing file on my machine and i can easily refer back to my notes via the email interface's search facilities.
there are other ways to archive tasks and ideas. one way is to write about them to someone. if i learn about a nice idea or nice article, i often just send it to a buddy along with some personal comments. one, this sometimes starts a nice discussion, two, i can easily refer back on the letter later. the benefit of doing this over the journal is that it's much easier to remember about this because you also talked about it with the other person. so even if you can't remember how to find your notes or article again, you might remember who you talked to about it, and just ask them if they remember anything. basically you are outsourcing your memory to other people. it's also a nice way to keep some social interactions alive.
another alternative is to write a public blog post about the idea. i think this is one the best things you can do if you have the guts to publish stuff online. this forces you think about things very carefully, forces you clear up your thoughts so that they can be put into words. and if you are not shy, you can even share the post with others. once it's published, you can pretty much forget about the idea, unless others come back to you and become interested in your specific idea. it can also act as a nice survey to see how good an idea is. if people don't seem to show interest after you show it to them, maybe it's not worth pursuing it. if they do, that interest can actually act as a motivation to start working on the demo. having said that, i don't popularize my blog. i write a lot of crap here that might be better if people wouldn't know about me. maybe when i'm older, this will become easier and i won't care about all this. it would be awesome if people would ask me about my posts after i wrote them though. but i don't want to keep notifying them about my posts - i want them to learn about the posts because they are interested in the posts and explicitly started following me. i want genuine interest rather than pleasantries. but for that i'd need to learn to write interesting posts, but let's postpone acquiring that skill for a later day.
having said all that, there's no reason you can archive a task only in one place. you could write a post, share it with a friend, and then finally mention it in your journal. in fact, that would be probably the ideal habit if you have the grit for it.
if you see some very old tasks in the stashed lists, then they are very good candidates for archival. in fact often it's best just simply decide not to do some tasks. give some thoughts about it, write down how you would go about them, publish them on the blog, and then just forget about them. at least this way you give yourself the closure that you gave the idea some attention but still didn't waste too much time on it. and since it's on your blog, you know you can always refer back to it from anywhere if you feel nostalgic about an idea. or just point to your blog entry whenever you see somebody else thinking of a similar idea. ask them to take a look at yours to see if they can use that as an inspiration.
anyways, that's pretty much how i manage my tasks currently. although i wrote quite a lot and i need custom tooling, i think my system is relatively simple - mostly consisting of 3-4 unstructured text files for most cases. i wrote a lot because the system is quite powerful and needs lot of explanation to explain said powers. i've seen more complicated systems used by people which eventually turned out to not being very effective for them. especially after they ran out of steam maintaining the required process or structure. task management must be low overhead. and i'd reiterate again, task management won't get you out of unproductivity and procrastination. i'm not using this for that purpose. i'm using this system simply for tracking and making an order of my outstanding tasks and ideas in a relatively low-overhead but featureful system. although i haven't tried, a similar method can scale up for teams as well, not just for individuals, it just needs careful thought. i'll spare the speculation about this aspect for now though. i'm still relatively new to managing my tasks this way (couple months) but let's see if it crumbles down or not.
edit after a few months later: i now have a little structure in my todo files. i start each task with a hash followed by an identifier name. this is optionally followed by a colon and a summary. the rest of the lines can be just details. my todo script only lists the identifiers and their summaries. this means i can add many details to a task, they won't add much visual noise when reviewing them. for identifiers i use the format "[a-z][a-z0-9]\{2,14}" to keep them simple. basically i limit them to 3-15 alphanumerical characters. example content of my todo file:
#email dear recipient! here's your email! thank you! #tell: tell my partner that i finally sent that email! #addreminder: do this after sending the email! add a reminder to check in with recipient that he got the email i wrote in #email.
and when i run my todo script, i get this:
$ todo #email #tell: tell my partner that i finally sent that email! #addreminder: do this after sending the email!
you can see that in #email i have some longer text yet it's not printed above. and the nice thing about naming the tasks is that i can refer them like i did in #addreminder. i find it quite convenient. and the todo script is incredibly simple too:
grep '^#[a-z]' todo
the only thing i need to avoid is accidentally starting a line with #. this could be a problem if i would be reformatting lines to 80 characters. but with semantic breaks this is not a problem (see my @/sembr post).
and if you truly do your tasks in fifo manner, then you can add the dependent tasks simply in subsequent lines, and not bother about somehow explicitly marking dependencies to auto-hide them.
i think this is a nice demo about many good practices working together in a way that allows you manage things quite effectively yet in a very simple manner.
# edit
i now put stashed tasks into file called ".backlog" rather than ".ideas". it sounds like a better name for these tasks.
published on 2020-02-01, last modified on 2021-09-29
# shooter: an idea for a simple fps game
this is another of those fantasy posts where i think aloud what sort of game i would try to make if i had infinite time, motivation and energy to do things. in the past i sometimes did sit down and start working on a game but i always gave up after the initial excitement evaporated. at this point, i'm happy if i can simply formulate what i would do. this way maybe my brain can give the obsessive thoughts about the game a rest.
so usually when i think about making a game or software, i try to think only about making the core work well and not care about making it fancy or good looking. for me if the core is good, i don't need fancy graphics or user interfaces. in fact, they would just get into the way. i'd only need fancy graphics if the core is just not good enough, and i'd need some sort of eye candy that sort of hides the fact that the underlying game is actually boring. unfortunately most modern games are like that: they look very fancy but are actually quite boring if you were to remove fancy graphics and replace it with simple shapes (e.g. spheres). the question is: can you make a shooter that is fun in itself even if it just consists of, say, spheres. e.g. each enemy and each projectile, (hell, maybe even the walls) are just spheres?
one of the reasons i'm actually not interested in making such a game, because there is already one good free single player shooter game: brutal doom when played on the original doom 2 maps. it runs on a relatively simple engine so it can't do too fancy stuff. but what remains is basically superb. good feedback on the enemies, good gun mechanics, good maps, no unskippable videos, no overlong loading durations, no high computer requirements. it just gets everything pretty much right. i couldn't find any other game coming near to the utility of this doom 2 mod. actually, most modern games try to model things more and more realistically which actually works against the fun of the game. if i wanted a really realistic shooter, i'd just go play paintball in real life. even though we already have brutal doom, i wonder, can you go for a significantly simpler game and still have it quite fun?
one of hard the problem of games is content. in case of shooters you need some maps and some motivation and goal for shooting all the enemies. i really hate the overly abstract games where you only play for scores. i'm not very competitive person, i want to enjoy the game alone, on its own, or if multiplayer, then it should be some sort of cooperative game where you have to play together to achieve a common goal rather than competing against each other. competition is only fun while i'm winning but if i'm constantly on the losing side, the game becomes quite boring for me. most of the time i don't want to invest into the game enough to become competitive so i just stick to single player games.
in this hypothetical game i would take the maps of doom 2. i like those maps since structurally they are 2d maps yet they still contain rooms with various heights so the fights have a vertical element. however good maps are not enough alone. so i'd also add some short story progression text between the level transitions. i'm not sure what sort of text but each transition text should have the following properties:
if it's possible, a few comics would also work but that sounds way too much effort. text is enough if one is going for simplicity.
on the technical side, i'd just hardcode the game resolution to 640x360. if the graphics and gameplay are quite simple, it doesn't need a lot of detail. then a smaller scale is more than enough. smaller scale means that the game is more performant, it will work on very weak machines too. having a fixed resolution makes a lot of things very simple: i wouldn't need to deal with supporting all sorts of aspect ratio issues, making sure my fonts and heads up display are legible, and many other things like that. i picked that resolution specifically because scaling it 2x will get me 720p, scaling it 3x will get me 1080p. i like such exact scaling because then the game can remain pixel exact. i don't like blurry things.
there would be only one weapon in the game. i think it's important to pick one weapon and focus on making the gameplay fun with that. i understand that game can be more compelling if it has a lot of variety but that is not my goal here. what i'm trying to see if you can make a shooter based on a single gun compelling enough. but what weapon should i pick? most shooters have 4 common weapons:
the first option is the sniper rifle with an optional zoom: this is a hitscan weapon for very long distance battles. this can be quite rewarding but at the same time quite frustrating if you have bad aim. it's also quite boring in the sense that you are usually quite motionless, the movement is not that important. so this gun doesn't satisfy the fun in the movement dimension. there's also the problem of dealing with lag in multiplayer games. getting the correctness right is quite a hard problem. one doesn't want to experience the fact that they correctly clicked on a target, yet the server refused to acknowledge the hit. so if one wants multiplayer, sniper rifles can get quite tricky to implement fairly.
by tracer guns i mean guns that are hitscan weapons with high fire rate. the player needs to trace the enemy continuously - keep aiming at the enemy while continuously attacking to slowly destroy the enemy's shields and health. examples are the machine guns in most old shooters, the lighting gun in quake 1, the link gun in unreal tournament, or most rapid or continuous fire guns. these are usually mid range weapons. my problem with this sort of guns is that they are not as satisfying as the other type of guns. with a sniper rifle or shotgun, you can eliminate the enemies with one shot if you are lucky. that's satisfying because you get an instant feedback for an action. with tracer guns the gameplay feels like a grind. gears of war contains lot of action like this and i find that boring. that game feels like a chore. so i'd totally avoid building the main gameplay around this.
i love the overpowered shotguns in some of the games. brutal doom has it pretty good. what i love about them the most is that in close range you can instant kill the enemy, and gibs of the enemy fly away. it's a very satisfying thing. and this also requires good amount of movement skill too. you have to run back and forth against the enemy for the attacks because the shotgun is ineffective outside its range. this is quite fun but the problem i think i have is that most of the satisfaction comes from the effect of the gun rather than the skill of the player. it's not super hard to play with it. and if you go with pure graphics, a lot of the gun feedback goes away and it won't be as enjoyable, at least not for long.
by projectile guns i mean guns that shoot flying projectiles that travel at moderate, constant speed. think of the rocket launcher of quake and unreal tournament, or the shock rifle's alternative attack in unreal tournament. i also assume that this gun is not fast firing, so there's some delay between the shots. i never really liked these guns for two reasons: they were slow so there was a lot of dead time during action, and more importantly it's usually super hard to hit moving targets with them. but i have to admit: hitting someone with such projectile is very satisfying. but still, in total: not fun. at least that was my opinion until i played shootmania which i think did something genius.
before explaining that, let's talk about the concept of ammo a little bit. ammo adds a tactical dimension to a game. the amount of ammo you have changes your tactic. full ammo? go guns blazing. low on ammo? play it very carefully, try to eliminate enemies one by one with precision attacks. it also paces the game a little bit. it forces you to explore the map for the resources. so it prevents the game from being all action. in modern games you even have reloading, which forces you to take mini-breaks from the action which helps you take a breath and perhaps rethink your strategy. it's also a nice ritual you do after each battle. it also helps to add a closure to a battle since you probably won't reload during a battle unless you absolutely must. you do it when you feel your job is done. i believe there might be also another psychological aspect of being more vulnerable during a reload which also satisfies some internal craving of being defenseless in a safe environment but i haven't thought about this aspect a lot so let's not get into this.
the problem i have with ammo is that they take away from the purity of the game. it makes the players inequal. the person with more ammo is at an advantage. so at this point the game is not pure shooting skill, but also map control tactics. both shootmania and mass effect solved this very nicely while still retaining some of the above mentioned benefits: just have infinite, slowly recharging ammo. in shootmania you have a single gun: a gun that shoots projectiles. but it has a catch compared to the above games: there's no splash damage, you have to hit the other player to frag them. that in itself would make it super hard but to counteract this problem, you can shoot the gun as fast as you can. so you can spray your enemy with projectiles. but that in itself would make it like a tracer gun so to counteract that, you have only 3 shots in the gun. but they quickly recharge, so even if you shoot away all your charges simultaneously, few seconds later you can shoot again. however if you shoot as soon as your first charge is ready, you'll need to wait again for your next shot. so what happens often in close battles is that you have two players dancing around each other, waiting for the right time to start attacking. too soon - they will have less charges available - less chance of hitting the enemy. if they wait too long, the enemy might start spray attacking sooner giving them a high chance for defeating the player. and there's no unnatural need to run away from a battle due to lack of ammo. the only thing the player needs to concentrate on is the other player and the timing. it's as pure skill as possible.
so that's one aspect of gameplay. the other aspect is that you have a projectile gun which means it's incredibly satisfying when you hit the other person. with a typical hitscan weapon you just need to move the cursor over the other person's avatar and shoot. it's a very mechanical skill that requires very good reflexes. with projectiles you don't need to do that. all you need to do is to predict where the enemy will be in a few seconds in the future. the nice thing about this is, that you can compensate for bad reflexes simply by increasing your distance to the enemy and making better predictions. and it's not like your predictions must be absolutely perfect. the projectile balls are quite sizeable so you have quite reasonable margin of error. and since you can spray 3 shots in a row, you can cover a larger area. or even shoot tactically - use the first projectile to make the enemy go down a certain path where you'll greet them with your second projectile.
to summarize: i think a fast shooting projectile gun with limited but recharging ammunition is the best gun to make a pure skill based bare bones shooter.
alright, we got the weapon down. next up is health. in general i think the concept of health is silly. especially recharging health. if you have the concept of health, then you start worrying about health. that takes away from the pure shooting skill. i think the best thing to do is just to have instant death. if you hit the enemy, the enemy dies. if the enemy hits you, you die. shootmania actually gives you 2-3 lives so the first shot doesn't kill you except for certain gamemodes. i think that's fine too up to a point. but if i have to be as pure as possible and choose one gamemode, i'd go with one hit one kill. my motivation here is to simply not allow place for mistakes. if you win a level then you should win it without any mistakes. that way you will feel the best about yourself, that's how it should maximise the feeling of achievement.
keep in mind that i'd play this game on doom 2 maps. they are relatively quite small and if you don't hunt for resources, you can pretty much run through them quite fast. so you wouldn't need checkpoints or savegame support. the game would be only about the fact whether you can run through the map without a mistake or not. the main challenge would be about you avoiding the enemy attacks until you either manage to run past them or eliminate them based on your preferences. you make a mistake, you quickly start from beginning and you keep trying until you can do the level without a mistake. no messing with healths and lives and whatnot. just pure movement and shooting.
and now come the enemies. i'd represent the enemies as spheres. the projectiles are also spheres so the collision detection becomes quite easy if you only have the spheres to spheres case and spheres to a static geometry. and drawing them is quite easy too: all you need to draw is a quad with a special shader that can correctly project a spherical texture to that quad with a 3d effect. you don't really need full human-like geometry to make the shooter fun. you usually need 3 pieces of information about an enemy:
the position is quite easy to solve: the enemies have a face. you know the enemy is facing towards you if you see their face. you just need to map the texture correctly.
you can implement the intent easily too: you just draw a different face for different action. e.g. if the enemy is preparing to shoot you, you could have a texture where one of their eyes is closed and they are squinting. of if they want to dodge, you just draw a big open mouth suggesting they are taking in air for the jump and have their eyes look into the direction of they planned dodge.
the direction of movement is a bit trickier since you can't represent that with texture tricks. you need two things: you need to implement "bobbing" during the movement. basically the sphere should move slightly up and down to indicate the movement. this is important because if they are moving towards or away from you, this would be your primary hint. secondly, you need to implement a "footsteps" like effect. basically every half a second add a quickly fading smoke effect in their position at the given time. the point is that you should be able to see the trail of their recent movement. this and the bobbing should be more than enough indication of the direction. although the technique is relatively simple, it needs a lot of finesse to get it right for maximum utility.
as for enemies, i wouldn't go overboard either. i'd implement only 3 enemies:
all three enemies would be quite mobile. if you shoot towards them, they will try to dodge the projectile. so you actually need to get close to them to battle with them. the game would be about close to mid range combat. of course that doesn't mean you can't land the occasional lucky shot but it should be rare (but incredibly satisfying). and of course the enemies have only one health too, so the challenge is all about hitting them while avoiding their attacks. as for differentiating the enemies: i'd just probably color their spheres differently and that's it.
biters are enemies that try to run towards you, jump on you and then bite your head off. they are quite easy to deal with as long as you don't let them get too close. if you do, you have to very carefully dodge their jumps.
divers are flying enemies that fly near you and once close, they dive towards you. very similar to biters the only difference is that they are not constrained to the floor. some doom levels have flying enemies, and having some vertical enemies adds some extra flavor to the game anyways.
spitters also run towards you until they get to a mid range, and then they shoot projectiles at you. they should be the closest that come to playing against other players. and your projectile avoiding techniques must be top notch to avoid their attacks. they should be able to predict your movements via simple linear interpolation and thus you can't simply run around to avoid attacks, you would need to move in a completely inpredictable way (which i often struggle with). they can't spray projectiles like you can do, but if there are multiple ones, that means a lot of projectiles to avoid.
in general i wouldn't put too many enemies on the map since you only have one health. too many enemies would just a grind anyways. maybe about 3-7 enemies per room depending on the size of the current room. that should provide plenty of spatial challenge in avoiding the attacks, and a tactical challenge in shooting them all quickly enough.
so that pretty much sums it up. i know one could extend this with gazillions of stuff. but if i were to make a basic game, i would totally start with only that. i think the above should be more than possible to finish someone in a few months from total scratch in c and yet still end up with a quite nice game that doesn't need a lot of polish.
edit: some other random ideas in no particular order:
published on 2020-02-16, last modified on 2024-08-01
# talking: a game to learn some secrets about others
suppose you have a friend or three. i like to imagine such hypothetical scenarios. and further imagine that you throw or are invited to a small party with them. what do you really do there? i don't really like music, dancing, drinking and such. i'm more of a sit in the quiet corner and listen to other people sort of person. maybe play some game. but what game?
ideally it will be a game that isn't too complex and doesn't really require too many props. i very quickly lose interest in games with many rules. and even if you can follow them all, what's the point in playing such a game? i feel it's just killing time. if i am already with people, i'd want a game that focuses on the people instead. it should make it possible for me to learn more about others to see what people they really are. so basically i just want some structured talking instead and the "game" could provide the structure.
one popular simple party game is cards against humanity. there is a list of cards with questions on it, face down. each turn a player (called the czar) turns a question card up and people have to come up with a witty answer to it. each player has 10 cards with pre-written answer cards from which they can choose from. or one could play this even without pre-written answers and rely on people's inner creativity to come up with witty answers. the person who turned up the question card has to pick the wittiest response. the owner of that response wins the round. the answer cards should be shuffled before the czar evaluates to avoid biased selection. this would be harder in the handwritten, artisan answers but one could solve that by writing the responses on a smartphone.
this is quite a fun game, potentially leading to fun times. the downside is that you don't learn much from the other people, only their wittiness. so i was looking for other similar games with more focus on the people themselves. and i found some! and the rules are even simpler. i found two games and they go with the names of "disturbing friends" and "voting game" and sort of came up with my own rules based on the ideas behind these games.
the first game has question cards which contain a question and 2 to 4 answers. a player, the round's czar, turns up a question card. the other players have to guess how the czar will answer the question. the czar must try to answer the question as honestly as they can. often there are no correct answers. in such case the czar must pick the answer closest to their heart. each player has some voting cards each with a number from 1 to 4. every player has to pick their answer and put the corresponding voting card in front of them, face down. once each player has voted, people reveal their vote one by one and finally the czar reveals their answer. the czar wins (or loses depending on perspective) the round if half or more of people didn't guess the answer correctly.
depending on the questions this can be quite fun with unexpected twists. you can have a neutral question like "best pet: cat/dog/fish" and learn what animal the czar likes. the czar also learns what other people's impressions of him are. you can have a more politically motivated question like "gun ownership: yes to all/only license/banned completely" to learn how people think politically. or you can have a question like "polyamory: it's a bad idea/ok but not for me/i am polyamorous" to learn other people's inclinations. the nice thing here is that the game brings up the question, you don't really have to awkwardly bring it up yourself in case you are curious about people's opinions on a topic. or you can have a dirty nsfw question like "my crotch has (select first that apply): jewelry/tattoo/other surprise". this is where the unexpected twists can occur: maybe some people get intrigued by the czar's answer and then the czar flashes their body to the party. that certainly could result in a lot of fun from then on!
the ideal number of people for this game is about 4 so that the czar can see the opinion of 3 people which is not too little, nor too much. but i think a couple or a pair of people could also play this game. in such case the goal remains to guess the other person's answer and see how well the two people know each other and learn more about each other.
the other game is a bit simpler because it doesn't have a czar. you don't have questions here but rather statements. each person gets assigned a distinct number from 1 to n before the game starts. each round the group turns up a statement card. people then have to vote which person is best described by the statement. the round is won (or lost depending on perspective) by the person acquiring the most votes. if there is a tie, people can break that verbally by arguing who should be the winner.
(edit: or one can simply get a point whenever they correctly guessed an answer. the person with the most points is the person who knows their friends the best.)
a neutral question could be something like "... cooks the best". people can then see whose cooking they find the best. a more interesting one could be "... can hold their breath the longest". people might contest the result of the vote and a fun breath holding contest might start. a nsfw statement might be "... wants to hang around naked". people then could then ask the winner "do you really want to be naked" and maybe the party pivots into a fun naked party!
this game is probably best played with 5 people so that there are less chances for ties. but i think this one could be played by a couple too. the couple just decides between each other who wins each statement.
in order to play this game, one needs voting cards. one solution is to take postit notes and write some numbers on them. the other solution is to cut up an a4 paper into small slips and write some number on them. or even less effort would be to find some coins or other small items. when you want to vote for 3, you put 3 coins into your hand under the table and then show your hand when your time comes. one doesn't need elaborate equipment or boards to play these games.
there could be some punishment or reward for the losers and winners each round. ideas:
it doesn't really matter much what it is but if there's some form of feedback then that raises the stakes a bit and makes the game a bit more interesting. the party members much agree on this beforehand so that everybody is comfortable with the punishments.
one could print the question and statement cards but i don't think it's necessary. as long as one has an app loaded with bunch of questions, one could just use a smartphone to present the questions. ideally people should source their own questions. nevertheless i decided to collect some sample questions and statements and make a small tool for it that is convenient to use from a smartphone. i even separated out the nsfw stuff so you can even play this in a family friendly setting. but a warning: the nsfw stuff is quite strong, i believe. only enable it with friends you absolutely trust no matter what happens or people you don't know at all so that there are less stakes in the manner. if in doubt, just look up the list of questions in the source of the webpage before playing the game. the webpage has no dependencies so feel free to copy it somewhere and edit the list of questions in it, e.g. remove the potentially offending ones and add your topics of interest. you can find my tool here:
load that on a smartphone, select your list and put it into the middle of the table and keep pressing next as the rounds progress. it has about 30 cards for each type. if you ever try it then let me know how it went. i never tried this so caveat emptor. maybe i'll have the chance to try this one day (with the nsfw stuff included) and then i can improve it or list more tips here.
edit: btw, i found a similar site with multiple games along the same ideas. it's here: https://psycatgames.com.
edit2: btw, if you are looking for a name for these sort of games, i'd go with "frivia" as in "friend trivia". it's a trivia about friends after all. let me know if there's a better or more popular name for these things.
edit3: i found an even better version: https://askhole.io. very cool name. and they provide their cards for free under a cc license. in case their server goes down, here are their cards: @/askhole.pdf. the pdf includes their recommended game rules too. you can play over web too: http://web.askhole.io.
edit4: so we have tried the askhole questions. they didn't seem to be working as well as my questions. askhole questions are open ended while mine just require a simple choice from the given options. and some questions are quite complex, we couldn't even understand them. and the party found lot of the askhole questions quite boring as they weren't very personal. the complexity of understanding and answering some of them was just not worth the cost. with @/cards if you pick a boring question, you just pick an answer quickly and move on, no need to overthink things. so if you have alcohol involved and thus have reduced cognitive capacity, @/cards might be simpler to play.
edit5: just in case i now incorporated some of the simpler but nice askhole questions into my cards deck. oh, btw, i accidentally came across https://playerten.com/products/the-voting-game which seems to be what i had in mind for the "statements" part of @/cards. it has a nsfw deck too.
published on 2020-04-07, last modified on 2022-04-14
# cards: questions for a party game, see @/talking
this is not an ordinary post, see this content at @/cards.html.
published on 2020-04-08
# touch: a touching game for couples
i'm quite a reserved person. it's quite hard for me to verbally express my wishes. i often don't even know what i want. and when i do, then i worry that if i express it to the other person, they will get offended about me and it just ruins the relationship. i'm always on the lookout for things that make human interactions a little bit easier.
i like receiving and giving touch quite much. but people have very diverse preferences about what is an okay touch and what is not. so i tend to err on the conservative side and just keep to myself. otherwise i'd need to communicate with people. fortunately i found a very nice but very simple game that can free up people from all the worries when it comes to touch. and you can play this with any willing person. it's called the "3 minute game" and was popularized by betty martin.
first, let's talk about some aspects of the "wheel of consent", or a simplified version of it. each act a human does can be categorized into one of the following 4 dimensions:
they complement each other. when person a is giving to b, then b is receiving. if person a is taking from b, person b is allowing. you can draw this in a fancy circle, that's where the name "wheel of consent" comes from.
how much giving, receiving, taking, allowing a person does, matters. each person has a healthy limit for each dimension. going over we get to the "shadow sides" of the dimensions:
you want to ensure that every act for everyone involved remains in the inner, non-shadow side of the dimensions.
next up, you really need to understand which dimension each act is in for each person involved. suppose you regularly do an activity (e.g. foot massage). you think you are doing it as a favor for person b so you are in the giving dimension. for the other person that activity is in the allowing dimension. they let you do it because they think you like doing it. but giving and allowing are not complementary dimensions. it turns out nobody really wants that activity yet none of the people involved realize this. this is basically a variant of the abilene paradox. there's also the flipside to this: you often don't do some acts because you think the other person wouldn't like it. however it might be the case they would allow you to experiment with it. but you don't even ask because of the fear of rejection.
the "3 minute game" is a short game that helps you structure communication along those 4 dimensions. it helps you do activities where it is super clear who it is for. it consists of four 3 minute rounds. in round 1 player a asks player b:
this means person a will be doing something to person b for person b's benefit. per above definitions from person a's perspective the activity is giving, from person b's perspective it is a receiving activity. keep in mind that person a shouldn't sink to the shadow sides of their dimension, they should only do what they are comfortable to give to the other person. in other words they have to consent to the act. if person a is not happy with the arrangement, they might negotiate a little bit what their limits are and then agree on that. on the flipside person b might just want a boring neck massage. it doesn't have to sexual all the time. person a has to accept that in this round it's all about person b's wishes. once everybody is happy agreed on the activity, person a does the agreed on touch for 3 minutes. then person b thanks for person a for this.
in round 2, player a again asks player b:
this means person b will be doing something to person a for person b's benefit. per above definitions from person a's perspective this is allowing, while from person b's perspective this is taking. the same negotiation and consent process happens just as before. person b might be very horny and might want to crazy stuff. person a must realize that this is fine to express and that they don't have to succumb to the shadow side, they can refuse and person b shall respect that otherwise they are succumbing to the shadow side. once agreed, person b does the activity for 3 minutes. again, since this was for person b's benefit, person b thanks person a for the act.
round 3 and 4 is the same as round 1 and 2 but with the other person asking the questions. the whole thing takes about 15 minutes and is worth every minute of it.
this game might sound a little bit silly at first. but what makes it truly remarkable is that it makes you stop for a minute and think. the question might initially look simple enough but answering them often is quite hard. it's very rare that we get a question on what we want. often i don't even know what sort of touch i really want but this lets me think deep on what sort of thing would fill me up now the best. and i can be very selfish in these thoughts, i don't need to play an internal chess to ensure whatever i want is something compatible with my partner. or that if i ask for this particular thing then my relationship would spoil a bit. the flipside is true too: my partner can think of anything. even if i don't really like the requested activity, i'm certainly willing to give it 3 minutes, whatever it is. it can be a really freeing sensation once you experience this game in a safe and supportive environment. you feel like you can ask for anything and not be judged. you can say anything you want. i haven't really tried it in a non-sexual environment so i don't know how well it works there but i'd suspect it should hold up quite well there as well. you can see sample sessions from such environment in betty's original videos and you can see the participants happy with the game. betty's videos are well worth a watch.
in the original documentation of this game, betty mentions that this is a game for 2 or more people. the "or more" version is quite intriguing to me. she didn't really explain that part as far as i remember. i'm not entirely sure how that would work. e.g. how could 3 people play this game? i think what you can do is that rather than a single person asking the questions, 2 people ask the questions together to the 3rd person. the third person then can come up with activities that involve the first two people doing something to the third and only proceed with the act if everyone agrees to it without succumbing to the shadow sides. i guess that's how the "or more" works: each round a selected person has to ask the group for something they can do together for the selected person's benefit. it probably scales okay to 4 people but afterwards i'd imagine it has way too much communication overhead. never tried this though so not sure how transformative experience the group setting is yet.
the wheel of consent itself is a quite generic concept. it can apply in other cases as well, not just the above game. e.g. you get invited to a party. do you go or not? who benefits from you going to the party? it is an interesting viewpoint to see our activities from. and things can get complicated: you only benefit from the party if some other person also goes. and that other person only benefits if you go. now you have these complex, conditional scenarios that i can't really wrap my head around yet, so i'll not dig into this aspect. i'm just trying to popularize this wheel of consent concept because looks like it's a useful framework to work with.
if you ever try this game then let me know how it went and what your experiences with it were.
edit: i just rewatched https://bettymartin.org/how-to-play-the-3-minute-game/ (https://youtu.be/_KCzpNBNbVM) and i realized the original questions from harry faddis were even more generic and powerful:
oh, and here's a short summary of the rules in the form of a neat booklet taken from betty's site and rehosted in case it ever goes down: @/touch.pdf. folding instructions at https://youtu.be/21qi9ZcQVto or https://en.wikibooks.org/wiki/Zine_Making/Putting_pages_together#An_8-sided_zine_from_1_sheet_with_1_cut.
published on 2020-04-09, last modified on 2022-01-30
# sembr: use semantic linebreaks for plaintext
document.body.innerHTML = document.body.innerHTML.replace(/[:;.?!,] /g, '$&<br>')
published on 2020-06-02, last modified on 2022-02-15
# dyncam: a barebones way to replace your webcam feed with a talking avatar
i keep my work laptop under my desk. i plug an external monitor, keyboard, mouse into it. i basically use it as a workstation. therefore its builtin webcam and microphone are not really accessible to me. these days i use a smartphone for the meetings. i was wondering, could i still use my laptop and just present a nice avatar on meetings?
an avatar that would stand still if i wasn't doing active. but it would talk if i talked. or it would be nodding yes or no if i wanted to be nodding. nothing fancy, but streaming simple, manually controlled, precanned animations.
if you are a sensible person, you would use obs studio for this. but obviously i'm too cheapskate to install and learn new free software. so i decided to find my own ways to solve this problem. the information here is absolutely of no use for anyone (if not harmful), i just thought i document it for my own future reference. (so that i have more content to facepalm myself about when i get old.)
i chose phoenix wright from the ace attorney game as my virtual avatar. it's about an attorney who must solve crimes right in the courtroom. his iconic move is saying "objection" whenever he hears a contradiction. it's a gameboy game and i found gif rips online. i found 9 animations i liked:
it doesn't have to be anime characters. one could prerecord short loops of themselves too. the point is that i have 9 mpg files called 1.mpg ... 9.mpg, and that all these animations can be looped. i want a little interface where i can choose the currently looping animation.
since the original art was gifs, i converted them into mpg files like this:
ffmpeg -re -i phoenix/anim008.gif -map 0:v -pix_fmt yuv420p \ -filter:v crop=960:540:0:0 3.mpg
then i needed a virtual webcam to stream these gifs into. i created one like this:
modprobe v4l2loopback exclusive_caps=1
now comes the tricky part. it's pretty easy to stream a particular video into such a virtual webcam. however what i want here is a little control box, with which i can dynamically change what i stream into the webcam. one obvious idea is to have ffmpeg loop a video statically into the webcam. whenever i want to change the animation, i kill the current ffmpeg and start a new one with the new animation. this felt unclean. and sometimes it messed up the virtual webcam. it was flaky due to unclean exits, i presume. i needed a saner solution. preferably something that doesn't really require me to code up anything. i found a very ugly hack which allowed me to do this.
ffmpeg has a feature where you can tell it to load a list of files from a file. it can then concatenate those files and loop them. so i created a simple loop.txt containing these two files:
file a.mpg file b.mpg
i instruct ffmpeg to loop concatenating these two files. in order to switch animation, i just replace these files with the new animation. yes, i need two separate files. otherwise ffmpeg doesn't reopen the file. it would keep playing the old animation even if i overwrote the underlying file. i guess this makes sense from an optimization perspective.
so then i just wrote a script that reads digits and rewrites files in a loop. i had one extra requirement though. my animation selection console is running in a terminal. the vidconf software is running in a browser. i wanted to be able to mute and unmute straight from the terminal script. so for that i used xdotool. whenever i press the 0 key i do this:
ugh, i know. for reference here's the full bash monstrosity:
#!/bin/bash echo select the browser window with the vidconf. current=$(xdotool getactivewindow) browser=$(xdotool selectwindow) echo # remind myself of my options. echo '1watch 2talk 3determined' echo '4thinking 5thinktalk 6ashamedtalk' echo '7yes 8no 9despair' # set the inital, standing only animation. cp 1.mpg a.mpg cp 1.mpg b.mpg # start the endless ffmpeg stream. ffmpeg -loglevel quiet -stream_loop -1 -re -f concat -i loop.txt -map 0:v \ -f v4l2 -vcodec rawvideo -pix_fmt yuv420p -filter:v crop=960:540:0:0 \ /dev/video2 & # read the requested animation from the keyboard. while read -sn1 choice; do if ! [[ "$choice" =~ ^[0-9]$ ]]; then continue fi if test "$choice" == 0; then # mute or unmute. xdotool windowactivate --sync "$browser" xdotool key ctrl+d xdotool windowactivate "$current" 2>/dev/null continue; fi # set the newly desired animation. cp $choice.mpg tmp mv tmp a.mpg cp $choice.mpg tmp mv tmp b.mpg done
it's a terrible way to do this but it works okay. i'm pretty sure the gazillion ways to do this better. the main limitation is that it can only switch to the next animation, when the current animation has finished. so it only works with short animations. but that was the case for me so that wasn't a big deal. i don't really use this thing often though, but sounded like a fun enough solution to share.
published on 2020-06-04
# pens: a review of the pens i use and like
i quite like to write on paper. it just feels oddly satisfying to draw letters nicely. if there's no time pressure, then i prefer writing on paper to writing on the computer. sometimes i even write my emails or blog posts in my notebook first. but most of the time i write just to think. simply writing down my thoughts often cuts my mental deadlocks. circular or obsessive thoughts are very easy to spot in writing. and if you spot them, it's much easier to avoid them. so as long as i "think" via writing, my "thinking" is more effective.
anyways, writing requires pens, and i just wanted to note my preferences. maybe the world will make more pens like them thanks to this post, who knows. i didn't give pens much thought for a long time. i just thought all of them are crappy until i learned that there are nice ones too. it was during my 2nd year in university, when a freshman roommate showed me his pen. it was a uniball 0.38 signo dx (um-151). i really liked how thin the writing was. i started using one. the ink was fast drying too, so i had much less smudging, and my hands stopped being all ink all the time. i then ordered a box of 0.28 ones straight from america. that was a very wise decision. those pens lasted my whole university time.
the reason i like fine lines is because i use relatively small letters. i'm quite myopic, about -5d (and worsening). that means i see clearly only up to 20cm. so i keep my head bove the paper about that distance. small letters let me have enough space in a small area. and for small letters i really need a fine pen.
now i live in switzerland and those signo dx pens are hard to come by. so now i'm testing the sakura pigma microns. i only started using them a few weeks ago. it was a bit weird initially since it is a plastic needle tip pen. i didn't use such a pen before. but they feel super nice to write with. they are not super thin though. even the smallest, 0.05 version feels about the same as the 0.38 signo dx. side note: some pens report the nib size, others report the resulting line size. no idea why they can't all use the same measurement to number their pens.
the only annoying thing about the pigma micron is that it is brittle. the problem is that its tip slowly goes back inside its metal frame. perhaps i'm using way too much pressure while writing. after a while it becomes very inconvenient or unable to write, even though there's plenty of ink remaining. and it's not something that can be easily repaired. or at least i'm not skilled enough to repair such a fine instrument. if these pens wouldn't have this flaw, i'd be happy to use them instead of the signo dx pens. but if i have to choose, i think i'd still stick with the 0.28 signo dx pens. another advantage of the signo dx pens is, that you can clearly see the amount of the remaining ink. the pigma microns lack this feature. not that i ever managed to write one dry.
btw, i understand not everyone likes small letters or fine lines. if i were to write something for others to read, i might use bigger letters and thicker pens. i recently tried the uniball eye micro (ub-150). it is quite thick, but also very nice to write with. i'd probably use that one for such writing (or a thicker pigma micron).
as for paper, i use a spiraled a5 graph ruled notebook. the grid is really helpful in nicely aligning my text or sometimes a drawing. i don't really like to use a completely clean paper. i don't think i have a preference about paper weight. if the paper is smooth and the ink doesn't bleed to the other side, i'm happy.
so i like to handwrite. do i like reading other people's handwriting? hell no! most people simply can't write readably. i even seen people who have very "aesthetically" looking writing, but it was still unreadable to me. during school some people did sometimes note that my writing is a bit ugly, but at the same time it was super rare that someone asked for a clarification. so even if my writing is ugly, at least it's somewhat readable. that's the important part. i guess people just don't really care about readability these modern times. handwriting is a lost art. btw, if curious about my handwriting, i took a photo of a page of my writing. it's at @/pens.jpg. this one is quite ugly though. i usually write much nicer if i expect others to read it. i didn't know i'll take a photo back then, so i didn't spend effort on niceness. at least you can see my ugly side. in any case, i wouldn't really want to communicate via handwriting. i prefer reading nicely printed text instead (if short then screen is fine too).
btw, one disclaimer to these preferences: i'm no big pen guru. i haven't tried many pens. so i constructed my preferences from a small sample size. if anyone knows cheap, available pens i'd like, then let me know.
anyways, to summarize, my favorite pens are (in this order, assuming their finest version):
edit: not long after writing this post, i had an idea. i realized that i found it quite uncomfortable to write on the left side of the notebook. my wrist rested on the spiral. and it was really annoying whenever i had to write near the right margin. the spiral was getting in the way of the pen. so i decided that from now on i'll just flip the notebook for the left side. so every time i start a new page, i have to flip the notebook. or more specifically: rotate the notebook 180 degrees. /pens.jpg shows the old style. in the new style i'd have flipped the notebook. the sentences would always start at the spiral, no matter where i write. this would be annoying if i wanted to read the notebook, but for me it's mostly write only. the reading inconvenience of the flipping is worth the writing convenience. i'll totally do this from now and see how it goes.
edit2: i came across the muji 0.38mm gel pens. they are similar to the sigma dx but can be bought here in switzerland in muji. muji is some sort of retailer for random japanese stuff, i think. it's not perfect though. i'm not sure if i got a faulty unit or all of them are like this, but the one i tried needed more pressure to ensure the ball is rolling. if i didn't do that (with micros i use barely any) the ink just skipped. but i could get used to this too. it's a nice pen. but after using the microns for a while, i might like them better than ballpens. the "needle goes back to its cave" is the only thing that annoys me. :(
edit3: i no longer flip my notebook each time i fill a page. what i do instead is that i simply skip the other side of the page. this way i can always easily refer to the previous pages and write at the same time though i don't usually refer back. i only flip the notebook when i filled the right side of the notebook. then i go backwards in the flipped notebook so i still write on the right side. very convenient.
published on 2020-06-08, last modified on 2020-09-24
# enacc: a silly system for motivating physical exercise
i'm quite the sucker for temptations and vices. i've managed to avoid the worst ones and fortunately no vice takes up too much time from me on average. but sometimes i have a flareup and then i tend to go overboard with things. i decide to check out a manga, an anime or a game, and then i'm spending 10 hours per day consuming it up to several weeks. i guess i have issues with moderation. during those flareups this can really affect my general productivity. in the past i had all sorts of addictions but i managed to cure myself out of them. i do that by avoiding the triggers and resisting the temptations. but sometimes it takes quite a long time for me to enact countermeasures. here's a random sampling of addictions i have or had in the past:
in moderation they are fine, but when i go overboard, i often regret all the wasted time and energy. i regret not spending the time on stuff i know i wouldn't regret. here's a sampling of stuff after which i feel somewhat good:
if i have a flareup of one of the former activities, these preferred activities get much less attention, which means i don't feel very good about myself. all of these good things require a lot of energy to start them, and if the activation energy is too high, i'm more tempted to procrastinate with the former activities.
i was thinking what options i have to help myself. one common tip against bad habits is to replace them with different habits. that sort of works but it's quite hard. and it doesn't really help with the flareups, where you spend a lot of time in a short burst on an activity. i want something that would force me to moderate myself and works regardless of activity.
my sudden idea is to assign an "energy cost" for those regretful activities. i then have a limited supply of energy and i have to budget it thoughtfully. if i have a lot of energy saved, i can let myself have some fun. if i'm low on energy, i can only allow the simplest things like checking email. this still allows me to do things in bursts (that's my preference), but thanks to the tracking i can now rely on the system that it will prevent me from going overboard.
what should be the source of this energy? well, these days i spend all my days indoors thanks to the covid19 lockdowns. i just sit all day long. i don't get any exercise at all. therefore i decided to gain energy from doing some simple exercises. the goal isn't to get buffed from these exercises, but to have less zero days. zero day means a day where you didn't do anything useful. the goal is to avoid them. so i guess this little gamification could help me avoid them.
i started this system when i was writing this post, and i felt that it already helped me to curb my email checking addiction. i don't want to waste my hard earned energy points on this silly habit. there's no need to check it more than a few times a day. this allows me to focus better and makes it actually possible to write this post. one could say that i'm actually quantifying my opportunity cost and i'm using my loss aversion tendency to battle the bad habits.
to make things harder, i track energy in multiple dimensions. each exercise type i track gets its own dimension. for example i can start with three dimensions:
in this example different exercises convert to different amount of energy. pullups are hard for me, so i'd get more energy from a single pushup. squats are relatively easy, so i'd need to do more from it for a single point.
to use up some energy, i subtract that energy from all dimensions! for example if i have pushup:7 pullup:6 squat:3 energy levels, and checking on email costs 2 energy points, then after that i'd have pushup:5 pullup:4 squat:1 energy remaining. i'd need to do 2 squats again before i could check on my email again. i subtract from all dimensions to ensure my exercises are somewhat balanced. the goal of the system is to stay in the positive range and rack up enough buffer so that i can enjoy some of the bad activities when i feel down.
it's super easy to add and remove exercise dimensions as i see fit. maybe i get some dumbbells and then i can add a dumbbell curls. maybe some day i want to focus on being more outside. then i can add an outside dimension which will result in 2 energy points for every minute spent outside. or if pushups become to easy, i can just change my accounting so that i need 2 pushups for each energy point. or maybe i break a leg bone, then i can remove tracking squat for a while.
the nice thing about using exercises is that after an exercise i feel more motivated to do sensible stuff. exercise somehow wakes up my spirit. so this system not only limits my bad habits, but it also motivates me to spend time on my preferred activities. and getting some exercise out of it is not a bad deal either. i tried going to gym a while ago. i've lasted a couple months but i found it incredibly boring. i felt that there was just no point to it. but this system gives me some goal for the exercises. i understand that these little exercises don't substitute real exercise. however i'm more likely to do it several times per day which is good from a "take a break from the computer" perspective at least. by the way, this style of training is called "grease the groove", although i'm not taking this experiment seriously enough to call it a training.
i also have a lot of flexibility over costs too. for example i can start with this:
the costs are arbitrary and subject to constant tweaking based on how i feel about my habits. in order for me to binge watch a long anime, i have to buffer up a lot of energy. which is good, because at least my body got something out of it. and since i couldn't watch said anime until i buffered up enough energy, i probably spent a lot of time on doing nice stuff in the meantime.
i don't plan to use this as an excuse to restart my old bad habits. i'd still heavily avoid hackernews for example. one visit to that site and my day is ruined. it's more for protection against accidental visits or accidental new habits. if i notice i started doing something that i regret afterwards, i can quickly assign some cost to it and thus limit myself.
i also put an upper limit of 1000 points on the values in the dimensions. for example that's about 16.5 hours of anime watching. this way i can be certain that i won't burn more than 2 days in a row just on a single anime. the other function of the upper limit, is to signal that an exercise is maybe too easy. if i can easily reach 1000 in a dimension, maybe i should make it harder. e.g. if i could easily make 1000 pushups in a few days (i wish), i could change the accounting to have 2 pushups only mean 1 point. or maybe i could pushups with a weighted vest.
although the system allows the energy levels to go below 0, but i wouldn't allow that to happen (hopefully).
it's relatively easy to track this on pen and paper. all you need is a table. each row should have a timestamp (mmdd hhmm format to save space), and the latest energy levels for each dimension. suppose it's july 17 and you start with 10 energy points in each dimension, check on the email, then do another 2 pushups, then watch a cat video next day. your table would look like this:
timestamp | pushup | pullup | squat | comment ----------+--------+--------+-------+-------- 0717 0800 | 10 | 10 | 10 | 0817 | 8 | 8 | 8 | email 0820 | 10 | | | 0718 0703 | 6 | 4 | 4 | 4min cat video
the comment column is optional, i think i would leave it empty most of the time. and if the level is the same as in the previous row, i can leave that empty too. timestamp is also optional to track. if you do it, you can then graph your energy levels over time. even if you do that, tracking hour and minute might be overkill, maybe just note the day and track only that.
in my case i spend almost all my time in front of the computer, so obviously i made a script for myself to do this tracking. i made a little "enacc" tool and it logs all my changes into the ~/.enacc file. enacc stands for energy accounting tool. i can write "enacc 2" and it subtracts 2 from all dimensions. then it prints the current stats. i can write "enacc pushup 10" and it logs that i gained 10 pushup points. i can just write "enacc" and it displays usage and the comments from ~/.enacc. i keep my current dimensions and costs in the comments in that file, so this way i can easily remind myself of my commitments. here's an example run:
$ enacc enacc - energy accounter. usage 1: enacc [dim val]... usage 2: enacc [val] dim is either 'sub' or one of the energy dimensions. dim 'sub' subtracts val from each energy dimension. otherwise val is added to the specific dimension. val on its own is the same as 'sub val'. ~/.enacc file comments and energy levels: # dimensions: # - push: 1 ordinary pushup. # - pull: 1 inverted row with the help of a desk. # - jump: 2 jumping jumps for each energy point. # costs: # - checking email or running the todo script: 2 # - for each minute of video entertainment: 1 # - for each minute of gaming: 1 # - checking on memes or aggregators: 10 # - eating junk food: 10 # - fapping: 20 push:24 pull:14 jump:14
that output was generated from this file:
$ cat ~/.enacc # dimensions: # - push: 1 ordinary pushup. # - pull: 1 inverted pushup with the help of a desk. # - jump: 2 jumping jumps for each energy point. # costs: # - checking email or running the todo script: 2 # - for each minute of video entertainment: 1 # - for each minute of gaming: 1 # - checking on memes or aggregators: 10 # - eating junk food: 10 # - fapping: 20 2020-07-17 17:00 limit 1000 2020-07-17 17:00 push 0 2020-07-17 17:00 pull 0 2020-07-17 17:00 jump 0 2020-07-17 17:00 push 25 2020-07-17 17:00 pull 25 2020-07-17 17:00 jump 25 2020-07-17 18:12 sub 2 2020-07-17 20:53 push 15 2020-07-17 20:56 jump 10 2020-07-17 22:03 pull 10 2020-07-18 09:21 push 12 2020-07-18 09:21 jump 7 2020-07-18 09:21 pull 7 2020-07-18 09:31 sub 24 2020-07-18 10:06 sub 2
i track a full timestamp here because for computers that's not a problem. i keep this script in my utilities repo here: https://github.com/ypsu/cfg/blob/ca855598/utils/enacc.c
it's a linux commandline utility though. there are probably gazillion more mature apps doing the same. maybe they can make the tracking even simpler. i don't know, i haven't researched this area online, i might have missed some nice improvements. i came up with this on my own after being frustrated with watching too much anime recently. maybe try the paper tracking first before investing too much time in a complicated tool though.
i also don't track on what i wasted my energy points on. it would just add more toil tracking this and i'd be more likely to give up. i want the process to be as easy as possible, so i only care about the numbers. to be fair, i wouldn't even care about using a log format in my tool, and just have like 3 numbers in a text file representing the actual levels. the only reason i use the log format because then i can easily append to it. i don't like rewriting files because it's brittle from coding perspective. but appending to files is usually a very safe and easy operation to implement. just think about tracking this on paper: appending is the only sensible way to do it.
i don't actually know if i'll be able to commit myself to this system long term. but uncertainty should stop me from trying random stuff. it's definitely worth a try and see how it goes.
# update from 2023:
i didn't do this for long. but since then i learned there are more serious attempts at gamifying tasks and life in general such as habitica, taskhero, magictask, habit hunter, etc. if i ever dabble with this again, maybe i'd try one of them. but nah, all this is just a hassle for me. the method in @/habits works well enough for me. most of these also have multiplayer which could be worth trying with others, hmm.
published on 2020-07-18, last modified on 2023-10-22
# peckmania: a keyboard pecking game
this is not an ordinary post, see this content at @/peckmania.html.
published on 2020-10-06
# kbd: my experience with the ergodox keyboard with the norman layout
for a very long time i was using a very standard us keyboard with a us layout. it was a das keyboard with the cherry mx brown switches. i bought it about 10 years ago and it still works perfectly. i average about 80 wpm on it. i got the blank keycap version so that i forced myself to not look at the keys. i never learned proper typewriting, so my typing style was whatever that evolved from only using hunt and peck.
but one thing was bugging me: the qwerty layout wasn't designed with efficiency or ergonomics in mind. the staggered rows was annoying me most -- i was really inaccurate for the non-main row keys. so about 8 years ago i learned about ergodox and thought maybe i should try switching to that. the design of that had at least some thought in it. and if i switch i might as well ditch the qwerty layout for something that also had some effort in it. but i never made the switch. i think one of the big reasons was price. it's quite expensive and i would need two: one for work, one for home. but now that most of the tech world switched to wfh, my excuse sort of evaporated, and i could no longer resist the temptation. i got one from ergodox-ez since i didn't want to build my own.
then i had to pick a new keyboard layout too. there were many to choose from: dvorak, colemak, workman, norman, etc. i went with the norman one since that seemed the newest one. and has incorporated the lessons of the previous ones and improved on them.
so i got my ergodox and i installed norman on it. the first few days were miserable. i had less than 10 wpm with it. every keypress needed several seconds of deliberation since i didn't know where the keys were by instinct. i didn't have any muscle memory. it was frustrating to have my thoughts buffered up in my mind, yet i couldn't express them, just very slowly. that actually changed my thinking a little bit temporarily: i thought and coded in a way that required less typing from me. i don't remember how it was different though, i didn't make notes about this.
the nice thing about ergodox is that is super configurable. it has an online configurator where you can set up the keys to do whatever you want. if that's not enough, then technically you could build your own firmware, but i never reached that point. i played a lot with the settings and the key placements. first, i put space on those big thumb keys, but then later i realized it's better if it's on a closer key. i also moved the ; key away from it's default position in norman. i use that key surprisingly often in the vim and tmux context, often with a modifier (in tmux) so i thought it's better on a big fat key.
i also experimented with its autoshift feature. the idea is that if you hold down a key long enough (175 ms by default) then you get the shifted version. the downside is that you can't keep a key held down for an autorepeat. though this can be worked around by disabling autoshift in other layers. i tried using this for a while. i only enabled it for the number row and the symbols. i liked the idea i could type anything without the shift. but i never managed to get the timing right so i made a lot of typos and later i felt it was slowing me down, so i eventually disabled this feature.
but the idea of the autoshift still intrigues me somewhat. i wish there were tactile switches with two levels. if you pressed down harder, then the other switch would activate. so a light press would trigger '4', a hard press would trigger '$'. it's a bit tricky but i think it's not impossible to implement this. on the other hand it might be a be bad idea. one would need to watch their pressure this way too and thus it might end up just a net drag over the long term. but still, it's an interesting idea.
anyways, for reference, here's my current keyboard layout: @/kbdl. i'll keep this up do date as i further change my layout.
i started using a few online tools to track my wpm. every morning i measured my speed and looked at the improvement rate. i even used sites like keybr.com to improve my improvement rate. my improvement rate was about 10 wpm per week for the first 4 weeks. so i could reach about 50 wpm on a good day after a month. the progress since then is much slower. i'm still at around 60 wpm currently.
huge gains in wpm wasn't even my primary goal. i think at the 70-80 range, the typing speed stops mattering, since i can't think fast enough to go at it other than for short bursts. however my goal was to improve my accuracy. i had a feeling that i'm a bit inaccurate on qwerty, and i suspected it was because the illogical staggered layout. but i'm quite inaccurate on my ergodox too. well, it's partly because of the new layout, but even as i got familiar with it, i still make a lot of mistakes, and then i have to retype a lot. this is actually what currently tanks my wpm.
i was hoping the online tools could improve this. but all of them are super forgiving when it comes to typos. they let you go back and fix your mistakes. what i really wanted is something that really drills correct writing. i haven't found one so i started thinking of making my own tool. i wanted an interface that shows me one specific text, and keeps me practicing on that singular text until i master it. this reminded me of the trackmania game from nadeo. it's a car racing game where you get an elaborate track, and you have race through it in as little time as possible. you then get a bronze/silver/gold medal based on your performance. it can even show you your replay in the form of a ghost car. i wanted to have something like this just for typing. i tried searching for "typemania". it had a lot of results but nothing useful. so i decided to make my own html5 game and called it peckmania in order to bypass all the bad results in case someone else is looking for this too.
the resulting game is at @/peckmania.
although trackmania lets you make mistakes and has checkpoints i didn't add support for backspacing to delete the last character/word. i guess i could make something like that, but i didn't bother. i want to be able to learn to type long sentences without mistakes, so i want to make the game as punishing as possible. otherwise i won't learn to slow down to my still accurate writing speed. if i can master this, i could then write even with closed eyes!
i also liked the medal and the ghostcar features in trackmania, so i implemented ranking and typeline. the biggest rank is for 100 wpm. nobody needs to be faster than that anyways. for reference 100 wpm is about 8.3 characters per second. it's quite insane and some people can do even 150 wpm with ease. the typeline is a visualization of a typing run: it displays which key was pressed at which time on a horizontal timeline. you could technically see which sections or combinations were fast or slow.
initially i wasn't sure how will i implement the typeline. i was thinking of a fancy graphical rendering logic using the html5 canvas. but one needs to be very careful to make that look good on all resolutions. after a lot of thinking on how to make it all look nice, i decided i should just stick to black and white text. that's super simple to deal with. implementing fancy graphics can take ages and i'd never finish then. but sticking to a barebones ui allowed me to actually finish all the important features, even if they are all presented in a somewhat non-traditional interface. but at least i completed something.
i'm glad i stuck to black and white text because i can now easily use the whole thing on a monochrome monitor. yes, i'm using a special monochrome eink monitor right now and i have lot of pent up sadness about the state of accessibility on the web, but let me save those for a later post.
when i started on peckmania, i still had two keyboards connected to my primary machine, hence i added support for "save slots". so if anybody else is in a similar situation, they can switch between the slots to track their progress on the different keyboards or layouts separately.
i also wanted to make it easy to experiment with different texts, so i made it easy to import a completely custom level set. i even included a few default ones like german, hungarian, programming. but one can just simply change the text after the hash in the url bar and can train on any text they can enter there.
peckmania saves all the results locally. just like how in old games it was easy to move savedata around, i wanted to have a similar usability feature here too. in the old days the games put things into files but that is a bit hard in the age of the browsers. i realized that one could just simply use the clipboard for this. so i just added event listeners for the clipboard events and manipulated those for the export/import features. i think it's quite neat, maybe this sort of pattern should be more common in the world. i ensured that all the data is simple text, so it's very easy for the users to move it around, or even track it in a version control system if they wished so. if they do that they could even build some custom stats over time.
anyways, my point is that i think i added all the important features i wished and now i can pretty much consider this little game as done. all i need to do now is to practice with it and see if my accuracy improves over time or now. we'll see.
anyways, back to ergodox. initially i experienced some slight discomfort in my thumbs. that lasted quite a few weeks as i was using it. but now that i got used to the keyboard, it's not really there anymore. i think moving the spaces to closer keys helped. that thumb block is really not for such a common key like space. i also feel that on a standard keyboard some keys are easier to reach. the middle fat keys still feel a bit unnatural to press. but maybe with time this will also improve. otherwise, now that i'm getting used to it, i start liking my ergodox. i wouldn't really recommend it for average users, but if you spend all your day in front of a computer in a static corner, i think it might worth a try. but don't be discouraged with the few weeks of reduced productivity until you reach back the same throughput as with an ordinary keyboard. just keep practicing with it.
as for the norman layout: i think it's a good layout once i got the hang of it. more stuff on the main row makes it easier to type english text for me. and i didn't lose all my qwerty skills either. after a few minutes of qwerty typing my brain switches back into qwerty mode and i can type the same as before, maybe with a bit higher typo rate. i don't do qwerty on the ergodox though. i think having two completely different keyboard helps with this switching. but one needs to regularly practice the switching otherwise one is likely to forget about the other layout.
however i still have a lot of trouble when it comes to writing symbols. i guess that's partly because i didn't practice those as much as english. but hopefully with time i'll catch up on those too.
i also didn't remap any vim, tmux or i3 keys. navigating in those became a bit painful but i sort of got the hang of it eventually.
in summary: currently i'm experiencing lower speed and higher typo rate, but at least my curiosity is sated, doesn't bug me anymore. so overall i'm glad i tried the switch and looks like i'll be using my norman ergodox for a while to see if i can get back to a similar performance long term. but this is just my stockholm syndrome speaking so take it with a grain of salt.
and remember, if peckmania is something that you'd like to try, it's at @/peckmania.
edit: i keep some progress data at @/kbdlog.
# update after 8 months:
after 1 month i've reached 50 wpm. after 3 months i've reached 60 wpm. the progress is very slow after that. after 10 months i'm still around 70 wpm with an accuracy about 98%.
what i did is that every morning i measured my speed on these two sites:
but the text was quite random and they were very forgiving when it came to typos. i decided to ditch them and focus solely on peckmania. now i even uploaded a full short story into it, press d1 to switch to it. i'll be typing one line a day and see how that goes. i think that will give me more value over time because i can practice on the same text over and over again even over multiple days if deem that i type a line too slow. i almost managed to finish all the main english lines at 80 wpm with perfect accuracy, some taking multiple attempts over multiple days. there's no point rushing this: i did notice that i can type the same text much faster the next day. i just need to give each line one or two decent attempts each day. i think the text randomness was slowing my progress down. we'll see. in any case i'll no longer track my speed so my morning ritual becomes simpler. the tracking overhead was annoying me anyways.
another edit: i've pretty much reached a plateau and can't seem to reach my normal qwerty keyboard speed on my norman ergodox. even if switch back to qwerty, i become faster and more accurate on it.
i think on a non-split keyboard i'm more efficient at combos. both of my hands can reach any key so it's not uncommon that i use both of my hands to press keys on the same half to type in some harder expressions faster especially when coding.
but still, i think speed is not that important to me. i really like the splitness of the ergodox so i might stick with it even if i'll never reach my old wpm and accuracy.
# update after ~4 years (2024-07-01):
i give up. i'm switching back to my good old qwerty keyboard from daskeyboard.
it's time to quit, sunken costs be damned. :(
published on 2020-10-07, last modified on 2024-07-01
# tscriter: transcription tester, see @/tscriting
this is not an ordinary post, see this content at @/tscriter.html.
published on 2020-10-17
# tscriting: the backstory of the @/tscriter tool
earlier this year i had this crazy idea that i wanted to learn german. i looked around and found smartergerman.com which would allow you to learn german online alone. it was quite fine for a while but i think having access to a private teacher is much better. so i eventually stopped using the site in favor of the teacher, well, at least as long as my job was reimbursing the lessons.
anyways, as i was lurking on a site i've seen that its owner was looking for someone to replicate a tool he has seen online. this tool basically plays you a video, and then you have to enter what you heard. you can keep replaying the audio/video until you got your sentence right. you can also ask for some hints too. the guy tried to contact the owners of the tool he found, but they weren't responsive at all, hence he looked someone to replicate it. he wanted to play around with such a tool and if people like it, he might even add it to his site. i thought that would be a fun tool to work on.
so i volunteered that i can give a stab at it. he even wanted to pay but i refused since i didn't want to deal with the taxes. besides, what i had in mind was quite trivial, i wouldn't really ask money for this.
for this project i came up with the name "tscriter". i meant it as a play on the phrase "transcription tester". i created a github project for it and started implementing it. then we iterated for a while. i implemented some features, and then he gave me feedback. working like this was quite nice. i even added some css after all the prompting. i think it's more motivating if you are creating something for someone rather than when you are creating something for yourself.
however as time went on and he played with my tool, he realized that he wanted to have something different. he wanted the tool to allow entering the full text, and then count the mistakes like in a real dictation. i thought this is also interesting but it should be a separate tool rather than changing what i was working on at the moment. i think someone else also volunteered to him and that someone else did the dictation tool for him so we sort of lost touch after this. but he did upload my tool and asked their users to test it. the results were mixed: some people liked it, some people not. after seeing that, i guess he didn't go forward with adding my tool to his site.
you can check out the tool at @/tscriter. we were testing it with this smartergerman text: @/tscriter#smartergerman.txt
i can no longer see any reference to this tool on his site so i thought i'll delete the project from github and put it on my blog to let it rest in peace.
before i stopped working on the project, i've added a few more features. all he wanted is just audio playback + a text entry box. but eventually i figured out i can easily play back youtube videos, and i can easily fetch the youtube subtitles too. so i added a feature where you point the tool at a youtube video, it extracts the subtitles and let's you type that.
however the problem is that there are very few videos with good quality subtitles. and with google deprecating apis all the time, i'd expect it won't work for long anyways. so i still retain the capability to define custom text. one can either host the texts or just paste them directly into the tool.
overall, it think it was a nice little project, i learned a lot. totally would do it again! try it out and let me know what you think about it!
published on 2020-10-18
# mornings: mornings are my productive time
i had a terrible track record of finishing anything i've set out to do. however i changed four things recently and now i feel quite good about the progress on my little goals.
i often have an idea of a game or a tool that i'd like to see. sometimes i even start working on a demo for it. but once the initial motivation is gone, i just pretty much abandon the project. and then i feel bad about myself, and i wonder what's wrong with me. i usually explain it "ah surely work is draining my energy" and that "all i need to do is retire and then i'll have energy for all this". but then over time i started tweaking things and i've noticed some nice changes. in my case there are four components at play here:
# scope
i had a very simple solution to the scope problem. unless something is clearly trivial and finishable in very little time, i changed all the goals from "implement this" to "write a blog post about this". now all my plans are suddenly feasible without retirement. from past experience, writing down those ideas already give me the satisfaction that i'd get from implementing the stuff. this is also a parenting 101 trick: when the kid wants something that you don't want to give them, often giving them in fantasy calms them down more than enough. sometimes the fantasy satisfies even more than the actual reality since everything looks and feels better in imagination.
i know some people are afraid of writing down their ideas because they "fear" that other people steal them and then make all the money that would be "rightfully" theirs. for me there's nothing wrong with this. that's actually the best outcome! it means that the idea resonates with people and when some other person implements it all then it's like improving the world from an armchair without lifting a finger. as for the money making bit: i have a stable, good job, i don't care about the money bit. actually, i don't even want to care about the money bit. tbf, none of my queued up ideas are something that one could make money with. i just wanted to mention that i wouldn't mind sharing business ideas either. i wish other people would also be less secretive about their ideas. sometimes it's quite hard to talk with such secretive people.
anyways, the point is that my plan is now just to write down more ideas rather than actually try to implement them. i have this single "ideas" plain text file with lots of junk in it. with this approach i think it would be feasible for me to drain it. it always bothered me that this file just keeps growing and i never do anything about it. i'd totally want it to become an empty file. if i can do that, i'd feel like i reached the nirvana. and maybe when i'm old, retired and time millionaire, i can just look at my blog posts and select some idea from there so it's not like that the idea is lost after i got it out of my system.
however i still implement some ideas. but only if i know it won't take ages. ideally something that would only need a few hours, tops few days. i tried implementing fps games in the past but then i abandoned them. nowadays i'd try to implement a single gun, and just reuse the doom maps. so then i don't need to think about content at all, i just need to make the existing content work with my engine, which makes the project much smaller in scope. makes it more achievable if i ever decide to work on something like this. i even wrote about this idea in @/shooter.
# motivation
a problem with some of the longer projects is that i eventually run out of steam. i stop caring about the idea. for one, my little endeavours don't really have a target audience. there's nobody to please, there's nobody that would nag me to finish my goals. i'm aware of the idea of accountability partners, but i never tried that because i'm way too asocial to ask people to care about my silly things.
and besides, with bigger projects is often unclear when is it "done". if you work on a game and you are making everything, you could always add one more feature, weapon, map. or i once worked on a silly programming language but i gave up when i had to start working on its standard library. it felt just much work that nobody would care about anyways.
reducing the scope just enough that i can complete it in a few days helps. then i don't need to struggle with the motivation. however even small projects are often hard to finish especially if i take a longer break (e.g. a vacation) in the middle of it. when i come back, i see all the pending tasks needing completion, and i just can't decide where to start again anymore. it might be analysis paralysis.
i realized i need a rather softer way to get back into a project every time i sit down to work on it. i noticed that breaking down the tasks into trivial steps and writing those steps down really helps. i don't mean breaking down all the steps but just the immediate ones.
i started having a plain text file called "tasks" for my projects. each line in it is a "task". there are two types of tasks:
to keep the format simple, i just simply prefix the latter tasks with '!'. when i start out a project, i map out all the tasks i plan to do, generally in the form of large tasks. i then break the tasks down into smaller ones as i go. e.g. for this blog post i could for instance have the following tasks:
then i just go from top to the bottom and work on the tasks. if the topmost task is a large (!) task, then my task is to break it down and replace it with smaller tasks, that i'm actually capable of doing almost any time. as you can see in the above example, the topmost tasks are simple ones.
in the old times i tried to juggle the breakdown in my head. however being explicit about this really helps. especially being methodical about going from top to bottom, i no longer feel paralysed by the remaining work, since i can see the end right in front of me. and i don't really need to think hard about the next item to tackle at any given moment since that's given too. and it's quite satisfying to see the todo items disappearing as i'm committing my changes. all i need now is to give the project some dedicated time. if i do that, then i certainly make progress, and making progress is often quite motivating on its own.
# time
i believe that the time aspect was one of the most crucial aspects for me. i tried to work on my hobby projects either on the weekends or the evenings after work. but the time available for me was very spotty. the weekend usually didn't work out since i had to tend my family. in fact tending my family even frustrated me a bit since i couldn't use that time for my own stuff. the evenings didn't really work out reliably either. my kid goes to bed at somewhat random time which means some days i have more time, some days i have less, and that was frustrating. especially if i have less time remaining, i don't feel like starting anything since i feel that i won't be able to achieve anything. and besides, by the end of the day i was tired, i was at the lowest "energy levels", least motivated.
when my motivation was very high, i did manage to make some progress in the evenings and on some lucky weekends, but i did not make steady progress, it was just sporadic progress. i thought that my official work is my primary blocker here, and that if i retired, i'd be able to work on these things. all i need is just struggle through my work years. i was wrong.
earlier this year i decided to track my myopia progression. this entails me regularly measuring my focus reach with a measuring tape. later i'll write a post about this but for now the point is that i had a developed a regular habit. initially, while the motivation was high. i measured multiple times a day. then once i got the technique and the logging mechanics down, i wanted to minimize the time i spend on this, so i decided that i'd measure myself once daily.
i've set up a little daily reminder for myself (see the reminder file in my @/task post for my reminder mechanics). so basically this reminder was the first thing i've seen each morning, which meant it was the first thing i did whenever i first sat down in front of my machine. i've noticed that doing this little thing each morning wasn't a big effort.
later this year i got a new keyboard with a new layout (see my @/kbd post). i decided to track my typing speed once a day in the morning too. so each morning i measured my eyes and my typing speed. those were my "dailies". i found it actually quite nice to have something "done" each day. and i could do this even on the weekend mornings if i decided to wake up before everyone else. so i decided to wake up around 6am every day or a bit sooner if i could manage. in the summer times it's easier for me to wake up earlier thanks to the sun. but this meant i couldn't stay up too late, so i started having a "go to bed alarm" too and i went to bed at 10pm every day.
so there i was, up early in the morning and i could see from my apartment window that all the other people were still sleeping. it was quite a nice feeling being awake alone in the world. it felt like the right "me time". it felt like this is the time i should be doing something productive. so i decided to use these mornings to make progress on my personal projects.
it worked out great. it turns out i'm a morning person, mornings is when i have to most energy, morning is when my motivation is at the highest levels. and in the mornings i have more time flexibility too. if i need a few more minutes to finish something, i just start my work a bit later. in the time of the work from home this is quite easy to achieve.
# routine
i started doing this morning ritual for my todo items when i was setting up a new raspberry pi for my new eink screen. this contained lot of tasks, including tweaking xterm source so that it completely ignores colors on this machine. delving into a foreign codebase is a bit scary for me, but breaking down the tasks into very manageable pieces like "download the source", "build it", "make it work", "grep for color", etc really helped to maintain momentum. and i did all this before checking my emails or todo items for the day. avoiding the reality in the morning helped me to focus on my tasks, i wouldn't start obsessing about the daily churn that i have in front of me.
once i was done with the setup, i decided to use my mornings to finish @/peckmania. that worked out great too. then i decided to make a tool for myself to better manage my issues at work. it worked greatly, i managed to finish what i've set to. working on small little projects in the mornings became a routine. i'm writing this post in the mornings too.
and it was a good routine: it meant that every morning i achieved something, even if a little thing. it also lightened my mood, i felt a bit more productive at work too. i no longer had "zero days" where i achieved absolutely nothing which usually led to feeling a bit sad afterwards. if i missed a morning, i felt an uneasiness until i did my dailies.
there's another thing that really helped to not break the routine so far: not trying to do large things in parallel. if i want to read a book, watch through a tv show, play a video game, now i queue it up as "project". i just consume such things after i finished my current project. and i do them primarily in the morning. this way i have much fewer regretful thoughts about what i should be doing instead while binge watching a new anime. i know that i can enjoy that show or game without regret, since i'm between little projects, so it's like a mini holiday that i earned for myself.
eventually i picked up a few more routine habits over time. since i'm in switzerland, i feel like i should have some german comprehension. therefore i'm reading a page or two of german text every morning and then look up and write down all the unknown words i encounter in it. i use the online linguee site for this and with my eink screen it's quite nice that i still don't actually have to look at some bright screen in the morning. my computer time in the morning is almost like reading a book. hopefully over time this will improve my german vocabulary and i'll be able to navigate this german world a little bit better. actually this became the first routine i do in the morning, since some slow reading and writing is a very nice way to wake up.
in the old times, while i lived in dublin, i used to walk a lot every day. that's no longer true in zürich, especially now with all the work from home. so i decided to reinstate some morning walks in the nearby small forest. the fresh morning air is very nice. i just wish the forest was bigger so that i could walk more.
i also changed my evening structure. in the old days i just used to watch youtube or read the internet until i got bored and went to bed. for one, i now go to bed at 22:00 quite punctually. but before that i try to avoid the computer from 20:00 or so. i just take my notebook and freeform write into it about anything that comes to my mind, basically reflecting. i just really like the feeling of freewriting. this usually involves thinking about future plans and what i should be doing. a lot of good things have come out of this. i decided to do that german reading practice after hours of thinking what easy and fun thing i could do to learn some german. even deciding to start walking again was thanks to a lot of reflecting. without all this reflecting i feel like i'm on autopilot and never really consider trying new things, so i really need it. another benefit of just simply writing rather than consuming something is that it helps me start feeling tired sooner which in turn helps fall asleep.
though i'd add that this doesn't mean that i never procrastinate. sure, i do that when at work and i'm unsure what to do. however i don't procrastinate in the mornings, and that's the important point here.
# effect
when i add together all the things i mentioned above, they do magic for me. i think if i were to take to away any component, my system would fall apart. but thanks to them, i feel quite good about my days, i no longer feel that "only if i'd retire, could i really achieve my goals". progress towards one's goals can be made anytime with the right habits. one just need to find them with lots of reflection.
published on 2020-11-25
# slowpals: a penpals site idea
i really like discussing various ideas. i especially like when people challenge my views since that means i can sharpen my arguments or perhaps change my views.
however doing this in an online discussion forum is quite exhausting. if you post something dumb in a public space, then you get lot of responses, some of them mean even. it's infeasible and pointless to respond to everyone. even if you do, you might still get another barrage of responses to any of your replies.
one solution to this is to avoid public discussions. private discussions are often more fruitful because you have more time and energy to focus on really understanding that single person's perspective. you'll be more likely be able to stand in their shoes if this other person is open to invest the energy to make this happen.
for online discussions i believe plain text emails is a good way to discuss. this means what you need is a good penpal finding site rather than a forum. since one doesn't really want to reveal their email address nilly-willy, ideally the platform would allow exchanging messages through itself. however even with penpal sites, it's very likely that you send a letter to someone, and then you don't get any feedback or response to your letter, and then you don't know if you were rude, or if your partner just lacks the energy to respond. ideally there would be something that incentivizes users to respond.
so here's an idea for a penpal site that i think could be quite trivial to implement, and requires almost no resources even. this would an online platform that could easily scale up to millions of users and still be operated from a small raspberry pi because you could outsource many of its operations to free online services. i'd totally implement it myself if i knew of a couple folks that would sign up.
it would consist of two parts: a static online site that lists all the profiles along with the profile data; and an email address through which one can interact with the platform.
the static online site would be a plaintext document (hosted on e.g. github) that just lists the usernames and their profile text. i wouldn't bother with profile pics and whatnot, plaintext should be enough.
then i'd have an email address, e.g. slowpals at gmail, and the users have to register and talk to others through that address. e.g. an user wishing to register could send an email to slowpals+admin at gmail with a title "register <usename>" and with their profile text as the body. then a script would process this email and upload their profile to that online site above. (in emails everything after + is ignored, so you can use that for such tricks.)
now comes the interesting part: exchanging messages. suppose alice notices and likes bob's profile. she can start a conversation by sending an email to slowpals+bob at gmail. slowpals will then forward the email to bob's private address. however there are three important rules that would make this interesting.
my goal here is to artificially "slow down" conversations in the hopes that they remain more civilized this way. rather than delivering all the messages at send time, slowpals would queue them up, and deliver them one at a time. each user would have a first in first out queue. so if charlie also sends a message to bob, bob will receive the message from charlie only the next day after he responded to alice. and bob can expect a response from alice: the only way to not receive one is if alice decides to not use the site anymore. alice will not have access to the rest of the members until she responded to bob's email. this also ensures that one doesn't get a barrage of emails. one can expect that on this site one only receives a few messages, and that one will never be overwhelmed by them. in fact, this platform degrades gracefully: if you stop responding, slowpals will stop nagging you, it's as if you simply deactivated your account and i'd even delete your profile from the public listing if you didn't respond to an email for a month.
there's one point to note: there should be a way to end conversations so that they don't go forever for no good reason. it should be possible to annotate messages for which you don't expect a reply. the same way it should be possible to report spam messages. i'm thinking of using the first line of message for optional directives. e.g. for a message like this (involving slowpals+alice and slowpals+bob):
!noreply hi alice! it was nice chatting with you! cheers!
alice wouldn't be expected to respond. she would get this email and the next day she would get another one regardless if she responded or not. that day she can start a new conversation with another member instead.
note that the oneaday rule makes it hard to start new conversations when your queue is not empty. i think this can be considered a feature rather than a bug. you should make the most of your existing conversations and you should respond promptly. most people are quite lazy when it comes to emails, so eventually your queue would drop to zero, which would also allow you to start new threads.
the slowness might be annoying when you start to like the other person. however in that situation you can exchange your real email address and you can have your discussions in real time.
and it would be quite easy to implement this site since the email queues would be stored in gmail. all i need is a daily cronjob that processes these emails and forwards the messages according to the above rules. and after i forwarded a message, i can simply delete it from gmail. it's quite nice from the user data perspective, since i only need to store queued emails. the only sensitive data that needs to be carefully maintained is the password to this gmail address and the username to email address mapping.
to keep this simple, i'd probably also enforce a plaintext rule: if you send an email with html or with attachments, i'd just simply reject your email. i'd limit the message size to 100k too. and i'd highly encourage people to strip the previous message from the body since i really don't see the value of that in this context.
with such rules i'd totally try participating in such a community. i don't think anybody reads this blog but if you do and you like the idea of such a penpal site then let me know. then i might be motivated enough to build it. or if you know that such a site already exists, then also let me know, i might sign up.
published on 2020-12-02
# postmore: blog more and link posts to keep discussions shorter
when i partake in some philosophical email discussions, i tend to write overly long emails. and usually such emails contain thoughts about multiple topics. this can be quite exhausting for the recipient to read and respond.
often those subtopics could be a blog post on their own. while i appreciate the nuance and understanding that comes from 1:1 discussions, there's no reason to limit ideas to two people. ideas are meant to be exchanged! maybe twitter was right: one should keep the direct messages short. instead we should write more on our public spaces and simply link them in discussions. when a reader wants to respond, they can just write their own public post. not responding to a public post feels less rude than not responding to a direct message. it feels much easier to ignore a link than a long passage of text in an email.
this is not the same as a forum discussion. first, forum posts are in a context of a thread, while a blog post ideally stands on its own. you can't just write "this is dumb" as a post on its own. second, you can disable comments on your own blog, and then you'll get less responses so you'll have to worry less about them. besides, more often than not, comments bikeshed about the small points, or the specific metaphores you used, rather than talking about the overall message of the post. this then makes the comments section not a very informative place. if one has an insightful addendum or rebuttal, they should write a post on their own, notify the original author, and that author should link to that post in their original post. this is a lot more effort than comments, but i think the resulting quality is worth the effort over the long term. it also limits the amount of the content associated with each post which is rather quite an underappreciated quality these days.
in other words i'm suggesting that people should blog more. sure, more posts mean less quality and more half digested ideas. but i think that's fine, the posts don't have to be perfect. maybe over time you learn more and completely disagree with your old posts, or maybe even regret or are ashamed of your old posts. i think it's still worth to keep the old posts, so that people can see how you changed over time. you can simply edit that old post to include links to your updated views. eventually we'll all die and everything will be in vain, so in the end there's nothing to lose by opening up a little bit and writing about the thoughts swirling in one's head.
i'm actually trying to convince myself to write more with this post. i have a lot of small things that i just want to see written down somewhere publicly. most of them are possibly dumb things that i'm somewhat reluctant to share. but maybe i shouldn't be and i should still make a post about them even if it's like a one sentence's worth of content. even this post fits that criteria: i don't really have anything interesting to say here, and yet i'm already in the 5th paragraph. actually, this post is very similar to the freewriting i often do in notebooks. just jotting down thoughts one after the other as they come. now that i'm doing it for a long time, i see the psychological benefits of having a much calmer, less stressed mind in general. so i might as well do it in the form of posts more often. and others should write more too!
published on 2020-12-04
# goldentesting: an alternative to unittesting
ugh, i really hate unittests. they might look nice for some trivial cases but for modules requiring more complicated setups and dependencies they just feel like boring busywork. and every time i want to make a change, i'm now required to maintain the unittests too. sure, they catch an error sometimes, but more often i'm making an intentional change, and now i have to implement that change at multiple places. i often dread making changes because i don't want to deal with the weird unittests some projects have.
but here's the good news: i firmly believe all this unittesting madness will go away when people learn that there is a much better alternative: goldentesting. i think that's the most common term for this. but i heard the terms of output testing or gold master testing too. the primary reason it's not super common yet is that there's no good generic tooling for it. but i'm pretty sure tools will slowly get there. though it's used in some niche areas for a very long time already.
the unittest idea is this: you write code and litter it with assertions. the goldentest idea is this: you write code and emit text to stdout. during code review you just need to review the diffs, you don't need to maintain the assertions manually.
suppose you write some c++ class like this:
class mystring { ... };
unittests could look like this (oversimplified):
int main() { mystring s("helló"); assert(s.length() == 6); assert(s.size() == 6); return 0; }
goldentests would look like this (oversimplified):
int main() { mystring s("helló"); printf("%s length %d\n", s.c_str(), (int)s.length()); printf("%s size %d\n", s.c_str(), (int)s.size()); return 0; }
running this code would then output this:
helló length 6 helló size 6
you might be inclined to commit this output next to the code, but that's a bit spammy. however this is where better tooling could come handy: that tool could run the test binary at both old and new versions, and then just present you the diff that you and the reviewer must explicitly acknowledge before merging.
for example let's assume that some user comes along and wants that the length() function should be unicode aware. if you simply make the change in your code then both unit and goldentests will fail. the unittest will fail with an assertion that you then have to manually fix. the goldentest will present you this diff:
-helló length 6 +helló length 5 helló size 6
all you and the reviewer needs to do here is to acknowledge the diff. the commit itself doesn't need to be littered with the test changes. after the merge, you don't need to worry about this diff anymore.
you don't even need to hardcode that "helló" string. it can come from from the stdin. then you can easily create multiple testcases simply by running this test binary on multiple inputs.
what is the function of the tests even? i believe there are two main functions: increase our confidence that the code is correct, and to catch inadvertent regressions. i claim that goldentests can do both with greater ease.
how do you get confident that your code is correct in general? you usually write some code and then check that it is doing the expected things. with goldentests you pretty much stop here and commit. with unittests you go one step further: you add assertions for those expectations. basically you are setting up a trap for future maintainers to painstakingly maintain your assertions. in the goldentests those assertions are still there but rather in an implicit manner so it still achieves the same goals.
and they are just as effective catching regressions as the unittests. you just need the right tooling to enforce the same standards for goldentests as for the unittests.
goldentests scale much better for larger codebases. suppose you are maintaining some logging library. and now you suddenly want to change its output format. more likely than not, in the unittest world there are assertions that are asserting your very specific line format for some reason. if you want to change the format, then you have to create a massive change that changes all such tests too. with goldentests this will just create a massive diff. however chances are that the diff will be very redundant and with some additional tooling (again, more tooling) you would be able to canonicalize all the diffs and you would end up with a small diff that you can easily inspect and determine that your change doesn't change the logic, just the output format.
goldentests are more generic too. for instance you could use it for compiler or linter warnings. one of the generated output files could be warnings. the diff tool for this would be smart enough to remove preexisting ones. so whenever you are working on some code, you would only see the new warnings that you introduce. sure, sometimes a warning is wrong (otherwise it would be an error), this method lets you acknowledge the warning and still commit, without adding silly "nolint" comments to silence the warning forever. the warning will be silenced automatically from the point of the commit. if the reviewer thinks this is undesired, they can ask the change's author to add a todo to address the warning in the future. this shines the best when you want to enable a new warning for your codebase. you can simply enable the warning and ignore the resulting diff. nobody will see that new warning for existing code, so you are not adding a large burden on others suddenly. the warning will only appear for new code which people will then address. and the warning is still in the full generated file, so if you want to clean up the whole codebase yourself, you can just simply fix the existing instances one by one and see that the number of warnings go down over time.
there's a practice of writing tests first, code later. goldentests work for this too! you can simply write down the expected output of your test app, and then keep hacking at your library and test app code until you get diff neutral. you can write down the expected output without code or compiler. maybe your teammate can just write down sample inputs and sample outputs, and you can readily use that, no need to put it into assertions.
if you ever done coding competitions (acm icpc, topcoder, hackerrank) then that environment is totally like this and it's quite a satisfying environment, especially when you see that your code passes all the tests. when you solve a problem there, you are usually pretty confident about your code. and all they needed is some sample input and output text files. furthermore all such testing is independent of the programming language. with diff testing you can decide that you'll rewrite your slow python script into some fast c++ code. with unittesting it can be quite hard to see that your rewrite had no effect on the logic. with goldentesting all you need to verify is that the diffs are neutral and then you'll be pretty much confident about your change.
at work i decided to write a little script that parses a schedule file and outputs a nice text calendar to visualise who is on duty and when. actually, such calendar visualizations already existed, what i really wanted is to visualize the diffs in a calendar whenever someone is making a change to the schedule. such a tool didn't exist before for these schedule files. so i wrote a tool that parses and compares the old and new schedule files, and then displays a calendar that has the differing days highlighted. this is an example of one writing a special diffing tool: most of the time the total state doesn't really matter, all we care about is the diff. but that's not even the point: my point is that i didn't write any ordinary unittests for this tool. all i did is that i hand written some sample inputs (old+new file pairs), and just committed the generated output from them since there's no good standard tooling for tracking golden diffs so far. i kept adding inputs until i reached very high code coverage as reported by the coverage tools. when i reached that, i was confident that i handled most edge cases. and obviously i carefully verified that the output is what it should be for all the sample inputs.
it worked out great. the most utility came after i released the tool and people pointed out that i made a few wrong assumptions about the schedules. so whenever i fixed a bug, all i needed to do is to add a new sample input to cover that case. or if it altered the output of an existing case, it was very easy and obvious to see what was the effect of my change. i usually don't get such a visceral feedback from unittests. or sometimes people wanted me to alter the output a bit. that was easy to do: i made formatting change and in the diffs it was easy to see how the new format looked like. i still love maintaining this piece of code because it's super easy to make changes in it while maintaining a high confidence in its correctness.
another example of such an environment would be the deployment configs of the service of the team i worked at once. this was a huge service consisting of many binaries running in many locations. the system that runs these binaries needs the configuration in a very denormalized manner. so in the end we need to have (binaries * locations) number of configs. to generate those configs we obviously use lot of templating. there is a shared template but then each binary must customize that (e.g. different cmdline arguments) and then each location can have further customizations (e.g. to test something in a single location only). how would you test something like that? you can't really. e.g. you set a new cmdline flag for a binary to launch your new feature. do you add a test into the configs that a flag is set? that would be pretty dumb busywork. what we had instead is that for each change we just generated all the old+new denormalized configs and then you inspected the diffs and verified that your change does what you expected. however on its own there would be massive diffs just because of the sheer amount of binaries and locations we had. e.g. you make a cmdline flag change in a binary's config and now you have 30 files with a diff because we have 30 locations. so we had a tool that canonicalized the diffs (replaced references to location names with a placeholder string), then it hashed the diffs (just the lines with a diff, unchanged lines didn't matter), and grouped the files into buckets based on their diff hash. this worked out pretty nice since each cmdline flag was on their own line. so what you actually need to do is to review a single diff because then you can be sure that the rest of the diffs are the same. if a single location has some special logic on the flag you are changing and the diff looks different then that diff will go into a different bucket, so you'll notice that too. (sidenote: it's true that in this system weird overrides can silence some diffs, but this could be combated with good discipline called "weird needs to expire". so all such weird overrides must have a clear deadline associated with them at which point somebody will follow up and hopefully remove it.)
anyways, the point here is that i quite liked working in this system simply because my confidence was very high in it. the configuration pipeline was quite a mess and sometimes very hard to understand, but at least silly unittests weren't getting into my way whenever i wanted to make a change. i just made a change, looked at the diff, and if it looked right, i knew it was fine. this also made the review much much easier. sometimes people implement quite complicated logic to achieve a thing. but i don't really need to obsess too much about the logic itself. all i need to look at the result and if it looks right, i'm not anxious about approving something that might be wrong. even if it's wrong, i can see that it works for the cases we care about, so it doesn't need to keep me up at night.
there's one caveat to this. if you generate such a golden output, make sure the output is deterministic and easy to diff. if you want to output a list then sort it and output the entries line by line. randomly ordered output would give you lots of spurious diffs that no human can easily understand. with too much info on a single line it's hard to see where the diff begins and where it ends. often you want to make a change but then see that the diff is hard to review. to alleviate this issue, if it appears, you can just prepare another change that changes the output such that it will make your subsequent change easy to review. e.g. you make change that sorts a previously unsorted list. two small focused diffs are often much easier to review than one larger one that does too many things at once.
however there is one significant area where golden diffs are really lacking in tooling: interaction tests. maybe you have some client server architecture and you want to verify that the interactions between them look good. here's how i imagine testing such a thing. let's assume we want to test a client's interaction with a server. ideally there would be a tool that can record the request/reply interations. so first i'd run my client against the real server and i'd record the interactions. then there would be a tool that could act as a fake server with some preconfigured request/reply behavior. then during the test i'd just assert that the interactions against the fake server are exactly the same as in the golden recorded interactions. these interactions would be committed along the code, since during the test it would infeasible to bring up that server. if the test interactions don't match, i'd rerun the recording tool to rerecord the interactions against the real server and commit that. so in the review one could see how the interactions changed too. this is quite similar to what happens in interaction unittests already but there people manually copy paste the interactions into assertions. in this solution that would be replaced by running a single tool.
now as with all things in life the question between explicit asserts and implicit diffs as tests is a question of tradeoffs. assertions have their place too in some cases. e.g. when you know there is no point in continuing some logic then sure, assert it away. and then maybe you can enforce that all tests must run successfully to end. so basically you have a bit of both. but i really hope that over time the tooling will improve just enough that this idea will catch on and then hopefully life will be much easier for code maintainers in general.
now it's true that acknowledging a diff is much easier than painstakingly update an assertion or expectation. so chances are that this might lead to more mistakes. however i'm not convinced that we should avoid mistakes at all costs. rather, we should strive for an environment where mistakes are cheap. changes should be rolled out progressively, changes should be able to easily rolled back, and so on. then we can focus more on the useful, new developments, rather than doing busywork with maintaining silly assertions.
i've tried talking with a few folks about this. so far i managed to convince nobody about this idea. fortunately this theory of mine would be quite easy to "test". i mean a sociological experiment on developers. you devise a project that a person has to finish. you make a version with goldentests and a version with unittests. then you divide people into two groups: one gets the goldentest one and is instructed to continue with that, the other one gets the unittest one and is instructed to continue with that. after the experiment you run a survey on how easy it was to work with the project and how confident are their about their code's correctness. you also review the time it took to finish the project, and also review their code to see how many mistakes they missed. i predict that the goldentest group will take less time, will be more confident about their code, and the correctness rate will be just about equal. the only problem is i'm too lazy and inexperienced to run such an experiment. i hope one day someone runs it and then we'll see if i was right or not.
published on 2020-12-06
# briefquiz: a fun, personalized challenge for some kids
in @/challenges i mentioned an idea of a challenge event i could run. but lately i was thinking a bit about it. perhaps that idea is a bit too impersonal, too steep as a starting point. i remembered how i all started developing my interest in computers at about an age of 10. there was actually a "competition" aimed at my level. you could sign up for it and then they would send you some questions via snail mail. then you would anwser them and send the answers back via snail mail. i started participating in this. but when i was starting, i didn't really know the answers. so one of the infotech teachers in the school started helping me. we worked through the problems together.
two things happened here: first, the letter format was a very good, soft introduction to the world of computing. second, i basically got a mentor out of this. i spent a lot of time at that teacher. i ran to him even between classes so that he explain some questions to me. i'm not sure why he invested so much time in me (i took away his breaks after all), but i'm glad he did, since it helped me significantly.
so based on these observations and my previous ideas, i think i'd want to make a challenge site that consists of two parts. there's a "qualification" phase that is done purely through email, and there's a "challenge" phase where the participants demonstrate their skills in person a bit similarly to what i described in @/challenges.
i think the qualification phase is important to light the fire in the kids' hearts. i imagine it as follows: a kid (or even adults if they wish) would sign up for my site. then i'd send the kid some easy questions. e.g.:
then on later rounds the questions would become harder:
and stuff like that. about 2-4 questions per round. i'd expect that the kids send the answer back in an email. and i'd limit the answer to 300 characters, they would need to fit their answers into that limit.
the kids can use any help they need, i wouldn't really care. and then i would answer each email individually. depending on the letter i might even get a bit philosophical: for example if for that information lookup question i get a googling answer, i might respond that using teachers and mentors is also a good source, and for some type of questions and problems, it's the only source. if they didn't answer the questions correctly, i might ask them why did that happen, otherwise i'd just send them the next set of questions.
if they persist through the qualification rounds (about 4-5 rounds) i'd introduce them to the "challenges" where you have actual coding tasks. i'd create 90 static "challenges". 90 because i want to refer to the challenges as a number starting from 10. keep in mind that these would be relatively easy challenges, wouldn't go deep into the algorithms. the idea is to keep them relatively easily achievable, so that the kids can get a sense of achievement, that would lead them to start studying these things deeper, and maybe go on to the more mature national contests to further hone their skills. and the challenges have to remain relatively easy, so that their cs teacher can easily work with the kids.
i'd make about 10 shell scripting tasks, about 40 c tasks, and about 40 javascript tasks. i think i can cover most important things with that. the c and javascript challenges would be very similar so basically i would be asking them to implement the same thing in two entirely different languages. the challenges themselves would be public, anybody can read and prepare for them on their own. think of relatively easy tasks, like guess what number i'm thinking or draw a large ascii art christmas tree.
however the act of solving these tasks wouldn't be conducted online. we'd probably go to a computer lab after school together, and i'd expect that the kid demonstrates writing the solution without any help. i wouldn't allow any references. they shall memorize the syntax and the function parameters. on the other hand they can try any time and retry any number of times. so there's no pressure. and to save time, they can do any number of challenges per session. even one challenge per session is fine. the challenges are intended to be easy enough that one can solve multiple ones in a short amount of time, depending on their experience. if they manage to solve the problem without help, i'll consider their challenge complete. they can now either try another one, or go home to prepare for the next one.
i'll keep their solution for myself, and after the session i'd send them a review of their solution or suggest improvements. and if somebody manages to get through all the 90 challenges, i'll add them to a "hall of fame" somewhere on the internet or maybe even to a physical poster somewhere (e.g. on a school wall).
i also figured out how could i start the whole process: when my kid becomes school age, i'm pretty sure there will be parent-teacher meetings. i could ask the teachers on such occassions if they were willing to advertise my challenges to the older kids. starting with a single school is fine, and from that on, i'm hoping to rely on a word of mouth. if that doesn't work out then i need to improve my product until it does. i wouldn't want more few kids signing up for this though. more than a dozen would be too much. if i get more, i'd just increase the difficulty of the qualification questions to cull the less motivated ones.
or maybe rather than using emails, i should stick to letters via snail mail to cull out the less motivated ones (the ones lazy to go to the post office). physical letter exchange might actually give it some extra excitement, and it also allows me respond relatively slowly, so that i can keep the pace of the whole thing is relatively slow. this also requires some token amount of money to participate, so i would be somewhat protected from spam or from a suddenly very high subscription rate.
and i could run this here in switzerland even if i don't speak german well. i can just keep everything in english and let the kids deal with the english rather than me with the german. at least they would have some extra motivation to learn english. although i'd probably accept german answers too but i wouldn't document this.
and i would only accept people from my local city. i don't really want to deal with people that i can't meet personally. i just want to give some interactive game for the local community.
more specifically i just want to give opportunity to kids similar to what i received as a kid and more. i very much wanted to get my schoolmates into coding too, but nobody was that much interested. even if i managed to get some people into this, the competitions were way too fierce for them to keep along for long. my hope with such a forgiving place would be to keep them interested. the only way to lose is to give up rather than being plain unlucky or not smart enough. the kids can even prepare each other for my exams.
i know that there are nice online communities like khan academy. but i can compare my experience with online and offline competitions: offline competitions, one where i actually am next to the others were usually a more exhilarating experience. a person giving you some recognition in front of others feels more exciting than watching a robot telling you that you did good while you sit alone in a dark room, isolated from the world. i just want to try giving such an experience for the next generation. i think this idea could totally give that with a really little effort. but it still requires effort from my part, so we'll see if i ever start this.
published on 2020-12-09
# typer: my wish for laptoplike device i'd like to exist
i don't usually use laptops, i much prefer the static desktop setups. but i sometimes i do dream about what my ideal mobile computer would be. my problem with most modern devices is that they run these ultracomplicated operating systems running all sorts of processes on it. it bothers me because it uses up energy and battery unnecessarily.
i wish for a machine that could last for weeks or months on a single charge. ideally something that doesn't consume any energy if you don't interact with it. the kindle is almost like this however it's screen has a too slow refresh rate so it's a bit limited for interactive use. and besides, even kindle's system is full of unnecessary stuff. it runs linux which pretty much means it's full of unnecessary stuff.
my primary usecase for such a device would be writing and text editing. so i definitely need a good keyboard as well. phones and tables are out of question. they have their place though: i think kindle is quite good for reading. for keyboard it would be nice if it were splittable just like ergodox. most ideal would be if the two halves could be snapped together to act as a single keyboard like on ordinary laptops too. the screen should be detachable too. it should come with a small tall stand that i could put it on so that i don't need to unnecessary hunch to use it if i have access to a proper desk. by detachable i don't mean wireless: i don't mind having the screen and the keyboard wired.
as for the screen: i don't need colors. i think my ideal screen would be those old monochrome lcd screens that old calculators had. those lasted quite long on very little battery. and those worked quite nice in sunlight without any backlight too. and i don't need a large resolution. something like 640x480 or in that range would be more than enough. hopefully this wouldn't drain much energy in general.
but still, what about the operating system and the cpu? how could i have a very dumb system but at the same time still have access to the modern world of compilers, internet and so on? i think this laptop needs two chips:
i think this dual system could work quite perfectly. using a dumb microcontroller for the primary interface means that you can really minimize all the unnecessary stuff to a bare minimum without needing to deal with the complexities of a full modern system. and ideally this microcontroller wouldn't consume lot of energy, nor would the keyboard or the screen, so i could easily use this device for a long time. sure, the text editor would have limited features, but that's fine. i don't even need wrapping support thanks to my semantic break style.
i could even code like this. for instance i'd implement some big function. then i'd activate the mini computer. the linux on it would quickly boot up, write my in-memory edits to disk, call the compiler and write its error messages back to another in-memory file, and then simply turn itself off. now i can fix all those errors one by one without running the full computer, without draining the battery. once i'm happy with the changes, i can turn the machine back on to compile again and maybe push the changes to, say, github. ideally the microcontroller would be programmable, so, for example, i should be able to run a light c syntax checker on it to save me activating the full computer before i fixed all the dumb errors.
even email reading would be quite nice (assuming people do plaintext emails). the process would be this: turn on the mini computer, it fetches the emails and writes them to the in-memory fs, and then it turns itself off. now i can read them at my pleasure, maybe even prepare some responses.
and since the battery could last for weeks maybe i could go into the woods for a week long fasting retreat into a forest or onto a boat for maximum silence and this little device (along with a kindle) could keep me quite entertained without the need of a big energy source.
and i suspect it wouldn't be too complicated to build such a device. maybe one could hack it together with some preexisting components. but to be fair, i don't have any hardware experience, and i don't really have a big need for such a device (i'm not mobile -- i spend almost all my life sitting at home) so i'm unlikely to ever attempt to create such a device. i'm just saying it would be nice if it existed.
published on 2020-12-11
# dialog: a silly dialog tree, see @/optioning
this is not an ordinary post, see this content at @/dialog.html.
published on 2020-12-29
# optioning: another way to have interesting conversations
i'm really bad in conversations. in real life i tend to be too silent and superficial. in emails i tend to write too much, sometimes being too insensitive. i'm pretty sure i often overwhelm the recipient with the quantity because i often don't get any replies. and my writing style is not very coherent, i just keep rambling about random stuff. reading my writing is probably quite hard. and often people don't even like to write, so then i'm having hard time to communicate with such people.
i think there are two big problems with my art of communication. the quantity problem: i'm tempted to ask too many questions. it's pretty much infeasible to answer them all in one message. and even if you were able to do, you have to go question by question which makes the email to have a very unnatural format.
then there's the quality problem: some of the questions are very hard, that nobody knows the answers to. the recipient has no idea how to respond to such a question, and as such is very discouraged from responding at all.
i think i found a way to address both issues. rather than asking all the questions in one letter, i focus on asking a single question. if i have more, then i might start tracking the list of questions or topics that needs further discourse, and simply ask them at a later point. furthermore i also provide 2-4 answer options and the recipient simply must choose the least wrong answer with an optional comment.
i don't think one needs to obsess about the answer quality since the expectation is to choose the least wrong. i'd expect people would mention a better answer if they have in the comment. the point is to force people to make a decision. in case of indecisive people you can pretty much bypass the indecisive consciousness and get an answer right from the subconsciousness. for your email partner the whole thing is like one of those conversational adventure games (e.g. telltale's walking dead or life is strange).
however the downside is that this is much harder on the questioner. they really need to think a lot what single question would be the one that uncovers the most information for them about the other person. it's an intriguing puzzle game. it's somewhat similar to debugging computer programs. but here you are debugging humans. you create several hypotheses and the other person tells you which one is the closest. or it's like that "hot and cold" kid game where you hide something and the kid has to find it with you converting their distance from it into temperatures.
(edit: to generate good answers, the questioner needs to put themselves in to the answerer's shoes. they questioner must see the question from the answerer's perspective. i think this can bring a lot of clarity to the questioner, and thus gives a big boost to feeling empathetic to the other person.)
it's a very slow process but if one has patience and the other person is willing to play this honestly, i think one can learn quite a lot of deep things about the other person. and it's very easy to start. you start with something like "how are you these days? good/bad" and then the rest of the questions sort of give themselves. e.g. "what makes you happy/sad these days?" for the above one. if unsure, you can always ask "why?" for the previous answer and try to come up with some realistic answers to it.
i think it's important to play this over email rather than instant messaging. sometimes it might take several days to come up with the next question or even with the answer. email supports labeling and threading by default so it's the best medium for slow communication.
such a discussion could be almost neverending. however given the fact that one could go at it very slowly, that shouldn't be too much of a problem. one could easily talk like that with multiple people if they are not bothered by the fact that the delays between the individual messages with a given person will keep growing. also, if you have lots of questions that you want to ask a single person, you could have multiple parallel threads with them. though i'd expect that could be quite strenuous to maintain.
to give a small taste how this could look like, i've created a demo about this at @/dialog. it's just a dumb dialog tree. it obviously cannot have as much nuance as a realtime conversation could have. but it was quite fun to write it. it was quite tiring to write it though so therefore it's very short.
btw, this idea could take many other forms. for instance that dialog tree from above could be a collaboratively edited one, implemented similarly like a wiki. that way it could grow quite big. with some sort of trusted peer review it could stay quite sensible. or one could make an app for it, that keeps asking you questions very slowly. and then its developer just keep adding new nodes based on the stats where the most people are stuck currently. the developer's goal would be to split people along the nodes as much as possible. or maybe one could make a live tv interview show where the host comes up with good questions that both the viewers and the interviewee tries to answer. first the interviewee tries to guess the viewers response, and then analyze those results. i think this could give a good insight how someone thinks since they have to put themselves into other people's shoes. the socractic method has similarities to this method too.
i'm not sure what the name of this technique would be. i went with "optioning" since the primary task is to give options to the other person.
anyways, at least i now have a new technique in my toolset, maybe i'll use it one day too.
published on 2020-12-30, last modified on 2021-02-08
# grow: thoughts about mentoring and schools
i feel that there's still a lot of undereducation, even illiteracy in places where things should really be much better. it seems to me that there are people who are not that interested in education and the more civilized way of life which in turn leads to another generation of theirs with the same qualities. often these people have completely different culture and lifestyle compared to the traditional western people. the traditional education experience simply doesn't work for them which is a loss for both them and everyone else in the society.
by "traditional education" i mean something where kids go to school, passively learn a fixed curriculum for about 6 hours a day (they sit at their little desks and listen to the teacher all day long), and then get examined and so on. people then keep repeating classes until they get a passing grade, or get bored of the school and simply don't go anymore. usually such classes contain a lot of people which causes problems around managing the classroom and around the boredom and the pacing of the material.
every person develops at a different pace, has different interests, needs different environment for effective learning, needs different psychological support to make sense of the world. i think the traditional one size for all system doesn't really scale well to diverse groups.
we also need to acknowledge that not everyone wants to be a doctor, engineer, professor, or something other that needs high education. some people just want to stay at home (e.g. to raise kids) or just have some simple non-demanding job that allows them a comfortable life. given the technological prowess the world has, it should probably be fine to not work at all.
i think the only things that everyone should know are the following:
i think that's about it what we should universally expect from all the people. anything on top of that should be at the person's own discretion. most of the above cannot be tested with standardized tests. (standardized tests are dumb on many levels but i don't want to get into that.) in fact there's no standardized way to teach all of the above, each person would need unique attention over many years to ensure achieving all of the above.
in order to achieve that, i think each kid needs a mentor who will appropriately challenge the kid and ensure their growth. we usually expect that the teachers do this for us but that doesn't really scale for most schools.
i'd make "mentor" an officially acknowledged title that people can wear. and i'd allow anyone to become a mentor after some short training. so if you are a bored stay at home mom, then you could sign up to mentor a few kids around the block (you could mentor your own kids but if the kids have a problem with you then you are robbing them from a truly 3rd party, neutral help.)
the mentor's task would be to ensure regular reflection in people. one can even formalize this. i'd expect that the mentor and the mentee would create a document together on a regular timeframe (no more than 5 months) that has a short answer to these prompts:
even a sentence's worth of answer is enough. the point here is to ask the question so that it triggers the reflection. this can prevent people going on autopilot all the time.
the last prompt about other people is for the mentor to solicit feedback about the mentee from other people at their own leisure time. this is to ensure that the various bubble and bias effects are somewhat smaller.
the answers to these questions would be relatively private. however to ensure accountability, the mentors would need to occasionally report to some mentor managers. these managers would be well experienced mentors that know what to look for and how to improve mentoring so they would review these answers for their reports. this means the mentor's manager would also have access to the answers.
i'd mandate everyone to have a mentor and to have such reflection documents written regularly. the nice thing about anybody easily becoming a mentor is that each mentee can then easily find a culturally similar mentor who has then a much higher chance to really connect with the mentee. (one of the ongoing expectations of the mentors would be to find a better mentor for the mentee if possible. mentor managers could help a lot with this.)
the mentor and mentees would regularly meet (e.g. weekly even). it doesn't have to be a formal meeting. they might go for a walk, coffee, gym, videogame arcade, whatever that really makes it easy to talk for the people. mentee would then tell about their ongoing struggles and the mentor would then challenge the mentee to overcome them and perhaps intervene or help out if the mentee has too large problems. the mentor can also suggest new things to try if the mentee is not sure what to do.
such mentorship shouldn't necessarily end at 18 years old. in fact this should be a lifelong thing. each citizen should have access to a neutral mentor (so ideally somebody with whom you have no conflict of interest with any topic). i'm not saying this should be mandatory, just a civil right. i mean government (or something) should ensure an active network of freely available mentors for consultation. stuff like this might already exists (e.g. in the form of self organized groups) but it can be quite hard to find and consider such things if you had never been exposed to such things before (and this is why i'd make it mandatory for teenagers at least).
now back to education. thanks to all the technological advancements a lot of new options have opened up when it comes to education. for instance we no longer need traditional lectures. people wanting lectures can just watch videos on the internet instead. and some of those videos (e.g. khan academy stuff) is much better quality than your average teacher could ever do whilst trying to maintain order in a classroom. learners can pause, rewind, alter the speed of such videos which makes it much easier to follow the content.
this doesn't eliminate the classrooms though. i think classrooms are still good for practicing together, asking questions, clearing up uncertainties about a certain topic. sometimes you don't even need a teacher, a group of similarly interested students can just get together and help each other understand some study materials.
so this means that schools would continue to exist and students can go there to learn all sorts of things. but what you learn there is mostly up to you. it is your mentor who nudges you to pick up interesting stuff and some stuff outside from your comfort zone too. it should be fine to not study anything and just play table tennis or to wrestle with others all day long too. the important point here is to ensure everyone can find something here that can occupy them rather than leaving people unsupervised and then having them go on some antisocial rampage.
i'd imagine that such schools could start when the kids become teenagers and until that time a somewhat less organized kindergarten like environment would be enough. however smarter kids could easily go earlier to a school like that if they feel like ready. i wouldn't put an upper age limit how long can people stay there. it should be possible even for adults to go back and learn with kids if they wish so. not sure how weird that would be.
i wouldn't give mandatory tests to the kids here. however it should be possible for the kids to have 1:1s with the teachers where the teacher tries to figure out the weaknesses of the kid. this wouldn't be graded and it would be solely for the kid's own development.
i think all sorts of kids could thrive here. the smart kid who simply soaks everything could just take all the modules. the one kid who has interest in one topic only and zones out on everything else can just learn that single topic and perhaps occasionally read about or listen to other topics on a mentor's prompt. the student who has no interest in learning or is antisocial: such kids usually don't thrive in traditional schools. at least in a place like this they might slowly learn to control their impulses if nothing else rather than let them develop uncontrollably.
in the old days teachers could simply use physical force to intimidate people into compliance. this might have given the illusion that schools worked better in the past. students these days know their rights very much so teachers need more subtle ways to make the school a nice place. i think people just need real good, personal guidance and that's why i talked so much about mentoring above.
i think schools like this already exist even with some mentoring (e.g. budapest school, i believe) but they aren't very mainstream. but i think all schools will slowly evolve in this direction over time. kids these days can already take lectures from internet. lectures can become the "homework" and classrooms can become more interactive practice or discussions groups if they haven't already. thanks to all instantaneous communication, calendar and scheduling software a school can decide for more flexible classroom schedules so kids can have more freedom to rearrange their week as they see fit. there's no need to centrally plan it all. this also opens up possibilties for the schools to provide more optional courses and kids can then focus more on their areas of interest.
in general i'm quite optimistic about the education in the future. but i expect the above changes will come only after a generation or two: the world is different than what it was when i grew up. to fully embrace it, i think you need people who were grown up in it. that's why i expect that all we need to do is to wait until the today's younglings start leading schools in the future.
published on 2021-01-15
# reflecting: reflect regularly
one thought stuck with me from my previous post, @/grow. in there i propose that one should occasionally write answers to 4 questions. to recap, let me list those 4 questions along with a single word that summarizes the question's intent:
i think these are pretty good questions: they don't overwhelm you because they only ask you to list one answer. even answering with one short sentence is enough. and just because you list at least one answer, it already bumps you out of a fully autopilot life.
in that post i suggest that people work on these questions regularly with a mentor. however what if someone doesn't have a mentor? well, i think one should still ask those questions from themselves regularly.
i think i'll give it a shot every 4 months or so. i tried answering those questions and they are not that easy. as an example here's what i came up with yesterday after some pondering (keep in mind that the answers are about the surrounding +/- 4 months):
it took me a while to answer those questions but now i feel i have a bit more clarity about where i am and where am i going. although i'll try to do this regularly but probably i won't do it publicly. i feel doing it publicly would prevent being fully honest with the answers. the answers could often require a lot of personal context that would just not make sense without that extra knowledge. e.g. my "goal" has more nuance to it that i didn't elaborate above. or one might not want to publicize their failures and aspirations. though i might change my mind and i'll just keep updating this post or add a new post for every reflection point even if things don't make sense.
note that this reflection doesn't necessary come with any commitments. for instance i can now decide how disturbing the procrastination mentioned in the failure question is. if it is, i might start tracking it or try to prevent it. or i might just make a mental note of it (raise mental awareness) and see how it changes over time. furthermore, i might make plans to achieve my goal or i might not. but i can certainly give it an occasional thought how could i come nearer the goal.
doing it every 4 months means 3 reflection points in a year. i find that not too frequent and not too rare: it's just 4 questions that need single sentence answer after all.
i think i'll be able to tell if this is valuable or not after i did it a few times and have some historical data. so maybe after a year or two i'll know. it's a cheap experiment to try.
# edit re goals (2022-08):
set small, regularly occurring routine as a goal rather than one big achievement. whether you can finish something is not always within control. showing up regularly to do an activity is on you.
this is pretty important but is something i forgot to highlight above.
# 2021-05-28 (4 months update)
# 2021-09-26 (4 month update)
it's time for my second reflection update. well, i think i've managed to make some of the things i wanted but i've failed to fully go through my idea from the previous update. tbf, it was very vaguely defined, i don't even remember what it was exactly because i didn't write it down. i'll definitely annotate my journal with more specific notes in the future. and i'll aim at specific actions that are easy to measure success with.
i'll stop tracking the peers section from this point on. i'm way too introverted. i don't mingle with others, so it's just too depressing to track this. i don't really need/miss such mingling anyways. if i'd feel overly isolated, i'd probably continue to track this though.
also, i think i'll bump the update period to 5 months. i think the updates should be not divisible by the number of months in a year. this way each update is done at some different time rather than at the same time each year. it makes it less of a seasonal thing and thus less boring hopefully.
# 2022-03-11 (5 month update)
# 2022-08-08 (5 month update)
this is now the 4th update. i really appreciate this reminder to think through my recent months and set some goals for the next. it really helps me reorganize thoughts, reprioritize matters in my life, force me to experiment with new things.
# 2023-01-07 (5 month update)
i started having private versions of these updates. it's pretty neat because i can be more open there. i even started tracking notes about personal relationships again there. i no longer agree with what i wrote in the 2021-09-26 update with regards to not tracking this. my primary problem was with doing it publicly. but doing it privately is helpful.
but if i do private notes, then why do public ones too? mostly for accountability. i promised in this post to make regular updates and i don't like to go back on promises without a good reason. otherwise i would be tempted to simply stop doing this properly even though i find the exercise quite useful. if i ever stop this, i shall document it here why i stopped doing it.
anyway, here is the public part of my current reflection notes:
# 2023-06-03 (5 month update)
and i added some notes about my social life into my private version of this note.
# 2023-11-14 (5 month update)
# 2024-05-01 (5 month update)
# 2024-09-29 (5 month update)
published on 2021-01-24, last modified on 2024-09-29
# seennet: an idea for a social networking site around videocalling
i think i like the idea of having community sites with very specific rules. so here's one idea that i think is optimized for "meeting" people. by "meeting" i mean a 10 minute-ish videocall. this would be a social networking site where you could interact with others only through videocalls.
there are sites like omegle and chatroulette where you can talk with strangers. the problem with them is that you don't really control what happens after the chat: you might feel the whole chat was in vain when a good call ended before exchanging contact data.
in seennet you can access a person's profile only after you've met them and as long as both parties agree to this in a short post-call survey. after getting the consent from both sides, you would become "friends". you would have to regularly meet to maintain the relationship otherwise seennet would break the connection (e.g. after 18 months).
in order to use the site, all you need to configure are the following:
then you would ask seennet to schedule you some videocalls.
simply chatting randomly could be boring and pointless. therefore i'd add a little gamification to all this: another goal on the site would be to "suggest arrangements". suppose you know quite a lot of people and you know a friend of yours would get along with another friend of yours very well but they don't know each other yet. then you enter this suggestion into the system along with a note that explains why they might like each other (e.g. you can mention that they both have the same secret hobby). then if seennet ever schedules a meeting for them they both see your note before the meeting so they know that they have a common friend. that means they are not so stranger after all and given the recommendation they have a good chance for connecting well.
you could compare this system with online dating sites. there you create an online profile, add photos, list interests. then you need to message a lot of people or hope that the right person messages you. if you are introvert who is into introverts then the latter strategy might never connect you up with the ideal partner. you have to invest a lot of energy into this system. in seennet you simply need to show up regularly and after a while you'll start meeting more like minded people without any reliance on any fancy algorithm doing the right thing.
in those dating sites a lot can matter on your profile. in seennet you re-present your profile every time you meet a new person. the first few minutes of your introduction is your "profile", basically. the nice thing about this is that your live "profile" can improve over time because you get constant feedback about it as you see the other people's reactions. you might not be so keen on improving your profile page simply because you have no idea what effect it has on people.
i think this sort of thing could bring together people with many interests not just romantic partners. maybe you are into learning german. every time you introduce yourself, you also tell people that you want to practice german. maybe the other person knows someone who also studies german. they can then add a recommendation with a note like this: "you both like hiking, want to practice german. you should meet!". i think there's less awkwardness with this sort of introductions compared to a meeting with a complete stranger. here at least a friend vouched for the other person, so you should be a bit of at an ease here. and you also have a common topic already, no need to spend a lot of time trying to find it.
another weird example could be nudity. i think it was quite common on chatroulette in its early times and it was usually unwanted by most people. on seennet you would initially appear on the calls clothed but you would mention that you like nude calls. (being clothed in the random calls could be a rule). if a person knows two people who like being nude they can arrange a call between them and the suggestion note could say: "you both want to be nude. have a nude chat!". then you would have the opportunity to go wild with strangers.
there's another psychological aspect here: you can express your weird wishes in an indirect way. in a traditional site with direct connections only you would mostly only experience rejection since the goal is to connect to the other matched person directly. but in seennet your only goal is to listen and note the desires so that you can connect people together. i think the fear of rejection would diminish on a site like this since the other person doesn't really have to like you in order to still rake in virtual points for successful matching.
i think the underlying idea behind seennet is very generic and can easily adapt to a wider range of interests than what typical sites usually have. for instance maybe you are a couple and looking for another couple to play boardgames (or other fun).
you could easily register a "couple" profile and appear as a couple on all videocalls. solo people might mention this couple in their other calls and if there are other people who are interested in some couple fun they could then also register as a couple. that solo person can then arrange a meeting between them. in fact a couple based subculture might appear on the site even without any specialcasing done on the site itself.
i wouldn't allow any messaging on this platform, only videocalls. if you want messaging, just connect on some other platform. i think this limitation would keep things simpler and cleaner.
but what would motivate members to keep suggesting connections? i'd make things a bit more complicated for this. you'll see when somebody suggests you a connection but this in itself won't increase the odds that seennet schedules the suggested meeting for you. in order for it to do that you'd need to "accept" the suggestion. that would increase the odds that seennet schedules its random calls with that person. simply increasing the odds i think is a good defense against spam suggestions. however if the other side also accepts the suggestion seennet pretty much immediately schedules the meeting or tells you that you have a calendar mismatch.
the trick is in the "accepting". you can't accept a connection unless you suggest one before. so basically the site has a currency. you get credit for suggesting. maybe also for someone accepting your suggestions. and accepting suggestions uses up such credit. to limit spam, i'd only allow suggesting one connection per day.
the assumption i'm making here is that people would feel a strong urge to accept suggestions since that's how they can find nice friends. and this urge will then drive them to suggest connections for others.
given that you can only establish new connections through the random or suggested calls, one would be quite invested into their profile. creating a new profile wouldn't give you much since it would take a while to build up a larger network that you could spam effectively. so i think the spam would be somewhat reduced on the site intrinsically. people would be motivated to adhere to the rules otherwise they have a lot to lose (i.e. their network).
another benefit of using such a site is that it takes control of "maintaining" the connections. i'm really bad at this in real life: if somebody doesn't call or write to me then i don't reach out to them. for one, i feel shy and feel that i would be disturbing them if i asked how are things with them. two, i know that such talking usually starts at and often ends at small talk. and i'm really bad and uncomfortable at small talk so i simply avoid it if i can. but if some entity randomly schedules some videocalls then it might help me take care of the anxieties and the scheduling work around this.
i've chosen short online videocalls because they can fit the modern schedule easier and give access to many people very conveniently. i'm sure such things exist in offline world too: e.g. i think there are apps that arrange lunch mates for you so you don't have to eat alone. in such places arranging dates with others might come less naturally so that's why a little gamified site around this could help. also, lunching can be expensive from both time and money perspective, hence i think i'd prefer the low cost videocalls. but i still would want to do it with local people and that's why i'd add the option for geographic filtering into the settings.
i came to this peer powered matchmaking site idea while reading fowler's book called "connected". that book talks about social networks/graphs in general. i really liked the "friend of a friend" aspect: the number of people you are connected through a friend is quite large. and your friend often connects you to another of their friend if they seem that such a friendship would be beneficial. in fact, this is how a lot of romantic relationships get arranged. so then i thought how could one build a network around this and maybe nudge people a little bit to be more active in suggesting. the above is what i came up with.
and these days it's pretty easy to set up videocalls between people using all the browser apis. so i think the implementation of such a site would be relatively simple. although i'm somewhat unsure if peer-to-peer videocalls should be allowed or if the videocalls should go through a central server. i don't know how bad it is to leak ip addresses these days. alternatively i'm sure one could use jitsi for this one way or another.
if such a site would exist, i might try it. maybe one day in my distant retirement i might build it if i still want it and it doesn't exist yet.
edit 2024-08-04: somewhat related, i came across https://noii.ch aimed currently mostly at zürich folks (iiuc). it's video speeddating. participiants have to join at 8pm and you'll have up to 7 quick video calls. after the each call you can mark whether you liked or not liked the other person. i really like that they provide an exact meeting date. that makes things more predictable. i haven't tried it since it's singles only but looks quite promising. adding a note here for myself to remember to check back on this to see how it evolves over time.
published on 2021-01-28, last modified on 2024-08-04
# solomove: doing the same exercise throghout the day over and over again
i'm quite the passive person. i pretty much sit all day long in front of my computer at home. but then there's everybody saying that some exercising is important.
a while ago i thought about how could i trick myself into some exercising. my goal was not to develop proper exercise routine just to avoid the absolutely zero exercise living. i found a way that worked for a while. i wrote about this in @/enacc. skim that, otherwise some of the things here won't make sense.
i eventually stopped caring about decrementing the enacc energy because i stopped procrastinating much. enacc wasn't the thing that stopped me from procrastinating. what stopped my bad habits was rather the improved daily routine.
nevertheless i tried working on incrementing the energy levels via exercising. i tried to keep it level across all exercise dimensions. which means i eventually started doing the exercises in a round robin fashion. i always pretty much knew which exercise to do at any given moment.
i usually stayed on a single exercise until i hit a switch point at which i started focusing on the next exercise. the switch point was at every 50 points. e.g. if all exercises are at 250 points then i start doing the first one until 300 points, and then switch to the next exercise. i don't do this in a single set. i usually accumulate 50 points over many sets over several days. i mostly focused on them in the morning, since exercise can be a part of the morning routine.
# problem
eventually i started dreading the system a little bit. my problem was the same what i've had previously when i tried going to a gym. i felt it requires too much time investment from me and i don't particularly enjoy myself during the exercise.
and as i was doing the exercises themselves, i felt that i focus too much solely on counting the repetitions. i counted so that i knew my strength and in order to enter the progress into enacc. but in the end i felt i did it for the numbers rather than for myself. i felt the "tyranny of metrics". the whole thing felt pointless.
# requirements
i really liked one part: enacc always told me what to do. it's almost like as if a personal trainer takes care of the "thinking". but then i thought, maybe a personal trainer could take of the counting too? or furthermore: what if i don't care about counting at all? do i lose anything?
basically here's what i want:
i added the static exercise requirement because i started liking the simplicity of doing only a single exercise per day from my enacc experience.
# solution
i think i managed to come up with a new system that seems to work for me. i write up the list of exercises to do: pushups, pullups, squats, dips, bench presses, etc. then each day i pick a single exercise and only do that through many small sets throughout the day.
i order the exercises into a least recently used list. then every day i just pop the least recently used exercise and that will be my exercise for the day. i then put that exercise to the end of the list. i also track the date i last used an exercise for reference but that is not really important.
this system tells me what to do for each day. whenever i decide to do a set, i just do however much i feel like doing. i don't track the rep count or the length the exercise because i no longer care. i don't particularly feel dread anymore because if i feel i did too little then i promise to myself that the next set will be harder. and sometimes it is, sometimes it's not. the point is not to have a proper exercise routine just to avoid the absolutely zero exercise days.
# amount
i try to do the exercises in a way that they are hard and i can't really do more than, say, 10 reps. this doesn't always work because one gets stronger over time. one learns to do more reps and then needs longer time to get to the amount that hits the limits of the muscles. but e.g. i try to do squats while holding weights to make it harder.
an ideal set is where i do the exercise until my muscles give up. and even then a couple more negative versions of the exercise (e.g. in pullups a negative is when you slowly lower yourself). iiuc negative exercises are the new hotness, just search for it. but unfortunately i often give up sooner than i reach this part.
in exchange one should do sets all the time throughout the day. i try to do a few sets in the morning already. if i don't forget i do try to do them throughout the day too but i don't obsess about it. if i forget then so be it. at least i did some in the morning.
another thing i find helpful is to do the exercises very slowly. i find this uses more muscle power and is actually more closer to the negative exercises. but i don't obsess about this either. sometimes i do things faster, sometimes slower, depending on my mood.
# soreness
muscle soreness is my feedback about whether i did something good or not. if i don't get sore muscles then it means i did either too little or the exercise had a way too weak form. i actually quite enjoy the pain that comes from this because i learned to associate it with the fact that i did good. now i actually miss it when i don't get sore. so my actual goal is to be sore all the time.
i watched a lot of dragon ball z as i was a kid. and the most important thing i learned from it: no pain no gain. the heroes got powerful through a lot of pain. so that show educated me that pain is fine.
but i do give myself a free pass for the day if i feel soreness. iiuc your muscles have to heal, so it's better to avoid training. my conscience is still in the clear when i avoid exercise such days. though if it's only my legs sore then i might still pick some upper body exercises to do.
# review
i'm using this system for the past few days and i really like it. it really makes the exercise easy: i don't really have to think about it. whenever i'm between things, i stand up and try to do a set if i remember it.
and i don't set any expectations for myself about the sets. if it's small, then it's small. it really helps me to actually start the exercise if i know it won't take too long. sometimes i still count during it because counting can make me push harder those last few reps. sometimes i don't, and i'll try to think about something during it. or sometimes i do it to clear my head: like in meditation, i try to focus on simply feeling the pain. and there's lot to feel once you are at your limits.
sometimes (usually?) i don't get sore muscles the next day. but that's fine, i'll remember that and maybe i'll do the same exercise harder or differently next time.
i like the least recently used list thing too. i even added other things to it to remember doing regularly, e.g. cold showers. i started to end my showers with turning the water to as cold as possible and have a totally cold shower for a few seconds. i can't really last longer than a few seconds. cold water is painful too but i very much like the feeling right after. maybe with some exposure i can increase my tolerance over time. it's like a form of mental training to learn to endure pain. but in order to not forget about this habit, i put it into my lru list to make sure i'm regularly reminded to do it. i can totally imagine that i might put other things into it over time.
one downside of this system is that it really only works from home. once i need to go back to the office, it's likely i might stop. but since i wake up quite early in the morning (i now aim at 5am), i might still be able to do enough sets in the morning so that i won't need to do them at work. we'll see.
in any case, i'll keep experimenting with this system and see how it goes.
published on 2021-02-19
# phones: thoughts about phones now that i have to buy a new one
this year (2021) swisscom decided to shut down its 2g network. i got no warning about this, my phone just suddenly stopped working. it took me quite a while to guess that 2g might be gone and then confirming in the news that it's indeed very likely. apparently i might have been the only person in switzerland who still used 2g phones. to be fair, this is a corporate subscription so maybe my workplace got a warning about this via snail mail. it would have been nice to give a few days headsup via sms too though.
i've switched to a dumbphone in 2015 after 1.5 years of using a smartphone. i got my first smartphone (nexus4) from my workplace in 2013. but it was quite addictive for me, i was checking it way too often rather than being present in the world. the constant updates were also super annoying. almost as if every month there is some big os update that takes ages to install and then it changes the user interface subtly enough so that you can throw out some of your muscle memory all the time. but what really pissed me up is that they break very quickly and you are then expected to get a new phone. after a year or so it started occassionally rebooting. it even rebooted at night. back then i had to have mandatory encryption due to corp policy and you would need to enter your unlock pattern to boot. this meant that on some nights it decided to reboot then the next morning i got no alarm or page notifications at all until i woke up naturally. and i was pretty sure this was a software problem only present with wifi on, but on support all i got that the phone is end of life, i should get a new one. i really hate this planned obsolescence attitude so i decided to get rid of smartphones from my life.
i had the first generation nokia 105 from 2013 that i bought in 2015. it had none of the issues that i had with the smartphone. i also felt that i got generally calmer. this nokia aged quite well. it still functioned well although the letters/numbers from its keypad completely faded away. i could type blind on this so this wasn't bothering me that much. separate buttons would have been nice though. later models had keypads like that. anyways, i wanted a similar phone that would work with the new networks.
in the meantime i dusted off the new corporate pixel 4 that i got from the company last year when i moved to switzerland. i only got it because i thought i'll need it for work (a special app) but then it turned out i don't so i didn't use it and couldn't be bothered to return it. i've put in the sim card and it worked fine.
i've spent some time on this android to make it somewhat usable. this entails removing all the unnecessary apps, turning off unnecessary features (animations: what's the point of this?), and other tweaks. i've disabled data and wifi, enabled battery saver. basically i've managed to turn it into a dumbphone.
the nice thing about the old nokia that its battery lasted for weeks. i thought all these fancy new phones can't last a day even. i was quite surprised to learn that the pixel4 with the latest android could probably last for a week even. it drained only about 12-15% battery per day.
my phone usage other than to check the time is very light: i only use it to set alarms for wakeup and for meeting reminders, and some evenings i use its flashlight to see in the dark rather than lamps because i don't want to accidentally wake my kid with the extra light. secondary reason is to receive pages when i'm oncall at work. and on very rare occasions i also use the sms and calling features.
i'd wager that 99% of the time my phone is on standby. it would be nice if i didn't need to mess around with chargers every day. after learning the pixel4 can probably survive a week i even considered just staying with it.
but there were a few things bothering me.
its size was much bigger than my old nokia. it didn't fit as nicely into my pocket. it felt quite bulky.
i missed the good old buttons. there were mornings when i was trying to disable the morning alarm via swiping and my swipes just didn't register. and the alarm just got louder and louder (note: i'm not living alone). that was frustrating, let's say to the least. in retrospect i learned that i could have probably used the side buttons for this.
i do appreciate that a touchscreen is more generic interface, but i prefer buttons. i find them more reliable. it happens often on various screens that my finger doesn't register, especially when i'm in a less than ideal conditions. i might use the phone rarely but when i use it, i really need it to work. i prefer reliability over "usefulness". in other words, i wish for a keypad.
the fact that pixel4 is a smartphone also bothered me for several reasons.
although i deleted all the apps from it, it would be very trivial for me to reenable data and start browsing crap when i feel uncomfortable at some place. sure, i could probably resist this for quite a while since i didn't associate internet with my phone for 6 years but i'm sure it would all come back over time. i'd very quickly adapt to it and then couldn't live without it (e.g. to live without gps). and i'm also sure that if i'd start using this more heavily then it would start having problems like i had with the nexus4 (even if it's just the annoying updates in case the hardware remains good). i can safe myself a lot of mental health if i completely cut myself from this addiction device.
also, if it's a smartphone device and if others see it, i feel that they will have different expectations from you. they might expect that you are on whatsapp, messenger, viber, snapchat or whatever today's messenger apps are. while if all you have is a dumbphone, they'll consider you as a weirdo and won't have much expectations from you. it's a good conversation starter too if you are hipster enough to flash it now and then in front of others.
besides, one needs to show a good example for the next generation: that one doesn't need a smartphone to survive in society. maybe this way i can somewhat delay my kid's smartphone addiction.
anyways, long story short: i still wanted an old fashioned dumbphone. easy peasey, i say to myself: let's check out nokia's newest models.
the newest nokia 105 (2019) can't do 3g or 4g. but nokia 225 4g can! it even has a camera. i don't really need a camera but at least that is not that addictive so that doesn't bother me too much. i almost bought this on the spot but then i noticed one little detail as i was comparing its specs with my old phone: the size.
here are the sizes of these 3 phones for reference:
the new phone i've looked up is much much bigger! this must be some weird model then, i thought. but all the other phones grew too, even the new nokia 105 models:
or compare my wife's very old dumbphone from her teenager times with a new model of the same number:
i recall from my childhood that the adults complained about the phones getting way too small. looks like in 2021 you can't get small phones anymore that are 3g/4g.
after researching a lot on the internet, i've found pretty much only these phones with comparable size of my old phone:
maybe there are more but these are the ones i found. all of these phones support at least 3g and you can message too. (i've seen some phones which can only do calls but i ignored those.)
oh, and based on the specs and the reviews, none of these phones can last for a week. which is odd because nokia claims to work for 28 days in 3g mode, 20 in 4g, yet 4 days is the longest duration i found in the customer reviews. but it runs kaios so i guess that's a huge battery drain at this point. i'm sad that battery duration also became a lost art over time.
let me immediately eliminate the jelly pro: it's a full smartphone and it comes with all the downsides. besides, for some reason you can't easily update past android 8, so it probably has worse battery management. the reviews say it works for about a day. (iirc battery management gets better with android versions. i guess developers are slowly learning that not running the apps constantly makes the battery last longer. probably the newer android builds have longer sleep cycles.)
at this point i pretty much gave up on the battery front and resolved to charging my phone every day. so i decided battery shouldn't be deciding factor for me.
at first i was eyeballing the light phone. it's an e-ink android phone that has a hardcoded dumbphone app running on it. technically you can get to the underlying full android phone, but it's a bit of a challenge and defeats the purpose of the phone anyways. it has no flashlight and no buttons. it's quite expensive too ($350). and you'd need to wait several months before they get another batch to ship. with all this together it was easy for me to say no to this phone too.
i was then eyeing for that zanco phone. there were a few things bothering me about it: it might be too small and i'm not sure about the quality: in some video reviews i've seen the reviewer struggling to press some buttons. and i'd have to order it from china which means it would take ages to arrive and i'd need to pay import taxes too. oh and it doesn't have a flashlight.
and then there's that nokia 2720 flipphone. it no longer uses nokia's standard dumbphone os but rather kaios. kaios, iiuc, is like android but for phones with buttons. it's a fork of mozilla's defunct firefox os. basically the whole os is just a webbrowser running in a linux and all the apps are just html5 pages. this totally makes sense to me but the battery time worries me because i don't really associate the web with efficiency. and since it's all web based maybe it could run the addictive apps too. but otherwise it does check okay on other dimensions: has flashlight and buttons, doesn't look like a smartphone, i can call and message with it. it can even act as a wifi hotspot to share the mobile internet, which i'm not sure is good or not, since then i can easily use a secondary device to browse internet anywhere. but it's a bit too big for my taste: bigger than my old nokia 105 even when closed. i couldn't find a smaller phone though, so i can't be very picky.
btw, if the size didn't bother me that much, i'd have probably gone with energizer e241s. it's also a kaios phone but the reviewers were happy with the battery life and pretty much was the cheapest at the time (40 chf). for reference the nokia2720 was 82 chf and the zanco $62 + shipping.
after contemplating a lot over my choices, i realized that i can't make a good decision here. all choices have some downsides. i just need to pick one and go with it.
my wife suggested that i go with the nokia 2720, it'll be less hassle. so i went with that. i'll soon post a review of it. you can look at @/phones.jpg to see how it compares to my other phones in terms of size and bulkiness.
published on 2021-02-20
# nokia2720: tweaking and using the nokia 2720 kaios phone
as i described in @/phones, i wanted a new non-smartphone. so i decided to get a nokia 2720 4g (2019) flipphone. i have a pic at @/phones.jpg that shows how it looks like in terms of size compared to my nokia 105 (2013) which was made obsolete by the 2g network shutdown in my area and pixel 4 that i used while i was waiting for the new phone. as you can see, it's bigger than my old phone. but that's still pretty much the smallest non-2g phone i found.
this phone runs kaios. kaios is a linux that runs some old version of firefox and all the apps on it are just html5 websites. it's a fork of firefox os and is optimized for phones with keypads.
and as expected, by the default it comes with lots of quirks that i needed quite some time to reconfigure. fortunately it's relatively easy to tweak the phone so at least that prevents one from getting unreasonably angry about the "design choices" its developers have made.
let me document the tweaks i needed to make. i'll try to be detailed so that if i ever need to switch to another kaios phone, i'll be able to set it up from scratch again.
there's a site called bananahackers. it's a collection of guides scraped from some kaios mailing list. it's a bit annoying site but it was very useful for me to figure out things.
there's quite a few hacks i did. some are straight from bananahackers, some are my own findings:
if you decide to go down this path then make sure you don't make a mistake. it's very easy to mess up the whole phone and turn it into a brick. i managed to make a mistake when editing the launcher's source and the phone's ui got completely broken. fortunately i could still start wallace-toolbox with gdeploy or webide so i could reenable root and push a fix. had i messed up the system app, then things would have been much harder.
note that all the patches below are against kaios 2.5.2. an upgrade would probably invalidate most of my hacks so i hope it won't come anytime soon. although you can easily turn the updates down if needed.
# tweaking
so let's start. i assume linux as your hacking device. the tools you need are: adb and kaiosrt. kaiosrt is basically just an old firefox that still has webide enabled. you would use that to sideload apps to the phone or to tweak some hidden settings. alternatively you can use gdeploy to sideload apps. i prefer the latter since you can easily run it from the command line. software sources:
enable debugging mode with "*#*#33284#*#*". a little bug icon should appear in the top status bar. now connect the phone to your computer via its usb cable. the device should appear when you run "adb devices".
use gdeploy to install the wallace-toolbox app. in that app you can enable call recording. i've enabled it because i have terrible hearing and would prefer to listen back to some conversations to ensure i picked up correctly everything. the conversations will appear in a callrecording folder on its internal storage. use mtp (e.g. mount it via go-mtpfs) to get to the folder when connected to it.
use wallace-toolbox to enable the developer menu. this unlocks a new option in the settings (settings->device->developer) where you can toggle the debug mode without needing to remember the code.
use wallace-toolbox to make all apps removable. then you can use the right soft key in the launcher to bring up the menu that will now contain an uninstall option for all apps. i only kept these:
that's 9 apps. it fits one screen without scrolling so that's nice. i think the rest is unneeded. just use an actual computer to do the rest of the stuff (e.g. browsing, gps, listening to recordings, radio, snake, etc).
use wallace-toolbox to enable adb root too. after that "adb shell" will log you in as root and you will be able to overwrite the builtin apps this way. you'll need to enable this after each reboot so maybe keep wallace-toolbox around or somehow make this autoenabled on boot.
there's one more easy setting you can do: disable the flip to answer. i often want to reject a call so that i can call back immediately. i'm on a company paid plan with unlimited calls so it's simply more cost effective for me to call back my wife. for that i need to open my phone, reject the call, and then call back. to set this up, start up kaiosrt and connect to the device. in it go to runtime -> device settings, find the option phone.answer.flipopen.enabled and set it to false. you might need to reboot. i've learned this one from the r/kaios subreddit.
# advanced tweaking + disabling the startup sound
all the system apps live at /system/b2g/webapps. in order to replace some of them, you need to copy the target app to /data/local/webapps and point the app's dir to the new path. to do that you need to edit /data/local/webapps/webapps.json and change the target app's basePath property to /data/local/webapps.
let's start with the disabling the startup sound tweak to demo all this. keep in mind that all the patches i show are against the formatted code. just use a js formatter to reformat the files and then they are easy to edit. i used clang-format with the google style but beware clang-format seems to mess up code where there's a missing semicolon at the end of the line. by messing up i mean the code won't work anymore. maybe apply the patches manually on the unformatted code directly.
to disable the startup sound, first grab the system app:
adb pull /system/b2g/webapps/system.gaiamobile.org
a system.gaiamobile.org directory should appear in your current directory and it should contain a file called application.zip. it's best if you can edit the files right in the zip file so that you don't need to unzip/rezip the contents. modern distributions of vim can do this already but probably other modern editors too.
apply this patch either manually or via patch:
diff -rpu base/system.gaiamobile.org/js/init_logo_handler.js mine/system.gaiamobile.org/js/init_logo_handler.js --- base/system.gaiamobile.org/js/init_logo_handler.js +++ mine/system.gaiamobile.org/js/init_logo_handler.js @@ -121,6 +121,7 @@ var InitLogoHandler = { _playDefaultPowerOnSound: function() { var self = this; window.addEventListener('mozChromeEvent', function startOsLogoSound(e) { + return; if (e.detail.type !== 'system-first-paint') { return; }
i just pretty much completely disable the startOsLogoSound function's body. after you made this change push this back to to the phone:
adb push system.gaiamobile.org /data/local/webapps
notice that this time we are pushing to /data/local/webapps. make sure to edit /data/local/webapps/webapps.json too:
adb pull /data/local/webapps/webapps.json sed -i '/system.gaiamobile.org/,/^ }/s:/system/b2g/webapps:/data/local/webapps:' webapps.json adb push webapps.json /data/local/webapps/
then reboot the phone for it to pick up the new system app:
adb reboot
there shouldn't be any startup sound. all changes below need a reboot in order for the phone to pick them up.
from now i'll just show the patches i used for the various tweaks. make sure to pull and push each of the change the same way as the system app.
# type numbers faster
this tweak is from the bananahackers site. basically if you want to type in a number while typing a message, you can long press a button to make it a number. but the duration is overly long so you can lower that like this:
diff -rpu base/keyboard.gaiamobile.org/js/keypad.js mine/keyboard.gaiamobile.org/js/keypad.js --- base/keyboard.gaiamobile.org/js/keypad.js +++ mine/keyboard.gaiamobile.org/js/keypad.js @@ -26,7 +26,7 @@ var Keypad = function() { this.voiceinputFTUDisplayedTime = parseInt(localStorage.getItem('voiceinput-ftu-displayed-time')); }; -Keypad.prototype.LONGPRESS_INTERVAL = 1000; +Keypad.prototype.LONGPRESS_INTERVAL = 500; Keypad.prototype.IDLE_INTERVAL = 1000; Keypad.prototype.VOICEINPUT_FTU_COUNT = 7; Keypad.prototype.VOICEINPUT_FTU_DURATION = 1000 * 60 * 60 * 24;
# replace the alarm clock sound
i didn't find an option to use custom sounds for the alarm clock. it's entirely possible i just missed an option for this. but what i did is that i just replaced
clock.gaiamobile.org/shared/resources/media/alarms/ac_woody.ogg
with a custom ogg file and pushed the clock app back to my phone.
i really hated the default selection. i dislike alarms that suddenly scare me awake. what i want is some white noise that gets louder slowly. i downloaded some 1 minute rain mp3 from some sound sharing site, opened it in audacity, applied a fade in effect over the whole sound, exported it to ogg, and then put it into the clock's application.zip. it worked just fine.
# make the assistant button toggle the flashlight
it baffles me that the "assistant button" is not configurable on this phone and it defaults to that useless google assistant thingie that i immediately deleted. a much better use for that button would be to toggle the flashlight.
however i don't want the pressing itself to be the flashlight toggle. i want to reserve that for checking the time. i want to hold the button for a little while to toggle it. i managed to set this up.
there is already some support in the code for holding down the button. that's what triggers the assistant. it needs a bit practice to get the hang of it though. i think that's because of the phone's deep sleep mode. the first time you press the button, the code can't seem to be able to successfully set up any timers or do any time related operations. so the first time you press the button, you basically turn the phone up. then the clock should now be visible on the external screen. only now try to hold the button to toggle the flashlight. if you omit the wakeup part, the holding won't work.
however there's also support for double tapping which activates the same function as the holding. at first i didn't disable the double tapping. but then during daytime i sometimes noticed that the flashlight was unexpectedly on. that explained why on some days the battery drained faster than the rest. this was quite a mystery for me but slowly i figured it out.
i often quickly check the time: i tap the button twice rapidly. if it's daylight and this enables the flashlight, i simply won't notice. furthermore, often it didn't enable the flashlight on the second tap. it enabled it the next time i've checked the time. i think that's because the second tap enables the flash and suspends the phone at the same time. but the latter action happens sooner. so the phone only enables the flash on the next wakeup when i check the time next time. this is not a problem with the holding because the code enables the flash while you hold the button and only suspends the phone after you release the button.
this bit of the code was quite tricky to get right. most combinations of changing the existing code simply didn't work reliably. in fact, the unmodified existing code didn't work reliably at all. i'm not sure what testing did people do on this. this piece of code is also meant for handling the emergency sos calls if you enable that in the accessibility settings. but it simply doesn't work unless you tap + hold or tap like gazillion times and hope that you manage trigger the code in the right manner. to be fair, if you enable wifi/data and the phone never sleeps then this is probably not a problem. but make sure you don't trust your life to a kaios device in any case.
anyways what worked in the end was this: on keydown, enable the external screen if it wasn't yet and set up a timer to toggle the flashlight. on keyup cancel the timer and turn off the screen if we didn't turn it on with this button. it took me quite a while to come up with this but now it works quite reliably with the tap + hold pattern.
oh and i also changed the default timeout for holding from 3 seconds to 600 ms because the former just felt too long.
here's the glorious patch. note that it changes two system applications.
diff -rpu base/launcher.gaiamobile.org/dist/app.bundle.js mine/launcher.gaiamobile.org/dist/app.bundle.js --- base/launcher.gaiamobile.org/dist/app.bundle.js +++ mine/launcher.gaiamobile.org/dist/app.bundle.js @@ -4186,17 +4186,9 @@ webpackJsonp([1], [ this._iceProcess(); else { if ('0' == AppStore.customApps) return; - dump('ICE try launch assistant'), - this._flipManager && - dump( - 'flipOpened: ' + - this._flipManager.flipOpened), - this._flipManager && - this._flipManager.flipOpened && - AppStore.apps.some(function(e) { - 'Assistant' === e.manifest.name && - (0, y.launch)(e) - }) + navigator.getFlashlightManager().then(function(fm) { + fm.flashlightEnabled = !fm.flashlightEnabled; + }); } } }, diff -rpu base/system.gaiamobile.org/js/hardware_buttons.js mine/system.gaiamobile.org/js/hardware_buttons.js --- base/system.gaiamobile.org/js/hardware_buttons.js +++ mine/system.gaiamobile.org/js/hardware_buttons.js @@ -151,52 +151,26 @@ HardwareButtons.prototype.helpKeyHandle if (evt.key != 'Help') { return; } - dump(`ice helpHandle helpPressed:${this._helpPressed}`); if (evt.type == 'keydown') { - if (this._pressingTimer) { - window.clearTimeout(this._pressingTimer); - this._pressingTimer = null; + if (!ScreenManager.lidOpened && !navigator.mozPower.extScreenEnabled) { + this._initalPress = true; + this.publish('extscreen-toggle'); + } else { + this._initalPress = false; } this._pressingTimer = window.setTimeout(() => { - this._helpLongPressed = true; - dump(`ice helpHandle longpressed`); navigator.mozSettings.createLock().set( {'accessibilitymode.helpkey.pressed': 'longpressed'}); this._pressingTimer = null; - }, 3000); + }, 600); } else if (evt.type == 'keyup') { if (this._pressingTimer) { window.clearTimeout(this._pressingTimer); this._pressingTimer = null; } - if (!this._helpLongPressed) { - if (this._helpPressed) { - window.clearTimeout(this._helpdblTimer); - this._helpdblTimer = null; - this._helpPressed = false; - dump(`ice helpHandle dblpressed`); - navigator.mozSettings.createLock().set( - {'accessibilitymode.helpkey.pressed': 'dblpressed'}); - } else { - this._helpPressed = true; - let lidOpened = ScreenManager.lidOpened; - this._helpdblTimer = window.setTimeout(() => { - this._helpPressed = false; - this._helpdblTimer = null; - dump(`ice helpHandle onepressed_${lidOpened}`); - navigator.mozSettings.createLock().set( - {'accessibilitymode.helpkey.pressed': `onepressed_${lidOpened}`}); - }, 600); - } - } - if (!ScreenManager.lidOpened) { - if (!navigator.mozPower.extScreenEnabled) { - this._helpPressed = false; - } - dump(`ice helpHandle toogle external screen`); + if (!ScreenManager.lidOpened && !this._initalPress) { this.publish('extscreen-toggle'); } - this._helpLongPressed = false; } }
if it's any easier, here's how that hardware_buttons.js change looks in the end:
HardwareButtons.prototype.helpKeyHandle = function hb_helpHandle(evt) { if (evt.key != 'Help') { return; } if (evt.type == 'keydown') { if (!ScreenManager.lidOpened && !navigator.mozPower.extScreenEnabled) { this._initalPress = true; this.publish('extscreen-toggle'); } else { this._initalPress = false; } this._pressingTimer = window.setTimeout(() => { navigator.mozSettings.createLock().set( {'accessibilitymode.helpkey.pressed': 'longpressed'}); this._pressingTimer = null; }, 600); } else if (evt.type == 'keyup') { if (this._pressingTimer) { window.clearTimeout(this._pressingTimer); this._pressingTimer = null; } if (!ScreenManager.lidOpened && !this._initalPress) { this.publish('extscreen-toggle'); } } }
# remove the toaster notification when switching cases/t9
when typing a message, you can press # to switch between T9, Abc, abc, ABC, 123 input modes. the current mode is always displayed in the status bar. however when you switch a slow "toaster" popup drops down from the top and is displayed for about a second showing the new mode. if you want to switch rapidly between modes then you simply don't know what the current mode is because this silly popup keeps hiding the actual state. i found a way to remove this redundant popup:
diff -rpu base/system.gaiamobile.org/js/keyboard_manager.js mine/system.gaiamobile.org/js/keyboard_manager.js --- base/system.gaiamobile.org/js/keyboard_manager.js +++ mine/system.gaiamobile.org/js/keyboard_manager.js @@ -106,7 +106,7 @@ window.KeyboardManager = { activeLayout: this.activeLayout } })); - if (value.byUser) { + if (false && value.byUser) { var ariaLabel = navigator.mozL10n.get(idMap[value.mode]); if (iconText && value.mode === 'abc') { this._showToaster({text: displayName});
the change just pretty much disables the code block that adds the popup.
btw, if you didn't know, if you long press # it switches the language in case you've set up multiple ones. that's quite handy for t9 input. i keep the toaster popup for that case since that's not indicated on top.
# made the alarm clock time setting ui more usable.
the time entry in the alarm clock app is quite weird. what i'd prefer is that i press "1234" to set an alarm for 12:34. instead, i need to press "12<right arrow>34" to enter that. i want the input field to automatically jump to the minutes field after i entered the hours. here's a patch to do that.
diff -rpu base/system.gaiamobile.org/js/value_selector/value_selector.js mine/system.gaiamobile.org/js/value_selector/value_selector.js --- base/system.gaiamobile.org/js/value_selector/value_selector.js +++ mine/system.gaiamobile.org/js/value_selector/value_selector.js @@ -1049,7 +1049,12 @@ TimePicker.prototype = { } this.timeItem[this.currentFocus].textContent = this.inputValue; this.validDataCheck(); - this.startAutoCorrectTimeout(); + if (this.inputValue.length == 2 || + (this.currentFocus == 0 && this.inputValue >= '3' || + this.currentFocus == 1 && this.inputValue >= '7')) { + this.autoCorrection(); + this.focusChange(1); + } } }, textChange: function tp_textChange(direction) {
# review
phew, that's all the hacks i made. now the phone became quite usable for me. i have a few more generic thoughts. note that i only care about the dumbphone qualities. fancy stuff like camera, music, browsing, apps interest me not. if someone is into that then they are probably better off with proper androids.
# battery
the battery level is shown via an icon in the status bar. i wanted to make it show percentages but i think it's a nontrivial change. each tenth level has a separate icon. the icons themselves are in a ttf file. they are unicode glyphs from unicode's private range. it's not impossible to make this work, i just didn't care enough about it. i can live with icons too.
you can check the exact battery percentage in the settings though, see settings -> device -> battery. you don't even need to get into the battery menu, it will display the percentage while you are in the device menu already. once in the settings, pressing left, left, up will get you to a place where you can see the battery after a second or two.
i was quite worried about the battery life. the most promising customer review said it lasts 4 days. that would be annoying but i still gave this phone a shot. i don't need any internet on my dumbphone so i disabled wifi and cellular data on it. i disabled gps too. i even switched the phone to strictly 3g mode since according to nokia's own documentation the battery lasts for 28 days in 3g mode, but only 20 days in 4g mode.
to my surprise the battery life is quite reasonable! at the time of writing i'm on day 20 without charging and i still have 6% left. and i used the alarm multiple times a day each day (with vibration), some calls here and there, accidentally kept the flashlight on for a few hours now and then. otherwise on my light usage days it uses up about 4% battery. i'm quite satisfied with it.
# physical properties
the phone's body is made of very slippery plastic. it slips very easily on a table. i'm not sure this is good or not, it doesn't really bother me.
you can open and close the phone with one hand but requires some practice until you get the hang of it. i feel it's harder than it should be. it's quite odd to me that this got a design award since it feels it could be much better: e.g. some hole on the side with which you could open it easier.
the flip works fine but i feel it won't last 6 years. i feel i'll have to replace this phone sooner than my previous 2g dumbphone. not that i see anything wrong with the design, just a general experience that whatever that moves will break down with time. each time i want to set/disable an alarm (multiple times a day) i have to open and close the phone. i'm sure that will wear the hinge down.
the vibrator on it is quite reasonable too. the vibrator on the pixel4 was very weak. i barely noticed it when it was on a desk while i was in an otherwise quiet room. no such problem with the nokia 2720.
# software
the call quality is pretty good, even in 3g mode. the phone can be set to be adequately loud too. my old nokia 105 was very quiet, so this is a big upgrade for me. it can do loudspeaker and you can attach headphones too. i tried it with a non-mic'd headphone but then i had to continue speaking into the phone. the phone has to be open because it drops the call when you close it.
i don't like the phone's font setting. it's either huge or enormous. it can barely fit a single message on the screen. this is probably also hackable, but i didn't bother. my goal is to use the phone very little so i can live with this inconvenience.
the keyboard seems fine so far, i can type easily. it's pretty much what you would expect from a phone like this. i can't really talk about the quality of its t9, i don't write enough to be able to tell. i haven't really used t9 before anyways. i can easily switch t9's language on the fly by holding down the # key so i might start finally writing via t9.
when closed and you press any of the side buttons once, the external screens turns on and shows the clock for you. every time you do this, it shows the previous time for a very small fraction of a second before it updates to the actual time. i suspect it doesn't bother rerendering the screen while the phone is sleeping which is good. but it also demonstrates just how slow webtech is for simple things like showing the clock. this "update time after turning on the screen" is also present when you open the phone. even there you'll see the previous time for a small fraction of a second. the effect is more visible in this mode since it uses an animation to update the clock's digits. it doesn't really bother me though.
the messaging app is threaded. so the messages from a specific person are in a single screen rather than spread across multiple messages like in my old phone. that's fine although sometimes my message doesn't show up in the thread after i've sent it. i have to quit the app and reopen it to make it appear.
the volume buttons on the side have a quirk too. they set the volume of the current app. if you happen to close the flip when an app is open (e.g. messaging or alarm), then the volume keys will adjust the "media volume". if you want it to adjust the ringtone volume, you have to exit all apps, go back to the main screen, and only then close the phone.
# alarm clock
the alarm clock has some quirks due to the phone being suspended all the time. it doesn't trigger exactly at the desired time, it can delay almost up to a minute. and because it starts later, it sometimes doesn't even sound for a full minute, but stops early. if you have a very slowly rising alarm then this might be a problem.
once i managed to completely miss an alarm. i've set the alarm to 05:00 and went to bed. in the morning i slowly became awake and started wondering what's the time. i've pressed the assistant button (that turns on the external screen) and it showed 05:13 and lo and behold the alarm started sounding. so this means i wasn't notified about the 05:00 alarm at all. or if it did notify, it was too short for me to wake up. i don't really mind becoming an alarm a minute or two later. but 10+ minutes is too much.
i'm not the only one describing this problem, just look at these posts and their comments:
fortunately the second thread explains the solution. don't quit the alarm app, just minimize it. press back to minimize the app, don't press the end call button to leave. or don't even bother quitting the app, just close the flip while it's running. i've started doing that and from that point i had no issues. it doesn't seem to affect the battery life.
had i not seen this solution, i probably would have written my own clock app that never stops playing the sound until i stop it. but with the above hack i don't need to bother.
now i can't stop wondering what interface would i make for a poweruser alarm clock app. allow me to indulge on this fantasy while on topic. all i need is a multiline textbox where the line format would be "hhmm[flags] arbitrary_comment". it would be trivial to maintain even multiple alarms in it and would be trivial for the app to figure out the next alarm. i could simple write
0500n wake up! 0930 go for a walk!
to set up two alarms. the n flag would mean no vibration. i could have an x flag to mean a disabled alarm. so after waking up and stopping the alarm, the app would put an x after the wakeup entry:
0500nx wake up! 0930 go for a walk!
this auto-x could be prevented with, say, an r flag which would mean a repeating alarm. the ui would always show the next alarm so i can have the confidence that i've set up the alarms correctly. easy peasy and very straightforward to implement. i don't understand why people bother with complicated uis that need megabytes of code to implement the simplest of things.
anyways.
# summary
apart from the big size, i think i'm generally happy with the phone so far. probably won't last forever but hopefully by that time there will be other small 3g phones to choose from.
# edit from 2021-09-29 (7 months after the original post): some battery data
the battery lost a bit of its oomph over time. over the few past weeks i've tracked how many days it took to get to a given percentage level from 100% given my light usage (alarm clock in the mornings and the occasional calls):
percentage | days -----------+----- 12% | 13d 21% | 10d 17% | 14d 37% | 10d 23% | 12d 14% | 14d
i didn't let it reach 0% since i was actually using the phone and had to keep it charged. the point is that i can easily get 2 weeks out of it but i think initially it managed to last longer. anyway, i'm still happy with the phone. i think i made a good choice here.
# edit from 2022-03-08 (1 year after the original post)
i'm now using this phone for over year a now. i'm pretty satisfied with it, no regrets. its battery can still last 2 weeks easily if i barely use it.
i sort of expected that the flipping hinge might break by this time but nope: it still works just as it did on the first day. i guess i had overly low expectations for consumer tech these days.
it now gives me the option to upgrade the operating system to a newer version. but i'm totally not going to press that. i don't want to through this customization nightmare again. fortunately this option is hidden in the settings, it doesn't pester me about it.
in any case, after 1 year of use i can still recommend this phone if someone is looking for a not-smartphone and is willing to invest some time and effort into the necessary customizations.
# edit from 2022-08-09
this phone was all good but i decided to switch back to a smartphone. see @/smartphone for the reason.
published on 2021-02-21, last modified on 2022-08-09
comment #nokia2720.1 on 2022-08-01
Hi,
I just wrote you an E-Mail a few days ago but there was a problem with the delivery und just today you activated the comments section :D My E-Mail was in german, therefore I translate the text:
Hallo,
Thank you for the documentation of the tweaks regarding the nokia feature phone. I own the Nokia 6400 4G an I have the typical 'double typing issue'. When a key is pressed, the hardware fires two inputs instead of one thus the software registers two inputs, which is really annoying, so instead of a 'b' sometimes there appears a 'c' etc. I could fix this in the keypad.js by simply adding a must have time of 150ms between two inputs, which solves the problem when typing text (like t9). However navigation through the system (e.g. using the D-Pad, or entering telephone numbers in the homescreen) this hack does not work, I think the keypad.js is not used there. I could not find the relevant *.js file for the system navigation and my question is, whether you have an idea where I can find it.
Cheers from Hamburg
comment #nokia2720.1 response from iio.ie
apologies about the email address, i didn't realize it broke. thanks for letting me know, i now replaced it with an anonaddy email address that definitely works. :)
actually, about a month ago i switched back to a smartphone because i needed lot of gps lately and didn't want to carry two devices. i don't have my nokia on hand currently, so just speculation follows.
iiuc the events start from firefox and then percolate through various event handlers. if so, the question is, is there a way to catch the event at an earlier stage and prevent it from propagating? looking at the files just from my post, i'd try looking around in hardware_buttons.js and see if it's possible to add `e.stopPropagation()` and `e.preventDefault()` to some relevant looking place.
try giving that a shot and let me know if it doesn't work. i can then dig up my old nokia give it a shot myself.
comment #nokia2720.2 on 2022-08-01
Thank you for the quick reply, I already had a look at hardware_buttons.js but after my first try the keys stopped working completely :D Luckily still in Debug-Mode I could re-enable the link to the original file. I will give it a second try and will let you know.
# parttime: thinking about going part time
i haven't written for a while now even though i have plenty of topics queued up. i spend most of my free time secretly working on a small tool that would make some operations at work a bit easier. i think the industry term for this is "20% time project". i'm doing this in my personal time ("120% time project") because it's not that much related to my core work (it might end up nobody using it other than me) and i'm doing it just for the sake of achieving something useful for my own entertainment. it's not a big thing but has many edge cases and i need to integrate with quite a few internal services. i spend about 1h or less per day in the morning so it takes ages. after 18:00 and during the weekends family takes all my time so i don't really have time (or energy even) to work on it then. (it's quite interesting to see now that i have less leisure time, i'm more conscious about using it well and pretty much achieve more. it probably also means i do need the time pressure to achieve things. but that's a topic to explore sometime later.)
after spending time on that, i don't really have time for anything else. so then i have these fantasies about retiring and having all the free time. but then i realize i pretty much like my workplace, otherwise i wouldn't have the opportunity to work on tools like the one above. i just want to have more freedom next to work. so i'm considering going 80% and having one weekday just for myself. 4 day weeks is the hotness lately anyways.
then i would have time to catch on my personal todo and bucket list, read some books, watch tv, play games, maybe spend more time away from the computer without having too much guilt because i'm not spending my time on work. i could have a little taste of the retired life i so much yearn for without the drastic change that a full retirement would require. (i really don't want to sacrifice my evenings and weekends for this so that i can remain present for my family.)
it also means i could save significantly less money but in exchange i can have more leisure time now. i think that's a fair trade. world is changing all the time, i suspect there's not much point to having large savings or net worth anyways. having a large stash just makes you worry whenever there's turbulence in the financial world. you could see that worry big time in the fire community (financial independence, retire early) when the covid pandemic started. and what will all that money mean on my death bed anyways?
but there are some risks with this. for me i think the biggest is this: what will stop me from still checking emails all the time and slowly drifting back to 100% while still retaining only 80% of the paycheck? i guess i just need to be good at compartmentalizing (i.e. avoiding my work laptop entirely on my off days) and learn to not care about work even when things are going bad (although i'd probably still allow an occasional crunch). but i've read around and a lot of people went part time and i haven't found a single account where someone regretted their decision.
also, i don't really take much vacation in general so i could pretty much burn a vacation day per week for quite a few months to try this. i'm actually doing this right now: i took a day off even though my todo list at work is overflowing big time. my only concern with that is that the expectations don't really change accordingly. but maybe i should learn to really just stop caring about the expectations. it's hard because i don't like to break existing promises i made.
anyways, there's not much to this, either i do it or not. the reason i'm making this post publicly is to plant the idea into my mind in a stronger manner so that i'm more likely to make the plunge.
published on 2021-04-14
# principles: how to play the game
published on 2021-06-02
# batch: send emails in the mornings
rube goldberg machines are machines that solve very simple problems in an overcomplicated manner. it's quite satisfying to start them: once you start them, you can just sit back and relax. the task is now outside of your control. it might break, it might succeed, but for now you just need to wait and see.
whenever i send a document or commit for review, or i just send an email with questions to someone, i get a similar feeling. while i didn't fully accomplish my task yet, the task itself is now outside of my control so i don't need to worry about it for a little while. it's all on other people. it's a very stoic approach to task management.
the problem at work is that there's always a lot more tasks to do. so it's very hard to get to the "sit back and relax" state. so here's an idea: don't send out your artifacts immediately!
keep working at stuff: prepare docs, commits, email drafts, but hold on to them. only send them out in the morning right after you are done with your morning routine or are interrupted otherwise. this will accomplish four things:
of course there's lot of nuance to how to do this without being annoying to others. in general you would only do this with your tasks and you wouldn't unreasonably slow down the progression of other people's tasks.
i don't really follow such a practice myself yet, only sometimes: e.g. when i suddenly get inspired on a weekend and feel like working. i might solve a few tasks but i don't send them out for review on the weekend. i send them out the next monday. i always felt good on such mondays and that's what i'm trying to generalize. i guess i'll experiment a bit and see.
published on 2021-06-03
# cooldown: forcing a wait before letting users exchange messages
how do you keep a discourse civil?
one approach is moderation or peer review where another person looks at your message before sending. they could flag any uncivil behavior that you would need to fix before publishing. i think this can be pretty good but doesn't really work for private, one on one conversations where there is no third party at all. and the third party is not always predictably responsive. e.g. what if the moderator or reviewer is on a vacation?
here's another idea: cooldown. you can split sending a message into three steps: draft the message, wait for a while (configurable but e.g. 1h), publish the draft.
there would be no auto-publish: the publish would be a conscious action. and an edit would reset the cooldown so you need to make the weird decision whether to publish an imperfect message or wait even longer.
so the idea is that you don't send your initial draft, you yourself review your own message, hopefully in a different, cooler mood in which you won't send a rude message. if the message isn't worth waiting 1h for, then it's maybe better if you don't send it at all.
you can adhere to such rules yourself but maybe a discussion forum plagued with flamewars could enact this on its members indiscriminately. it could cool its members down a bit without fully stopping the discussion. it would definitely drive some people away but that's good: large discussion forums are hard to maintain and bringing down its population count is probably good. hopefully the people who remain are the ones who are really motivated to publish their thoughts, not just gut reactions. and as the community cools, the admins can lower the cooldown duration.
i do expect that some members would use browser extensions to auto-publish messages and defeat the whole purpose of this restriction. but there's still the possibility of a user reconsidering a message even if it's auto-published. so there is some potential benefit even in this case. and i'd also expect that only a minority of people would bother installing such extensions so the overall effect would be still strong.
this relates a bit to my previous @/batch post where i recommended waiting until morning to send messages. that is pretty much infeasible for most things but with the cooldown idea one can get to it halfway. prepare all the drafts one by one and then pretty much send them at once even during the day.
not sure if this is a good idea but if i ever were to build a discussion forum (or even something like an anonymous comment section on a blog like this), i'd definitely try this 3 step method as an attempt to increase the quality of the messages.
i'd implement an anonymous comment section like this:
sounds complicated but i think it should be pretty easy to implement without keeping any extra state on the server. it doesn't really protect against a dedicated spammer but might work fine in the wild until the blog becomes a target.
published on 2021-06-16
# freewrite: freewriting is the best adult pacifier
adults use pacifiers to calm down babies. but adults have their own pacifiers too, e.g.:
when one is waiting for something, e.g.
one is tempted to switch to such a pacifying activity. i guess that's because most people are very uncomfortable with just waiting.
there are two problems with the above pacifiers:
so what to do instead? freewrite! get a notebook and every time you need to wait and/or have an urge to do something else, just write out the uncomfortableness instead!
this shouldn't be your notebook for todo lists. this should be a write only notebook that you just append thoughts to, which are never to be read again.
if you don't know know what to write, just write down what is actually happening. e.g. "i'm waiting for a response from john. i feel like i should check on my email. i'm expecting an important email, i wonder i got it already. probably not. what should i respond to john if he doesn't like my idea? [...]"
keep your device open at the activity that you are waiting for. while writing you'll quickly notice if your webpage finished loading or you received your response so you can immediately switch back to your previous activity. with writing you don't need to wait until you "finish" your pacifier activity. writing can fill any duration you need to wait and can be easily stopped anytime.
it is very weird at the beginning but quite nice once the habit is established. you'll lose less context by this and at the same time it helps you to organize your thoughts in general. it's a win-win!
published on 2021-06-20
# intmon: no to intellectual monopoly
by intellectual monopoly (intmon) i mean a government mandated monopoly for specific ideas or creations. i mean mostly copyright and patents. trademarks are fine since they are for protecting specific identities so that the consumers can trust the actual product.
abolishing them has lot of upsides: more content and products, lower prices, etc. you can easily mix and match content and share it with everyone without repercussions. you can freely invent new things and not worry about patent trolls pestering you.
on the other hand intmon seems one of those things that people simply cannot imagine life without. but i'm quite convinced that if it wouldn't exist and you wanted to introduce it, it would be met with huge resistance. in an intmon-free world completely different business models would have emerged.
# copyright
in the copyright case i'd expect people wouldn't be selling the actual content but rather their self and their brand. this is already happening with youtube creators. they are not selling their videos, those are free. if they have a large number of subscribers (high influence) they sell that to sponsors by mentioning their products in their video. and most of them do this in a sensible manner: they review the product themselves which actually makes me want to watch through their sponsored section. it's not the insensitive random annoying ads that the internet is full of.
lot of book authors these days have a blog with large following. they could publish their writing there first and once they have enough content, they could bind it into a big book. or if they have a popular book already, they could be touring and talking about it with people like how musicians tour and give concerts.
i'd expect more demand for customized content: what if a vocal group really likes a fanfic of a popular tv show? now small scale studios can create that on demand. and if people can get their wishes created rather than choosing from a selection, i'd expect people would be happier with the content, and pay even more, further exacerbating the demand. perhaps content would be paid beforehand rather than after like it's done currently.
and in case of copyright i acknowledge that there would be less aaa games and movies because big studios couldn't justify spending millions in creating something that will be free in the end. but i think that's fine. those millions of moneys and human hours saved can go to more useful things like research, infrastructure maintenance or humanitarian causes.
# patents
on the patent side the most common counterargument is about the research. who will do the research if not big companies who do it in exchange for patents? drug companies are the most common example where a drug needs lots of millions of dollars to develop but very easy to produce once the r&d is done so the r&d company needs some protection to recoup costs.
but this assumes that it's companies who need to do this complex research. academia has not even a chance because these companies poach all the researchers from it. i'd expect that without patents maybe drug companies wouldn't invest that much into research but rather they would fund academia where researchers could now stay and earn good pay. and because academia is open and independent, a global community could work on the more important things rather than drug companies developing yet another antidepressant drug. but it's hard to tell what would happen but i'm quite convinced that research would still happen, researchers wouldn't disappear into thin air.
another argument is that lack of patents encourage secrecy and complexity to maintain the secrecy. but what companies can keep a secret today, they already keep that as a secret. patents are used mostly for easily reverse-engineered or replicated products. sure, it's a risk that the r&d develops something easily replicable. if a company doesn't like that risk, maybe it shouldn't do such r&d in the first place. i don't find it a compelling reason that private r&d should be rewarded like that. i'd rather see more open research done in the academia instead and ensure that any r&d fruits can be immediately enjoyed by everyone at the lowest cost.
# other thoughts
for reference i've run this idea through r/changemyview: https://old.reddit.com/r/changemyview/comments/ofdnn1/cmv_a_copyrightpatentipfree_world_is_nicer/. it didn't really make any change in my views. most commenters assumed that we would continue to use the current business models in the intmon-free world and then explain how that wouldn't work ("people would just steal your work and sell it cheaper"). well duh. that's not what i'm arguing here. i couldn't really get into the details because discussions on r/changemyview are incredibly exhausting. i'd probably need to divide my views into subpoints: lack of aaa content, no drug patents, secrecy, etc. but i'd expect discussing even the subpoints would be exhausting. i'll expand my thoughts about r/changemyview in general in an upcoming post.
in practice, while i respect the right of others, i assume any of my output is public domain. i don't really care how people use it. but i'm not producing any meaningful content really so it doesn't really matter anyways.
edit: note to myself to ask this question next time i'm discussing this topic: what's the difference between "roads" and "drug research"? why is that "roads can be provided only by the government" while "drug research can be provided only by private companies"?
published on 2021-07-12, last modified on 2012-07-14
# cmv: r/changemyview is a pretty safe corner in the harsh internet
https://reddit.com/r/changemyview is a heavily moderated forum with strict rules that try to maintain civility in very sensitive topics. usually such topics go crazy very quickly on a typical internet forum but this doesn't seem to plague this forum.
the idea is that someone posts some view they harbor and the commenters will try to convince the author of the opposite, or at least have the author learn more nuance about the issues. funny comments, agreeing with the author, rudeness gets all removed so the thread stays very much focused on the author's view.
and the whole thing is gamified. whenever the author acknowledges that they have shifted their view or gained a more nuanced view about their issue thanks to a comment, they have to give that comment a "delta". basically they have to include "!delta" or "Δ" in their response. a bot then counts the delta points over the whole subreddit and displays the accumulated delta points next to each username. it's probably a nice feeling to get rewarded with such a point and that might keep people engaged in the discussions.
the delta system also helps researchers to understand what makes some comments more persuasive than others. here's one academic's research site about this. note specifically the media coverage section: https://chenhaot.com/pages/changemyview.html.
i've tried posting some of my crazy views to see what happens:
although the discourse remains relatively civil, the whole thing is quite overwhelming. for one, there's a lot of repetition since most commenters don't seem to read the other comment threads. and some commenters seem still quite mean even if they are within all the rules which can make responding to the commenters quite exhausting emotionally.
and then i quickly learn that most issues can be broken down into smaller issues that need to be discussed separately. discussing everything in one big thread can get confusing. e.g. when i wanted to argue about the usage of uppercase letters, i could break that down into capitalization of sentence beginnings and the capitalization of names. those must be argued completely differently.
and it's incredibly time consuming. understanding your opponents' arguments, preparing a detailed but short response is not trivial. i think such discussions can't happen on a very short timeframe. while i gained a bit of nuance during the discussions, they didn't fundamentally change my views. i feel i'd need to invest more time into the whole thing for that to happen, not just the few hours i reserved to test the site.
and i felt quite disconnected from my opponents: i didn't feel i understand them, and i didn't feel they understand me either. i think anonymous forums are not for me. i prefer to know my opponent personally, i think that can make the communication more effective. i think i'd prefer to be paired with a single person to discuss an issue over months and maybe then present a shared document that contains our agreement rather than arguing with a dozen people at the same time. reddit doesn't really have a good way to present long back&forth discussions anyways.
while i probably won't be posting much to r/changemyview, it's definitely a site where i can look up discussions about almost any topic. all i need to do is to append "site:reddit.com/r/changemyview" into my search query. i recommend anyone fancying online discussions to explore this site too.
published on 2021-07-13
# ffpoll: free form poll results are more usable
how do you poll people? the typical form i see is this:
do you want x? [ ] yes [ ] no some other question? [ ] option 1 [ ] option 2 [ ] option 3
and you are expected to put a cross next to your answer. the whole thing is then very easy to summarize. but i think the result is often quite puzzling because nobody understands why people voted the way they voted.
i prefer this form:
do you want x? - yes because: ________ - no because: ________ - alternative proposal: ________ some other question? - option 1 because: ________ - option 2 because: ________ - option 3 because: ________ - alternative proposal: ________
in this form you are giving free form responses. you can still just put an x down next to the option you want in case you don't want to expand your rationale. so this form is also easy to summarize. but people often do want to express nuance and this manages to capture that. this lets pollsters better understand why people voted the way they voted. the result is then hopefully less of a mystery. make sure to publish the free form text too not just the absolute number of responses (perhaps with some editorialization if some responses can't be published).
i'm also fan of the alternative proposal line because i don't like forcing people into false dilemmas. it gives a way for people to explain their reason for abstaining. and sometimes you might find a good alternative solution with it.
note that this has some limitations. if a person chooses to give a rationale, you might be able to identify said person even if the form was anonymous. and such deliberate voting can take a lot of time. so it mostly works for polls where anonymity is not important and there's no time pressure.
i don't have much experience with this but i'm hoping that this gets more popular over time. if it doesn't really work, i guess i'll try to make peace with the simple form.
published on 2021-07-14
# news: ideas about relevant newsletters
i don't really follow news and newsletters. the stoic wisdom says "focus on things you can control". well, news is full of things i can't control. it contains mostly unactionable passages that makes me angry and depressed. it also make me distracted and i focus less on things i actually want to achieve.
i can imagine a relevant newsletter for me though. it would be very local: it would be made and involve people and places i interact with daily (e.g. my team and workplace, a sport club and its arena, a neighborhood and its street, a group of friends and their favorite pub). i'm imagining a monthly newsletter with topics like this:
not all of the above must be present in an instance of the newsletter. just a few is enough. the whole thing should be short. it should fit on a page or two so that i can skim it through quickly. the goal of such a newsletter wouldn't be to fully inform people. it should be to raise awareness and interest about my peers. and since they are my peers, i can freely ask them in person about their short snippet from the newsletter. this means that the snippets are somewhat actionable for me. it gives the people relevant topics to chat about. such a newsletter probably doesn't make sense below 5 people and above a dozen people it starts getting irrelevant. it should be put together by the same person all the time so that quality remains constant.
on the other hand i can see that such newsletter might require lot of time investment and thus might not worth it. maybe it might make sense only when the team morale or cohesion is low. a team in such scenario could commit to make 6 issues (e.g. 1 per month for half a year) and then see if people find it useful or not. in case there's a newsletter already and if one doesn't find it too relevant, maybe one could ask the writers to include more items like the above. at least now i think i know what to ask for whenever someone tries to start a newsletter around me.
published on 2021-07-15
# bureaucracy: make paperwork fun
i hear some warnings that eventually humanity won't be able to employ most people meaningfully when robots can do most of the mundane tasks for us. that might be true but i don't see that humanity would ever run out of jobs. i expect bureaucracy will take up most of the time of people. i mean even unemployed people have to spend a lot of time trapped in various procedures, e.g. waiting in lines, seeking jobs, interviewing, etc. unemployment can be like a full time job.
here's a random list of tasks that can be associated with the ever growing bureaucracy (listed alphabetically):
everything makes sense on its own but when taken all together then it feels that humanity spends more and more time on busywork. we can always find some paperwork to do for any person on earth at any time.
one way out of this is starting a company or government anew with a clean slate. or maybe you can fight against the existing bureaucracy. but what if you are not in a mood for a fight? one can try changing their perception about the whole thing. a lot of these things are painful because they are forced on people and because they often have to struggle through them alone.
try making all the unnecessary paperwork more fun. if you have to fill boring forms (e.g. tax returns) maybe draw or write some art to the margins. make it the best looking tax return ever!
a peer wants you to peer review something for them? if they are a gym buff then ask them to do 100 pushups for your review. they might be glad that you motivated them to do the pushups and in exchange you feel good about yourself being such a good motivator.
or pair up with someone to tackle stuff you hate together. you need to write some sort of report? make it an improv game where each person must write a sentence in turn. sure, it might not be the best report in the end, but at least you have something to hand in and you had some fun while writing it.
need to itemize a long expense report? if each item has a comment section then write some witty reason for each item. you can do this together if you found a partner. e.g. you can fill the details of the actual item while your partner writes the witty comment. if management protests the total time spent on writing this report then you can start arguing against the need of such report in the first place.
if some task was utterly pointless and you couldn't find a way to make it fun then you can blog about the utter pointlessness of such tasks every time you do it. maybe you gain enough followers with whom you can start a serious opposition of the need for the task or maybe someone can point out a way to make it fun for you.
if you are creating some bureaucratic form, then make sure you leave some space for people to express some creativity. at least add some free form comment or feedback section. and then do publish that feedback somewhere.
if you can make it fun then all this bureaucracy might not be such a bad thing in the end. in fact it might be a nice utopia: everyone has something to do and people have fun while doing it. i'm not saying i like bureaucracy, i'm just trying to look on the bright side of things.
# edit from 2023-12-10
on a more serious note about jobs going away: i have yet to see a hospital or school where there's no nurse, teacher, or maintenance crew shortage. i think our biological programming will continue desire to human touch so there will be always demand for certain jobs. some jobs such as nursing could absorb a large amount of people if we start to value it more. and if you don't overwork the nurses, they could do it as a part time job while they study medicine to become doctors. you could have a very clear path from apprenticeship to mastery while providing value to society during the studies. also see my @/utopia post for other related ideas.
published on 2021-07-16, last modified on 2023-12-10
# redesign: i rewrote this site's server code from scratch
this site used to serve all the posts in plaintext. but now it serves them all in html so it's convenient to read the content from any device. this is because i rewrote the whole server from scratch with a little bit different goals this time.
# server
i wrote the old server in c. it was quite simple but i found it a bit hard to modify after a while. in the past year i was working with go and found it a nice language so i decided to rewrite the whole thing in go.
the old c code's main loop was this:
it was a dumb server but super reliable. i didn't even need any state tracking and dynamic memory allocation. the server was single threaded so it couldn't become overloaded at all. the kernel itself could still become overloaded but at least that's not the server's problem.
with go things became a little bit more complex with lots of goroutines and dynamic memory allocations. and i had to be a little bit more careful about ensuring it doesn't fall over for some obvious attacks. but in exchange the code was much simpler to write because go is a really convenient language. now it will be much easier for me to add more features if i ever want to (e.g. comments). my little rpi might break sooner if i expose a more complicated server on it to the wild internet. but hey, live and learn.
# backup
an important thing i want from my blog is easy consumability. i want a single megapage that contains all the posts one page that people can simply scroll through. i call this "the backup" page and i want it to be available even if my domain or myself is unavailable. i host this on github (https://ypsu.github.io/blog/) so that it doesn't rely on my tiny webserver.
with the old solution i always simply regenerated the full backup site whenever i created a new post. but over time this became quite slow on my old raspberry pi as the number of posts and the length of the full backup page grew. this was getting more and more annoying as time went on.
in my new solution i use an automated github action for this. apparently github lets you run arbitrary code on specific events completely free for anyone on the internet. i guess i got to try it while it lasts. so it's quite neat now: i push a new post, and the backup page is automatically updated in the background after a few minutes. and even if free github actions are gone, i can now do this easily as a background task on my rpi without disrupting my usual post creation workflow.
# html
i was in a little bit of a pickle when it came to plaintext vs html. i really like the simplicity of plaintext but having the flexibility of html is sometimes awesome. i've decided it's time to go mainstream and have things in html. especially given in the last year i've created a few html demos. maybe this way i'll be tempted to do more of that type of stuff.
but i'll still write everything in plaintext files, it's just the presentation that changes.
the migration to html was quite easy because i wrote all my posts with markdown in mind. the backup page from before was already rendered as html with markdown so i was pretty much prepared for this since the beginning.
# summary
rewriting the site was fun and should make reading the dumb brainpoop i write here much easier. if i ever write something worth sharing now i hope the plaintext-ness of the site won't discourage people from reading it.
published on 2021-09-05, last modified on 2023-09-04
# golang: go is my new favorite language for hobby coding
# my history
for a very long time i was only using c and c++ to program. i used c to do all my hobby programming and doing programming competitions, and i used c++ at work.
c was fine. i really liked its simplicity. i have a peculiar style to it though: just because memory allocation and tracking is somewhat hard and error-prone in it, i just used preallocated arrays everywhere. that made coding up simple tools and puzzle solutions pretty simple: you could just focus on the task at hand, most of your effort went into the essential complexity of the problem. but such design only works if you work alone on your program and can keep everything in your head. with multi-person projects that probably doesn't scale well.
and then there was c++. i was able to do everything i wanted in it but i felt the language frustrating to use. for one, the language is constantly changing. it's quite effortful to always keep up with the ever-changing best practices and keep altering your coding style accordingly. it has gazillion small things to keep in mind when working with it and requires a lot of syntactic overhead/noise for ordinary code. but more on this as i mention how nice go is in comparison.
now and then i've looked into python but i hated it all the time. i hated that it's 100x slower than c back when i was playing with it. i hated the dumb indentation rules: i could no longer move code around and hit reindent. no, i'd either need to be very careful about this or use advanced tooling just to be able to use the language. and the fact it had no syntax check or basic types made me very anxious about correctness whenever i was coding in python. definitely not a language for me.
javascript is interesting though. on its own it's a bad language, i wouldn't really use where i could use go. but for gluing things together in web i think it's pretty neat. i think i'm pretty happy as it is. i don't use typescript though. if i felt i'd need to use typescript because my web js grew to a non-trivial size, i'd probably switch to go and use little js to glue things together.
about a year ago i started dabbling with go at work. at first it was weird but i quickly became a convert.
# wisdom
maybe i drank too much koolaid but go seems very mature to me. with most of the other languages i feel they are just a random set features their creators felt nice. with go i feel it has a limited number of features but all those features are important for achieving your daily coding tasks. it's as if their creators were very experienced programmers who knew what one needs for programming conveniently without all the nonsense.
take the zero by default stance. in c you can have uninitialized variables. sure, in theory this might be a little bit inefficient in some cases. but in practice it means you don't have to litter your code with excessive initialization code. it's a sensible default that you can lean on, embrace, and reduce total noise in your code. less accidental complexity in your code.
and these sensible defaults perpetuate the whole standard library. for instance the standard library allows you to run a web server with only a few lines of code and no external dependencies. and you don't need to set up gazillion structs, configs, compiler flags, and other noise. you need a port and a serving function. you can serve anything, go will detect the type and serve the content with the right mime type. it still allows you to configure everything but tries hard to make the common usecase very effortless.
# naming
go's naming structure is one of the nicest things in the language! i really hate c++'s namespace solution. people tend to create ::very::deep::namespaces and it's a pain to work with. go encourages short, unique, single word (no dashes/underscores) names. and it's not hierarchical. every reference is <package>.<object> so referring to objects is not agonizing to type. this is a big win to reducing the "noise" i feel with the other languages.
giving uppercase letters a meaning was quite a brilliant idea. it was very odd for me initially but it's a very neat way to reduce visual pollution in the code. no need to explicitly write out "private" and "public" anymore. that thing annoyed me in c++. it also made reading code harder: suppose you are digging into the code and you spot a nice utility function that you could use. can you use it? well, who knows. you now need to scroll around in the code to figure what context it is defined in: is it exported or is it in the unnamed namespace? if it's a class member, is it in the public section? that's very easy to tell in go at one glance.
# memory management
with explicit memory management you need to be very careful about how you structure things. you need to figure out which object will own what other objects so that it's clear who will be responsible for the cleanups. and even if you manage to do this, now you have to do a lot of busywork during initialization: you have to use special pointers with cryptic initialization schemes (hello std::unique_ptr<> and std::make_unique<>) and have to explicitly transfer ownership (hello std::move) multiple layers down until the pointer gets to the rightful owner.
it's a lot of busywork that i really hate and that's why i stuck to using static arrays in c. i'm sure clear ownership structure can be satisfying and all but i don't really care about that. i just want to get things done.
garbage collection alleviates these problems. coming from the c world this was very alien to me and created some anxieties about performance and resource utilization. but then i've seen how much simpler coding is. and then i've seen how much of a good job go is doing in this area. in practice it has pretty low overhead. and these days computers got quite overpowered when it comes to cpu and memory so i might as well trade off these advances to make my daily life more convenient. so now i don't mind having a garbage collector. it's a tough pill to swallow at first but it's easy to get used to its comfort.
# tooling
tooling is incredible for this language. and they all come prepackaged, no need to install gazillion auxilliary tools.
let's take the compiler. with c/c++ you need quite a few of cmdline flags and makefiles to get it working. in go if you structure your project well, then there's nothing to configure. just "go [build|run|test] [packagename|filename]" and that's it.
and i really like how much nicer the error messages are in go. you make a one char typo? you probably get one line worth of error in go on the line you made the typo. in c++ you are likely to get rewarded with thousand lines of errors and a puzzle of trying to figure where your error might be hiding.
my favourite tool is goimports. this one tool boosted my productivity significantly. now keep in mind that i'm pretty much a caveman when it comes to computers. i use a vanilla vim with no plugins: no autocomplete, no syntax highlighting. i like it this way because i enjoy the puzzle of figuring out the right things to write without help. however figuring out the right header files to include was not fun. in fact it was annoying. but in go this problem goes away completely. you just write code normally as you are, and go figures out the right dependencies for you. you don't need to deal with that. that's pretty neat. i guess a modern editor can also do this for the other languages but i like that go doesn't need an elaborate editor. even a dumb simpleton like me can use it without wanting to jump out of the window.
godoc is another great tool. i used to browse the source code directly either in my editor or in a hyperlinked source code viewer. that worked quite well in general. i was never really fond of doxygen like stuff. i felt it as an unnecessary overhead. but i don't really have that feeling with godoc. go docs are almost like manpages in terms of quality. maybe it's because if i'm looking at some code, it's very easy to jump to its doc based on the short package name + function name. in c++ you don't really have a good idea what's the fully qualified name under the symbol, and even if you do, you probably need some editor support to jump to find the right place. with go i can look up documentation without advanced tooling support so that's nice.
# threads
generally i don't like threads. i've debugged a lot of race conditions in my life. my favorite hobby is putting some carefully placed sleep statements in people's code and then see their code blow up. threaded code is quite error prone.
so i was initially quite averse to goroutines. but over time i got quite okay with them. again, go also provides channels as a language construct and recommends using them everywhere with goroutines. thanks to these i had to deal with only a handful of race conditions in go. one just generally avoids them there.
and i like how lightweight the goroutines are compared to a full os thread. i'm still averse to using multiple threads though. it makes the code a bit harder to understand. but with channels i can often think about goroutines as a small standalone processes that don't share memory with others and that makes it somewhat easier. so in the end i'm pretty much on good terms with go's concurrency, i don't hate threads in go as much as i'm hating them in c++.
# other features
i probably don't even remember all the nice things i like about this language. but here are a couple more small things:
# other contenders
there are a few other languages that i had cursory look but never liked them.
# summary
over time i started to hate programming because of all the nonsense they require but with go i started to like programming again thanks to its simplicity and approachability. i really hope its creators don't catch featuritis and it stays simple at least until my retirement. if anyone asks me what language they should program in, then i can only recommend go.
though keep in mind that my usecase for a programming language is to occassionally write a small tool or a little service. i'm not really working on huge codebases, doing high performance computing, or coding all the time. for my usecase i think go is great. other people's mileage may vary.
published on 2021-09-20
# yogurt: the cherry emmi yogurt is my favorite
this post has non-textual or interactive elements that were snipped from this backup page. see the full content at @/yogurt.html.
this is a post for my own reference in case i ever forget this tidbit because of old age or whatever. i quite like yogurts in general as dietary entertainment. i'm not entirely sure what they are made of and i probably don't want to know. i guess i like their creaminess. finding the perfect yogurt is pretty hard though. but i think i've managed to do so this time. it's the emmi's cherry yogurt here in switzerland. you can get it in many places, including coop and lidl.
it's one that you need to mix up: the cherry sauce is at the bottom. it has a pretty good tasting sauce. but the white cream at top is a bit sweet on its own, so it can be eaten alone too. it's best if you don't fully mix the sauce and the white cream but eat it like the way it is pictured on its cup (see pic below). for some reason this cherry flavor goes well with the yogurt cream unlike, say, chocolate which is a bit weird (though i like that too).
if you ever wanna try a yogurt, try this one:
[non-text content snipped]
published on 2021-09-21
# semhi: auto-highlighting @/sembr lines
this post has non-textual or interactive elements that were snipped from this backup page. see the full content at @/semhi.html.
a while ago i wrote about how i love semantic linebreaking in @/sembr. i still use that form of writing wherever i can and simply rely on markdown presenting the text in the usual, justified manner. the source of this post and all the posts after that sembr post are written in this manner. i also write my emails with sembr and then convert them to html via my own markdown renderer just before sending them out. people usually don't notice that i write in this manner.
i was wondering about something. some sites (e.g. medium.com or google docs) allow you to select a text and then do an action on the selection. e.g. add a comment. so how about making such actions work only on the full lines from the source? each line is almost of a full thought after all.
so this post is actually an interactive demo! you need javascript for this to work though. if you have a mouse and hover over the text, then you'll see the full line of the text under the mouse highlighted. (i know some people obsessively highlight sentences as they read. maybe this could help them a bit too?) and then you can click or touch on a thought and a small popup under it will appear with bunch of buttons. click on the sentence again to dismiss it.
the buttons in the popup don't do anything, this demo just wants to investigate if there's any usability benefit of restricting operations to implicit ranges rather than requiring the user to select the range explicitly.
i think i like the idea but so far i'm not sure for what would this be a good match for.
edit: a few more notes. given i use hash in the url to store the state, i can easily link to a specific line: the browser will immediately scroll to it. this can be better observed if you zoom in the page and then open the url with a specific line in it on a new tab. i think this is pretty nice.
edit on 2024-10-12: simplified the js. one gets better at programming over time, fascinating.
[non-text content snipped]
published on 2021-09-26, last modified on 2024-10-12
# dasung: a review for the dasung 13.3" e-ink monitor
in late 2020 i bought dasung's 13.3" hd-ft e-ink monitor. hd means high definition (2200x1650) and ft means frontlight + touchscreen.
i'm using it for a year now for the occasional hobby writing and i'm pretty satisfied with it. it does what it says on the tin: it's an e-ink screen that you can connect to your machine with an hdmi cable.
i think my eyes like it quite well. i usually use it in the mornings to do some writing or coding because i don't feel it's burning out my eyes like an ordinary led screen usually does. it takes a while until my eyes "wake up" and can take an ordinary monitor. but i also use it whenever i feel doing some hobby work (like writing this blog post).
it has vesa mounts so i have it mounted on a monitor arm. i'm heavily myopic, about -5D which means i see clearly up until about 20 cm. i usually look at this monitor from a close distance without any glasses. i sometimes tried doing this with ordinary monitors but that usually wasn't too pleasant. with this monitor i don't mind doing this. i also read my kindle without glasses and this is similar. it's a nice feeling that sometimes i can use the computer without any glasses. the most satisfying time to use this for me is the afternoons. i arrange its monitor arm in a way that the sun shines onto it. it just feels nice to work in sunlight.
i have it connected to my raspberry pi 4. it was bit of challenge to set it up. for starters, my archlinux needed a special hdmi_enable_4kp60=1 setting in its config.txt (https://github.com/tommythorn/Paperlike-Raspberry-Pi-4/issues/4). this one took me a while to figure out.
but the bigger challenge comes in setting up the user interfaces right. this is a monochrome screen. it can do only black and white. no grayscale. anything other than black and white is emulated via dithering.
this means i've disabled any aliased fonts in firefox and simply hardcoded all the fonts to terminus in it. that font is crystal clear to me, while aliased fonts were a bit too noisy for me (maybe i'm too picky). some of the websites look a bit uglier but in exchange it's easier for me to read them.
and i also made some changes to xterm to disable color handling in it: with my change anything colored is usually handled by either with a very light gray background (so very little noise around the letters) or simply inverting the colors: white on black for that cell. it works pretty well. for my own reference, this xterm patch is at @/dasung.xtermpatch.
i do some limited internet surfing on this too. it works completely fine but it's not as nice as on a fully colored monitor. at least i'm reminded that i should be doing some more coding or writing instead. if it could do grayscale, maybe there would be no dithering and i would like it even more.
the refresh rate is obviously slower than a led screen but much faster than on a kindle. it's fast enough that it doesn't really get in the way. fun fact: in the past i also used kindles as a screen for my text editor, mostly the large kindle dx 2. i usually ssh'd onto it, then ssh'd back into my tmux while my keyboard was still connected to my raspberry pi. so i still controlled my rpi but thanks to tmux's multiplexing feature, i've seen the output on the kindle too. but the overly slow refresh rate of kindle dx 2 made that painful so i didn't do this that much. no such problems with this dasung.
i think dasung now has a 25" e-ink monitor too. i probably wouldn't buy that, it's a bit too expensive at the time of writing and i don't really need it. at work i have to interact with all sorts of colorful web user interfaces so all the dithering would bother me too much.
but otherwise i can wholeheartedly endorse this product for someone who wants do some distraction-free text work and doesn't mind a bit of tinkering to get the editor color settings right.
published on 2021-09-29
# emailhost: i use gmail for my personal email, i couldn't find anything better
what service should one use for their private emailing? there are many options and each individual's needs are different. but let me explain how i arrived at gmail as the option for my usecase by exploring couple of alternatives.
# fastmail
fastmail is a paid email service. its list of features is pretty nice. for instance it lets you create aliases so you don't need to give out your real email address when somebody needs an email address.
however it is a paid service: you need to pay each month. if you don't, your account gets cancelled, you are locked out of your address. and it's even worse: after your account is gone, your username reopens for registration so somebody else can easily take over your email address. that sounds pretty scary in today's world where email is pretty important since you can easily get access to any service with just a simple password reset via email. this just feels too risky for me. this is described at https://www.fastmail.help/hc/en-us/articles/1500000279581-Expired-subscriptions:
If the account is still not renewed after a few weeks, access to the account will be disabled. Eventually, the entire account will be deleted, including all stored messages. Once an account has been deleted, the username and any aliases on the account can be re-used.
# custom domains
i see lot of people advocating for custom domains. it makes sense if you use the email as a professional address but for a personal address it sounds a lot of hassle.
this also needs payments so it has similar downsides: if you are incapable of paying for any reason, you get locked out of your email and others can take your address which is too big of a risk for me. oh and you need to make sure your dns provider doesn't get hacked either. overtaking your domain would also mean game over for your digital life.
and custom domains require a lot of expertise (or money) to get right. you need to run the email hosting service or pay someone to do it for you. and ensuring that you keep getting through the spam filters is also a lot of work.
# protonmail
ok so i don't like paid email because it requires non-trivial effort to keep them running. there are many free alternatives. one example is protonmail which aggressively encrypts your email storage. but protonmail is a usability nightmare for me. vanilla imap no longer works with protonmail due to the encryption. and if you ever lose your password, you can no longer access your old emails. this is described at https://protonmail.com/support/knowledge-base/reset-password/:
Your password is used to decrypt your emails and other data. Proton does not have access to it. If you forget your password, you will lose the ability to read your existing emails and access saved data.
there are some cases when that doesn't apply (https://protonmail.com/support/knowledge-base/restoring-encrypted-mailbox/) but in general protonmail's threat model doesn't really apply to me. besides, if i wanted to have a sensitive conversation with someone, email would not be my protocol for that anyway.
# gmail
i use gmail with mutt/imap and it works pretty well. my only big concern about gmail is that they might lock down my account at any time and i won't be able access my email anymore. such things happen quite frequently according to the news. but this risk can be somewhat reduced: don't use your gmail account for any other google service. don't use it for youtube, don't comment using it, don't use drive. create separate account to use different services. keep a separate account just for private emails. then there's very little risk that you'll lose your account for leaving a bad comment or similar nonsense. and besides, such risks are present with other services too. you can be locked out of your fastmail account or your domain could be seized. at least gmail doesn't allow username reuse.
the other big feature i really like with gmail is its inactive account handling. if i understand correctly, it allows configuring trustees for your account. e.g. after an inactivity period elapsed your spouse can access your email. then they can then access government and financial services that you registered with your email address. and since the account is free, the account will stay live if you simply share your password. compare this with fastmail where any random stranger can take over your email address after some inactivity period.
# aliases
there's one thing lacking in gmail: it doesn't allow you creating aliases so if you use it raw, you'll leak your email address and get ton of spam with no option to stop that after the leak. i'm aware of the + aliases, but that still leaks your address. this is a bit annoying so you need a forwarding service to address this issue. i found the following ones:
all of them have free plans. i started using anonaddy since that seemed the most sympathetic to me. it's pretty neat: you click a button and it generates a "randomstring@anonaddy.me" email address for you. you can generate a new address every time you need an email address (e.g. to register on a site).
when somebody sends an email to that address, anonaddy will forward it to you. anonaddy will wrap the original message, it will tell you through which address you got the email from. it will also let you disable the address in case you start getting spam on it. it will also let you reply through that anonymous address. anonaddy will automatically rewrite the to/from fields so you can have email conversations without ever leaking your address.
another benefit of using a forwarding service is that it's a bit easier to change your personal email. you just forward the anonaddy emails to a different address, no need to update the email address in all the services.
# would i pay for email?
yes! with the right payment model, of course.
i don't like the monthly subscription model. i'd prefer a usage based model. rather than paying monthly, you pay, say, $10 and you get a quota of 10k emails and 100 MB bandwidth. you can use your account indefinitely until you run out of your quota in any dimension. then you can still access your account (up to, say, 10 years), you just can't send and receive emails. you can then top up your account again to bump your limits. you would only pay a monthly fee if your storage goes over, say, 10 GB. the service could delete old emails to get your account under the quota if you don't pay.
with such a service i would worry much less about the fact that i cannot pay for some reason and then i lose my account even if it barely gets any usage. in the fastmail's case a heavy email user pays the same as the light user. this model is paid after usage. it sounds fairer to me.
but i haven't found such a service yet. if fastmail fixed the account name reuse issue and provided such a payment model, i'd definitely consider paying for it.
to be fair, i don't really need indefinite account retention and username reservation. about 10 years should be relative safe.
# summary
in summary for my personal email i choose a free service like gmail with a free forwarding service like anonaddy. so far that's the best combination to get the features i need:
edit 2024-01-19: added a note about hacking dns providers to the custom domains section.
published on 2021-10-26, last modified on 2024-01-19
# stream: stream your consciousness using freewriting
consciousness is one of the unsolved mysteries of life. some people (including me) also experience an inner voice that just keeps talking talking talking without end. i know some people don't have such voice (reddit calls them NPCs as in non-playable characters, see https://nationalfile.com/redditors-go-viral-for-admitting-to-having-no-internal-monologue-thinking-like-npcs/), and some people think primarily in images or emotions.
but if you happen to have a voice in your head then you can easily record it! this voice often has some good ideas but we often zone out, don't listen to it. and in my case then it goes in circles and says the same thing over and over again obsessively. maybe it keeps telling me the same thing just because i refuse to hear it out. but magical things happen if you keep recording this voice over a long time.
and the tool for recording it is freewriting.
# method
so what do you write?
everything!
get a notebook and simply write down all your thoughts as they come, don't filter, write as much as you can. write every word that pops into your head.
i write one thought per line rather than writing continuosly. this way it's clearer for me where the thoughts start and end.
you don't need to publish these thoughts. all it matters that you write them down. feel free to throw away or shred your notebook after you filled it.
freewriting might also work if you write your thoughts on a computer only. but i prefer writing on paper so i don't have as much experience with that.
# sensitivite thoughts
sometimes you might want to write sensitive thoughts. e.g. vent about your partner that you really don't want them to ever read. if you are concerned about other people reading your thoughts, then just shred your notebook papers right away. sensitivity shouldn't stop you from writing. often freewriting is most useful for the topics we feel sensitive about.
in case shredding is not possible (e.g. you want to hoard your writing), you can try using codewords to encode your thoughts on paper. it's usually only the last sentence that you need to be able to decode and your short term memory will be good enough to be able to decode that for a while.
example: "my preferred 6 p is the sn p." that probably made no sense. but make these substitutions: p=position, sn=sixty-nine, 6=sex. suddenly you can decode that private thought even though for others it makes no sense.
or you can use metaphors. my @/thecook post was a big metaphor for a thing that occurred to me and wanted to vent in a way that the actual event is unrecognizable. that story probably makes no sense for anyone but me. i know what i meant by each concept so the story makes total sense to me and that's all what matters when it comes to freewriting.
it's not really a novel finding that writing helps one sort things out, look: https://en.wikipedia.org/wiki/Writing_therapy.
# finding time
if you are a morning person like me, then i think the best time for this is just before going to bed. then the mornings are your productive hours so make sure to spend that on productive stuff. but at the end of the day people are usually tired, they tend to do aimless browsing, netflix binging. rather than that, just try to observe your consciousness when tired using this tool. it's quite fun after you get the hang of it!
published on 2021-11-05
# focus: maintain focus by freewriting
how does one avoid all the distracting thoughts while trying to focus on a task?
by freewriting! (the technique explained in @/stream.)
# caveats
i should start with a few caveats though. everybody is different so freewriting won't work for everyone. i suspect that for this to work you need to:
also, as with any habit, it's quite hard to start working like this. but it's pretty mechanical, so it's easy to tell whether you are doing it right or not. and it might take a few months until you get the hang of it which means you might give up before you start seeing the benefits from doing this.
# modes of operation
i think there are two main modes we operate in:
you need to be in feedback mode when you work on something that you don't necessarily love. when you work on a computer alone, there's nobody who will tell you to get back on track if you ever start doing something else. and a lot of work actually happens invisibly in the head. so even if you had another person watching you, they wouldn't be able to tell if you are distracted or not.
and often even yourself cannot keep a watch of your own thoughts. maybe a very distracting thought keeps popping back into your stream of consciousness. e.g. a drama from your personal life, or a strong desire to do something else (play a video game, or watch netflix/porn, smoke). they simply overtake your ordinary thoughts that you need for the task at hand.
i propose that the solution consists of two parts:
# anchoring
expressing a thought in a written form makes it more coherent, more concrete. that's a big help in understanding your own ideas. but the primary utility is in anchoring.
whenever you complete a thought, a bunch of new thoughts appear. they can either relate to the previous thought or they can be completely unrelated (e.g. a desire to procrastinate).
if you are daydreaming (i.e. you are in instinct mode) you would select the most comforting thought and you would follow that without anybody stopping you. if this new comfortable thought is unrelated to your task at hand, you pretty much stopped thinking about your task.
but if you are freewriting then you now need to write down this new comforting thought if that's the one you want to select as your next thought. if it's unrelated to your previous thought then writing that down will feel wrong. it would make your writing way too incoherent. and that feeling of wrongness is the feedback that will help you get back to your task (i.e. you are in feedback mode). you are now more likely to drop the comfortable idea and select a different, more on-topic thought to write down.
so as you write down your sentences, they act as an anchor that keeps you somewhat on topic. and the act of writing takes time during which you need to keep your thought in mind. this helps you to gain more on-topic followup thoughts.
writing things down also helps you avoid thinking in circles. in instinct mode we often busy-loop over the same obsessive thoughts. but if you keep writing everything down, you'll quickly notice that you'll develop new thoughts just to avoid writing down the same sentences over and over.
# anecdote
i found a nice anecdote about the renowned feynman that suggests to me that he also did use writing to sort his thoughts out. here's the anecdote:
When historian Charles Weiner looked over a pile of Richard Feynman's notebooks, he called them a wonderful 'record of his day-to-day work'.
"No, no!", Feynman objected strongly.
"They aren't a record of my thinking process. They are my thinking process. I actually did the work on the paper."
"Well," Weiner said, "The work was done in your head, but the record of it is still here."
"No, it's not a record, not really. It's working. You have to work on paper and this is the paper. Okay?", Feynman explained.
if he thought writing is the real thinking process, then maybe it's really worth a shot to write more!
# in practice
so what is the actual method?
suppose you have to write an essay or a complicated email. what often happens is that you don't even know where to start. you don't even know what should be the first sentence. i propose that you run the following algorithm in a loop:
published on 2021-11-06
# questions: the famous 36 questions
there's the famous 36 questions that can help you make friends with a stranger. i quite like them, they are pretty good questions. i'll save them in this post so i can easily refer to them without wading through search engines and ads all the time.
for my own reference, here's the hungarian translation:
published on 2021-11-20, last modified on 2022-01-05
# mingling: i can do only work related interactions
i'm useless at informal social interactions. i fail even at informal penpal emailing: people stop responding to me after a while. i guess i have an overly annoying, unhelpful style. or maybe it's because i just can't seem to be able to care enough about others, and thus can't really connect with them.
on the other hand at work people seem to be content with my communication skills. i answer people's questions, follow up on my todo items, etc. i really like completing tasks and then seeing people happy with the result.
during work i interact with people. and sometimes such interaction has casual elements. the nice thing is this: if i'm not in the mood for casual stuff, it's easy to switch to work matters. i don't have such a fallback in non-work relationships so i just stay silent for most of the time.
so for me to casually interact with another person, i really need a common task or goal with the other person. then i can talk with them about that and slowly open up for some casual interactions.
it's impossible for me to go to a bar or a dinner party and "mingle". but if i have a clear task with clear expectations (like what you usually have at work) then i can maintain a facade of a reasonably-behaving adult.
i have been working from home since about 18 months thanks to the covid pandemic. during this period i often thought about maybe getting new friends and doing some socialization, but nothing really works for me. now the company is pretty lax about being remote vs working from the office. while i like being at home, i think that when the office world returns to normal, i'll probably start going to the office 1-3 days a week just to get some of this social life. i feel significantly more productive at home so this will come with some productivity loss. it's not that i really need this social life, but it's nice if you can rant/vent about things in person during lunch and other breaks.
i wonder if this realization could help me with some of the non-work interactions. maybe during such an event i just need to find a common task or goal with my conversational partner. that would transform the interaction into a worklike one and maybe then i could function. hmm. something for me to think about.
published on 2021-11-21
# codereview: phrase code review comments as questions
it's well established by now that code reviews are incredibly useful. but how should i phrase the comments?
i found pretty good guidelines on commit messages and code comments but i haven't found any good guidelines on code review comment phrasing. for my own reference, let me recap what i found on those first two topics.
# commit messages
git recommends imperative mood for the first line of the commit message, the commit title. "fix bug" rather than "fixed bug" or "fixes bug". it explains what the commit should do when applied to the codebase.
i'm not sure if there is a strong reason for this custom but it's quite common, unambiguous in this context, and is the shortest english form. i quite like it.
# code comments
for code comments the 3rd person form is the best (indicative mood). take this snippet:
// fill the slice with zeros. func frobnicate(v []int);
what does that tell you? it can either tell what the function does:
// (frobnicate) fills the slice with zeros. func frobnicate(v []int);
or it can be a request towards the user:
// (you should) fill the slice with zeros (before calling frobnicate). func frobnicate(v []int);
with the imperative it's unclear whether the comment is a function description or an instruction towards the function's user.
this problem is significantly reduced in go, since godoc requires that the function doc comment starts with the function's name. this ensures that only the 3rd person form can be used.
# review comments
but what about code reviews?
if the reviewer has to ask for a clarification then that's easy: they ask. but what if the reviewer has requests? take the following code snippet:
// fill the slice with zeros. func frobnicate(v []int) { for i := 0; i < len(v); i++ { v[i] = 1 } }
there are 3 problems:
the reviewer thinks this is how it should look like:
// frobnicate fills the slice with zeros. func frobnicate(v []int) { for i := range v { v[i] = 0 } }
but how should the reviewer ask for the necessary changes?
# survey
i surveyed a couple folks that if they were the author, what comments would they like and what comments would annoy them. now keep in mind that we are all professionals and we always communicate in a respectful manner. but even respectful communication has small nuances to it.
note that our code is company owned, there's no "this is my code" mentality among my peers. in this particular case i asked about the "setting to one" bug. nor i do i like comments like "why did you assign one?" or "couldn't you assign zero here?" because that's commenting about the person, not the code. they were mentioned in the survey but people didn't really like them (nor were they the worst alternatives).
(i admit i used a different, much longer code snippet in my original survey but i'll try my best to paraphrase the comments so that they apply to this scenario. i've sent out the survey on a whim without thinking it through. oh well.)
here the reviewer is trying to phrase a request in an overly soft way. but this comment is annoying because it states a preference: why should the author care about the reviewer's preferences? the author might not even sure how to respond to such a comment.
a similar analysis could apply to comments starting with "we should", "you could", "can we" etc.
in the survey i differentiated "assign 0 here." and "please assign 0 here." people found the one with the exclamation mark the most annoying. i guess the problem is that it makes you feel like a subordinate to the reviewer because all you can do here is to follow the other person's commands to the word or start arguing with them.
the word "please" also annoys a lot of people (including me). for me the command form already creates this subordinate feeling and then you top it off with "please" which makes the whole sound patronising. (i'm exaggerating here, i actually have pretty thick skin when it comes to any online messaging.)
this phrases the comment as a question. this is pretty neat: it clearly points out a problem without radiating any antagonistic intent.
answering after fixing the bug is easy: "oops, fixed, thanks!" such a positive response flows very naturally.
the answer is quite positive even if the author's code is correct: "nah, that should be one. the function comment is wrong, let me fix that instead."
questions are cool.
this message is a clear indication of the problem but it doesn't have that commanding mannerism around it. the "think" makes it clear that the reviewer considers themselves a fallible person, they are here to catch problems rather than telling the author how to do their job.
# my suggestion
the preferred comments are more of descriptive nature. they point out problems rather than simply tell the author what to do. the author might even have better solutions for resolving the reviewer's concerns since they probably have more context about the particular code snippet due to the fact they are working on it right now.
giving a request is also possible. phrasing it as a question opens a discussion which is a more pleasant form of exchange than commands sprinkled with fake pleasantries (e.g. please).
two together leads to this 2 part form:
often one part makes the other part obvious. in that case the other part (either of them) can be left out.
# examples
here are some examples how my comment style changed after the above thoughts.
// fill the slice with zeros. func frobnicate(v []int) {
though in this particular case i often might omit the first part if i know that the author is well familiar with the style guide and this is just an omission. in that case i'd say only "frobnicate fills" but with the question mark.
for i := 0; i < len(v); i++ { v[i] = 1 }
// fill the slice with zeros. func frobnicate(v []int) { for i := 0; i < len(v); i++ { v[i] = 1 } }
here the "assign zero?" part could perhaps be left out (more precisely: left implied).
err := doX() if err != nil { return err }
enabled: false
for _, v := range a { if err := doX(v); err != nil { log.Error(err) } doY(v) }
for _, v := range a { go func() { a(b(v) + c(v)) } }
func (o *obj) f() { o.mu.Lock() o.count++ }
i'd use "what do you think about" for the cases where i'm less certain about:
if err := g(); err != nil { return err }
if err := g(); err != nil { return err }
# other considerations
these types of comments work best for authors whose judgment i already trust. for junior members i might lean to have a more instructive style rather than the questioning style. the rationale would be that they might really just want someone to tell them what to do until they get the hang of all the things.
i generally approve early on and trust that the author addresses my comments. i try to avoid nitpicking about naming, commenting style, even at design choices as long as everything looks reasonable enough. i'd rather err more on "let's make mistakes and learn" than obsessing too much about perfectionism. the author will feel less ownership and control of the code if they have to rewrite all their code to the reviewer's preferences. it sours the relationship with the code review, makes it something that people will dread rather than look forward to. note that with this i'm making gross simplifications and omitting a lot of nuance here; i just want to raise this aspect of the reviews: it's sometimes ok to submit lesser quality code to make sure people make progress and are not trapped in a bad place.
in any case now i just need to get into the habit of using this new style of communication.
published on 2021-12-25
# poker: a reference post about the rules and the hands
this post has non-textual or interactive elements that were snipped from this backup page. see the full content at @/poker.html.
this is a reference post for myself so that i can easily look up / print poker rules and hand order.
# game variants
# hand cheatsheet
distributing a cheatsheet to everyone before the game makes thinking easier during the game. press print on this page to print many copies of this table below. you might want to limit the print range to the first page only and might need to play with print scaling to get enough cards onto one page.
[non-text content snipped]
# personal notes
this is probably quite annoying to others but i love to reveal only the weakest cards that can still give me a win. e.g. even if i have a four of kind, i'd only reveal one pair if that secures me a win. this is extra fun with another player who does that thing. imagine this showdown:
i find such revealing method more fun than the boring "let's show all the cards at once". obviously this only works in for-fun settings with friends rather than for serious games.
published on 2021-12-26, last modified on 2022-04-10
# progress: innovation is inevitable
in @/intmon i ranted about intellectual monopolies. the existence of such things makes me a bit sad so i thought i'll try to collect some thoughts to convince myself that it's a temporary thing and we'll grow out of it. i came across a very comforting thought: "innovation is inevitable". that's good news: perhaps in the end all attempts at stifling progress will eventually fail.
# evolution
life is one of the big mysteries of the world. but we know about the building blocks: genes. these genes copy, transform/mutate, and combine themselves to create new genes.
ideas or memes are the same. whenever you see something, that something's idea is copied into your mind. you can then spread it. often you mutate said idea or meme a little bit (adding a caption) or you combine it with other idea or meme in a novel way, and thus new interesting ideas or memes born. this could be called as "social evolution".
# learning
how does learning actually work? do you read a book and then suddenly understand everything in it? if you are like me, then probably not.
every idea is basically a combination of other ideas or concepts. when you see an idea where the concepts it works on are unfamiliar, learning cannot happen. however if you know all the interacting concepts well, and the combination makes sense, learning seems to be effortless.
think about explaining the intricacies of the c++ programming language to a caveman: impossible. however if you talk with an experienced programmer, they will probably know some of the words and might have some vague idea what you are talking about.
learning happens when we combine and strengthen the concepts we are already familiar with.
# fertility
when weed takes root in a fertile ground, it will spread. in the case of an idea, the fertile ground can be thought as having a large number of people with an understanding of an idea's concepts. when the idea makes sense, it'll spread among the people. if it's simple, you cannot stop an idea from spreading. and so the new idea's concept will expand the list of concepts upon which new ideas can grow on.
but this means that ideas have a "prime time". an idea can be too early and it simply won't make sense. you couldn't build facebook in the medieval times.
but there's a converse observation: when the ground becomes fertile for a specific idea, it's very likely it will appear and spread. if the right fertile ground appears, an innovation happens on multiple fronts. in practice this means that new inventions born independently around the same time. this happens very frequently: https://en.wikipedia.org/wiki/List_of_multiple_discoveries.
so if you invent something, chances are someone invented it at the same time too just because you work on the same fertile ground.
just think about companies facebook or youtube. many people have attempted to create similar technologies before them. but usually they were too early: internet wasn't as commonplace that would have allowed such companies to grow. facebook and youtube came at the right time with the right interface (being free). basically they had dumb luck. had they not come, some other companies would have created very similar software to fill this niche.
this means that if the time is right, innovation will happen one way or another. innovation is inevitable.
edit 2023-12-04: the book "where good ideas come from" from steven johnson calls this "the adjacent possible". it's a nice book, i recommend it.
# regulation
uncontrolled evolution in life leads to jungles: a rich, diverse, self-sustaining, and very resilient ecosystem.
controlled evolution is like agriculture: a monoculture that requires a lot of resources and maintenance. it's not self-sustaining. and it's very vulnerable. think about how much worry banana farmers always have due to the banana plant being very vulnerable to disease.
currently the regulatory world (copyrights and patents) doesn't acknowledge the combining nature of the ideas. it treats them as property, as if they live in isolation of other ideas. however this view is in a strong clash with reality. thanks to the internet, ideas are combined at an even larger rate. similarly to agriculture, this will become more expensive and brittle as people need more and more patents and copyrights to defend their turf. the regulation won't be able to keep up. i'm on the strong opinion that it will simply fail. the regulation can delete videos from youtube or delete code from github, but they cannot delete them from people's machines. all regulation can do is to move things underground.
# tragedy of commons
a common counterpoint against unregulated access to a resource is the tragedy of commons. the resource can be a field to graze cows on or a lake to fish in. it assumes that people will be greedy and will overgraze or overfish the resource to extreme levels at which the resource will not be able to regenerate and thus the resource dies.
however in practice this turns out not to be true. in practice a governing community grows around the resource and people learn to take only their fair share. elinor ostrom got a nobel prize in 2009 for disproving that the tragedy of commons being universally true.
and this is true even in truly underground activities like piracy. just look at the elaborate release rules or the warez scene: https://en.wikipedia.org/wiki/Warez_scene#Release_procedure.
i'm not concerned that lack of regulation in this space will cause trouble. there's no need to regulate a jungle to keep it alive. trying to control it usually leads to death in some way. however the jungles are important piece of life on earth (they provide the breathable air for us). similarly, we need idea jungles because our big problems need lot of creativity to resolve.
# prime time
in general there's a slow trend to work less. there might be a time, when our basic needs will be met well without needing to work for it. when that comes, people will have a lot more free time to pursue their non-profitable activities. scientists will stay in academia where they will work for the fame rather than money. since academia is more about ideas rather than actual products, there wouldn't be much to litigate about. or they will work in government sponsored research where they can work free from the threat of patents (e.g. nasa). artistic people will create their remixes in underground as mainstream's litigative native will be too expensive. underground material will start to overtake the mainstream in demand and the copyrighted mainstream will slowly dwindle away.
if some company wants to litigate others, they might do so for a while but they will soon go broke simply because of the litigation costs. their litigation courts might not even take place because the system will not care about them, waiting times will be simply too long. the time they spend on litigation means they don't evolve which means they will soon become obsolete as novel ideas take over world. it'll be a losing battle.
# future
i'm optimistic that humanity will reach a point when we'll be so rich that hard work won't be needed. work will be done for pleasure.
i think the key turning point will be when the asteroid mining becomes a thing. suddenly we'll get access to an incredible amount of raw resources. at that point we'll build more and more crafting infrastructure in space, outside earth. nobody cares about pollution in space so it's the best place to build stuff there. and humanity will remotely control all this from earth. production on earth will cease as it will be more hassle to deal with all the environmental regulation. we'll import our goods from space.
earth will become a pollution-free living space for humans where we'll live for the art of progressing our ideas and to have fun. the future will be awesome!
one can dream, right?
(my primary inspiration for this post was the "everything is a remix" youtube video: https://www.youtube.com/watch?v=nJPERZDfyWc.)
published on 2021-12-30, last modified on 2023-12-04
# clarity: it's the last day of 2021; where am i in life?
it's the last day of 2021, i thought i collect my thoughts of where am i in life.
quick summary about me: i'm a techie guy who married about 8 years ago and now we are raising a kid together. moved to ireland about 8 years ago and then to switzerland 2 years ago. i was working from home at a megacorp since the pandemic started, so about 18 months ago. in general i'm super introverted, probably a bit autistic even.
the staying at home gave me ample time to think things through. if i have to use one word to describe my state of mind, i'd say "clarity". i feel like i understand my needs and through this understanding i can meet them and thus be happy in general.
# relationship
i think i'm in the incredibly rare situation of being in a caring and understanding relationship. the relationship was a bit volatile in the past simply because i didn't know what i wanted out of life.
but opening up and communicating everything you feel can really deepen relationships. this was hard at first because i didn't know how to communicate. at some times i thought i can't communicate with my partner the way i want. i was more of a writing-type, she was more of a verbal type.
but then i simply kept experimenting with various methods. @/optioning really worked out for us here. i can now discuss anything i want in depth. this eliminated the need for a "communicative partner" for me that i was always trying to look for in one way or another (see @/slowpals for such a desire).
now if anything bothers me, i have means to talk about it and get support right from my closest person to me. this helped me a lot to put my private thoughts in order.
# work
another key aspect to happiness is that i can get things done both at work and in personal matters. and my secret for this is to wake up early and make progress while i still have the early morning productivity boost effect. i wrote about this in @/mornings.
and if something is too big or abstract for me to actually invest time in, i just write a blog entry about it. blogging was incredibly helpful for me: it helped to get a lot of dumb noise out of my system and this helped me to focus on other things afterwards.
also, looking back and seeing that i did something makes me feel good, and motivates me to do more. there's the old adage "if you want something done, give it to a busy person". i can totally feel it on myself: since i have a kid, i'm more time constrained. this forced me to get more organized to get anything done and in the end i became more productive overall.
# sex
some see sexual expression as one of the fundamental needs of humans. i really feel that on myself. in fact, i think i might have stronger sexual desires than average.
i was raised in a quite a sexually conservative environment. sex was never really discussed around me and monogamy was the only relationship i have seen.
and even though i had an awesome wife who could give me everything i ever wanted, for some reason i still didn't feel fully satisfied sexually. i couldn't understand it.
after some serious discussions, i started trying out stuff. it started with innocent things like naked yoga. i did it, but still wasn't fully satisfying. but zürich is quite awesome from this perspective: they have this sexual bodywork school thing here. its primary attraction are the tantramassage courses. i did quite a few of them.
i could say a lot about it, but let me condense things here. there's lot of intro, talking and prep but eventually you are paired with another person, and exchange massage with each other. this massage includes genital pleasuring too. you do it in a room with 10-20 other naked people doing the same around you. and the whole thing is guided, the instructor tells the group what to do, how to touch the other person. it's quite fun.
this school also taught me that it's normal to have sexual desires. other people have them too. there's nothing indecent about having them. we should talk about them. we should explore them, etc.
i decided that i'll try to have such fun extramarital sexual experience regularly. i even paid to have sex. sex is a nice experience. i can't explain why, but it's a wonderful experience to connect with someone on such an intimate level. i don't know... it's fulfilling? it definitely calms my sexual desires down for a while and i can then focus on other things.
a lot of people find such activities very taboo. but it does wonders to my general mood. i never tried antidepressants or similar things but i think this is much better so why should i deny this from myself? and i'm talking about this just so that this idea of "sex can have a therapeutic effect" gets more widespread and is not something to be ashamed of when one reaches toward it. in fact we should talk more about it, so that the people really understand what they want and reach for the right thing.
(think of this like cooking: it's feasible to always cook at home. but isn't it nice to go to a nice restaurant sometimes where you are completely pampered? why is such pampering ok for one's belly but not for one's genitals? putting arbitrary junk prepared by strangers in secret into our digestive system is fine, but having a stranger touch us makes us feel squeamish.)
as for the effect on the relationship: i'm very open about the reasons and goals of my actions. it required a lot of discussion but the relationship works. everybody benefits: i'm more happy, better mood in general, more playful, a more pleasant person to be around (or so i think). we accept each other as we are.
# future
i had a pretty good, eventful year. i still have lots of things to try or at least write about.
if it's good now, chances are things will go sour sooner or later for one reason or another. if anything, i expect most of the problems to come from health issues because i stay at home all the time sitting and staring at a screen. but i think i'm more prepared to handle calamities than ever. modulo those i think i'll be able to maintain my good fortune for quite a while. we'll see. fingers crossed.
published on 2021-12-31
# sigquit: sigint and sigquit are handy signals to handle specially
if you have a terminal application in linux, you can easily send it the following two signals from your keyboard:
in go binaries the default behavior for sigint is to simply exit the application. for sigquit it also exits but with a full stacktrace of all the goroutines.
i started to use the same pattern in multiple tools i wrote in the recent times so i thought i share it. it's for daemon-like or long running tools where the tools don't require any input, and they just keep running and logging what they are doing. for such tools i occasionally want it to do a specific action on demand. this can be something like dumping stats and/or reinitialization.
in such case i set up sigint to do my one-off action and sigquit to quit without the stacktrace dump (those stacktraces can be quite spammy).
for example my server that serves this page doesn't touch disk to serve the pages. it reads everything to memory and serves from there. when i change or write a new post, or when i update the ssl certificates, i simply hit ctrl-c in the terminal where the server is running to reload all the data.
or i'm working on a little backup daemon that periodically wakes up to upload changed files from my homedir to google drive as a backup. in there i interpret ctrl-c as a triggering mechanism to start a backup cycle sooner.
now all this could be implemented with raw keyboard input or with other signals (sighup, sigusr1). it's just that sigint is very convenient to use out of box thanks to go's signal package that uses channels for them.
one caveat: you have to handle sigquit in a background goroutine:
go func() { sigquitch := make(chan os.Signal, 1) signal.Notify(sigquitch, syscall.SIGQUIT) <-sigquitch log.Print("sigquit received, quitting.") os.Exit(3) }()
this is needed so that sigquit is immediately handled. but sigint you can handle on your main loop. e.g. when there are no requests in flight or when there's no backup cycle ongoing.
also note that such artistic reinterpretation of sigint can be surprising to the users. make sure to print a reminder to use ctrl-\ to quit whenever the user presses ctrl-c.
published on 2022-01-14
# inspiration: what do i freewrite about?
in @/freewrite and @/stream i wrote about how i like freewriting, especially in the evenings. but what do i usually freewrite about?
if i don't have drama around me, i usually stick to the topic of planning. it's a very generic, endless source of thoughts for me. should i get a new place for living? should i move to a different country? should i go work part time? should i go on a vacation? should i change my daily routine? why and why not? thinking about these help me get clarity in life in general.
but it's even better if i just think about the things i'll do the next morning. if i have a small project that i'm working on then i can think about breaking down the upcoming tasks. i keep breaking tasks down until they become trivial "let me just write all this down" type of tasks. such thinking can be incredibly motivating for making progress because next morning i'll know what to do already! the dread of not knowing where to start when i open my project disappears.
it even drives me to make progress on my project simply because the next tasks are already worked out and i don't want to lose them by not writing them down. in other words i use my loss aversion tendency as a source of motivation. and just because i do this before going to bed, it sometimes primes my brain to work on my project even in my sleep. not sure if that actually works but it certainly doesn't hinder my progress.
in general freewriting about such topics is super helpful for me to get unstuck in projects or life in general.
edit 2024-01-19: in case i don't have a project at hand, i can always pick some hard leetcode tasks and think about those. that's an evergreen source of problems to think about.
published on 2022-01-30, last modified on 2024-01-19
# recording: tried recording my computer usage but i didn't learn much out of it
lately i'm feeling quite productive. but i wondered if there's a way to get even more productive. i found a few posts online that claim that recording their screen during work and then subsequently analyzing them helped them become a bit better:
i was quite intrigued by this idea. i wanted to try it too to see if there are some low hanging fruits in my case too. i also liked the aspect that if i ever doubt why i did something, i could simply go back in time to rewatch how i implemented said work item. this should jolt my memory just like how looking at old photos can jolt my memory.
# implementation
recording my screen would quite resource expensive on my old crappy machines though. as an alternative i decided to record timelapses. basically grab a frame every 4 seconds and append it pretty much uncompressed into a movie file. i went for not compressing in the first pass so that the cpu hit from this is absolutely minimal. i'd simply recompress in the evening or some other time when i'm not using the computer (my current computer overheats way too quickly - within seconds - and then throttles itself to near unusability; the fans are probably full of dust and i should really get that cleaned some day.)
anyway, this is what i came up for recording the timelapses:
#!/bin/bash # srec: screen recorder. resolution="$(xrandr | fgrep \* | awk '{print $1}')" fname="$(date -u +%F.%H%M)s.mkv" ffmpeg -f x11grab -video_size "$resolution" -framerate 0.25 -i :0 -vcodec libx264 -preset ultrafast -qp 0 -pix_fmt yuv444p "$fname"
it basically writes a timestamped videofile into the current directory. and this is how i recompress all the not-yet-compressed videos into smaller files:
#!/bin/bash # compress my recordings. cd "$HOME/rec" for f in *s.mkv; do if fuser -s $f 2>/dev/null; then echo "$f might be still being recorded, skipping." continue fi h="${f%s.mkv}.mkv" echo -e "\e[32mgenerating $h\e[0m" if ! test -f "$h"; then ffmpeg -i $f -r 30 -filter:v "setpts=PTS/120" $h fi done
sure, maybe i could do all this better, but i thought that's a good enough starting point for my experiment.
# tracking
one thing immediately annoyed me. when you are watching a timelapse, everything happens very fast. it's very hard to grok what am i working on or thinking at any given moment.
so now i wanted that my statusbar displays a small comment that i can edit at all times. the idea would be that whenever i start working on something, then i simply update the comment so that in the video i can see what i'm doing.
i managed to get that working well but there was one problem: i often forgot to update the comment when i started to work on something else or when i got an interrupt.
to address the forgetfulness problem, i made it to nag me every 20 minutes to update the comment. at this point the whole thing started to feel like a variant of the pomodoro technique.
oh, one more thing: i made sure that every comment change would be logged to a timestamped append-only logfile. this would let me text-search my activities and then thanks to the timestamps, i could very quickly jump to the right moment in my videos. it also allows me to answer the "what the hell did i do last week?" type of questions quite easily.
here's the timestamped logger/nagger utility for reference: https://raw.githubusercontent.com/ypsu/cfg/5c299133/utils/tlog.go. it must run from a terminal and it starts a vim editor that autosaves after every edit. the nagging is done with the terminal bell (echo -e '\a').
# results
i have to admit, i didn't learn much from my timelapses. i found that watching the videos through is time consuming. but nevertheless i watched them through but it was pretty much just noise. maybe for the actual progress you would need near real time recordings where you would have better insight on the small inefficiencies you are making.
or even better, maybe have someone watch you work. in this case verbal commentary would be enough, no need for the above tracking hacks. almost like doing a coding interview. and then you listen to their feedback and see if you can learn from them.
on the upside, the explicit current focus tracking made me more focused on work. i could resist interruptions better. i'd feel less concerned about simply closing the chat windows during focused work. and the timestamped commentlog turned out quite handy when writing my weekly work summary at work.
but i feel all this tracking exhausting and annoying. there are days when my work consists of many interruptions and small tickets (e.g. during oncall hours). on those days all this tracking feels pure toil. but even on normal days i'm not sure i like the extra work this setup needs for me.
it also made me realize that i don't actually care too much about my productivity. nor did i ever felt the desire to "rewatch my past self" to see why i did something. i just want to have fun and not feel annoyed when using the computers. who cares if i do things slowly or if i'm not prioritizing correctly or that i don't know what i did last week. as long as i feel i achieved something by the end of the day, i think i'm pretty happy.
so i won't continue this recording experiment. maybe i'll retry now and then but for now it's a meh for me.
published on 2022-02-09
# gdsnap: i automated my backups with inotify and google drive
i'm not the collector type: i don't collect photos or movies or that sort of things. i only have a handful of megabytes of data i care about that i don't really want to upload to publicly readable places: my journals, my todo lists, configs, some half-started mini projects. i care about this data but i always worry that my machine will break and i'll lose some of this data. so i had a "backup" script that i often ran. it zipped up the relevant files, encrypted the package, and scp'd it to my very old university account.
i was always a bit annoyed that i had to run the backup script manually. and it always created a full snapshot. to reduce space wastage, i named the file after the date and omitted time. so there was at most one backup for every day. if i ran the script multiple times in a single day then each backup overwrote that day's backup. but even with this system i had to manually delete old snapshots every 2-3 months or so. i was looking for something better, that doesn't require maintenance.
at work we have a nice (but proprietary) fuse filesystem that pretty much saved every write to a central database. but then you could look at your tree at any given moment: e.g. i deleted accidentally a file? i can go back to 10 minutes ago and restore it from there. or i want to look at the diff since yesterday? easy peasy! i grew fond of this and wished that i could have this at home too in some form.
the interface wasn't really nice though: in the root directory there was a .snapshot directory and under it you could cd into a timestamp, a version, or something like .snapshot/minutes.ago/5.
anyway, i was looking at various opensource backup systems and interestingly none had such a nice diffing feature. so i decided to build my own backup system that can do time based diffing too!
# solution
i have to admit: i spent more than a year thinking about this until i found the right approach. but the thinking time was worth it because i now found a system that is pretty simple and works well for my usecase:
and that's it. here's the trick: google drive automatically saves your last 100 revisions for 30 days. that means i have automatic history and i don't have to manage it! and since google drive is free, this backup solution is entirely free and available for anyone.
i called my tool "gdsnap" as in "google drive snapshotter".
now i just freely edit my files as i want. if i want to see what changed in my todo file since yesterday, i can run this:
gdsnap -t=24h diff todo
i could run "gdsnap -t=24h diff" and it will tell me the diffs from all files since yesterday. it's reasonably fast even on my first generation armv6 rasperry pi! i don't have a lot of files though; my home dir has about 4k files only.
i wrote the whole thing in go without any dependencies other than its standard library. it's about 1300 lines of code. i was again impressed with go: it's incredibly easy to code up anything in it. i know that this would have been utter pain to implement in a dependency-free c/c++.
# help
here's an excerpt of the help screen of the tool to see what's it capable of:
$ gdsnap help gdsnap: google drive snapshotter usage: gdsnap [global flags...] subcommand [args...] periodically snapshots the changed files of a directory to gdrive as a backup. to use: set up the right -dir and -gdir flags (ideally in a config file), then use the auth subcommand to authorize, and then run the watch command as a daemon to back up data continuosly. if you want to restore, use the restore subcommand. you can alter the -dir flag for restore in case you want to restore files somewhere else. subcommands: auth: authorize a gdrive account for gdsnap. cat: prints a file from the archive. diff: diff the whole tree or specific files. the diff is between gdrive and the files on disk. help: print help about a subcommand. list: list gdrive metadata. quota: print gdrive quota usage and limit. restore: restores files from the backup (destructive operation!). save: snapshot a specific file. watch: watch target directory for changes and back them up. [more description and help snipped]
# nice things
# summary
if interested, here's the source code from the time of writing this blog post: https://github.com/ypsu/cfg/blob/611e906/utils/gdsnap.go. it's all in one single file. it might have some bugs but so far it worked well for me. the help screen should explain how to set up your personal google drive for gdsnap and how to set up gdsnap's config files.
and i'm now happy that i have a nice automatic backup along with diffs. \o/
published on 2022-02-13
# habits: i encode my life into habits
dear journal, i'm quite proud that i've managed to complete my little @/gdsnap idea. it wasn't a big project but it took me quite a while to finish. as usual, the initial motivation was high while i figured out the big pieces. but i often lost the motivation when i had to deal with all the corner cases and other quirks.
yet, i completed it. i managed this little side project quite well:
basically i did what i talked about in @/mornings. sure, some mornings i made very little progress: i just did some minor refactorings to make place for the next feature. but then slowly, one by one, all the features landed and i ran out of tasks. i completed the project.
it's pretty cool to have a project finished. now i take it a bit easy, sort some of my other queued todos out, and then i'll probably tackle my next big thing i'm planning for a long time.
i really like how daily tiny habits over long time can compound to actual achievements. i recall reading the book "compound effect" from darren hardy very long time ago. i think it was talking about this particular effect and it was strongly advising to do a little bit every day. it took me a while but i took the advice to heart and it worked out. i can wholeheartedly recommend this to others too.
# other habits
i have other daily habits too: for instance i read a little bit of german every day along with a dictionary just to pick up a little bit of german over time. sometimes it's just 1 page, sometimes it's more if the text is interesting. the point is to do it every day. my goal is not to become a perfect german speaker, just that i have some understanding of it. i think this habit increased my comprehension quite a lot over time and it requires very little time from me. i'm usually a bit slow right after wakeup, my eyes wake up slowly, so a bit of reading is a very nice way to start the day.
i have weekly habits too: i try to watch a little bit of german at least every week so that i can pick up german voice too, not just reading. or i try to make progress on the codeforces educational corner by solving at least one problem per week. or calling family is another weekly task for me.
i have monthly habits too: i try to participate in at least one codeforces programming competition per month. i don't want to become a top coding competitor, i just want a little bit of competition because i feel a void in me if i don't do it. that's because i did a lot of competitions when i was a kid but these days i'm not that super interested in them. but i don't want to completely stop either so i found this as the perfect compromise.
another monthly habit is a variant of "i should meet someone every month". this worked out surprisingly well for me given my ultra-introverted nature. i might lower the frequency of this to every quarter since i feel monthly is more than i actually need.
i even have yearly habits: reach out to folks on their birthday or around the new year's eve to maintain some old relationships. ("what's your plan for the next year?" is a very good icebreaker!)
# implementation
i really like how my system dictates what i should be doing in general. i don't really have to make decisions about when and how much i should be doing a particular activity. i implement this by having a time triggered todo items in my todo list and they linger there until i finish/schedule them. once i finish them, i bump the trigger date to the next period's start.
take the "compete in codeforces" task: on the 1st of the month this task appears in my todo list. i find the next competition in the calendar and postpone this item to that day (e.g. the 10th). if i can make the competition that day, i do it, otherwise i postpone it again to the next event. the more later it is in the month, the more pressure i exert on myself to make it. and when done, i postpone the todo item to the 1st of the next month. note: i don't simply "snooze" the task for 30 days because that would definitely lead to me doing less of it and i wouldn't have the "end-of-month-pressure" that i really need to make sure i complete stuff. under pressure i might even try to do the competition half-assed (e.g. not taking the full time) but that's fine because at least i participated and had some fun out of it.
# life encoded into habits
but anyway, the point is that everything i want to get out of life is sort of encoded into these regular habits. and thanks to the compounding effect i feel i make progress on every important-to-me life area. with these even my family relationships improved a bit, which i happened to neglect way too much in the past. i guess this really helps for me to feel happy in general and to avoid living a life full of missed opportunities.
published on 2022-02-18
# wakeup: my tricks to waking up early
for me a good day begins with a nice morning. and a nice morning begins with waking up quite early when i can still hack on my hobbies undisturbed. i have to wake up before the world starts nagging and distracting me. the problem is: waking up is hard.
but thanks to a few tricks i've managed to get the hang of waking up early in a reliably manner.
i always wake up at the same time and i think that helps a lot. going to sleep always at the same time helps even further. my current pattern is bedtime at 22:00, wakeup at 05:30. i try to wake up even when i had a crappy sleep and i simply rely on powernaps thorough the day to break even. the only exception to this is when powernaps will be unavailable, e.g. when there's travel or some other full day event upcoming. if i feel i have some sleep debt, i'd rather go to bed earlier than wake up later.
i have a very slowly loudening white noise as the alarm clock. i think this helps to soften the wakeup process. i used to have some ordinary alarm sound or music but that often startled me too suddenly. it wasn't a nice start for the day.
i think this slowly loudening white noise works similarly to sunlight: it might not immediately wake me up but it probably starts the background wakeup processes in my brain as soon as the first rays/soundwaves reach me. by the time i get conscious about the alarm, i'm already long into the wakeup process, i don't feel it too sudden.
if i'm having trouble getting up out of the bed after the alarm clock, i just sit up with my eyes closed. in this mode i don't need to move and i can still feel that i'm continuing to rest but it will totally prevent me to falling back to sleep. i start reminding myself that i shouldn't worry about tiredness because i can powernap later on. i also start reminding myself about my morning routine, the things i want to do. that usually gets me excited enough that i then actually want to wake up and do my routine. all tiredness evaporates out of me after i'm out of bed and done something, even if it's simply brushing my teeth.
i don't drink coffee (or energy drinks) at all. i have this pet conspiracy theory that over long term coffee just increases your baseline tiredness and drinking it just temporarily removes the strains it slowly added onto your body. basically it messes you up. that's my armchair philosophy explanation of why seemingly some people can't seem to function without coffee anymore (in other words: they are addicted). aaaanyway, regardless of that, it's one addiction less, which means more mental acuity for other stuff.
and that's it. in short:
published on 2022-04-11
# dumbness: i don't mind being dumb because i trust the smart people
i struggle with learning. it's a very slow process for me. i can't simply listen to a presentation or to someone explaining something. i zone out, or in case of presentations i fall asleep. it's very hard for me to maintain in-person technical discussions too.
instead, i need to do something, e.g. be solving problems or writing code. if i get stuck during it, then looking up information is much easier: my mind is then very receptive to ideas that will help me finish my task. i'm then able to focus on the relevant sections of someone's explanation. it's a slow process though because building stuff is a slow process.
but i've met people who are always in this receptive state. they can easily just skim a book and fully understand the ideas in it, even quote parts from it. basically they can read a book and then become experts in the book's topic. i mean for real, i'm not sarcastic here. there are very few people like this, but they do exist. it's quite fascinating to experience such people up close.
but it also reminds me how dumb and slow i am. i guess this feeling is exacerbated by the messages how we should be always learning and developing ourselves. such messages come often from successful and smart people for whom learning, i suppose, is much easier than for others. for me it's very hard and i see it as pointless because the stuff just doesn't stick.
so how do i cope with dumbness and feeling inadequate in the world? part of it is stoicism: i don't care or stress about it much because i can't seem to do much about it. but i think there's also a more important component to this: trust.
it's trust that there will be always smart people around and that they will do/build all the right things. i've seen smart people up close as mentioned above: they are cool, not scary. sure, they get things wrong a few times. but that's human. i also get things wrong. no need to get antagonistic about things, that path leads to despair. i think approaching disagreements with trust is more productive.
i'm not saying blind trust is cure for everything. rather, up to a limit, it allows me to stop wondering about motives, or worry too much about all the bad things people could do. it allows me to stay dumb without the uncomfortable feeling that i should become expert in everything just so that i can have a say in things.
i wish there was more trust in the world. to be fair, more transparency and voice in the leaders' decisions would go long way to be more trustful in general. but that's a different can of worms for some other time.
published on 2022-05-08, last modified on 2022-07-09
# clockdoc: a barebones app for showing time and setting visual alarms
i've created a simple clock app available at @/clock. features:
the alarm can have both a start and end time. before start the clock is yellow, between the two endpoints it's green, and it's red afterwards. supported format strings:
omit : between the units as in hh:mm. this cleaner syntax makes it easier to enter the desired time ranges on phone.
e.g. you want to be jumping rope for a minute, then you would set the alarm to "1323-1324" to start at a specific timepoint or you would just enter "100." and start right away.
intended usecase is for timing physical exercise or playing the 3 minute game (@/touch) where audio cues could be way too disrupting. or you can just use it as a short break for your screen time: go to @/clock, go fullscreen (f11), enter "30." and relax while the screen is green.
published on 2022-06-18
# codeclub: a meetup idea for doing competitive coding together
i often wonder what sort of meetup i'd like to attend to have some sort of social life outside family and work. like what sort of hobby do i have where i could break through my introversion and actually talk to people?
after a lot of deliberation, i think there's only one club that i can imagine: a competitive programming club.
i imagine it this way:
here i would have a reason to talk! e.g. if someone doesn't know how to solve a problem but i do, then i could try explaining it -- i would be talking! or i could help find bugs. i love debugging. or i could even feel somewhat useful to someone else's learning efforts through the review part.
the latter bit could be especially helpful if junior people would come along these events for the fun. that could be achieved by advertising this event in high schools or in nearby universities.
and in general i quite enjoy coding up the puzzles from these competitiions. but doing it alone can be a bit boring. i have been to many similar competition events when i was in high school and university and i generally liked them. so such a meetup would be a good match for me.
of course logistics could be hard: one would need to rent a meeting room for this. although if it's popular among university folks, maybe the university can offer the room for this.
i'd probably be organizing this already if meetup.com and renting rooms weren't so much of a hassle (meaning me being cheapskate about the costs). but i'll keep this in my mind just in case if i ever get enough bravery for this.
edit: see @/coderate for another idea what to do in a code club.
published on 2022-06-19, last modified on 2022-09-03
# swapcoding: a competitive way to build software
this is probably a terrible idea but here it goes. suppose there are two expert coders and they want to compare their skillz and learn from each other. what can they do?
i propose the following game. i named it as swapcoding. the duo gets together and agrees to build some piece of software. something they both have the necessary skills to build without much research. e.g. maybe it's a terminal based tic-tac-toe game or a sudoku solver written in html + javascript. something that can be implemented with 1-2 hours independently by both.
both people implement the challenge themselves. but they will work on it in a turn based manner in multiple rounds. the "swap" part of name comes from this aspect: that they swap places during development.
each round starts with a small discussion where they agree which feature they will both implement in the next round. then the first person starts working on implementing the agreed feature while the other person just watches. during this time the second person cannot touch their laptop. there's a chess timer counting the time used. once the first person finishes their feature, they press the timer and now the time is counting for the second person. the second person starts working and now the first person watches. then another discussion happens and then the next round starts. each player builds on top of their solution in the subsequent next round. these rounds continue until some total timeout is reached (e.g. 4 hours).
example rounds for the terminal based tic-tac-toe's case:
once the game is over the duo compares the end results. if both solutions are comparable then they can look at their time usage from the chess clock to determine the winner. but the game is not really about winning. for me it would be about watching how people approach developing code. e.g. how much they rely on autocompletion? is it slowing them down or does it give them an advantage? the fact that i'm also implementing the same problem puts me into the right mindset to really appreciate the specific problem's nuances to fully understand what the other person is doing. simply watching others without this extra competitive pressure on me would be boring to me.
i never really tried this game so there's a lot of details to iron out. but maybe some day i come across someone who really wants to play this game and then i can determine whether this is fun or not.
edit: see @/codingtime for a suggestion on how to measure time.
published on 2022-06-20, last modified on 2022-08-21
# actionlog: a simple alternative to sql for simple cases
suppose you are working on an application and you have to store state somewhere. i find sql too much of a hassle to use. i prefer to use something i call "actionlogs". i'm sure it's a common pattern but i'm not sure if it has an official name so i went with that.
with sql you would always store the current state. with actionlog you append changes to an append only logfile. e.g. one action per line. making changes is pretty fast but whenever you start your application, it has to re-read the entire logfile to reconstruct the current state.
i find actionlogs super easy to work with! they are not super scalable but most of my little applications are small so scalability or fast startup is not a concern.
# example
suppose that you are writing a chat app with rooms support to augment your product. you could implement this with a single actionlog file. each line could have the format of
[timestamp] [room] [user] [message]
e.g.:
1656843732 teamchat alice "hello all!" 1656843752 teamchat bob "hi alice!\nhow are you?"
super easy to write in go:
fmt.Fprintf(log, "%d %s %s %q\n", time.Now().Unix(), room, user, msg)
super easy to parse in go:
for _, line := range strings.Split(actionlog, "\n") { var t int64 var room, user, msg string fmt.Sscanf(line, "%d %s %s %q", &t, &room, &user, &msg) ... }
or maybe you can use percent encoding for the unsafe strings to keep things easy to parse in javascript too.
doing the same thing in sql usually requires a lot of boilerplate compared to this.
# actionlog service
now here's a crazy idea. what if there was a service where you could log in and then write to any actionlog file? this service would have the following http handlers accessible to its users:
the actionlogs in this service would have the following form:
[timestamp] [user] [msg]
the timestamp and user is determined automatically, only the msg part is controlled by the user.
this generic service would allow implementing completely secure applications just with client side javascript! whenever the user loads the app, the javascript would load the entire actionlog and replay the whole log to reconstruct the current state. the trick is that it will ignore incorrect messages.
# actionlog chat
you could have the user open /chat#myroom. then chat would fetch chat's whole actionlog file. the individual lines have the format of "[timestamp] [user] [room] [msg]". it would filter for lines where [room]=myroom. and then it would just display the contents of the chatroom. if the user writes something, it would send "myroom [msg]" to the server.
since the actionlog service supports blocking reads, all the other clients will be immediately notified of this new write. they will immediately see the new message.
# actionlog bank
you could implement a simple bank where everyone sees everyone's account publicly. the actionlog would log transactions in the following form:
[timestamp] [user] [recipient] [amount] [note]
there would be a special "bank" user. money deposit would look like this:
1656843732 bank alice 100 deposit
means that alice's account has now 100 more money.
money withdrawal would look like this:
1656843732 alice bank 100 withdrawal
this means alice wrote a message that she sent 100 from her account to the bank. she could now go and pick up the money. and ordinary transactions between users would look like this:
1656843732 alice bob 100 for the lunch.
alice sent 100 money to bob.
when the client opens up, it loads the full actionlog. it will ignore lines where an account would go negative (except for the bank user). remember, there's zero validation on the actionlog service side. there's nothing stopping alice from sending the service a message "bob 123456789 let's get rich!". however when replaying the clients will see that alice doesn't have that much money, so they will simply ignore such bogus loglines.
after the client replayed all the messages, it can show in the interface how much money the user has. and then can provide ui to send money to the other users.
and as with chat: the client does blocking reads so all the user interfaces get updated real-time after each write.
# other examples
there are so many other things that could be implemented solely with a single static http file! examples:
# experience
i actually did create such a service at work and implemented some of the applications mentioned here. the most popular one was the tournament ladder one. it works really well. i didn't do any optimizations, yet the logfile grows quite slowly so the whole thing is still super fast. it's super fun to create little demos now that i don't have to deal with the pesky backend logic. and if something becomes popular, i can rewrite it as needed: but you never know what blows up, so this allows me to avoid spending too much time on designing the most efficient data structures. maybe sometime in the future i'll add this feature to this site too. :)
published on 2022-07-03
# comments: i've enabled anonymous commenting on this site
# summary
# markup
the comments support some markup based formatting. a paragraph's first character determines how it's going to be formatted:
web links are deliberately not supported. i'm allowed to use them in my comment responses though.
# motivation
one thing i really like on blogs: having the ability to leave a comment. i like reading some challenging responses to the blog posts. and sometimes i feel i really want to point something out to the author. ideally i could do this without dealing with account management and all that.
on the other hand low quality comments can really ruin this section. i definitely don't want to deal with spammers and low effort comments. to combat these aspects, i'll open anonymous comments with very heavy limitations.
first, the commenter will need to wait 1 minute between crafting their message and committing it to my site. i've talked about this idea in @/cooldown. i hope that during the cooldown the user will either not bother posting the message if it's not that important, or have a chance to review to make it even nicer if needed. although a change will cost them additional 1 minute. i hope only the really important messages get posted here, where the message is definitely worth the 1 minute wait.
i also ratelimit the incoming comments to a few messages per hour. i don't think anybody will post here as i don't think i have readers but i definitely don't want to have a firehose of messages even if i have a popular post. this limit should be fine for my initial experiment.
these limitations will defeat the automated comment spam but won't stop a dedicated attack on my site. if it comes to that point, i'll just simply kill this experiment.
# implementation
the backing store for the old comments is just a @/actionlog file in the blog's git project. this allows me to get the comments into the static archive too. the actionfile has the following format:
[unix_millis] comment [postname] "[message]" "[response]"
my server keeps all the comments in memory and serves from there. but new comments are persisted in a cloudflare kv store until i move them to the actionfile manually. once the server sees that a comment is in the actionfile, it will delete it from the kv store. all this should be transparent for the users though.
the markup is quite restrictive but in exchange it's super easy to implement in most languages. i have the same implementation in both javascript and go: split the message on "\n\n" and then look at the first character of each paragraph to decide what html tag to wrap it and what additional processing it needs.
and the cooldown part is implemented by the mechanism i proposed at the end of @/cooldown. when the user presses preview, their browser computes the message's sha2-256 and sends that to my server. my server responds with a token that was generated by hashing timestamp+commentid+user_hash+secret_salt+cooldown_timestamp. when the cooldown elapsed and user presses post, the user's browser sends that token along the comment. the token includes the timestamp so the server can verify that the message was something that the user uploaded before without storing any state for this.
security is not really the point of this. it's just obscure enough to guard against simple spammer bots and make it not-so-simple to bypass the cooldown.
in case you want to contact me privately, send an email to qxp2fs8j at anonaddy.me.
anyway, comment away!
published on 2022-08-01, last modified on 2023-12-12
comment #comments.1 on 2022-08-01
this is how a comment looks like.
comment #comments.1 response from iio.ie
and this is how a response from me looks like.
comment #comments.2 on 2022-10-08
Globally rate limiting across the whole site discourages commenting, especially when you post 6 post at once, each of which takes less than 10min to read, digest, and formulate a comment for.
comment #comments.2 response from iio.ie
i started out with allowing 1 comment per hour because i wasn't sure what to expect after opening up to the internet. but looks like nobody is trying to spam me so i bumped to limit to 4 comments per hour. i still want to keep the global limits because makes me sleep better knowing that i won't get gazillion messages overnight.
but now i also added alerts to notify me if this new limit is ever reached. then i can reevaluate again if i need to further adjust the rules.
comment #comments.3 on 2023-02-23
I have a question I've been breaking my head with, probably with a simple answer if not for my lack of good understanding of the web: how do I ensure that the server responds ONLY to requests coming from my site, and no-one else?
In your implementation, when I click preview, my browser sends a message to your server, and your server responds with a token, that will allow me to post the message. On the server-side, how do you ensure that the request from my browser is coming from your website only?
How does your server know that this fetch request:
fetch('/commentsapi', { method: 'POST', body: `sign=${msghash}`, headers: { 'content-type': 'application/x-www-form-urlencoded', }, })is coming from your website, and not from any random terminal doing a CURL request with the appropriate request & headers to look like your website?
I am not nitpicking on the security of the implementation here, I just want to understand how to implement this check, as I wasn't able to find any simple answer on the internet. This says it's impossible: https://security.stackexchange.com/a/246442.
I'd appreciate it lots if you could point me to some reading that will help me understand this.
comment #comments.3 response from iio.ie
On the server-side, how do you ensure that the request from my browser is coming from your website only?
i don't know that what tool you post your comment with. you could totally post a comment from curl too if you curl the signature before you send it back via a second curl call.
one protection i can do is to look at the origin http header. someone could create a page which on visit would post an anonymous comment on my page. but then the origin will be the other site's domain so i can prevent that by dropping requests with unexpected origin header.
but this won't prevent someone just posting something from the terminal where they can set any header. from the terminal you can do a denial-of-service attack against me. all requests will come from a single place. with putting some javascript contacting my page on some popular page you could mount a distributed-denial-of-service attack against my site. then any visitor of your page would try to contact my site. but the origin check can easily defend against this attack.
there are other approaches described at https://en.wikipedia.org/wiki/Cross-site_request_forgery.
nevertheless, i'm having bit of a trouble with your question. sounds like a xy problem (https://en.wikipedia.org/wiki/XY_problem). what feature are you trying to implement in your service?
comment #comments.4 on 2023-02-23
Thanks for the fast response! The CSRF wiki describes some interesting solutions, thanks.
Ha, could be an XY problem. I'm still learning lots on how the web works. I have a website, https://aristot.io which is currently pure client-side and I want to add a commenting system to it. I don't want to rely on 3rd party, and I thought it would be a good learning project to make a simple backend for this. I am learning to create APIs with Node - seemed to be a worthy tool to invest time learning - and intend to get some basic server hosting somewhere like digital ocean and add a SQL database (probably overkill, but good for a learning project) to store comments, manage newsletter subscribers, and whatever else arises.
But I can't think of how would I ensure for example that only someone from my website would be able to make requests to my API. I don't want my DB to get spammed with data unrelated to my site. Am I thinking about this wrongly?
P.S. I love the cooldown concept :)
comment #comments.4 response from iio.ie
[...] only someone from my website would be able to make requests to my API. I don't want my DB to get spammed with data unrelated to my site.
the former won't protect against the latter. i could go to your website, open the web console, and spam you with requests which would genuinely seem to come from your website.
let me try a metaphor. your service is a mailbox, the browser is the postal service that delivers mail and packages to your post. the postal service will ensure that it only delivers legit mail and packages. but how do you prevent your local kids putting trash, flyers or real looking mail into your mailbox? if you want to keep it open to all, you can't really do anything against this. anybody will be able to put stuff into your mailbox. similarly, anybody will be able to send you random requests, even real looking ones.
you could lock your mailbox down and give the postal services the key. similarly you could only allow registered users to post. then perhaps you don't even need to care where the request is coming from.
nevertheless, if you want to protect your db, you need to implement a ratelimit. at the moment here on my site i only allow 4 comments per hour and so far the limit wasn't reached. even honest users might inadvertently spam you if some post gets wildly popular and the commenters start a heated discussion among each other. the ratelimit would not only protect your db but also cool down the comments a bit.
i would also argue to not try to do such lockdowns even if it would be technically feasible. innovation is frequently about combining things unexpectedly. maybe your comment section gets popular and a user wants to write an app or extension to make the commenting section better. the extension could notify the users about new comments and allow quick responses. or maybe someone wants to create some statistics about the comments and needs to access your content programmatically. why prevent people trying to improve your site?
comment #comments.5 on 2023-02-24
Okay, yes I see your point.
Last thing that's still dark in my head:
maybe your comment section gets popular [...] why prevent people trying to improve your site?
If anyone has access to the API, and my website's code is open-sourced doesn't that mean that in theory someone can just clone my site, publish it under some domain/host, and then use my backend server to host the comments of *their* website? How do backends in general prevent this kind of abuse? Ratelimiting would slow-down, but still, anyone would be able to use my backend as free storage/db. Or?
comment #comments.5 response from iio.ie
checking the origin or referer header would prevent that. the users of that clone-site wouldn't be able to talk to your site if you do that. this check is like two lines of code on the server side. :)
but if someone creates a tool or browser extension to talk to your site, then yeah, they could use it as a storage. adjust your limits in a way that it makes this impractical. or just limit commenting to registered users if you are concerned about unintended usage. if some user misuses your service, you simply ban them. i think banning bad users is what most sites do.
but then make sure the registration is somewhat limited (asking for money is a good deterrent) and that the new users cannot immediately spam you. coming up with the right rules is a rabbit hole. it's best to not worry too much about it initially. just adjust over time based on the actual user behavior you see.
# smartphone: i've switched to a smartphone after 6 years of dumbphoning
why? because i started relying on gps a lot lately and i didn't want to carry two devices.
i bought an ebike a few months ago and i'm using it relatively frequently. joyrides with it are quite fun. visiting nearby hills, forests, lakes is enjoyable. going downhill fast is incredibly thrilling.
but i need gps navigation otherwise i would be lost all the time and wouldn't dare to venture out. the bike came with a small computer mounted on it (kiox) for controlling the motor. there's an accompanying app. the user can set a destination in it, connect to kiox via bluetooth, and then the small display will continuously navigate. it's very handy: the smartphone's screen remains turned off so this way it can last much longer.
(yes, i have some beef with gps, see @/gps, but i simply can't force myself not to use it given it's so accessible nowadays.)
initially i carried two devices: my dumbphone and a smartphone without a sim card just for its offline navigation. worked fine but i found it awkward to carry two devices. i decided i'll use one. i'm sure i can manage that.
# history
i have used a smartphone for about 2 years quite a few years ago. but back then i found it incredibly addictive and unreliable. i was constantly checking my email on it and reading reddit on the toilet. and sometimes it rebooted in the middle of the night for updates, didn't boot up properly and i missed my morning alarm.
but now:
it should be fine for me to try it again.
# rules
i'm using it for a month now and i'm still all good. i've set a few rules for myself though:
looking up some information (e.g. train departure times, shop opening times, nearby restaurants) is fine. but i shall not browse reddit or hackernews on it. i shall simply meditate when i'm on the toilet or waiting for trains. if i want to browse the internet, i shall use my desktop computer. there's no place for feed apps on the phone. (though there's no place for them on the desktop either.)
i disabled notifications for everything except for sms and phone calls. i might enable for some other messaging apps if i ever install one. but only for direct messages. if i want to look up email for some ungodly reason, i'll just open its app and check it explicitly.
the clock app, the bike app, the phone and sms app, the public transport ticket app, and camera. that's it for now. everything else (browser, email, chat apps, etc) needs me to wade through menus to start them. i hope this small extra friction will continuously remind me that i shall proceed with care.
i've made a lot of customizations to ensure i'm comfortable using it.
"hey google"? completely disabled.
i've disabled all autocompletion and autocorrection magic in the keyboard app. i'm a patient persion, i'll type what i want exactly, no need to tell me what to think, thank you very much. if i need to type something longer, i'll use my desktop anyway.
i disabled all sorts of animations in the hidden settings. animations annoy me.
i've disabled automatic backups for the photos. i don't take photos. even if i were to, i definitely don't want to unintentionally rely on cloud services. e.g. what if i run out of quota and suddenly cannot receive emails? or if i accidentally photograph an illegal number and my account gets deleted? not having automatic backups will ensure that i take care of anything important explicitly.
probably i have a lot more customizations but i can't recall them.
# control
i can now easily look up information anywhere. that's incredible! but such access is incredibly addictive. some consider smartphones the modern version of smoking.
i think to combat it i just need to be conscious about the usage. there should be a regular habit where i ask myself: am i still using the smartphone in a healthy way? so i now added a quarterly event to my todo list where i need to answer this question in my journal. it's very similar to what i do in @/reflecting but for smartphone usage. if i can see that i'm doing fine, i can reduce the check-in frequency to yearly.
so here i am: i'm a modern person now. let's see how that works out!
published on 2022-08-09
# codingtime: measure time for @/swapcoding with git
this post has non-textual or interactive elements that were snipped from this backup page. see the full content at @/codingtime.html.
for the full @/swapcoding experience, i need to be able to measure time spent coding. i found a neater way to do it than using a dumb chess clock. do this:
source <(curl -s https://iio.ie/gittime)
this installs two functions into the current shell. then the workflow in the game is the following:
works in both bash and zsh.
# implementation
gitstart just commits an empty commit with `start` as the sole commit message. gittime then simply adds up the time between the commits except for the start commits. the full source of the script is this:
[non-text content snipped]
# example
the output looks something like this:
min task --- ---- 3 initial project setup with source code and makefiles 7 create the game state structures 11 render the state into a nice interface 6 add colors to the interface 5 advance the state based on user prompt 8 detect end of game state and quit total time: 0 h 40 m
the `min` column represents the elapsed minutes for the given task.
# background
so i had the opportunity to try swapcoding with a friend. we both created a simple terminal tic-tac-toe game. it had a nice, colorful terminal interface, an optimal ai player, player hints, etc. the experience was super fun and we achieved much more than i initially expected. it's something i totally want to try again. we did it without a clock but we really missed it. so i came up with this easy to share hack for the next time.
published on 2022-08-21
# coderate: a meetup event idea where you rate and criticise each other's code
i wrote about a code related meetup in @/codeclub previously. that post was a bit vague about the details on the structure of the event. i thought a little bit longer about this and came up with a better idea.
my idea is based on the following two observations:
so the idea is this:
and that's it. you code, rate, comment, improve until the event ends. while the solving time and ratings can be used to make the event competitive, that is not the goal. they are just metrics to give some meaning to the event. it's all about learning together through code reviews.
# evaluation
to make things exciting, i need a service that can evaluate the solutions for correctness. but i really want to keep things simple. i'm not really concerned about cheating so i'd push the evaluation to the client side. coderate comes with a command line tool that can run the user's solution on their machine and tell whether it was correct or not. it fetches the input data from the online service and runs the solution against it. the solutions will run under a strict time limit of 2 seconds. if the solution is incorrect, it will tell the participant why or just show a diff between the wanted and got output.
to keep the interface simple, the solution must consist of one file named after the problem's name. it must read the input data from standard input and write the solution to standard output. assuming the user is working on `problemx`, they can run the evaluator as a shell command like this:
coderate eval problemx.go
this will compile their program and run it on all the inputs. it will provide detailed memory and timing stats for each input.
the user can also run the evaluator for one specific input in case they are debugging one:
coderate eval problemx.cc 07
they can also "watch" a file. in that mode coderate detects whenever the file changed and immediately reruns the solution on all inputs. the current state would be always presented in a nice, colorful ascii table in the terminal. the user just needs to edit the code and the rest is dealt with.
coderate watch problemx.py
coderate will come with recipes for most languages. but it should be easy to add custom rules. each recipe needs an optional build step and a run command. the percent sign would be always be replaced with the problem's name. examples:
coderate setrecipe ext=c build="gcc -Wall -Wextra -O2 %.c -o %" run="./%" coderate setrecipe ext=go run="go run %.go" coderate setrecipe ext=py run="python py %.go"
in go's example the separate build command is omitted. the downside of this is that go would rebuild the file for each input so the solution stats would be off. a better recipe would be this:
coderate setrecipe ext=go build="go build %.go" run="./%"
# upload
when the user is done with a problem and is ready to share the solution, they have to upload it. but before they can do it, they have to "join" the current event. since the system would allow multiple simultaneous events, each event would have a secret identifier. the organizer would share this id with the participants beforehand. then users can use that to select where to upload their solutions:
coderate join [event_id]
subsequent upload commands will then be associated with the given event. the user would upload their solution like this:
coderate upload problemx.java
the tool would rerun the solution on the inputs, gather stats, and upload the solution along with those stats. sure, the stats will not be comparable along the different users due to the differences between their computers. however the reviewers can rerun the author's latest code on their machine if they desire so:
coderate check alice/problemx.rs
the authors can upload multiple versions of their code as their code improves. if the reviewer wants to rerun specific testcase on a specific version, they can do so. e.g. to rerun bob's 3rd attempt on testcase 07:
coderate check bob/problemx.js/3 07
# review
coderate's website will present a grid. each row contains a user and each column is a problem. i expect more users than problems so this is the sensible layout.
each cell will be a short status summary of the user's solution for the given problem. the cell's background color is:
the cell's text is 3 numbers: average rating (1-5 scale like on amazon), number of raters, number of open comments.
the reviewer clicks on a cell and coderate presents solution page. the page has several tabs they can select:
the reviewer can highlight parts of the code and start a comment thread about it. or they can start a comment thread without any context too. or they add another comment to an existing comment thread.
the first line of each comment is special. it's meant to be the "action summary" and can be at most 80 characters. if that line ends with ! or ? the comment thread is open and closed otherwise. for open comments the line can start with "@u/user1, @u/user2:" then the thread is assigned to user1, user2. they are expected to respond on it. otherwise the open threads are assigned to the author of the solution. the last comment in each thread is the always actual summary line for the thread.
the summary lines add some overhead to commenting. it has an upside though. it makes the reviewer think hard about the point they want to make and forces them to formulate it succinctly. less fluffiness. and then the author can list all open threads and show their summaries. i think such overview could be quite nice.
as a general idea, i'd expect most comments to be in this form:
code: sum := 0 for i := 0; i < len(vs); i++ { sum += vs[i] } comment: wdyt about using a range loop here? range loops are shorter and more idiomatic. like this: sum := 0 for _, v := range vs { sum += v }
the first line of the comment ends in a question mark so the comment is open and is assigned to the author automatically. "wdyt about" questions are a pretty nice way to provide feedback that still allows rejection without being weird about it:
response: acknowledged, i'll keep range loops in mind in the future. i'll keep this code as is for now to save time for my other tasks.
the goal of the author would be to resolve all open threads one way or another. either accept the suggestion or challenge the reviewer. one can accept a feedback even without going ahead and fixing the code right away just like in the above example. the point is that one can learn a lot through such conversations.
the user prepares a batch of comments and publishes them in bulk. the comments are persisted as the user is writing them so that an accidental tab close doesn't result in lost data.
i'm well aware that i'm not making a very clear description of what i'm imagining. all this is more like notes for my future self. i hope this is enough text for him to remember the picture i'm imagining right now for the interface. and yeah, maybe all this is an overkill, but i always wanted to experiment with a review interface. looks like this project could be my ideal playground for this.
# edit: review incentives
what would be the motivational factor for someone providing a review to others? okay, here's an idea to gamify this. whenever a user opens someone else's solution, they will be required to answer two questions:
basically the reviewer has to leave a praising and a constructive comment. not sure how to phrase the prompt for the constructive one. i want to ensure something meaningful could be written almost everywhere. e.g. "the solution looks solid. perhaps i'd add more clarifying comments or would use clearer variable names." or something like that. and the point for the praise is to ensure the feedback has some nice stuff in it so the participants keep coming back to hear nice things about their work.
while beginners would focus just on finishing the solutions, giving reviews could be the attraction for the more experienced participants. i'm not fully sure how fun this would be but it's something that could be experimented with.
# limits
this service could be quite cheap to run. all it needs is to serve some data files, and allow users upload code and comments. ratelimits should be enough to keep people in check.
each comment is at most 2k bytes long. the reviewing platform is not a soapbox. the reviewers should keep them short or split the thoughts up into smaller points.
and there would be also limits on how many event rooms can be running simultaneously. this can be low as 10 to keep the service lean and fast. if you want to make sure you have a room at the scheduled time, you can preserve your room for the given time. and if there are too many reservations already, then you can contact the service's admin to manually preregister the event. this extra process is needed only to keep spam and nasty robots at bay.
# feasibility
this post is getting quite long so i omitted a lot of implementation details. e.g. how would the problem input-output data served or how the comment notifications work. but these are probably not hard problems, i'm sure one can figure them out during the implementation.
i think all this would be relatively simple to implement. especially in go. it is completely multiplatform, so it would be easy to support multiple platform like linux, windows, mac out of the box.
maybe one day i'll go and implement this and can try it among friends. or maybe it could be used to teach coding for novices. the realtime feedback system could be immensely conductive for learners who thrive in that environment. so maybe i could try organizing a "let's practice coding" meetup and use this there.
anyway, i still have a few things queued up so i'm not getting to this anytime soon. maybe later.
# edit: measurements
printing the stable memory and cputime footprint when comparing solutions could be a nice motivating factor for looking into improvements.
so in the meantime i've learned about facebook's "hermit" software. it's like rr but supposedly better: https://developers.facebook.com/blog/post/2022/11/22/hermit-deterministic-linux-testing/. basically it can run software deterministically.
the nice thing about deterministic runs is that even the time measurement is deterministic. so this piece of software could be used to measure the tiniest changes in runtime. it could be used to deterministically rank by performance. per https://news.ycombinator.com/item?id=33712414 this is still a bit in an early phase. but i think for the simple usecase from this post this would work perfectly.
if possible, coderate should detect if hermit is present in the system and if yes, use it to run the software rather than running it directly.
# edit: problems
i expect to have a bunch of easier tasks for beginners and a bunch of complex problems for more experienced folks. if i'm ever looking for a high quality problemset with harder tasks, i shall look at https://cses.fi/problemset/list. it's pretty good and has a creative commons license. only downside is that i don't see the testdata being available but nevertheless it's a good start.
# edit: stretch goals
some additional feature ideas:
published on 2022-09-03, last modified on 2023-04-03
# coretask: a series of rambling thoughts about human organizations (1/6)
lately i was pondering a lot about human organizations. this was triggered mostly by some baffling decisions made at some large companies. this reminded me of governments too: they often make baffling decisions too. by baffling decisions i mean decisions that i don't agree with or simply don't understand. it makes me wonder how they are run, or more interestingly, how should they be running instead.
the internet is full of answers how companies and governments should be run. but it's like rock-paper-scissors: every argument has a counterargument and the arguments then form a circle. and then people argue in circles. i have no idea what to think after reading all this circular argumentation.
i don't know... i feel like i need to organize my thoughts a little bit before i can go back reading the internet. but i'm quite the simpleton and having hard time grasping all the complexities. so let me think aloud about the core tasks of the various pieces of an organization. maybe through all this loud thinking i can learn something.
i try to find answers that can apply to both private companies and country governments. i think both are somewhat similar problem of "organizing human cooperation". a good solution should be appliable to both.
so this is a multipart post series where i try to make sense of the world through simplification. i ask myself questions and provide some answers. save yourself some anger about my stupidity and skip these. i write these for myself only. :)
the entries are the following:
published on 2022-10-01
# coreleader: the core task of a leader is to approve plans (2/6)
most organizations, governments have leadership. what is the role of this entity? i think in general that would be to ensure the organization remains healthy and long living. i understand it's a complex role but i believe "approving plans" could be a somewhat appropriate description of the core task of a leader.
note that i'll use "leader" and "leadership" interchangeably. for now i'll think of it as a single person to make the discussion simpler.
this leader will participate in many meetings where various people discuss various problems. people then propose various plans to address the problems. the task of the leader is to analyze all the proposals and simply approve a plan by signing some piece of important paper. and if it's a somewhat controversial decision, he needs to carefully explain the rationale behind the approval.
notice that this definition doesn't require wide expertise from the leader. the leader doesn't have to be an expert in all fields known to mankind. he just needs to make sure he does decisionmaking in a good way. for instance he might never approve big sudden sweeping changes such as "eliminate all x" or "give free y for everyone". he might reject such proposals in favor smaller scope, gradually rolled out approaches to achieving the same goals. such approach will be much cheaper, problems encountered will be cheaper to fix, and doesn't make everyone angry at the same time. basically a good leader must be good in change-making rather than being the navigator himself.
# power
what gives this leader this power? why will people follow his approval? it's because the leader wields indirect physical power.
a company's boss might have power to simply fire non-compliant employees. a government's president might have the power to request military or police action.
in aggregate people respect such power. behaving differently to the well trodden path is ridden with risk and uncertainty. at the end of the day most people just want a relaxing evening at home so they won't rock the boat too much. therefore it's natural that the currently accepted norms have a big traction.
i don't think power in this sense is necessarily evil. it's actually quite efficient. it allows me to predict what will happen for certain actions. i know if i go up to a person to ask time, i won't be violently assaulted or insulted. the government and company take care of such bad elements so that i can better focus on my life and work.
# abuse
but if a leader has such power, how do we prevent abuse of power? such a leader could make decisions that favors only himself and leaves everyone else in a bad place. i think there are two general solutions to this problem:
i don't think accountability is enough on its own. a leader can be very often skillful in avoiding accountability. i'd rather focus on dilution.
however i don't think large dilution works when it comes to enforcement. suppose a company leader wants to fire a person or a government wants to take military action. there's innumerate sensitive details that need to be discussed. that cannot be done in the open without creating a lot of damage to trust and goodwill when people play the devil's advocate. i do believe that there are topics better discussed behind closed doors amoung few key people. in the end often a small number of people need to make large-impact decisions.
besides, large dilution is also ineffective. individuals cannot be involved in all the nitty-gritty details of all decisions. it would be hard for them to focus on their own life and work. a lot of people don't really care about the details, they just want to trust that decisions are made in a sound way. or at least that's the case for me. it's like babysitting: i don't really care how exactly the babysitter works as long as i know my baby is properly handled and remains happy. all i need to do is to pick the right babysitter. i don't want to stay at home and hold her hand telling her how to do babysitting.
i think a small scale dilution of leadership should be enough to avoid most of the bad effects of both a single bad leader and of large dilution.
but then who is the leader working for and how do we align the interests between them and the leaders? i'll tackle that in @/corerepr.
published on 2022-10-02
# corerepr: the core task of representatives is to prevent bad plans (3/6)
in @/coreleader i observed that leadership doesn't work if it has large number of people involved. this means we need to make it work with few people. in that previous post i also mentioned that the leadership's role is to ensure a healthy and long-living organization.
# organization
what is an organization? i think it's just a set of people interpersonally connected through some shared belief or goal.
even among those, different people are connected with an organization on different levels. some people care if the organization is long living, some people don't. let's call "stakeholders" the people who want the organization long-living.
this means the leader's interest has to align with the stakeholders.
# stakeholders
who are the stakeholders? i think we need to consider three sets of people:
which group's interest should the leader's interest be aligned with?
affected people? no because they have the least stake and because it's infeasible to find all the affected people. barring some extreme circumstances, customers can simply walk away from the company. such group might have unreasonable demands just because they don't have to deal with the consequences of bad decisions. and how do you even find the affected people? anybody could argue that some decision affected them. just because i don't like sugary foods, i should not have the power to ban selling cookies in my local shop.
power source? no because paying for something doesn't legitimatize things. if i'm a billionaire then would it be fair for me to completely take over a business and then tell people what to do? or if i'm a big company, can i buy up smaller companies and tell them to shut down? wealth should give you the power to invest but not the power to tell people what to do. i understand the two are very tightly coupled but let's keep this distinct in this formal setting for now.
controlled people? yes because this has the greatest power inversion. jailing up or firing people are major life events. that's an incredible amount of power to wield above someone. it's only fair if we try to equalize this power. i think that people's desire for prosperous and free living will average to an interest that makes the whole organization prosperous and free.
an example organization could be your body. the power source is the food you eat, or books and videos you consume. the affected entities are the other people you interact with such as friends and family. the controlled entities live inside you: it's your organs. you can remove an organ you don't like. but you remove too much and you no longer exist. if one of your organs doesn't work well, you can't work well either. a headache or a broken bone and you can no longer work. the power source is replaceable. if you are out of carrots, you eat potatoes. so is the affected entities: you can change the people around you. not so for your organs. it's very expensive to change your organs given how critically interconnected they are (also see the #power section in @/coreleader). if the "you" wants to live long and healthy, then keeping your organs (controlled people) healthy and in sync should be the most important task.
with a healthy body the rest will follow naturally. e.g. you can go to shop on your own to pick the nicest fruits. and just how you would buy the healthiest looking apple, similarly investors prefer buying healthy looking companies to dysfunctional ones. just focus on keeping your organization healthy and investors and customers will come but they don't need to overtake leadership.
# aligning
how do we align the interests of the leaders and the stakeholders? there are many ways to look at this but i'll go at this from the simplicity angle.
most proposals have only two sides: for and against. and each citizen (or employee) has an opinion (again, let's go with this for simplicity). often this is split at the 50% boundary: half the people are for, the other half are against a specific proposal. if the leader chooses the same option as what the citizen wants, we can say the citizen is represented.
the problem is that if there's a single leader, then they might live in an echo chamber and completely oblivious to the large opposition.
what if there are 2 leaders? they would cover the whole opinion spectrum in this simplified model. when one of the leaders signs a proposal, it gives it to the other person. the other person has two options: approve or veto.
however there are two downsides: first, if one of the leaders is sick, the whole decisionmaking is on a break. second, if the two leaders really don't like each other, the leaders might just veto everything and no progress will be made. this can get quite nasty over time.
what if there are 3 leaders? i think this is quite the sweet spot. there's is significantly more chance that 2 out of 3 people can agree on a proposal. it's even more representative: in a nuanced organization a 3rd candidate could represent a minority voice.
what about more leaders? i don't think there's a good number. 3 is pretty much the minimal number that avoids the worst problems hence i'll go with that for simplicity.
if we have 3 leaders, then i think voting a leader starts working again. if done right, the selected 3 leaders will be an authentic voice of the citizens or employees. but if we vote people to represent us, perhaps we could call them representatives rather than leaders. they don't really lead after all, but rather accept proposals on our behalf. let's just call them representatives rather than leaders.
so what are those 3 representatives do? the same thing as a single leader would do: approve proposals and then enforce them.
i want the bureaucracy around all this to be minimum. on a high level it's really just a one-click task: approve or not. there's not much formal process to it. this way the representatives can focus on the task they do best: ask questions, inform themselves, debate, ask the proposal writers for improvements.
in the end the proposals to make decisions are coming from everywhere. all they need to ensure that really bad proposals are never approved.
now the only question is: how do we vote for our representatives? i'll explore that in @/corevoting.
# edit from 2023-08-13
here are some interesting references about multi-person leadership i found over time:
published on 2022-10-03, last modified on 2023-08-13
# corevoting: the core task of voting is to select good representatives (4/6)
in @/corerepr i mentioned that i think we should have 3 representatives at the rudder wheel of an organization. but how should the stakeholders (the citizens or employees) pick the right 3 people?
approval voting is my answer since it's one of the simplest system i can think of that allows picking multiple people. each stakeholder just gives a tick to each person he would accept as representing them and that's it.
but there's some devil in the details. picking the list of candidates needs to be done carefully but i don't want to go into that here.
# eliminations
so we have a list of votes, how do we pick the 3 representatives from them? we can't simply take the top 3 people since the choices are quite correlated. we would end up with 3 people having the same opinion.
pick the first winner as the person who got the most votes. if a person gets most votes, then clearly there are a lot of people who want him.
before picking the second winner, eliminate all votes that voted for the first winner. we can consider those votes to have a representation already. the votes remaining are the voices that doesn't represent the majority opinion. so just pick the top winner from these remaining votes.
do the same thing for the 3rd winner: further eliminate votes that picked the second winner. this way an even smaller group will have representation.
in any round break ties by date of birth or name if it's still a tie.
# results
how are the results applied? if the 3 new winners are same as the current set of representatives then it's easy: no change. but otherwise i strongly believe that changes should be gradual. big changes cause lot of chaos. therefore my proposal is just to replace the least popular representative with the most popular not-yet-representative.
changing a single person at a time avoids the often disastrous results stemming from big sudden changes. and onboarding the new representative is much smoother too. with a single leader the new tasks can be overwhelming. but here the country/company keeps working until the new person fully learns the ropes. the danger of making newbie mistakes is much less.
(edit: hmm, now that i think of this, the above doesn't work. the whole leadership must be replaced at once otherwise the resulting trio might not represent the desired mix of representation.)
# frequency
how often should these elections recur? getting this new responsibility can be stressful. losing this responsibility (a job basically) can be stressful. if we have frequent elections, the representatives might be stressing about it all the time. in fact elections are an expensive event. the already elected representatives might spend inordinate amount of resources on campaigning for themselves to keep their job instead of doing their job. in fact they might be incentivised to make worse long-term choices just to make people happy now and keep their voters happy.
a way to combat this could be to reduce the frequency of elections. i say it should be done every 10 years. i say 10 years so that it's a round number and we can think in decades. so e.g. a trio would lead during the years 2020-2029 and we can talk about the "leadership of 2020".
longer terms not only means that the leaders can focus more on their job. they will also have the means to work or invest into longer term projects with less risk.
(edit: in fact, maybe allow one term per person so that during leadership they at no point focus on getting reelected. maybe allow coming back after a decade of break. but perhaps not, strict term limits are probably good.)
one problem with a decade long period is that the chances are high that one of the representatives might be incapacitated. to combat this i'd also involve the 4th winner in the whole leadership stuff. i'd grant them same confidentality privileges as the first 3 winners, i just wouldn't give him approval powers. however if one of the 3 representatives can no longer do their job, they can hop in as a replacement.
# voters
who should be able to vote for the representatives? if you have a small company of at most thousand employees, i say let everyone vote.
however at much larger organizations like whole countries this can be quite tricky. running such an organization is quite complex. how would voters know who is the best person for the job? even if they have a hunch, how do they know that the person they selected is a truthful person who doesn't lie on their promises? and how can an ordinary voter even hold a leader accountable?
it requires a lot of work to be an informed voter. fortunately there are a lot of people who are willing to invest the work into this but they are often drowned out by the uninformed voters.
so there's a crazy idea but i quite like it: create a new "the notables" class of people. they would consist of about 5% of the population. so 1 out of 20 citizens would be a notable. the notables are like ordinary citizens but with an additional privilege: they can vote in the representatives polls.
# notables
how are the notables picked? the citizens vote them too! with similar approval voting as described above, of course. i really liked the idea in https://demodexio.substack.com/p/how-to-fix-democracy-empower-the. you divide your country into districts of 100,000 people. the citizens of each district each month elect 20 new notables. the notables then serve for 15 years. so in a steady state you will have 15years * 12months_per_year * 20new_members = 3,600 notables. 3,600 of 100,000 citizens is about 5.5% of the population.
if you are a politically informed person or just want to vote yourself, then simply run for being notable. anybody should be able to join the monthly election. large applicant lists can be resolved with a simple queue. if you sign up to enter an election, you get added to a queue. every month the first 100 candidates are popped and added to the next election. so you will eventually participate in a future month's election.
if you are not that interested in politics but you know of friends who are and you really respect their opinions, then vote for them. if you ever knew a person who you think should never vote, well, this system does give some protections against that.
it also moves politics out of ordinary people's lives so they can focus on their own work better. i believe this system also makes the campaigning less of a circus. there's less value in targeting the general population with campaign ads since they have no power. and the notables are well informed, misleading campaigns targeting them should be much less effective.
the whole voting infrastructure could become easier this way since there's less votes to manage. and for notables the anonymity requirement could be eliminated too and then there would be much more trust in the results of the presidential votes. i have to admit though that i haven't really thought through all the implications of this, i came across this idea quite recently.
anyway, speaking of countries and assuming we have a way to elect leaders, what should be the government's job be? i elaborate on my crazy idea on this in @/coregov.
published on 2022-10-04, last modified on 2024-01-02
# coregov: the core task of a government is to distribute money (5/6)
what type of government would i really like to have? from @/corevoting i know i would like something that 3 democratically elected representatives at the head. but what exactly is the government's core task?
# requirements
what do i want the government to provide for me and my fellow citizens?
so basically i expect a lot of things from it. some of my requests seem even contradicting each other. how would it provide food, housing, education and all that while being minimalistic?
if i want to simplify things, what would be the core task of a country's leadership? if it's one thing, then it should be making decisions how the money flows through it. there's a lot to unpack here.
# money
what is money even? in general i don't really like the concept of money but i cannot deny it's a very useful abstraction. making decisions around housing, food, etc is quite hard. but money allows us to project everything's value onto a single one-dimensional scale. then comparing solutions becomes much easier. so i think of it as a simple measuring scale of complex objects.
if we want to have a simple system, i think using money or a similar token concept is useful. sure, money can corrupt people. but it's like saying knives can kill people. that's true but it doesn't mean it cannot be used as a tool. so i think it's fine to think in money when we are making decisions.
# decisions
what are the decisions that the government makes? the government might choose to give food for homeless or build a school. but it's not the representatives who are going to cook the food or hammer together the school. they give money to other people to do so. so in a very high level they are just the stewards of the country's common bank account.
if that's so, we might as well make that quite formal: that's the only task of these representatives. basically they have a budget and have to approve plans in a way that the expenditures are in the budget and the people are happy.
# algorithm
how does the money flow? the representatives make decisions about money but it's not like they manually carry and distribute bags of money. i imagine there's a big bank account where taxpayers send their tax to. then there's a computer program that runs every day and sends money to appropriate places according to its algorithm.
so the proposals that the representatives decide on are simply changes to this algorithm. maybe today schools are financed with the formula of ($10,000 + number_of_kids * $1,000) / month. and in exchange the school must educate kids for free as best as it can from that money. that's the government's idea of investing into school. it doesn't prescribe how schools should run, it would delegate that to the local school's administration. they probably know better what their community needs. this satisfies both my requirements: investment into education yet quite minimal and not prescriptive.
and if someone wants the government to invest more into education, then they can simply send an adjustment to the formula. e.g. they can send that the formula should be ($20,000 + number_of_kids * $1,500) / month. and then the representatives can think hard if this is worth or is the budget better spent somewhere else.
the government program could then be completely open source. citizens would have then greater insight how their society is structured.
# competition
is even the tax revenue service just another company that government hires? yes!
in fact, why hire only one? it could hire two or three and then people can choose which service they use to hand in and audit the tax they owe. let people pick the nicest tax collector help them figure out the tax.
in fact, allow entrepreneurs start new tax collection service if they want to. they still need to satisfy the various regulatory requirements. but maybe they can do it in a more friendly and cheaper way than the competitors so why not. all the government needs to ensure that it approves some rules and to ensure it finds someone to enforce them. just because a government owned organization does it something it doesn't mean it will be intrinsically better or more efficient.
it doesn't work super well everywhere though. take something like the police department. i think that's a special case where having just a single organization is beneficial. but that can be modeled recursively: the government just allocates a big recurring payment to the whole department. it's then the police's department task to figure out how to further allocate that money. and given it is a separate organization funded by public money, it would have its own elected representatives managing it as they best see fit.
# investments
so the government ensures that organizations providing for basic needs are well funded. how would it decide financing experimental projects that could fix climate or take us to mars?
if the economy is doing well, there should be plenty of surplus in the budget assuming the government doesn't squander it all. at this point it should look at long-term experimental investments. maybe it could fund space tech. asteroid mining and moving thrash off the planet could give humanity a huge breathing room.
basically the representatives could gauge what future people want and allocate funds towards those goals. technically people could do this on their own with their daily choices but only to an extent. ordinarily a poor person cannot decide where the rich man's tax should be invested into. but this would give them that power in a very indirect manner. of course there's a lot of nuance to ensure this is done sensibly but that would be my rough idea. it might not be much but still better than nothing.
once the government decides to send money, say, to a school, how does it ensure that money is well spent? that's something i'd like to think about in my final post, @/coreedu.
published on 2022-10-05
comment #coregov.1 on 2022-10-08
Where does money ultimately come from?
comment #coregov.1 response from iio.ie
i haven't thought much about it. i suppose there could be a central bank of some sort that can create money by loaning strategically. or if cryptocurrencies ever become stable enough, maybe using one of them could be fine too. while it's an interesting question, it probably doesn't really matter that much at this high level where i already assume we have a working monetary system.
but in case money is very volatile (high inflation), maybe all accounting could be done in terms of a stable commodity such as gold. e.g. in the school example it would mean the school gets 1 ounce of gold per kid per month. and then that gets converted to whatever money that is worth before each transaction. this might seem very crazy but not sure if the proposed framework has any other stable means to deal with this problem.
# coreedu: using the core-task principles for running schools as an example (6/6)
in @/coregov i've talked about how governments could fund schools. i'm picking school as an example, the ideas here could apply to other organizations too. how would such a publicly funded school operate?
i say anybody can start a school assuming they can prove the government that they are ready to hire enough teachers and have enough potential students to make it worth the overhead. or maybe a community is already running a private school but wants to convert to a publicly funded school. they can just fill an application form, the government runs some background checks, and if it checks out they will receive the funding.
# costs
how much they get? i think there should be a static formula for it. e.g. (number_of_kids * $1,000) / month. so if the school has, say, 100 kids, then they will receive $110,000 per month. if they can run it with, say, 10 employees, they can pay each $5,000 monthly and still have $50,000 over for supplies and maintenance. the exact the numbers don't really matter, it's just an example.
i'm also assuming that the town or government provided a building for this purpose so the school doesn't have to pay rent. otherwise they would need to pay less to the teachers or have less teachers to make up the difference with the rent. the nice thing about this is that the central government doesn't need to deal with local problems.
local problems can be still addressed, it just needs different channel. e.g. ensuring adequate building for a school is the responsibility of the town's administration, not the central government's. for some towns renting a building might be simpler than expropriating an existing one. there's no need for the government to prescribe how this should be secured.
# competition
can a town have multiple schools? sure! in fact from administration's point of view they might even be housed in the same building. this might make sense in some extreme cases.
maybe the town wants to want to have very successful sport athletes. they might operate a school that focuses on sport while also operating a traditional school. they are so different that having a completely different administration makes sense so let them be. for the government it shouldn't really matter, it's the same cost per kid.
if anything, the town can stop creating a sport school by not giving a building for free.
a publicly funded school must accept all kids for free and there cannot be a paid tier. but people can also start private, for profit schools. the government shouldn't care. it's actually better for it since it's less expenditure.
# representatives
how is it ensured that the public money is not mismanaged by the school's administration? first, the use of public money must be written down into a logbook. each expenditure must have a justification. this logbook can be then audited by appropriate personnel.
and there's some safety in numbers. in order to qualify for public funding, the government might require at least 10 employees in a given school. per @/corerepr the employees would vote 3 representatives among themselves to oversee the school administration. then these representatives must approve every decision and expenditure. this is really just clicking the approve button so if everything is clear this not much of an overhead. but it still gives a lot of power to the employees to stop corruption from within.
i think of representatives as the consciousness of the organization. if all things are well oiled, they just rubberstamp the benelovent administration's actions. hopefully vetoing something would happen rarely.
furthermore parents also have an indirect choice. if they don't like the school, it should be possible for them to take their kid to a different one. and then the school's funding drops. hopefully this would be enough incentive for the organization to stay healthy and provide value to the parents.
# summary
and this concludes my foray into philosophy of organizations. i think these principles could be used to organize humans in a relatively low-conflict manner. i have to admit, i haven't thought through all the implications of such a system. but at least i now have some weird topics to talk with people about. :)
published on 2022-10-06
comment #coreedu.1 on 2022-10-08
1. How do you prevent monopolies/anti-competitive behavior?
2. What happens in rural communities that have, say, 3 kids? How do you ensure they are schooled appropriately?
comment #coreedu.1 response from iio.ie
re preventing monopolies: i'd like to keep the barrier for starting a new school low. my hope is that then competitors can easily pop up. i expect more specialized schools would appear this way: schools with focus on arts, sports, stem, etc. then perhaps less talent goes wasted if kids are with other like-minded kids and teachers.
re preventing anti-competitive behavior: i wouldn't build any protections against this specifically. people can raise such issues to the judicial system and they will, hopefully, sort it out.
re rural communities: no specific provisions for them. the kids can either commute to the nearest school or join a school that can teach remotely. if the kids need additional support (e.g. commuting assistance), they can request help from their local municipality. explicitly not supporting every snowflake situation helps keeping the system low complexity.
# aidsim: a monetary aid distribution simulator
this post has non-textual or interactive elements that were snipped from this backup page. see the full content at @/aidsim.html.
if i have some amount of cash, which people should i aid financially? the poor or the smart ones? i've built a little simulator to help me think about this question.
# the human model
i model an individual person with two variables:
both variables are normally distributed just how i imagine reality is.
i measure the person's value like this:
the average person of potential 1 and wealth 2.71 will have a 1 * log(2.72) = 1 value.
# log(wealth)
using log(wealth) to model reality seems relatively accurate to me. think of a very poor, hungry student and give them $10. then he might not starve the night so those $10 have a very large utility for him. now take a rich student and give them $10. it changes nothing. however if you give him $100,000 then he might go to an elite school and improve his own value significantly. but that needed exponentially more wealth to afford. the richer someone is, the less utility each individual dollar has. i think the natural logarithm function nicely fits this phenomenon.
# potential is unmeasurable
in my simulation i won't allow selecting beneficiaries based on potential. consider a genius who was never given proper food, care, never learned to read and write. no matter how large potential he has, he will not have a chance to demonstrate it. you actually need to invest a lot of effort (wealth) into creating a supportive environment for the person to thrive. and then you can measure the value of the person but that value already contains the environmental factor, log(wealth).
# visualization
below you will see two scatterplots. the y axis on both graphs is the value of each person. the x axis of the first one is the potential, on the second one it's the wealth. each person will be represented by a single dot on each scatterplot.
i added visualization because it's nice visually seeing which slice of population are you selecting and aiding.
# goal
suppose you have to distribute 10k wealth and your goal is to increase the total amount of value gained. you can choose to give the money to a combination of x% worthiest and y% poorest population.
in @/aiddist i'll share my own observations.
# the simulator
[non-text content snipped]
published on 2022-10-09
comment #aidsim.1 on 2022-10-10
It looks like you're over-complicating this. Since your model doesn't have feedback loops or non-random external factors you can simple do: d/dv potential*log(wealth) ∝ d/dwealth ... ∝ 1/wealth. So you maximize value by giving to the poorest.
(Also, I think the term you're looking for is "productivity" or at least "[economic/society] value creation".)
comment #aidsim.1 response from iio.ie
in my simulator i get a better result if i filter out both the wealthy and the unproductive people, see @/aiddist.
# aiddist: aid the poorest but already productive people
in @/aidsim i've created a simple model of society and then little toy to play with various aid distribution strategies. i don't claim that the model is realistic but nevertheless let's pretend it is and see what the results would mean.
# few high-value individuals
even before we send any aid, the baseline scatterplots show an interesting thing already. there are surprisingly few people that are super valuable and there's a large population of low value people.
this turns out to be an artifact of the random value generation. in order to be high value, you need to have both high potential and you have to be wealthy. both of them are rare so together they are even rarer.
in practice one of the variables will be below average for most people so they will have a limited value. i claim this is actually quite realistic: there are only a handful of truly high-value individuals in societies. and by high-value i mean a person, whose impact improves many people's lives immensely.
# universal distribution is ineffective
one thing i immediately noticed is that distributing money uniformly is not efficient. and that totally makes sense to me. imagine aiding a criminal (person with potential less than 0) with money. the criminal can now buy more efficient weapons and bombs. of course that will just make things worse for society overall.
or imagine giving money to a very disabled person (person with potential around 0). there will be very little value return for that so the money invested will be pretty much wasted.
big sidenote: i'm not saying we should not help low potential people. rather, they need different sort of help than sending them money directly. you might give a homeless person money and he might spend it on drugs because he can't do anything else. but instead you give them housing and job training, and it might actually unblock some of their hidden potential. after that investing money makes sense.
or just think about educating young students: you don't give them money and then let them buy their education. you teach them first. once they are independent and reliable adults, you give them money through employment. this is another example where it's not always money that people actually need to increase their worth.
and in general i have a lot of other beefs with the concept of universal basic income. stuff like where is that money coming from and how will be the resulting inflation dealt with. so far the only reliable way towards equality was to make everyone equally poor. a lot of societies managed to achieve that throughout the history. and my expectation from ubi is that it can achieve equality only through the same means. (my current opinion for the utopia is that we have to embrace inequality a little bit but more on this in a future post.)
# help the poor
giving money to rich people is mostly wasted money. they already have a lot of them so each individual dollar will give them very little value. giving to poor will give more for the bang.
# help the valuable
only aid people who have already proven that they are a worthy individual. this is probably the most nasty observation but it actually makes sense if i think about it.
ideally we could measure the potential but as i described in @/aidsim, it's not possible. the next available proxy is the individual's current value. imagine the case of the poor genius. a lot of value is held back due to low wealth. but if they passed the value threshold, then it means they have incredibly large potential to compensate. giving them a little money gives a large amount of value back. maybe the genius can afford internet access and then his knowledge exponentially grows. that is definitely worth the investment.
it's unfortunate that this approach won't detect the truly high potential but super poor people. but there's no good way to catch such people. the best thing to do is to improve society at large such that even the poorest people can have a high standard of living. and to achieve that, we just need keep advancing our society's technological achievements and hope that the advances trickle down to everyone.
# tiebreaking
suppose after all the filtering you have surplus people and you need to eliminate about half the people. from what i can see simply randomly picking the beneficiaries is a relatively sound strategy. relatively little value is lost as i drag the random slider compared to the filter sliders.
an alternative approach (not modeled by my demo) could be to look for evidence of additional hurdles in the person's life. if they managed to overcome those, then it also means they have larger potential to compensate for them. so i think discrimination based on race, religion, sexuality, gender, etc could make sense. e.g. suppose there are two equally wealthy and equally qualified candidates for a tech job, one white guy and one black woman. i'd expect the black woman would have more hidden potential simply because she is likely to have had more hardships in her life. then picking i'd expect that the black woman will give you more value assuming you can create an inclusive place for her where she can unleash her potential. but if such discrimination is off the table then random should work too.
# results
after some poking i found that for 1k wealth about 30% worthiest and 30% poorest works the best. for 10k wealth about 40% worthiest and 40% poorest. the exact numbers don't really matter. what matters is that basically the optimum number of beneficiaries highly correlates with the amount of wealth available to distribute. it isn't worth giving a little to everyone or a lot to a few. it's best if you give a reasonable amount of wealth to as many people as you can afford in a very specific priority order.
again, all this thinking was based on a toy model which might not be representative of reality. but at least it gives me some sort of intuition about a problem space if such topics ever come up in discussions.
published on 2022-10-10
# autotax: an alternative money system to simplify taxation
if i had the chance to create a monetary system for a society, what system would i create? disclaimer, i don't know anything about money. i just find it interesting to come up with random rules and then see what properties the resulting system has. let's just pretend i'm 5 years old and it's creative writing time.
# rough summary
that is a very rough summary but there's a lot more nuance to it. i'll elaborate on that below.
note that i'll use $ as the unit of the new fictional money i'm talking about. it's not meant to represent dollar but my new money.
# taxation in the current system
taxation can be an incredibly complex process. iiuc its goal is to ensure a fair reallocation of resources in a society. but one needs to track all transactions, enumerate all assets, fill long forms. the tax code just keeps on growing which results in an ever growing army of bureaucrats. then there's lot of bickering about how much tax each person and company should owe. i feel there's just way too much effort wasted in this process that could be spent on more fruitful efforts instead.
so i'll think about a system that avoids this problem. i'm sure it would have a new set of yet unknown problems but nevertheless it's worth starting somewhere.
# central bank
the core idea of my proposal is that there is a single big central bank. this bank is not for ordinary citizens but rather for government, community banks, big corporations. this is the only bank the government would enforce strict rules on.
to keep things accountable each account's ledger is public. each citizen can see the transactions between the accounts along with the transaction note if there was one attached.
each evening the accounts are taxed by moving 0.05% of the funds to the government's account. over a full year that's a tax rate of about 20% (1.0005^365.25 = 1.20). the government's account is special, it's not taxed.
# community bank
if a village wants to provide banking for its villagers, it can open a `villagebank` account in the central bank. to kickstart society, let's assume that the government gives $1,000 to each 1,000 villagers. this means that villagebank will have $1,000,000 in its central bank account. the central bank doesn't track each villager's account, that's the responsibility of villagebank's management. the government has no insight into the villagers' actual transactions either.
on the first day the central bank will tax the account with $1,000,000 * 0.05% = $500. so the remaining money is $999,500. it's up to the villagebank's administration how it funds this liability from its customers.
e.g. villagebank can simply charge a daily 0.06% tax on its customer accounts. the extra 0.01% is meant for the bank's profit. but then maybe villagebank2 appears which charges only 0.055% tax. and then the villagers can choose which bank they keep their money in.
if a villager moves to villagebank2 then it will transfer his money to the new bank. this means villagebank will need to transfer $1,000 to villagebank2's central bank account. note in this central bank transaction it's not visible which customer's account is affected. other citizens can only see that a transaction happened between the two banks and villagebank2 is now richer and thus will generate more tax revenue.
# taxation
so after the first day villagebank has $999,500 and the government's account has $500. this means there will be a transaction with the contents of `$500 villagebank->government tax`.
the government wants to invest into the village's education so it sends $500 to the village's school. the school's bank account is also residing in villagebank so this transaction appears: `$500 government->villagebank public education`. from the note villagebank will know to debit that amount to the school's account. villagebank's central bank account is at $1,000,000 again. and the school's administration then distributes those $500 among 4 teachers and 1 administrator.
this demonstrated how a small community can fund education without:
i'm fine with taxing landownership too since they should be relatively easy to manage without too much bureaucracy. e.g. each day each villager must pay $1 for their little farmland. but then the government sends the collected $1,000 back to the village's major. the major can then spend it on whatever the village needs.
# public funding
imagine villagebank has 50 students to educate. the government's strategy is to provide $10 per student per day for the school.
after the first day the school would receive $500 and the school's account would contain $500. the next day is account will be taxed with $500 * 0.05% = $0.25. and then they receive $500 so at the end of the day they will have $999.75. the next day they will be taxed almost $0.50. so the net account increase is $500 - $0.50 = $499.50. the more money the school keeps on its bank account, the less money it will receive daily.
as long as the school doesn't spend any money, its account will never exceed $1,000,000. $1,000,000 will be the fixed point of the account since $1,000,000 * 0.05 = $500, the amount it actually receives daily. in other words, all the villager's money will be eventually acquired by the school. the school must invest the money back into the villagers otherwise the village grinds to a halt. since the school is publicly funded, i'd require for its account and its transactions to be publicly auditable so that the villagers can see what they get for their mandatory taxes.
the school is incentivized to spend/reinvest most of its money that it gets but even if it doesn't do it immediately, it doesn't lose too much. i think this system is somewhat nicer than the "use it or lose it" type of budget systems that is commonly used nowadays.
# loaning
first of all, i'd outlaw fractional reserve banking (remember, i'm 5 years old). i feel it's an inherently risky way to manage money. and it also gives the bank the incredible power of creating money out of thin air. i understand that loan repayment then later destroys the money created. but between the two timepoints the additional magic money creates inflation that lasts even after the loan is repaid. basically if you give your money to a bank, then it devalues it without you knowing about it. i think loans can work just fine even without that.
let's take a simplistic example. suppose alice wants to borrow $500. alice can take a loan of $500 if she promises to pay back $600. the bank's sole task is now to find another customer who is willing to part with $500 of their money in exchange of getting $600 back. or if the bank has its own reserves, they can use that too on their own risk. suppose bob is willing to help alice. if alice cannot pay the sum back, bob loses whatever money alice couldn't repay. and that's the end of story.
it may seem $600 was created here but it's not the case. when bob loaned $500, bob's purchasing power dropped by $500. and bob can't use that $100 interest either until alice manages to actually pay that back to him. so eventually that $100 will come from alice's future paycheck, alice will have that much less buying power in the future. there's no extra money flowing in the system at any given moment.
# bank insolvency
what if a bank was run by corrupt administrators and loaned out more money than it is actually available? as people trade, banks have to settle transactions between each other through the central bank. suppose the villagers go to the city and buy bunch of stuff with their villagebank credit cards. now it might be the case that villagebank is owing $1,000,000 to citybank but villagebank has only $500,000 on its account.
one solution: government bails out villagebank and transfers them the missing $500,000 from the government's account. in that case the corrupt bank administrators just managed to extract free $500,000 from the tax paying citizens, yay.
a fairer solution is to do nothing. at this point citybank has to accept that they lost $500,000. it can sue villagebank though. villagebank can close its doors and then maybe citybank can regain some of its value by repossessing some of the assets of its administrators.
to deal with the lost $500,000, citybank can distribute the losses among its customers. if citybank has 10,000 customers, it can charge $50 on each account to make up the loss. maybe it will lose some customers who will go to banks who do more due diligence what other banks they transact with.
but the point is that it's not the taxpayers directly who pay for the bank failures. it's the citizens who keep their money in risky or shady banks who pay for these costs. it's a risk citizens can avoid by choosing their banks carefully. perhaps the government can help enforcing some standards to ensure citizens are aware what they are signing up for.
# privacy
people might be concerned with privacy if everything is electronic. there's nothing stopping someone to create a bank that will give you physical tokens in exchange for government money. and then you can trade with those physical tokens as you see fit. however such activity is a bit riskier in general (e.g. you have to deal with counterfeit tokens) but it's a risk citizens can take if they wish.
# high liquidity
the biggest problem with this monetary system is that it is not worth keeping your saving in the state currency. you are incentivized to exchange your money for something else so that it's not you who gets taxed at the end of the day.
on an individual level i think this is more of a presentation problem. it can be psychologically damaging to see that your money is getting smaller every day. but maybe villagebank will allow you to prepay 365 * $0.6 = $219. then you never need to think about your account throughout the year as long as you don't exceed $1,000. and then all the taxation is out of mind.
another way to solve this problem is to transfer the salary on a daily basis. then just like in the school's case all you will see is that your account keeps growing. it's just that it will grow at a slower rate as you get richer.
the problem is bigger for big companies who want to hoard large amount of money. hoarding money is expensive for them. this system incentivizes them to invest their money, keep things flowing. i think it's generally healthier to have agile, living organisms than just companies that lazily grow to enormous sizes without bounds.
# less wealth inequality
the system itself has no protection against someone earning a bigger share of the total pie than deserved. however the system is self-correcting. 1.0005 ^ (2.2 * 365) = 1.494. this means that after 2.2 years you lose half of your wealth.
this might sound crazy but keep in mind it's not the money that gets devalued but rather unused money gets repurposed. if you don't want to lose your wealth, take on risks and sell loans, hold stocks or commodities. then that money goes to the creators, entrepreneurs, farmers so life moves on even if you decided to retire. you can no longer idly sit on money.
in today's system our money is at risk thanks to the fractional reserve banking. but it's all abstracted away and we don't realize that the system might crumble overnight after a bank run. if in this new system you decide to invest your money into financing loans then at least you are aware what risks are you taking on. financing loans could be a safe default option for people wanting to maintain their wealth in an indirect manner.
i'd expect it would be much harder to keep a large wealth inequality in this system because it makes no sense to directly own a large chunk of the total wealth.
but i admit, account half-life being 2 years might be too aggressive. the numbers can be tweaked in an actual implementation though.
# incentive to operate publicly
public institutions have a great advantage compared to private companies. they have their income guaranteed so they don't need to do capital management. i'd expect that companies would outsource more research and development to universities to keep their companies leaner. or perhaps big companies would try to convert themselves into public utilities to avoid dealing with said capital management. so over time i'd expect that the economy might turn out to be of socialistic nature. i don't think that's a bad thing as long as the institutions are well managed (see @/corerepr). the free market remains to correct inefficiently managed public institutions though.
# capital flight
another nice property of this system is that capital cannot escape it. you can't simply pick up cash and move abroad. the money must always sit in one of the accounts.
one thing you can do is to convert all your money into a commodity, say, oil. but in this case you are actually doing an economic activity. keeping oil is expensive and dangerous. you take on all this work and risk on you in exchange for future reward.
so people are incentivized to take risks and do something useful with their money. i think that's actually a good thing!
# new money
a small amount of inflation is probably healthy to avoid the bad effects of deflation. a nice thing with having a central bank is that you can know exactly the amount of money society has. you can then have a rule that statically adds a 0.003% of the total money to the government's account every day. over time this adds up to 1.00003^365 = 1.011 => ~1% growth per year. so you would have 1% government generated money inflation per year. i think that's relatively harmless.
# bootstrapping
initially the value could be tied to another currency, e.g. euro. then the government sets up the first community bank, say, govbank. then as a bootstrapping investment, it commits to regularly transfer $1M to govbank. interestingly at this point the government already starts receiving tax income on its government account. that growing tax income can be later used to pay government employees as the system slowly rolls out.
then govbank provides a service to the citizens that allows easily converting between $ and euro. if someone has $1, they can ask govbank to give them 1 euro in exchange and vice versa.
once that works the government slowly switches government employee paychecks to the new system. initially this would be optional: if people choose to do so, they no longer need to do taxes. this could be a strong incentive to opt for the new currency. sure, people can then immediately convert their money to euro. let them do so. make this available only to a few people first so that the shock on the system is small.
then start allowing people to pay their taxes with $. and if they do so, give them a small discount. basically people will be incentivised to start using the new currency.
also start giving our welfare in the new currency. start asking government duties in the new currency.
over time start slowly loosening the connection to euro. e.g. once enough $ is circulating, allow the conversion rate to be between [0.9, 1.1] of euro. and then increase that to [0.8, 1.2] and so on over time until you remove it completely.
allow more people to forego tax forms in exchange for receiving income in the new currency. slowly ramp down the old taxation system.
so basically keep doing one small step at a time until the old system simply disappears.
# adoption incentives
assuming the small scale experiments didn't fail, the government would adopt the new money across the whole public sector. all nurses, teachers, policemen, would be funded by this new money. all welfare benefits would be paid in the new money too. and as i wrote in "incentive to operate publicly" i'd expect that the public sector would keep growing. in my @/utopia post i even talk about how easy it would be for the unskilled masses to enter the public sector fueling its further growth. so the new money would get a forced adoption by a large slice of the population. then it should make economic sense for companies to also serve customers owning the new money.
to further increase adoption among citizens, the government could commit to a universal income of $1 per day for each person who signs up for a govbank account. that's $365 / person / year, not that much. accounts under $2,000 end up having negative tax. the account will slowly grow towards $2,000. when it reaches $2,000, the tax due will be exactly $1 so the growth stops. this should incentivise people to have a govbank account and keep using it to receive further free money. of course such government commitment would be rolled out slowly to keep the shock effect small.
as for business owners: i'd offer them a deal. go new money only and you don't need to deal with taxes at all. i think there are a lot of people who don't like dealing with taxes so this would be a sweet deal. and then consumers would need acquire this new money to have a purchasing power for these new businesses.
furthermore, for the first few small business owners the government could offer a similar early adopter benefit: $10 / company / day. that would cost the government only $3,650 / company / year. that would mean that such companies would have a negative tax rate if their account is under $20,000. that could be super advantageous for small companies.
in the end it's mainly the business owners who need to be convinced to accept the new money. but hopefully the tax accounting simplification will be a strong enough incentive for them.
# budget management for private companies
i talked about governments at large but such a system could be used internally by larger private companies too. suppose the company wants to manage a budget for fun team activities, travel, equipment purchases, bonus payments. then each team has a shared account that the company tops up with $10 per day per employee but also taxes it 0.05% per day.
after each purchase the employee files an expense report. then the employee's manager reviews whether it was a valid business expense and there's budget remaining. if so then the refund is transferred from the shared account to the employee's next salary. or if the company can issue personal credit cards, things could be implemented even simpler.
the employees can send each other mini-bonuses while charging the shared account whenever a peer does something extra nice. if the attached justification makes sense, i think this is a good use of money too.
it's then up to the individual teams to decide whether they spend their money on fun events, travel, high tech equipment, or peer bonuses. the company doesn't really need to think too hard how the employees spend their money. the company doesn't lose much money through this process since unused money gets repurposed automatically. and if the company is in a tight spot, it can just decide to reduce the daily payment and let individual teams decide what to cut.
# conclusion
and that concludes my idea of this alternative monetary system. it probably requires a competent government to manage it well. the government can no longer create money out of thin air and hope things work out. but i hope it cannot be messed up too much since it tries to self-correct wealth inequality. it would probably take a while to get used to it, but i can totally imagine this could end up being a stable system.
# demurrage (added on 2023-01-29)
in the meantime i've learned that a similar can be applied to physical money too and in fact has been tried in the past: https://en.wikipedia.org/wiki/Demurrage_(currency). And there are existing currencies operating in this way: https://en.wikipedia.org/wiki/Chiemgauer#Demurrage. The idea is this:
... in order to prevent this complementary currency from degenerating into a means of hoarding and to confer it on high liquidity. It is required to put a stamp of 2% of the face value (€0.10 for 5 Chiemgauer, for instance) every three months to keep it valid, obliging its bearers to give up hoarding this complementary currency and to spend it as soon as possible and stimulating consequently the regional economy.
neat!
published on 2022-10-11, last modified on 2023-01-29
comment #autotax.1 on 2022-10-11
What is the incentive to participate in the first place? From what I can see only landowners have one. And government contractors, maybe. But you're keeping the government minimal so you don't have a lot of those.
comment #autotax.1 response from iio.ie
good question, thank you! i now added a new "adoption incentives" section about that.
comment #autotax.2 on 2022-10-12
I find this topic very interesting and keep reading your posts. I also often think about alternatives to fiat money, but cannot really find a solution. I like the idea of the current system, but the central banks f*** it up by buying government bonds by creating money out of nothing and not letting bad banks and as a result bad companies go bankrupt. Good old gold is the way to go, because its amount is physically limited. Sew a thin sheet of gold of appropriate value into paper money?
comment #autotax.2 response from iio.ie
a gold-backed cash-only currency still has a lot of problems:
- complex tax rules: small businesses have to do a lot of busywork to do to ensure they are paying the right amount. i'd even go as far to call tax accounting as one of those meaningless bullshit jobs.
- taxation only through violence: the government has to use physical force to repossess wealth from individuals who don't want to share.
- wealth accumulation: a single person can accumulate a large fraction of the gold and then the rest of people remain incredibly poor. often there's no incentive for the wealth owner to sensibly reinvest the accumulated wealth back into the society. capital holders are not taxed, only the doers, who are actually doing something sensible who need to pay taxes. this sounds crazy to me.
- costly counterfeit protection: small businesses have to be very careful about accepting only the real cash. this adds extra process and cost to the daily transactions.
- wastes precious resources: imbuing gold into cash makes it less available for other use such as electronics. similarly with bitcoin: is it really worth all the energy investment?
i say eventually our society should be technologically mature enough that we should be able track and redistribute our resources with minimal overhead. my proposal is one such solution.
# utopia: let people choose between free money vs free services
it's again time for me to pretend to be 5 years old and fantasize.
iiuc there are two main utopia ideas:
i'm personally in the universal services camp. all i ever do is sit in front of my computer and watch silly youtube videos. you give me money and i won't spend it. it's a waste of money. just give me some private space, some food and i'm happy.
but i can totally imagine some people would be much better off with receiving money. they can effectively invest that and provide great benefits to the society.
so which one should it be? i think it's possible to create a system that can accommodate both types of people.
note that i write this post assuming the @/coregov and @/autotax ideas are already in place.
between capitalism and socialism, it's probably corporatism that is the closest to what i'm describing. but i have to admit, i know very little about this ideology. just wanted to drop the name here for my own future reference in case i ever decide to look into this sort of stuff more seriously.
# publicly funded organizations
first, we have to establish that the government itself will fund some organizations, e.g.:
per @/coregov i'd fund these organizations based on the amount of people they are servicing. e.g. schools i'd fund per the number of students, or police by the town's size. and then it's up to the organization's administration how effectively it can manage its resources. e.g. if a police does policing well, they won't need many policemen and each policeman can have higher salary. hiring more policemen will not mean they will get a higher budget from the government. or hospitals: keep the population healthy because sick people will cost you money but healthy people are pure profit.
# voluntary prisons
let's take prisons as the first example. usually prisons are meant to keep bad actors away from society.
but look at it from the perspective of inmates: they get free housing and free food. maybe some reclusive people (like me?) would even consider moving to such a place voluntarily.
sounds like a simple life. so let's suppose somebody creates voluntary prisons. the voluntary prison administration receives funding per inmate. they would be incentivised to solve the housing problem for a large inmate population efficiently. this might lead to a more efficient solution than what we would end up if each person would need to finance their room independently. and if i don't like my voluntary prison's offering, i might go to another voluntary prison.
this idea is a bit similar to what chapter 4 of manna describes: https://marshallbrain.com/manna4.
it's also possible to earn a little bit of pocket money if i want to. e.g. if i help out with the cleaning or in the kitchen, the administration might reward me with some money. if i'm doing a good job, i might even become a supervisor of other cleaners or cooks. then i would receive more money. so i can have a carrier with an upwards trajectory even in a prison.
# military
but suppose i don't like doing nothing all day long. i want someone to tell me what to do. in that case i could join the military organization.
the military would also provide me with free food and housing. but they would also train me hard so that i remain a fit human who can help in emergency situations. i'd need to wake up every day and train. but otherwise i don't need to think hard about money here either.
if i want to earn money, i can help out with the cleaning and catering so i have a similar carrier possibility here too.
# education
but perhaps physical activity is not for me, i'd rather pursue academic goals. i could join an educational organization. the entry level positions would require a bit more qualifications though.
maybe i could start out as teacher's assistant. i'd grade people's essays, answer common questions, facilitate workshops, moderate internal forums. if i get the hang of it, i might become an actual teacher, or later a researcher myself. i wouldn't receive a lot of money in exchange but i would be eligible to live in the school's cheap dormitories.
# redistributors
but no, i don't want to join any organization at all. in that case i could join a redistributor organization. the government could support a few public organizations that simply redistribute money.
everyone who doesn't join the other public organizations can join a redistributor organization. this organization would have the least amount of conditions. it's basic income for people who forego the other options. however it wouldn't pay much. chances are likely that on this money i couldn't afford living in a city.
i would either move to a small village or have an actual job in a private company on top of this extra income. but that's actually pretty great. this means the city is left for people who actually do something useful. the government doesn't need support pure existence in the most expensive places.
# an option for everyone
those were just couple example organizations. more such public organizations could exist based on what society deems worth doing publicly (e.g. agriculture). the point is that this system gives pretty much everyone a place to be. it also gives a way to start earning money and the ability to climb organizational ladders. but it also allows for laziness if people want that. it just means they will have less luxuries then.
i think it's pretty neat and would totally like to try living in such a future even if i were totally poor.
published on 2022-10-12
# ranks: i think 6 separate employee ranks is all what an organization needs
in @/utopia i briefly mentioned how people can start climbing the organization ladder. but what are the individual rungs of such organizational ladder? i propose the following six ranks:
i'm sure one can think of higher ranks but i think that's counterproductive. at such high level ranks start matter less and different forms of organization should take over instead. if an organization still wants to rank higher-ups, it should do it informally.
# what are the ranks for?
when i'm interacting with another employee, i can use the rank to estimate the weight of the other person's request. suppose i maintain a piece of software and someone reports an issue in the software. i then look at the reporter's rank. if it's from a director, then it means that fixing the bug will have a larger effect on the organization compared to a member. by making a director's life easier it means he will have more time to focus on his high impact work.
but more importantly, i'd use the ranks for determining salary. i'd get rid of the per person salary numbers and just have a fixed formula for it. it would be a function of the rank and tenure and nothing else. i want to reward tenure too to disincentivize people from job hopping.
if an organization wants to reward performance, it can do so through one time bonuses. a one time high performance stunt wouldn't result in forever increased salary.
managing pay like this would be super simple, no need to deal with secrecy or problematic stuff like wage gaps.
# how is rank determined?
this is nasty and i don't have a good solution. i suppose some committee based system would be the best. nevertheless let me try to come up with an algorithmic solution and then explore its properties.
i'd create an online feedback system where each employee can give endorsement for another employee. in a public company we would want things to be accountable so the data entered into this system would readable by everyone in the company.
for each endorsement, the endorser needs to pick one of the following two prompts to respond to:
the endorsement must be reviewed and approved by another employee who can verify that the endorsement is truthful and is relevant to the employee's assignment. for leadership endorsement the reviewers would ensure that the individual endorsements are distinct enough.
people can send endorsements at any given moment. then each day the system takes the approved endorsements from the past year and assigns ranks according to the rules below. your rank is determined by the highest condition you meet. it's each employee's responsibility to ask others to write feedback for them. if they don't do it regularly, they will start losing their ranks automatically. yes, i'd totally allow going down in ranks too. i don't get what's so bad about that.
here are the requirements i'm imagining:
the requirements for rank 5 and rank 6 are significantly different. but i think that's fine. leadership is a critical role. if someone wants the high esteem that comes from high rank, they should continuously work for it. their underlings should continuously prove that said leader is still worthy. and because all the endorsements are public, anybody can check why people consider a person so highly ranked.
when bootstrapping, assume that there's at least 3 rank4+s. all the other ranks are reachable after that. people just need to keep entering endorsements. if you have less than 3 rank4s then just keep the 3 most tenured people as rank4. eventually the system will self-correct any imbalance.
# developmental feedback
suppose alice, a rank4, wants to achieve rank5. she asks bob to give her a leadership endorsement. but bob is not entirely sure alice is actually rank5 material. bob can discuss this with alice privately and alice can work with bob to ensure alice is providing work for bob meaningfully.
while alice is working on improving her performance, bob can start entering the draft endorsement into the feedback tool. once alice's performance is adequate, bob can finalize the endorsement in the tool.
# low drama
this system doesn't allow entering negative feedback. i think that's fine. negative feedback is probably best conveyed through private channels than public ones.
but suppose you know that alice, a rank5, did a seriously bad thing and you think she doesn't deserve their current rank. in the feedback system you (or the hr department) can track down who supported her rank5 and talk to them directly. when alice is asking the endorsers the next time, they might simply not do it due to the raised concerns. you might also warn the reviewers of the endorsements about alice's problems. so even if alice finds other endorsers, chances are the endorsements will not get through the reviews. alice will lose her high rank after a year without much public drama.
# jump to top
notice how at low ranks both work and leadership endorsements are accepted. this ensures two things: even if rank5 secures only two leadership endorsements, they will downgrade only to rank4.
it works the other way too. suppose you hire a prominent ceo from another company. initially you would give this person rank 1. if they can prove themselves right away, they can very quickly jump to rank 6. so this ranking system doesn't require experienced employees to go through all the rungs individually. however if the new person doesn't really work out, you didn't lose much. you just gave him a few months of rank 1 salary after all.
# limited positions
what if the company is low on money and wants to reduce the number of rank6s? it's really easy to do so. it can simply change the requirements. e.g. for rank6 the algorithm will now require 4 leadership endorsements. then only the truly worthy rank6s remain.
# low process
i want to keep the process relatively simple, that's another reason i differentiate work and leadership endorsement. the work endorsement can be quite simple: "alice prepares the daily meals perfectly without any supervision". two people say that and alice can stay rank 4. it should take only a couple taps on people's smartphones. i'd expect most people would coast at rank 4 for most of their carrier.
for leadership endorsement the process would be more involved, i'd expect more elaboration about the work done. but that's fine, high level people should be able to deal with the extra bureaucracy.
# no self packets
initially i considered having a system where each employee writes their own achievement packet and then others just approve the packet. but i find that a bit too self-oriented. i want people to rank each other rather than themselves. after all people's impact is only real if the other people can actually see it and describe it with their own words. then the employees are incentivized to be nice so that others write nice things into the public records.
and that concludes my idea about employee ranking. i have no idea how realistic this idea actually is. it seems like a low-overhead system so i wouldn't mind working in a company that is experimenting with a system like this.
published on 2022-10-13
# carriages: free uber as public transportation in small towns
this post has non-textual or interactive elements that were snipped from this backup page. see the full content at @/carriages.html.
modern, high density public transportation in cities is super convenient. i have high confidence that this hugely increases a city's total productivity.
but what about small, relatively high density towns where it is still not economical to build such infrastructure? i think such places would also see increased productivity if there was some transportation assistance. my crazy idea for this is that the town should offer free uber-like service for its citizens.
# why have public transportation at all?
most small town people own a car. otherwise their life would be quite hard. nevertheless, having an accessible public transportation is still useful:
and many more. the point is that there's always a need for accessible transportation assistance.
# solution?
crazy idea: self-driving electric carriages. by carriage i mean something like this but more modern and spacious:
[non-text content snipped]
i'm imagining a large metal box frame with large plastic windows on the side. so the passengers have a good vision outside. and the other townsfolk also see who use the service because why not. it should fit about 4 passengers.
the idea is this: it's like an uber app. if a citizen wants to travel, he just enters the from and to addresses and an available carriage is dispatched. if there is no available carriage, then he will wait until one is available. when the carriage arrives, he enters, he travels, and then he exits the carriage. the carriage goes back home after use to recharge unless there are other travel requests queued up.
the service would be available only for short local distances. i'm not trying to solve the long distance travel problem.
yeah, i'm assuming that everyone is tech savvy enough to use this service. i think that will be a reasonable expectation within a generation or two. even in today's world we assume everyone is capable to read, write, and fill complex welfare and tax forms. nowadays most schools teach computer usage. so having a smartphone and being able to tap a few buttons to access optional government services should be an okay expectation in the future.
# stepping stone towards a serious solution
this solution might sound silly. however the most important feature of it is that it's a stepping stone for a more serious solution. in general i believe it's quite hard to estimate whether investing into public transportation is worth it at all. however this proposal is relatively cheap and gives super useful data about the potentially important local routes.
maybe nobody uses the service and the town can pass the carriages down to the next town who wants to try a similar experiment. or the town notices that there is a large traffic between the train station and the school. then it can invest into a bus, and later into a proper tram for that section to aid the affected people.
# why free?
money based alternatives already exist: taxies or actual uber. however they are often not economical in small towns so they are not available or generally more expensive.
furthermore, if you ask for money, then less people will use the service. probably the poorest folks will not use it. those are the people who would be best served with public transportation.
i think of it like this: this is an expensive way to gather potential route utilization data. but once the data is gathered and the efficient routes are built, the investment would return in an indirect matter.
# how many carriages does a small town need?
i say a town should start out with 3. there won't be much use initially since people won't know about it.
but then the townsfolk will see the carriages moving around and might decide to try them themselves. to increase adoption, the carriages could go to the church or to a similar communal service to pick people up and transport them back home. this way the town could easily popularize the carriages among the older population who need it the most.
to assist less tech-inclined people in this situation, maybe there could be a button in the carriage to initiate a call with the operator. the passenger can press that and tell the operator where she wants to travel. this way people going home from church don't even need to have a smartphone to use the service.
if the carriages get popular, the town could order more of them.
a small group might decide to use it all the time. but over time their requests might get deprioritized in favor of others to make the service's availability distributed more fairly.
# simple self-driving tech
tech-wise i'm imagining an ebike-like contraption perhaps with a bit stronger motor and more battery. to increase efficiency, it's better if the carriage has no driver on it. less weight to carry, more travel distance on a single charge.
no driver means it has to be self-driven. i don't think that's a hard problem as long as:
at such slow speed even a track painted with a special reflective paint on the street could work quite well. that could be very cheaply painted over existing roads. or if that isn't reliable, perhaps rfid tags could be embedded into the roads that the software could easily follow. such solution should be perfect for straight roads.
it doesn't need very advanced radar tech. you can just install 4-6 cheap smartphones cameras around the carriage to act as the sensors. some of the cameras would try to follow the paint tracks, the other cameras are mainly for detecting vandalism.
there should be some distance sensors installed on it to detect people jumping in front of the carriage. nothing fancy but the detected distance should be just long enough that the carriage can stop in time. and there would be also a big red button in carriage that the passengers can press to stop it. perhaps the carriage might go slower (15 km/h) when it is driving in fully unsupervised mode until people start trusting it more. or perhaps the passenger could be fully in control of the speed of the carriage (but not the direction).
turns and crossroads could be quite tricky when it comes to self-driving. but for those, i'd just fall back to remote control. in the control center there would be a few operators who oversee the army of the carriages. every time a carriage comes to a crossroad, it would alert an operator to drive the carriage through it. they would also remote control the device in segments where there are no road markers.
adding more road markers and traffic lights could alleviate the need for operators handling the tricky cases.
# more small town life
this sort of weird free carriages could add a really interesting new character to small towns. it would be less hassle to go to places so it could liven up the town a bit.
however i'd emphasize that i really meant this for the last mile hauling at low density places. otherwise buses, trams, trains are much better solution.
anyway, i wish for a future where more people could live car-free even in small towns. i loathe cars, even self-driving ones (unless they go really slow). less cars in the suburbs will mean less cars in the cities too so it would be a win-win for everyone. biking too is more convenient around less cars so i hope at some point people in charge start implementing more stuff like this.
published on 2022-10-15
# cpprantdemo: a short dialog about c++ between a cat and a dog
here's the demo: @/cpprant.
out of curiosity i wanted to create a little javascript dialog demo with the following properties:
i've managed to implement that. wasn't sure that dialog to put into it, went with some silly c++ bashing.
the script is here: @/cpprant.script. all data is generated from this single file. i use rhvoice to generate the audio file: @/cpprant.go.
anyway, i can now cross one little project off my bucket list, yay.
published on 2022-11-05
# scratch: scratching notebooks can be addictive
this post has non-textual or interactive elements that were snipped from this backup page. see the full content at @/scratch.html.
[non-text content snipped]
published on 2022-12-04
# dynmem: golang is pretty much c if you avoid using dynamic memory
memory happens to be a very special resource in programming. it has to be used and well managed everywhere. when you don't know ahead how much memory you will need to compute something then you need to fall back to using dynamic memory. in non-gc languages this means lot of annotation and busywork, e.g. in c++:
class Car { public: void AddWheel(std::unique_ptr<Wheel> wheel) { wheels_.push_back(std::move(wheel)); } private: std::vector<std::unique_ptr<Wheel>> wheels_; }; int main() { auto wheel = std::make_unique<Wheel>(); ... car.AddWheel(std::move(wheel)); }
that's a lot of colon (:) signs and generally there's a lot of syntactic noise in there. it's quite painful for me to write this stuff out all the time. it also makes the lines unnecessary long. but in gc languages you don't deal with this nonsense. memory management is all automated, you just pass around pointers. you can focus on the logic rather than micromanaging ownership relationships:
type Car struct { wheels []*Wheel } func (c *Car) AddWheel(w *Wheel) { c.wheels = append(c.wheels, w) } func main() { wheel := NewWheel() ... car.AddWheel(wheel) }
# the problem
most common objection i hear to this are that gc slows down the application in an unpredictable manner. well, that might be the case in most gc languages. but if you are skilled enough in go, you can avoid most of that unpredictability and still have super clear and straightforward code.
the problem is using dynamic memory in the first place. if you rely a lot on a web of pointers and use lot of dynamic memory, then sure, gc will be a noticeable overhead. but this memory management will be present in c++ too, just more spread out.
but you could simply go for simpler structures like arrays and use indices instead of pointers, memory pools for allocation. then gc would have nothing to do so it would have no overhead. go would be pretty much like c performance-wise but with an extraordinarily rich standard library.
i have a daily habit where i solve a leetcode.com problem every day. i'm routinely in the top percentile in memory usage among go solutions. i simply try to avoid unnecessary memory allocation. but then this also results in much faster code too. so i'm usually in the top percentile for code too. so it's not that gc is bad, it's overusing dynamic memory what's bad. avoid that and it doesn't matter whether your language is gc or not.
there's a very good pep talk from andrew kelly about how to sanely manage data structures. i highly recommend watching it: https://media.handmade-seattle.com/practical-data-oriented-design/. another motivational post can be this: https://floooh.github.io/2018/06/17/handles-vs-pointers.html, another go specific best practice notes can be found at https://golang.org/doc/gc-guide#Eliminating_heap_allocations.
# disabling gc
if you feel brave, you can even completely disable garbage collection in go with the `GOGC=off` environment variable or from the code like this:
debug.SetGCPercent(-1)
but then make sure you periodically rerun the gc just in case you still generate some garbage. but as long as you truly don't do any allocation, this should be fine. in games you might not have any gc-ing while the player is playing but you run runtime.GC() manually whenever a new level starts or when the player unpauses the game. you wouldn't do any memory allocation in a performant game written in c++ either so you aren't losing much performance due to using go.
well, okay, clang can optimize and vectorize more effectively than go but perhaps those critical loops could be outsourced into a c library which you call from go. but then the rest of the code remains in the relatively easy to read and write go codebase.
# gc triggers
what follows is my understanding of the current defaults in go 1.19. go will trigger gc when heap allocations reach the heap size target. after that it will set the heap size target to the double of the live heap. this means your memory usage can double before another gc run. this is tunable though.
furthermore, with gc enabled go will wake up every 2 minutes to run the gc in the background. a better way to observe this is if you reduce the wakeup interval to one second and then trace the collection:
$ cat a.go package main import ( "runtime" "time" _ "unsafe" ) //go:linkname forcegcperiod runtime.forcegcperiod var forcegcperiod int64 func init() { runtime.GC() // needed otherwise the linking doesn't work correctly. forcegcperiod = time.Second.Nanoseconds() } func main() { time.Sleep(48 * time.Hour) } $ go build a.go $ GODEBUG=gctrace=1 ./a gc 1 @0.002s 6%: 0.40+1.3+0.059 ms clock, 0.40+0/0.29/0.72+0.059 ms cpu, 0->0->0 MB, 4 MB goal, 1 P (forced) GC forced gc 2 @1.062s 0%: 0.48+1.2+0.068 ms clock, 0.48+0/0.35/0.72+0.068 ms cpu, 0->0->0 MB, 4 MB goal, 1 P GC forced gc 3 @2.172s 0%: 0.44+1.2+0.078 ms clock, 0.44+0/0.31/0.73+0.078 ms cpu, 0->0->0 MB, 4 MB goal, 1 P ...
it's somewhat a shame that this knob is not exposed at all. but this go:linkname is a pretty neat trick that allows poking go runtime intervals, i love it.
# measuring
if you are considering to disable gc or run it less frequently, you first need to eliminate dynamic memory usage. you need to make some measurements for that. it can be tricky to see whether you allocate anything or not. if you build with `go build -gcflags=-m` then the compiler will tell you all the allocations that happened on each source line. you can have this output overlayed over the source code to see where the allocations happen. you can also use `go test -bench . -benchmem` to see the allocations from the benchmarked functions.
for a very barebones measurement of a function call, you can do this:
func mallocs() int { var ms runtime.MemStats runtime.ReadMemStats(&ms) return int(ms.Mallocs) } ... start := mallocs() f() println("allocated", mallocs() - start, "times during f()")
this measures the number of times f() allocated memory. you can use MemStats.TotalAlloc to get the number of bytes allocated instead. but i don't think the size matters much, the primary cost is stemming from the number of times you allocate.
if you are still concerned with memory usage, you could also look at how much memory f() introduced with something like this:
func usage() int { runtime.GC() var ms runtime.MemStats runtime.ReadMemStats(&ms) return int(ms.HeapAlloc) }
basically you force a free operation by running the gc to ensure the measurement doesn't include the already freed objects. it's not perfect though. the gc collector itself does some allocations so this number will be perturbed a bit. it only makes sense if you are allocating a lot of memory and you want to lower that.
# profiling
but the above function might be too coarse. you might want to see where the allocations actually happen in the form of stacktraces.
https://go.dev/blog/pprof is a good article about how to benchmark memory, eliminate unnecessary allocations and make stuff significantly faster. it turns out if go detects that you ever call to a memory profiling function then it enables automatic sampling of allocations. by default it samples every 512 kiBth allocation on average. you can use `runtime.MemProfileRate = 1` to have go collect a stacktrace on every allocation and gather a very accurate heap state.
you can do something like this to measure allocations from a single function:
func mprof(filename string) { // must run GC twice because runtime.MemProfile might be 2 cycles delayed per documentation. runtime.GC() runtime.GC() f, err := os.Create(filename) if err != nil { log.Fatal(err) } pprof.WriteHeapProfile(f) f.Close() } ... mprof("f.base.mprof") f() mprof("f.mprof") ...
then do something like this to explore the allocations from f():
$ go tool pprof -sample_index=alloc_objects -base=f.base.mprof mybinary f.mprof (pprof) top -cum 10 ... (pprof) list f ...
the `top` function lists where the allocations happened while `list f` does a source annotation. with `list f` you will see the number of allocations that happened on each line of f().
there are multiple sample types collected not just `alloc_objects`. you can use `alloc_space` to see how much total data in bytes was allocated in the function (frees due to gc are ignored). or you can use `inuse_space` to see how much non-temporary data was left over in memory after f() returned. mprof() runs gc so it will be able to correctly account freed objects too for this latter sample type.
alternatively you can poke around the data with pprof's web tool too:
$ go tool pprof -http :8080 -base=f.base.mprof serve f.mprof
# summary
so in short i claim allocating memory is an antipattern in high performing code and go provides great out-of-box tools to track down the sources of it. try doing the minimum allocations you need at initialization and then keep stuff simple. and if all that dynamic crap is gone from your go, what remains is just a supercharged c.
doing such measurements is much more painful to do in c and c++ because it doesn't ship with that much useful tooling out of box. one needs to hunt together all the necessary tools to do such analysis.
but in case my primary point got lost in this long post, let me put it into a bold claim. suppose you implement the same program in both c++ and go and you find go is slower due to gc. then i claim that the go version can be rewritten in a way that beats the c++ version. that's because in both cases you are using too much dynamic memory and if you avoid that, you'll see a large performance improvement in any language.
and once you give up obsessively micromanaging memory ownership, programming becomes joyful again. the language doesn't even need any features for ownership management. there are some rare cases where ensuring a resource has a single owner has some benefits. but even in those cases a better design would alleviate needing to have those benefits in the first place.
published on 2022-12-22