HNHacker News
TopNewBestAskShowJobs

beckford

264 karma · joined June 6, 2021

jonah AT diskuv DOT com; its founder. Created the DkML Windows OCaml distribution. An eon ago, when AI was still called deep learning, I was the Principal Engineer for Research at Amazon Go. And many eons ago I did fraud analytics, big data and data security.
submissionscomments
beckford··on OCaml as the Universal Translator – DkSDK Merry Christmas 2023
Author here. In the article I highlighted how easy it is now to translate OCaml line-by-line into other languages while at the same time preserving exact semantics. That was the cool news that deserved its own callout. But as you noticed I didn't spend any time talking about how translating OCaml helps solve the problem of managing types "all with slightly different variations".

Briefly: atd, Cap n' Proto, Protobuf and many others occupy the role of representing the same datatype in different languages and transmitting values of that datatype across the wire and/or persisting in storage. But I'm finding most programs have a need for multiple variations to that core record datatype. For example, when you persist an OCaml/Java/etc record datatype to a database, you don't use the OCaml/Java/etc record datatype. You use the data types provided by the database (VARCHAR, BLOB, etc). You can adopt an ORM solution, use an object database, or write a pair of type-conversion functions from OCaml/Java/etc to your database datatype. That is one example of a "variation" that you must spend engineering time on.

I mentioned in the article that my user needed 5 different variations. For example, with the sqlite3 database they were using, the database table variation required writing a pair of datatype-conversion functions to and from the sqlite3 database. What if there was a way where we could write these datatype-conversion functions in one place (cough cough: OCaml with a line-by-line semantics preserving feature) and have bindings to/from the database, the view layer, the controller and all the other variations generated in the appropriate Java/Swift/SQL/etc languages? And what if we could deploy modifications to that datatype (ex. adding a database field) in the same uniform way we do all other minor variations to a datatype? That is the "drastic QOL (quality of life) improvement" win my users asked for.

That QOL win deserves its own article. Yes, I'll post it when done.

beckford··on Dive into Deep Learning: Interactive deep learning book with codes and maths
Reading + building neural nets to play games? Yes! Count me interested.
beckford··on Cloud, Why So Difficult?
Was in agreement until I drilled down to the following statement on the Wing GitHub page and in the docs (https://docs.winglang.io/faq/why-a-language#very-cool-but-wh...):

“In existing languages, where there is no way to distinguish between multiple execution phases, it is impossible to naturally represent this idea that an object has methods that can only be executed from within a specific execution phase.”

This is not true. Several languages (Haskell, OCaml, F#, Scala, etc) allow you to define and use monads. Granted, monads are not something many developers know about … but it may make sense to learn about them before writing a new language.

Otherwise, this is a great read.

beckford··on Element is one of fourteen messaging apps blocked by Central Indian Government
Completely agree.

For a while I did run a fork of the Signal Server. Beyond the sheer difficulty getting it to run without the server being updated for a year during the mobilecoin launch, it was extremely disconcerting to see PHONE NUMBERS spread throughout the log messages. It doesn't take much imagination to see how you can build a network of who you are talking to (etc.) from this log information.

While it is quite possible that they had some non-default log configuration (and hopefully the metadata leaking in the logs is fixed), if you can't run the server you can't check what data is being leaked.

Take the E2EE claim with a grain of salt if it is difficult to run a server.

beckford··on WinLibs: Standalone build of GCC and MinGW-w64 for Windows
I missed the answer to: How is this different than MSYS2?

After digging through some of the sublinks:

- You can run gcc in the Command Prompt without using a special shell (MSYS2 has its own shell launcher)

- Maybe MSYS2’s gcc handles exceptions (SEH, etc.) differently

- Lacks a package manager like MSYS2’s pacman (which comes from Arch Linux). But winlibs plans to have something in the future

What did I miss? Would love to see a comparison directly on the home page.

← PreviousPage 2 of 2