Better HN
topnewbestaskshowjobs
Log inSign up

dev_dan_2

93 karma · joined Jul 22, 2026 (4mo ago) · 60 submissions

Submissions

comment 2d ago · link · parent

To add to the other answers, let me address the experience of "a series of steps" versus "a big single expression with a type" - real life is calling, so I have to make this quicker than I would like to; feel free to ask any followup questions / for clarification! I am sure others or later, I when I am back on the screen can answer :)

So the very short version: There is no difference between those two worlds if you squint your eyes hard enough! They are equally powerfull; just different ways of expressing the same truth. This is the whole declarative ("WHAT should the end result be") vs. implerative ("HOW to achieve the end result")stuff, but it's all the same at the end. Some examples:

  - SQL is declarative; but under the hood, it will get translated to a sequence of operations on the database by the query engine (or however it's called)
  - HTML is declarative; but there is no theoretical reason stopping you from building some sort of "imperative" HTML where you just add elements and stuff in a sequence of steps and at the end; are shown the same webpage (in fact, there are GUI frameworks that build up the GUI in an imperative manner; for the web, transmitting a declaration of what you want rather than a program that constructs it was the more practical choice I assume)
  - Haskell is often considered declarative (for good reasons), but if you think about the IO type as ("Hey I am a wrapper type and all I do is to enforce that step A happens before step B"), then you are pretty close to a imperative way of doing things again
  - Go/Java/C#/Python with types are almost always considered imperative; but you can also put on the type checking hat and pretend that the program is just one big function that will - if written correctly - have a final type. How does composition happen here? It's basically the line break, line :103 is executed before line :104, so lines :103-:104 can be viewed as: "the function that does whatever :103 does, then whatever :104 does", and it has the type "whatever input type :103 has and whatever input type :104 has", and type checking ensures that all those pieces fit together neatly.
They can even be mixed; in the proof assistant Rocq (formerly known as coq), there where both styles used often. In Lean, as I vaguely remember, you can pick both style too, so to say.

I think the pragmatic answer is that most such languages originated from the "one big function" school, and so it is more natural to program/proove in that way.

---------------------------

*Wait, does this mean that every proof I learned can also be done in this "one big function" way, instead of "a series of steps"?*

Yep! But you will find that it is not really practical to do so. A good exercise for sure though; and something I did (by that I mean: infering types on paper; not really taking proofs I know and doing them be type inference on paper) by hand when diving deeper into this topic in grad school.

Here is how that approach looks like, roughly: https://www.researchgate.net/figure/Example-of-type-inferenc... (the term I search for regarding illustration is: "type inference examples")

comment 2d ago · link · parent

Sure, and I am very glad to hear that you liked it! :> (I really want to start blogging soon! Then I can simply link it / paste from it haha)

comment 2d ago · link · parent

I am 100% sure that yes, it's just not mainstream yet. (Why? Because lean proofs are computer programs)

----------------

The big caveat: This is only if the proof is formulated as a computer program, which is the case here with the Riemann Hypothesis proof. (Lean is a general programming language; and every "proof formalized in Lean" is also a Lean computer program.)

Much of mathematics is not yet formualated in such way (although much progress was made by countless contributions of researchers and amateurs in the last years, both in Lean but also in other proof assistants. Lean seems to become the de facto standard though, but I am watching from the sidelines, so take that with a pinch of salt please)

I explained this connection between computer programs and proofs further in this comment: https://news.ycombinator.com/item?id=50589618#50594374

comment 3d ago · link · parent

I am not in the front row, but what you say alligns with how I would assume things play out, unfortunately (and short-sightedly; how easy would it have been to not antagonize the mathematical community, i.e. by redirecting a few 10M$ into scholarships, conferences etc... also maybe 1-2 fulltime positions that focus on human-LLM-collaboration as in "how can we this new technology to increase understanding?", which seems to still be an afterthought for the big AI companies...)

Slightly related: I am fairly confident that we can let LLMs loose on those 17M lines of code with the instruction to refactor the heck out of it: Instead of "optimize that program so that it runs faster" (which AlphaCode did to great success already), the task would be "optimize that program so that it uses less theorems" etc... which is a very easy-to-verify task, since we after each refactor, the end result will never change! I predict that 1) this will be done more; once this first wave settled down a bit 2) this too might be a way to help us (humans) discover and understand new mathematics. For the LLM, it might have been just a boring ordinary code refactoring by extracting some common code out; for mathematitians, this might actually correspond to a deep connection between two areas.

Which is pretty cool IMO, it's basically an army of statistical parots that mine abstractions all day, and they only can succeed because at the end it is still the same outer lean statement being checked (we just rearange some stuff under the hood)

comment 3d ago · link · parent

I am sure you will get some more detailed answers; I am a bit lazy today; so I will give you the very high level / informal version of the answer (Edit from the future: It grew longer than expected, whelp :D):

Gödel's two incompleteness theorems basically amount to "As soon as your system can do a ridicolously little amount of things, then either of two things is true in this system: 1) You can express facts in your system that you cannot prove within your system or 2) your system claims that some false statement is true."

Now, because 2) is way way worse than 1), you design your systems so that you are firmly in the 1) camp - that way, we gain full confidence in the results our systems proofs, and the price we pay is that our system is less powerfull than it could be.

With Lean, it's similar. The foundation of Lean comes from type theory. There, we do something that is familar to above: We restrict our power (i.e. "which Lean statements do get verified by lean?", and we gain absolute confidence in its proofs (ignoring implementation errors, hardware limitations etc. for now). Intuitively: We have to work harder to satisfy the typechecker/prover, but when it is satisfied, then we have confidence in it.

-------------- Deeper down the rabbit hole

You might have noticed that I seem to muddle the waters a bit with programs, proofs, types and so on... There is a deep reason behind it! In a very strong sense, programs = types = proofs... So, here is how it is all connected (including the RH):

- Lean is a programming language (like Haskell, Rust, ... There is nothing stopping you from writing a server in Lean and deploying that binary somewhere in the cloud. Regarding developer experience, you could think of it like a modern Haskell without lazy evaluation and without its historical warts)

- programs can be tied to types: We first check if the whole program as such has a type ("do all of its parts fit together in a strictly defined way?"). Only if it does, we proceed (and for example, run it). If it does not, then the compiler declares "this program is not good! here is a type error!". Now, here is the price hat Gödel proved we cannot avoid (if we want to trust the typechecker): There are programs that don't type check, but behave perfectly fine at runtime. (That's the "we limit our power" part - those are perfectly good programs where the compiler throws their hand in the air and gives up!)

- Enter the third puzzle piece: proofs and the Riemann Hypothesis: turns out, we can think of types as theorems, and a successful type check as a correct proof! And the RH is a hypothesis we would like to prove...

- So here is how it all ties together: RH is written so that it can be used as a type, in the Lean programming language. The "main program" is basically just another ordinary function with some input types, and returns the type version of the RH being true. Because the function needs an implementation, we are forced to implement that function body - which are many small functions that correspond to mathematical theorems/lemmas if you look at it with the proof glasses on. From the programming pov, it is just functions that call functions that call functions and so on. And from the typechecking point of view; we compose a bunch of functions and check whether input types and output types match up.

Finally, the payoff: *If that program typechecks, then we know RH is true*, which is what just happened!

(PS: The same principle is behind the computational proof of the four-color-theorem. The proof of the four color theorem is "simply" a program that typechecks, where the final type happens to correspond to "can we color any planar graph with at most 4 colors?")

-------------- Further reading

If you want to read up more about this, here would be some sources (note: I am not up to date with how the cool kids these days learn about this topic; so there might now be better resources to learn from!):

  - Here is how I learned about it first: https://existentialtype.wordpress.com/2011/03/27/the-holy-trinity/
  - wiki: https://en.wikipedia.org/wiki/Curry%E2%80%93Howard_correspondence
  - "That's all cute and stuff, but basically fast food for me, give me the good stuff!" okay, okay! how about...
    - tying quantum physics, topology, logic and computing together? https://math.ucr.edu/home/baez/rosetta.pdf
    - anything on the nLab (a wiki/community(?) that collects and explores those kinds of things... nerds, I tell ya (no, I am not envious at all, naaaah)). For example, this page is about the relation between logic and types: https://ncatlab.org/nlab/show/propositions+as+types

comment 3d ago · link · parent

> But the statement as written has 4 points, none of which rests on the human involvement.

The theory and implementation of Lean is very much so a result of human involvement, on a massive scale even. Just because it is something repeatable does not lower that in any way.

Distrust of LLM output should not turn into distrust of automation, I think. The former I totally get (and deeply hold myself), the later is likely to hold one back - imagine banning calculators because there is not human in the loop, to make an extreme example.

comment 3d ago · link · parent

very, due to the precautions explained in the link. For example, they used multiple kernels with different implementations etc.

comment 3d ago · link · parent

not with that attitude

comment 6d ago · link · parent

As long as the AI is then consequently blamed for the resulting outages and bugs, I don't see the problem here =)

comment 1w ago · link · parent

Thanks for your answer & input, will chew on that when revisiting this topic again!

Besten Dank euch, bitte weiter so und Gottesgeschwindigkeit! :>

comment 1w ago · link · parent

Cool! (And massive thanks for all the great work you and your team do!) An idea I had was to "finetune" the KV cache compression to a dataset that represents what data one uses - but sliding window kinda achieves that out of the box, neat!

Some more ideas, most if not all were likely tried out already:

- add a decay to the KV cache: Each KV cell has an age, and if not read for a long enough time; we can throw that cell out and free that memory? (as I understood, KV cache stores intermediate results that can be restored on the fly - so if we throw out a cell that will be used in the future; it can just be recomputed)

  - could expand on that: If we "revive" a KV cell that we killed; we could decrease it's likelyhood to get killed again...
- could we dynamically learn what input leads to what KV cache usage? this would be a start time thing - maybe we could preemptively set many KV cells to 2,3,4 bit and just bump their accuracy once accessed at least once? (this is related to the sliding window approach I think)

- last; I think probabilistic data structures lurk somewhere around the edges here and wait for their chance to shine... ;D "need to storage big amount of information in a set AND have a fast way to verify/falsify whether set membership (i.e. KV cell in the KV cache") was correct" seems to be applicable; but I don't have a clue how! And I am a huge fan of probalistic datastructures in general; so I might be a victim of "if everything is a hammer, ..." ;)

comment 1mo ago · link · parent

Cautionary note (and a serious one, not to be snarky): Being well off financially is not a protection against gambling addiction (which can also take the form of day trading, for example); which is a pretty efficient way to ruin ones financial wealth, amongst other things.

As with many other psychological phenomenona, finances and education only protect to a certain degree or not at all, depending on what one is talking about in detail.

This is not a comment about correlation or causation of wealth with mental health, but rather a warning to keep in the back of ones head; success and a sharp mind don't make one immune against mental health issues in general and gambling addiction in particular.

comment 1mo ago · link · parent

Always nice seeing others arriving at similar conclusions! Those two jump out to me:

- "Most compilers hard-code a cost model. Vx reads one. A machine file describes the memory hierarchy and interconnect of a real part, and the compiler admits or rejects placements against it." I also designed it so that the target system is described by a single file that is picked up by the static analysis - cool!

- "Where data lives is part of its type" also doing that - when I got my project to an mvp state; I need to check out how vxlang does what it does: do they use a literal typesystem, or also compile checks outside of that? If its a type system, is it a dependent type system, or another flavor?

Yet another motivation to finally get my side project starting (forth-adjacent, many similar claims with regards to compile-time checks as vxlang; however, I still have to achieve that, while they already seem to have at least those and more in place; kudos to the vxlang team!)

comment 1mo ago · link · parent

I am sorry about the negative feelings and associations you have towards RC. Let's think constructively: What are 1-2 points you would do differently?

comment 2mo ago · link · parent

What is your point? Please don't be obtuse, it is more constructive to make your points clearly.

comment 2mo ago · link · parent

As a software engineer, I could not care less about how a bug was found or by whom, as long as I can quickly verify it is correct, I always appreciate being able to improve my work. I don't see why it should be different for mathematicians (the ones I knew would think similarly, I would assume.)

comment 2mo ago · link · parent

> Please do not ask the LLM to break the universe :)

Eh, every school db should be able to service a student called "Robert'); DROP TABLE Students;--", and every public facing LLM should still work even if asked to calculate the last digit of pi - that fulfills two noble purposes: 1) is fun and teaches whoever is responsible for the service some valuable lessons in craftsmanship or 2) if the service is built robustly (i.e. simple token limit and time limit per user), that's an easy way to gain street cred

comment 2mo ago · link · parent

> in fact history is frequently left out of mathematical teaching even when the history would in fact help in the understanding of some concepts.

That is well-known I assumed and continue to assume.

> I'm not seeing the direct link you're talking about

You are stating that link yourself; indirectly: "though I consider it unlikely that he is [being unaware of any mathematical history]". Why is it unlikely, precisely?

- Maybe because it is unlikely that he recieved the mathematical teaching that frequently does not contain history of mathematics (wild! I wonder which university you have in mind in particular) that you seem to be refering to?

- Maybe because his writing is evidence that he is interested about, incorporates and refers to history of mathematics, refer for example to https://terrytao.wordpress.com/2008/01/04/pcm-article-genera... or https://terrytao.wordpress.com/career-advice/theres-more-to-...

- Or maybe because he is quite the opposite of a person that never ventures outside of their own area; being blind for other fields, or ones own history; as evidence by being famously collaborative across different fields, having a popular blog where he writes about non-mathematical topics too and last; him being one of the main proponents of foundational topics such as formalization of mathematics; or the use of LLMs for mathematical research.

Does all that really make it more likely to you that Tao is not aware of the existence of counterexamples like those the commenter above mentioned - more likely than the commenter simply having missed a nuance or taking something out of context?

If so; I would be genuinely curious why - people work differently, and I am always happy to learn, or close gaps in my own understanding.

comment 2mo ago · link · parent

> If this turns out to be true I think my take above is not correct, in the short term people will have to stop sharing updates because otherwise openai will dishonestly race to finish their work.

Which I don't see a reason for Anthropic and "Open"AI not to, given their not so stellar track record with IP of individuals/entities-that-are-not-rich-enough ;)

comment 2mo ago · link · parent

Partially; but also in order to be able to focus, as stated by himself in https://www.pbs.org/wgbh/nova/transcripts/2414proof.html:

"But I realized after a while that talking to people casually about Fermat was impossible, because it just generates too much interest, and you can't really focus yourself for years unless you have this kind of undivided concentration, which too many spectators would have destroyed."

But yes; him reaping the benefits of himself having the idea first was part of it too; as far as I am aware.

-----

Which is still something completely different than some anonymous organisation keeping mathematical research secret because it is better for hype reasons. One is competition between individuals or groups within a field; the other is boring and sometimes borderline nihilistic generating of mathematical knowledge as an marketing asset.

comment 2mo ago · link · parent

It is a strong argument in this case though, because Terence Taos expertise is directly linked to his ability to not misstate the history of mathematics.

Also note how the quote by Tao is in all likelyhood not meant as an absolute; rather than a statement of a trend - a handfull of counterexamples do I no way change anything about the truth value of Tao's quote.

On the other heand; consider how absurd it would be if "... in the direction of no longer sharing any promising research directions with the broader community, which would reverse centuries of traditions of open science ..." would indeed be a misstatement; which would imply that far more promising research directions were not shared with the broader community (i.e.: published). I wonder what different reading of that counterfactual there could be other than secret societies that kept their discoveries and research directions to themselves - which we just learned about (since we would otherwise not be refering to the secret societies and their supposed promising research directions).

All pretty straightforward, I would say - both that "misstatement" is hopefully based an overly strict reading of Tao's quote, and that mentioning Tao's background as one of the fields leading practitioners is relevant as well. Again; to make sure: A few counterexamples achieves nothing here. It would need to reach a certain threshold of such counterexamples before we will have to write the history of mathematics; and before Tao actually made a misstatement here.

comment 2mo ago · link · parent

It should obviously not come as a surprise that having areas of the brains working differently can explain an awfull lot of things... but to answer your question directly, yes of course of course there are!

Simply look up all the many, well -supported and -researched known correlations with ADHD first. In the second step, you can construct the set of all possible correlations, and subtract the well-researched ones if it. What is left is the set of correlations that are either not explained by ADHD (the big majority I would assume) or explained by ADHD, but as-of-yet unknowingly so.

This might be a bit anticlimatic, but clinical psychology is pretty straightforward study design and statistics, and set theory is not that new either, so... no big surprises I am afraid.

comment 2mo ago · link · parent

100% agree on the ad angle. Ads normalised using digital products/services by paying with data and attention.

That is one of the reasons why I would love to see - reasonably priced - paid services, or even have governments offer them (as in: Source is open, hosting is being paid by the government). Given the role social media, the internet and so on plays today, it might make sense to treat this as a common good.

But that side track aside; I think that privacy respecting, ad free products can be offered for cheap, if their goal is only to finance themselves, development and gain a small margin. And true, network effects / buyin is real, but I also think that the market for ad-free digital spaces/services will continue to grow, as hopefully people become more and more aware of how precious and limited their attention really is.

comment 2mo ago · link · parent

Given your position and the responsibility that comes with it; I sure hope you updated your mental model in another way than simply "they are acting irrational"... It's not clear from your comment that you did, but it sounded a bit like it.

comment 3mo ago · link · parent

> Even the early medieval period has a lot of blanks. Did you know a homossexual bishop called "Flora" lived in first millennium France?

I did not, but like all the facts you mentioned so far, this is not a surprise at all for me (if that was the intention), since it does not contradict any belief I had about first millenium france. It is an interesting fact, though!

> Anyway, you don't seem to be taking me seriously

That's not the case, and I am sorry if I came over as such; I would not have tried to argue my points if I would not have taken you seriously. English is also not my native language, which might contribute to more subtle points being missed/misscommunicated.

> to be reading as a confrontational argument something that I meant as a friendly and helpful nudge towards digging deeper instead of making assumptions

You see, that's the issue; your nudge would only be helpful if I indeed did not dig appropriately deep yet already; which may or may not be, but instead of verifying it first, you told me things that I either knew already, or that did not address my point at all, which was irritating. I am all for infodumps, everytime, everywhere, love 'em. What I took issue with was that you seemed to assume a lack of knowledge, and decided to nudge, seemingly not considering the possibility that you might have completely missed my point.

Which is, succinctly stated: "Surely we should be able and are able to make educated assumptions about all aspects about anytime anywhere of human history; with the strong assumption that we do not have time machines and are therefore are limitited to guessing (or theorising, if one wants to use the fancy word), not measuring or anything or anything of that sort. It is perfectly understood that it's all guesswork, that might be mightly off regarding how it really was - and if we are lucky, the theory is not totally off".

You seemed to take this as a much stronger claim, as is evidenced by you bringing up exceptions to the "rule" more than once; that would only make sense if you literaly believe that statements such as "most of the books in the old testament were written for with an audience in mind that mostly viewed being the first born son a special, higher social condition" was meant in its absolutes (or with absolute certainty), which it was not. Anectodes, counterexamples and so on are meaningless when it comes to statements of bigger trends. They would only be relevant if they would turn out to be a common occurance, or when the source mentions the homosexuality of a monk in passing, without making a big fuzz about it for example - a possible indication that non-hidden homosexuality amongst monks might have been at least tolerated, and maybe even not-rare in first millenium france in at least that monstery. Or was not an issue to the person who reported that. Or it was a smear campain (not all sources are reliable). And so on and so on... (Note: I don't doubt that a homosexual monk named Flora existed back than, it might be well established that he did. I am just using that fact as an example)

---

To wrap up: Infodumps/facts? Heck yeah! Exchange? Yes please. The two of us talking past each other? That's not an exchange, yes. Simply assuming I do not know something instead of verifying it? Heck no, I firmly reject that. If you would have shown me where I was wrong, a nudge would have been appreciated, but as I read it, even now, you simply misunderstood my claims - then, the nudge was missplaced, and came over as patronizing to me.

I think I understood now where it went wrong and what you tried to bring across. Appreciate the facts you droped; I am more the top-down than bottom-up type, but facts like those are interesting to me nonetheless.

I will also stop this thread; in case it helps resolving open ends: "most of the books in the old testament were written/edited/composed for with an audience in mind that mostly viewed being the first born son a special, higher social condition" was and is my intended claim; independent of who the individuals where that wrote these books, of periods where social hierarchies within the intended audiences at time of writting/editing/composition changed, and so on and so for. Yes, that audience encompasses a bit amount of time and space. Still, people who are paid to think and write about this seem to majorily agree with "most of the books in the old testament were written for with an audience in mind that mostly viewed being the first born son a special, higher social condition", if I did not wildly misread the current consensus of academic research. Again, this is a big picture claim; no singular counterexamples or short time periods can change the assumed validity of that statement, only once new sources or new interpretations of old sources indicate a different quantitative historic reality than previously assumed.

---

All the best & happy nerding!

comment 3mo ago · link · parent

Currently, that is the case, yes. Not everyone is equally happy about that though ;)

comment 3mo ago · link · parent

Appreciate the link! That is not what I had in mind though; for them, the Prolog Code is the goal, for me, Prolog is an interface language within a system I build. That code could be generated on the fly, but I lean more towards fixed templates that can be instantiated by input some variables by the LLM that is doing agentic code, rather than having that LLM reproducing that query code completely on the flow.

The reasoning behind it is that I want to put as much logic as possible into the harness where it is deterministic, controled and fast - My goal is to make agentic coding usable for my purposes even with small local LLM models. Those might botcher generating Prolog queries sometimes, but they might might be able to used my API/interface/whatever reliably (and then the harness does everything else under the hood, including instantiating the Prolog templates and running the queries)

comment 3mo ago · link · parent

> I suspect that the next big AI breakthrough will result at least in part from constraining LLM decisions with old AI approaches. Frank Coyle presented the idea of ontologies constraining LLM output about a month ago: https://www.youtube.com/watch?v=Sir59K8ZDPU

Interesting, thanks for sharing!

I plan to give it my own shot with vibing my own harness; I plan to use https://glean.software/ as the central database for everything code, then for documentation. After that, it could be used for bookkeeping for reasoning in a style similar to what you describe; after all, Angle, the query language of Glean, is a https://en.wikipedia.org/wiki/Datalog with some extras (I don't know which yet), so stuff like onthologies could be queried quite well, I would guess.

comment 3mo ago · link · parent

Hmm, I would say even older than that (which, of course, is in no way intended to be a value statement of any kind, I like the website and the project, cool idea! :D).

In 2015, https://en.wikipedia.org/wiki/AlphaGo came around and latest from there on, AI was associated heavily with NNs, deep learning and so on (but not with the transformer architecture which became popular later, the foundational paper itself was published in 2017: https://en.wikipedia.org/wiki/Attention_Is_All_You_Need).

If you squint a little, the linked project is basically a https://en.wikipedia.org/wiki/A*_search_algorithm with optimized implementation, heuristics and so on. I also think that A* was associated with AI due to its use in path finding in early robotics - But I am not sure!

12