Random things I wanna figure out eventually, but don't have time for

TODO [B] [2018-06-05 17:19] distributed cloud sync (Dropbox/Syncthing)   cloud

Basically, continuous (e.g. inotify-backed), open source and always available file sync.

  • Dropbox is continuous, but proprietary. It's not distributed, but central server tends to be very available.
  • Syncthing is continuous and open source, but only syncs among your own devices. If all of them are off, you wouldn't be able to access your files.

    It's also not necessarily very friendly towards average user: it works best when you have a device that is always on like a VPS.

Ideally, it would be something based on Bittorrent, and the chunks of data would be distributed among participants with sufficient redundancy. So most of the time you would rely on your own devices like in Syncthing, but in case of device loss or temporary outage you'd be able to assemble the data from redundant chunks in the peer network. Not sure how much redundant it has to be and if that approach works in practice.

  • [2019-05-03 08:29] apparently Resilio Sync exists, but it's proprietary, nothing else I know of or resulting from quick googling
  • [2019-06-13 19:45] IPFS looks close, but appparently not user friendly yet

TODO [C] [2018-08-26 19:13] instant messengers are too linear   im communication

You chat with someone and discuss something. Because conventional IM software imposes timestamp ordering, it often ends up interleaved with some ongoing things (e.g. "by the way remember about that thing tomorrow"), and you distract or switch. The discussion gets forgotten and/or the context is lost.

It's way worse in bigger Slack or Telegram channels (e.g. 15+ people). Sometimes you (well, at least I do) wait to post a message because you don't feel like interrupting some ongoing discussion and you don't want your message to be buried either. So you have to keep it somewhere and make a reminder or something, which is cognitive overhead. Because of the overall volume of messages people tend to mute group conversations, and then miss actually useful stuff.

Ideally, in a certain group chat/channel you should be able to:

  • fork conversation off an arbitrary message, so you'd have a tree.
  • view all the ongoing conversations/threads. Mute, mark as high priority, etc.
  • perhaps archive the ones that are not relevant anymore.

Currently existing things I know of:

  • Google wave?
  • Telegram got replies which work in very few specific cases and not very sustainable for a proper conversation.
  • Slack got threads, which sort of solve this issue.

    You can't turn old conversations into threads, but if you notice an opportunity early, or make a habit of spinning off early, you can work with it. It's not really used for personal conversations thought.

  • XMPP is dead I guess, so not sure how easy it would be to prototype that.

Interesting enough, meatspace conversations also have this curse of linear order let alone other aspects that make them hard! But that's a whole different problem.

TODO [C] [2018-04-02 16:48] structured VCS   vcs

Something that understands the syntax of programming language and operates on top of that. So for instance, reordering methods in a class would be trivial operation and not show up in diff. There are some caveats though: e.g. in some dynamic languages order of definition might matter, so you still want it to be backed by plaintext, probably. Perhaps it has to be a diff filter rather than full scale VCS.

TODO [C] [2019-04-30 11:44] programming language in which correct programs are feasible physical states   plt physics

Where physics is described by some sort of Lagrangian, and the evaluation semantics would would be consistent with its dynamics. Wonder if that's possible without involving explicit computations via dependent types. I guess would also correspond to some sort of special logic. Also making sure the set of correct programs is exactly the set of feasible states is presumably way harder.

TODO [C] [2018-01-17 20:42] phone app for keeping sensitive data   privacy

I sometimes find myself making a note or taking a picture or a voice recording which I wouldn't want to go public under any circumstances.

Relying on locking your phone is not really enough as it's easy to hack, or fail to lock, or reveal content by accident. What is worse, locking doesn't save you if if you're using some sort of cloud sync.

Of course, you can try and make sure you only keep it locally on phone, but you do need some means of syncing and arguably, waiting till you got a moment to tranfer it via the cable bypassing network is even more insecure. Even if you're willing to do that, it turns out to be notoriously hard not to sync to the cloud by accident. Examples straight out of my head:

  • You want to take an extremely private photo. If you take it with default Google camera app, it will immediately try to sync it to Google Photos. If you're like me and not using Google Photos sync, it's still quite useful to sync your whole photos directory automatically.
  • You want to take an extremely private note. I'm not even sure that these days you can create an empty text file on an average phone (afaik, ipones didn't even have file system until recently), unless you've got a special app installed. All the default ones having note taking capabilities: Google Keep, Google Docs, email drafs, etc, all of them would get leak in the cloud immediately.

It sounds like a fairly general problem. So there are some criteria I want from such an app:

  • allow taking pictures, notes, recordings etc from withing the container app, so intermediate data doesn't end up in insecure locations
  • handle content share intents in case for content that potentially can't be from within the app

    Would be cool to prompt user to delete the original files afterwards, but not sure if it's possible in modern Android though.

  • use asymmetric encryption for keeping data in the secure container

    Asymmetric is fairly important here, that allows to put data in container without actually asking for some sort of password every time, which would make using it way less frictionless.

  • backed by filesystem

    That would allow actually synchronising encrypted container through normal and less secure channels as long as you keep your private key safe. Not sure what to do with metadata though, but perhaps encrypting filenames with same key (with padding etc.) is not too bad.

So far I don't know any applications that match most of these criteria. Closest I know of are:

  • open-keychain: you can share files so it encrypts them via PGP. That's the only thing that it does though, afaiu, it's more meant for integrating with other apps. It's open source though so would be good to use it as a library/intermediate.
  • I'm personally using an Encfs container via EDS Lite and just use separate apps for secure photo taking and audio recording which don't have their containt saved to cloud synced location.

If you know of something better, please let me know!

START [C] [2019-04-01 13:50] share highlights from Kobo to Goodreads   kobo pkm reading

Kobo doesn't have Goodreads integration like Kindle does. However sharing hightlights is a great way to engage other people in the book you really like and want them to read. This can relatively easily be achieved via a script:

  1. run the script in kron or via udev rule configured to trigger on your Kobo device
  2. query the highlights from Kobo (they are in a nice sqlite database)

    I already have a local python script for that (my.books.kobo), e.g. used here.

  3. choose which annotations you want to share. Some options are:
    • based on a special marker word (e.g. if annotation includes 'kobo')
    • interactively via prompting what you wanna share
  4. send to Goodreads via quotes.create method

    You are gonna need some method of comparing highlights you already sent and diff them.

    Boring: just track annotation ids you already shared in some state file. Fun: use some elaborate comparison/hashing to match kobo annotations and goodreads ones.

Actually, this could even be useful for Kindle if you have pirated a book for whatever reason or have a DRM free copy from elsewhere. Or other ebooks.

DONE [2019-05-19 00:13] reverse engineered 'started reading' and 'finished reading' events, so at least it's possible to mark them manually on goodreads now

TODO [2019-05-19 00:13] need to share kobo provider on github

TODO [C] [2019-01-30 17:40] continuous piano keyboard. When you press a 'key', the harmonics are highlighted as well as octaves   music

[2019-05-07 20:32] ableton push kinda does that

[2019-06-01 15:26] not sure if it would be really beneficial for proper musicians, perhaps as a learning tool only?

TODO [D] [2018-04-27 16:15] coffee brew simulation   coffee simulation

In the simplest approximation take some simple conical/cylindrical filter, water flow/temperature dependency and coarseness. As an output we get expected amount of caffeine, oils, some estimate of bitterness and acidity etc.

Some potentially relevant links:

[2019-04-22 21:28] I ran into this guide and surely coffee brewing doesn't have to be so elaborate!

I mean, seriously:

Pulse pour by adding 65g of water in 15 seconds, followed by a waiting period of 15 seconds and repeat 5 more times (pouring timeline below) . Each pour should begin in the center, work its way outward, and then return back to the center.

What the fuck is that?? There is no way coffee taste depends on such intricate patterns of pouring water. A mathematical model would cast away this bro science at least to some extent.

I also can't really understand how is one capable of estimating coffee on the scale from 0 to 10, but perhaps that's just my unsophisticated taste buds, and I accept other people can train themselves to do that.

Shower thoughts

TODO [C] [2019-02-03 15:00] Why most popular music has such regular structure?   music

Most popular music (from traditional to classical to modern pop/eletronic) seems to have regular beats, verse structure etc. What's about it that human brains like? Can someone write a very irregular but yet enjoyable piece?

TODO [D] [2019-01-11 15:26] Why are avocados fatty? They are literally the only fatty fruit I can think of.   food