Readit News logoReadit News
john01dav commented on JSDoc is TypeScript   culi.bearblog.dev/jsdoc-i... · Posted by u/culi
Waterluvian · 3 days ago
A few things I've come to personally believe after spending years developing web and robotics software in Python/JavaScript then spending years having to maintain while constantly adding new features and dealing with company pivots:

- The types exist whether you write them down or not.

- If they're not written down, they're written down in your head.

- Your head is very volatile and hard for others to access.

- Typing is an incredibly good form of documentation.

- JSDoc and TypeScript are standards/formats for typing. Like any tools, they both have advantages and disadvantages. Neither is objectively better than the other.

- Make informed decisions on how you'll describe your types, and then be consistent and unsurprising.

- A type checker is the computer saying, "okay then, prove it" about your program's type validity.

- Not every program benefits from the same amount of "prove it."

- Too much can be as bad as too little. You're wasting resources proving throwaway code.

- I like languages that let you decide how much you need to "prove it."

john01dav · 3 days ago
> - I like languages that let you decide how much you need to "prove it."

Rust is known for being very "prove it," as you put it, but I think that it is not, and it exposes a weakness in your perspective here. In particular, Rust lets you be lax about types (Any) or other proved constraints (borrow checker bypass by unsafe, Arc, or cloning), but it forces you to decide how the unproven constraints are handled (ranging from undefined behavior to doing what you probably want with performance trade-offs). A langauge that simply lets you not prove it still must choose one of these approaches to run, but you will be less aware of what is chosen and unable to pick the right one for your use case. Writing something with, for example, Arc, .clone(), or Any is almost as easy as writing it in something like Python at the start (just arbitrarily pick one approach and go with it), but you get the aforementioned advantages and it scales better (the reader can instantly see (instead of dredging through the code to try to figure it out) "oh, this could be any type" or "oh, this is taken by ownership, so no spooky action at a distance is likely").

john01dav commented on Valve reveals it’s the architect behind a push to bring Windows games to Arm   theverge.com/report/82065... · Posted by u/evolve2k
mitkebes · 12 days ago
To be fair 30% is the standard.

As far as I know, all of the following stores take a 30% cut:

* Steam * GOG * Microsoft store * Xbox store * PlayStation store * Nintendo eShop * App store * Play store * Kindle store

There's also stuff like Audible where Amazon takes a 75% cut unless you agree to exclusively sell your audiobook through them. And there was a lawsuit over that because it turned out Audible was actually only paying authors a 15% cut, while keeping 85% of sales for themselves.

john01dav · 11 days ago
The majority (Steam, Xbox, PlayStation, Nintento, App Store, Play Store, and Kindle Store) have a captive market of developers (with varying degrees of enforcement, from end users demanding it (Steam) to it being impossible to use anything else (App Store and the consoles)). This will absolutely put upward pressure on the cut that the market will bear.
john01dav commented on Using LLMs at Oxide   rfd.shared.oxide.computer... · Posted by u/steveklabnik
john01dav · 11 days ago
> Wherever LLM-generated code is used, it becomes the responsibility of the engineer. As part of this process of taking responsibility, self-review becomes essential: LLM-generated code should not be reviewed by others if the responsible engineer has not themselves reviewed it. Moreover, once in the loop of peer review, generation should more or less be removed: if code review comments are addressed by wholesale re-generation, iterative review becomes impossible.

My general procedure for using an LLM to write code, which is in the spirit of what is advocated here, is:

1) First, feed in the existing relevant code into an LLM. This is usually just a few source files in a larger project

2) Describe what I want to do, either giving an architecture or letting the LLM generate one. I tell it to not write code at this point.

3) Let it speak about the plan, and make sure that I like it. I will converse to address any deficiencies that I see, and I almost always do.

4) I then tell it to generate the code

5) I skim & test the code to see if it's generally correct, and have it make corrections as needed

6) Closely read the entire generated artifact at this point, and make manual corrections (occasionally automatic corrections like "replace all C style casts with the appropriate C++ style casts" then a review of the diff)

The hardest part for me is #6, where I feel a strong emotional bias towards not doing it, since I am not yet aware of any errors compelling such action.

This allows me to operate at a higher level of abstraction (architecture) and remove the drudgery of turning an architectural idea into written, precise, code. But, when doing so, you are abandoning those details to a non-deterministic system. This is different from, for example, using a compiler or higher level VM language. With these other tools, you can understand how they work and rapidly have a good idea of what you're going to get, and you have robust assurances. Understanding LLMs helps, but thus not to the same degree.

john01dav commented on Using LLMs at Oxide   rfd.shared.oxide.computer... · Posted by u/steveklabnik
an_ko · 11 days ago
I would have expected at least some consideration of public perception, given the extremely negative opinions many people hold about LLMs being trained on stolen data. Whether it's an ethical issue or a brand hazard depends on your opinions about that, but it's definitely at least one of those currently.
john01dav · 11 days ago
He speaks of trust and LLMs breaking that trust. Is this not what you mean, but by another name?

> First, to those who can recognize an LLM’s reveals (an expanding demographic!), it’s just embarrassing — it’s as if the writer is walking around with their intellectual fly open. But there are deeper problems: LLM-generated writing undermines the authenticity of not just one’s writing but of the thinking behind it as well. If the prose is automatically generated, might the ideas be too? The reader can’t be sure — and increasingly, the hallmarks of LLM generation cause readers to turn off (or worse).

> Specifically, we must be careful to not use LLMs in such a way as to undermine the trust that we have in one another

> our writing is an important vessel for building trust — and that trust can be quickly eroded if we are not speaking with our own voice

john01dav commented on Using LLMs at Oxide   rfd.shared.oxide.computer... · Posted by u/steveklabnik
john01dav · 11 days ago
> it is presumed that of the reader and the writer, it is the writer that has undertaken the greater intellectual exertion. (That is, it is more work to write than to read!)

This applies to natural language, but, interestingly, the opposite is true of code (in my experience and that of other people that I've discussed it with).

john01dav commented on Sam Altman’s DRAM Deal   mooreslawisdead.com/post/... · Posted by u/pabs3
john01dav · 12 days ago
Does this violate anti trust law?
john01dav commented on Valve reveals it’s the architect behind a push to bring Windows games to Arm   theverge.com/report/82065... · Posted by u/evolve2k
adverbly · 15 days ago
Everything valve doing for linux is making such a huge impact.

The HL3 memes don't even seem fair to use anymore. I don't even want to un-seriously make joke fun of them at this point. They are just genuinely doing so much for the community.

john01dav · 13 days ago
Their absurdly high 30% cut combined with having the only otherwise decent store with real network effect driven market share is a very real criticism
john01dav commented on Google denies 'misleading' reports of Gmail using your emails to train AI   theverge.com/news/826902/... · Posted by u/causenad
dontlaugh · 20 days ago
The first step is to get your own domain. You can set that up in Apple Mail at first if it’s most convenient. Then you can get everything moved over.

After that it’s much easier to move provider again.

john01dav · 20 days ago
How often do big providers like Gmail, customers of whom you will want to communicate with, eat the emails? I know that this is common if you run your own email server, and often just gone and not even to spam.

Google would probably justify this as security, and not necessarily unreasonably, but it has a clear anti-competitive effect too. The security concerns would be more credible if they made it easy to debug this, like giving a useful error message back to the sender stating what the missing security criteria are and having a clear process for appeals (like if you got unlucky with an IP address, or if you are missing a specific security measure on your domain).

john01dav commented on EU Council Approves New "Chat Control" Mandate Pushing Mass Surveillance   reclaimthenet.org/eu-coun... · Posted by u/fragebogen
IlikeKitties · 20 days ago
> Hi Mom, please install this peer to peer dark net chat to talk to me in the future, thanks Oh honey, why don't we just use iMessage instead. Thx bye.
john01dav · 20 days ago
I have been successful in getting non-technical people onto Signal. As far as a technical product goes, Signal is kindof shit (among other things: no support for non-Debian-based Linux forcing users to use sketchy third party repos when they are a massive target for backdoors, really shitty UX for backups), but it gets the job done and seems to have robust encryption from what other people say (I am not qualified to evaluate this myself).

If a P2P solution that solved the aforementioned Signal issues were to have excellent UX, then that could probably work.

Lastly, what counts as "excellent UX" for technical and non-technical people seems to differ. For example, I consider Discord and Slack to be quite intuitive and easy to use, but multiple technical people have expressed to me that they find it to be very confusing and that they prefer other solutions, such as GroupMe in one example. To me, GroupMe shoving the SMS paradigm into something that's fundamentally not SMS is more confusing and poor UX, but to these non-technical people that seems easy. I suspect that Signal's shortcomings that I perceive are an example of this: making UX trade-offs that work great for non-technical people but are less good for technical people. I'm not sure what these specific UX trade-offs are, but I suspect that it's something akin to having a conceptually sound underlying model (like Discord or Slack servers/workspaces and channels), versus having really obvious "CLICK HERE TO NOT FUSS" buttons like GroupMe, while having graceful failures for non-technical users that can't even figure that out (like just pretending to be SMS in GroupMe's case if you can't figure out how to install an app, or don't want to put that effort in, something that many people know how to use).

john01dav commented on GitLab discovers widespread NPM supply chain attack   about.gitlab.com/blog/git... · Posted by u/OuterVale
dmitrygr · 20 days ago
Lucky for us C programmers. Each distro provides its own trusted libc, and my code has no other dependencies. :)
john01dav · 20 days ago
Do you rewrite fundamental data structures over and over, like maps, of just not use them?

u/john01dav

KarmaCake day626March 20, 2021View Original