Better HN
topnewbestaskshowjobs
Log inSign up

rhdunn

1,498 karma · joined May 28, 2021 (5y ago) · 681 submissions

Submissions

comment 1d ago · link · parent

Part of the issue will be the training and the reward function. It is difficult to reward for human readability, simplicity, etc.

You could use various tools and checks like:

- linters and other code style tools;

- line length;

- cyclometricity, etc.

- dead code checks (unused variables, etc.);

- lines of code/diff size.

Those don't check things like whether the code changes are minimal/don't make unrelated changes/etc.

There's also the issue of maintaining consistency. I.e. detecting the code style of the project/code and using that (quoting, etc.). You also find that in prose, such as with British vs American dialogue.

I think the only way to make the style consistent is to have some sort of "reasoning context" that can learn the overall style and apply/use that across all tokens. That way, the model wouldn't have to add it to the context, and it wouldn't suffer from things like the excluded middle and dropping out of the context.

comment 2d ago · link · parent

Domains like code are easier to create autonomous RL loops for as you can easily check what the LLM generates by running it through a compiler, etc..

Domains like creative writing are harder as the automated grading suitable for autonomous RL is difficult (aside from spell checking and grammar checking).

comment 2d ago · link · parent

An interesting experiment would be to create a transformer model that is just designed to play Chess or Go. Specifically, the only thing that should change is the number of tokens, consisting of:

- the row of the move;

- the column of the move;

- the piece moved;

- any special/additional states from that move -- check, checkmate, castle, etc.;

- maybe an indication of whose turn it is (i.e. a black piece and a white piece token).

You could then train the base model on published game transcripts and use the interactive RL approach like AlphaZero and LeelaChess use, as well as what you mention for LLMs.

Why this is interesting is that it should give insights into how LLMs/transformers learn Chess/Go without having other data affecting the results. Specifically whether the token semantics identify valid moves, etc. and whether the context window encodes gameplay strategies across the different layers.

comment 2d ago · link · parent

As always, it depends.

For example, PyTorch (and numpy IIUC) store matrices/tensors as a 1D array of numbers. This is more memory efficient as all the data is colocated.

They use a technique to store the distance within the array to move when moving along each axis (strides). This allows for operations such as transpose to be swapping the array and stride values instead of performing an expensive array/vector copy.

Another example: using string formatter or join instead of separate concatenations allows the compiler/language to compute the size of the resulting string up front (if the language/library supports that) rather than allocating on demand.

Another example: using a hash map/set instead of an array to check for the presence of strings.

comment 2d ago · link · parent

Libraries generally write hot code in languages like C, C++, or Rust and bind that to Python (PyTorch, etc.) or provide bindings/wrappers around libraries in those languages (SQLite, PostgreSQL, etc.).

As with anything performance related you need to profile the code with realistic data/workflows and identify the parts that are slow.

Typically, doing things like changing algorithms, data structures, careful use of caching, reusing calculations, etc. are more important to performance than the choice of language.

comment 2d ago · link · parent

Those are all series that I've watched over the years, not put into an AI, as I have a passing interest in that area. I also watch various Minecraft videos, hence that playlist in my list.

And he may not be looking for information on CPUs but other people may be, hence me posting that comment.

I found the Ben Eater playlist interesting for understanding microcode and micro-operations.

I've found the Fabian Schuiki series interesting for how CPUs handle out of order execution, especially the last couple of episodes where he builds logic to talk with an LCD.

I've found the Polymath Unlimited series interesting as it goes into practical things like using a Carry Lookahead Adder and constructing a combined circuit for arithmetic and logic operations (my understanding is that his construction is similar to the one used in the 6502).

I found the mattbatwing series interesting due to it using redstone within Minecraft, and learning more about how that works.

comment 3d ago · link · parent

It should be theoretically possible to use C/etc. source code, assembly output, and compiled output in the training set with equivalence mapping between them. That would make it possible for the LLM to learn disassembly and decompiling to some degree.

You don't need software for that aside from the compiler/linker tools (which are free for C/C++ compilers, rust, etc.). You can then permutate/generate the source code using tools/techniques like fuzzing.

There's also things like Intel's instruction set documentation.

comment 3d ago · link · parent

How is it karma farming? That wasn't my intention. My intention was to provide resources on CPUs that I've found interesting for people interested in finding out more about designing CPUs.

comment 3d ago · link · parent

No. It's about connecting two areas/domains of mathematics.

An example would be how you can specify complex numbers in multiple forms:

- as a (real, imaginary) pair using the definitions of operations like addition and multiplication;

- as a 2x2 matrix, with 1 and i having matrix representations;

- as a 2D vector (angle, magnitude).

The idea is that if you prove something in one area you can apply that proof to the other domain using the equivalence mappings without having to prove all of those in the target domain. The basic construction is:

- have the problem in domain A (e.g. a complex number in (re, im) form);

- apply mappings converting domain A to domain B (e.g. representing the complex number as a 2x2 matrix);

- apply the proof from domain B;

- apply mappings converting domain B to domain A;

- QED

In a way, the Langlands program is like a subset of Concept Theory.

comment 4d ago · link · parent

I think it's more that the proof requires several leaps in multiple fields/areas of mathematics, so I wouldn't be surprised if this was actually something like 100 separate proofs.

comment 4d ago · link · parent

Do we know that that is the case?

We know the architectures of the open weight models as they include architecture diagrams, support in projects like llama.cpp, etc.

Companies like Anthropic and OpenAI don't release information about their models (aside from general things like context window size, whether they support reasoning, etc.). A lot of what we know is speculation. From press releases Anthropic have stated that they are getting Claude to assist with designing new iterations of the models, but no specific details.

The open weight models and other arXiv papers/research are iterating on and experimenting with the base/core transformer architecture:

- RoPE/NoPE/etc. for context window scaling;

- dense vs mixture of experts models;

- Mamba-based State Space Models (falcon models, etc.);

- reasoning, combining transformers with a residual stream, Attention Residuals (Kimi), etc.

- activation functions: ReLU; SwiGLU; etc.

- etc.

comment 4d ago · link · parent

> once we saw multiplicity 2 on O(2, n) via the "natively-automorphic" determinant ... meaning holo/automorphy over a function field

So if I understand correctly this proof has proofs for additional things that are steps to the main proof. That would be similar to the proof of Fermat's Last Theorem that required proving the Taniyama–Shimura conjecture [1].

[1] https://en.wikipedia.org/wiki/Fermat's_Last_Theorem#Subseque...

comment 4d ago · link · parent

The Riemann Hypothesis is used as a foundation for several important theorems. See https://en.wikipedia.org/wiki/Riemann_hypothesis#Consequence... for details.

comment 4d ago · link · parent

# TTS = Text-to-Speech

This is for the assistant reading out the responses. There are various models such as Qwen3, Kokoro, and more.

- Models: https://huggingface.co/models?pipeline_tag=text-to-speech&so...

- Benchmark Blog (with link to the benchmark): https://huggingface.co/blog/open-tts-leaderboard

# ASR = Automated Speech Recognition

This is for the assistant processing speech commands, etc. There are various models for this as well. You will likely get errors in the detected text depending on things like accent and technical/obscure/domain-specific words/terms.

- Models: https://huggingface.co/models?pipeline_tag=automatic-speech-...

- Benchmark: https://huggingface.co/spaces/hf-audio/open_asr_leaderboard

comment 4d ago · link · parent

If you are interested in understanding how CPUs work there are a number of "build your own CPU" style video series on YouTube:

- Ben Eater's series "Building an 8-bit breadboard computer!": https://www.youtube.com/playlist?list=PLowKtXNTBypGqImE405J2...

- Fabian Schuiki's series "Build a Superscalar CPU" (breadboard and custom boards): https://www.youtube.com/playlist?list=PLyR4neQXqQo5nPdEiMbaE...

- Polymath Unlimited's series "The CPU you can build (Tutorial Series)" (logisim): https://www.youtube.com/playlist?list=PLe8IZRJAn3oD3E2tDhNpI...

- mattbatwing's series "Let's Make a Redstone Computer!" (Minecraft): https://www.youtube.com/playlist?list=PL5LiOvrbVo8nPTtdXAdSm...

comment 5d ago · link · parent

One of the things driving the cost is having to keep training new models. It was every 6 months or so, now it seems like every 2-3 months. If they stop the other companies will catch up, so they are forced to pace (or race) the frontier to make sure they always have something better to offer if/when another company catches up.

That requires the hardware (GPUs/TPUs) and data centres to run them. It's not clear how many training runs they do, for how long, or at what cost.

In terms of profitability they need to get people to spend on tokens and subscriptions, and those need to be run cost effectively. Any subsidisation cuts into their profits.

The current boost has likely been due to tokenmaxxing, agentic coding, and convincing companies and influencers to spend money on adopting that. However, several companies have been scaling back their token spend and it is unclear how much more they can increase in this area. This is likely why they are pushing into other areas like mathematics and more recently genetics -- they need new customers to keep and increase the token spending.

comment 6d ago · link · parent

Or gitolite + cgit if you don't need the additional features like issue tracking and pull requests. It's harder to set up than Gitea, Forejo, or GitLab, but is a lot more flexible with things like repository layout. I've written custom install scripts to help with this.

You can use SSH directly, but using something like gitolite makes managing the git repos easier.

My main gripe with this setup (gitolite + cgit) is the lack of repository labels/tags. You can define a namespaced/scoped category, but that's not as flexible as a hierarchical tag system.

comment 1w ago · link · parent

That's the archive page for older downloads. The main download page [1] reports the latest version as 25.0.5.1.

[1] https://www.oracle.com/java/technologies/downloads/#java25

comment 1w ago · link · parent

I view refactoring as steering the code in a particular direction. You have to know where you want to end up, or you'll wander aimlessly or end up somewhere else, making it harder to get things right. And each refactor is documentation of that journey.

comment 1w ago · link · parent

1. Have declared nullability (e.g. `String? foo` / `val foo: String?`)

2. Use null coalescing (e.g. `foo?.bar?.baz`)

Languages such as Kotlin and C# support this style o programming.

The thing that I don't like about Optional types (in e.g. Scala or Java) is that they are too verbose. For example, instead of:

    return foo?.bar?.baz ?? 0
you have something like:

    return foo.flatMap(_.bar).flatMap(_.baz).getOrElse(0);
This is even harder to read if you have more complicated logic, requiring implicit lambdas and other machinery.

comment 1w ago · link · parent

There are tools like promptfoo that can be used for internal benchmarks and evaluations that allow you to compare results across different models and runs. This can be useful for personalized benchmarks and for business applications where you need to evaluate models and/or system prompts.

comment 1w ago · link · parent

It's not just frontier models, though. There are a large number of LLM models from different vendors to choose from [1]. There are even more if you expand that to other areas like image generation, text-to-speech, automated speech recognition, natural language processing, etc. Plus all the fine tunes and derivative models based on those on places like huggingface.

With generic hardware it is possible to train custom models and experiment with them. They also allow for other things like optimizing the spectrogram viewer in applications like audacity.

The main thing holding up local training is the amount of VRAM on the GPUs. Existing GPUs (and other TPUs/NPUs) have specialized instructions for matrix multiplication and other operations used by current and SOTA models.

[1] 1) OpenAI; 2) Anthropic (Opus, Mythos, Sonnet, Haiku); 3) Google; 4) Mistral; 5) Microsoft (Phi); 6) TIIUAE (Falcon); 7) IBM (Granite); 8) DeepSeek; 9) Qwen; 10) Kimi; ...

comment 1w ago · link · parent

Yes, that's another challenge with constructing benchmarks.

You could run the benchmarks using downstream providers like AWS if they are available.

You could vary the parameters of the tests to both help with LLMs learning as is and to help obscure that this is a test. Especially if sending them through a thirdparty, so the providers don't get identifying markers like IP addresses.

But ultimately it's another arms race like with viruses and anti-virus software.

comment 1w ago · link · parent

The key issue with public benchmarks is that they allow the model providers to train against them and artificially inflate their score accordingly. Private benchmarks are a way of making it harder to game the system, though it makes it harder for people looking at the benchmark to assess it as well.

Neither option is perfect.

A third option would be updating the benchmark every 6-12 months, but that has its challenges as well as you need to make sure that the benchmark covers things the model hasn't seen or is harder for the models to game.

comment 1w ago · link · parent

You may be right, but I'd need to see the data and analysis of the number of passes through each stage for the various languages.

The reason I think speculative decoding would scale the same is that the smaller predictive model has the same token behaviour as any other model compared to the other models. So the only savings would be if the smaller model can better predict more tokens for non-English compared with English such that the ratio of tokens between the two becomes the same or lower for the non-English language.

For Latin-script languages like Spanish I can see the smaller model predicting verb endings correctly, improving performance there. These languages have 1.5x-2x more tokens [1] so will need to be 1.5x-2x better than English in the speculative decoder for the performance of the non-English languages to be comparable.

For Han characters (Chinese and Japanese) it looks like the tokenizer is splitting the characters in the middle of UTF-8 byte sequences, at least in [1] where the number of tokens is larger than the number of Han characters. This would potentially make the paired tokens harder to predict by the smaller model. Given that there are ~2 Han tokens per English token the speculative decoding would need to be 2x better for Han than for English to make it perform the same compute energy wise.

If we assume that the smaller decoder model is perfect and that there is no additional cost on the verifier then the English vs non-English languages are going to scale the same on the smaller model, so speculative decoding would just be like using that smaller model and the non-English languages would perform worse due to them having more tokens that need to be processed by the smaller model.

The other factor is the context length of the transformers in the verifier. The question then is how quickly does that fill up and how many passes through that are needed for English (fewer tokens) compared to non-English (more tokens).

[1] https://ikriv.com/blog/?p=5322

comment 1w ago · link · parent

Intuition: there are YouTube videos from 3blue1brown [1] and Welch Labs [2] on neural networks, LLMs, and related tech that are good.

Building: the videos/tutorials from Andrej Karpathy in Python [3] are considered to be very good at building and understanding the basics, from a small/toy neural network engine to transformers and tokenizers.

There was a post here a few weeks ago [4] on reasoning models using Python/PyTorch with links to an older series on non-reasoning transformers.

[1] https://www.youtube.com/playlist?list=PLZHQObOWTQDNU6R1_6700...

[2] https://www.youtube.com/@WelchLabs/videos

[3] https://karpathy.ai/zero-to-hero.html

[4] https://news.ycombinator.com/item?id=50245138

comment 1w ago · link · parent

Speculative decoding will be model/software based and apply to all languages. The time, compute, and energy will be less compared to other models, but for the same model, hardware, and software used my reasoning still applies -- comparing English to other languages (unless optimized by the tokenizer) then English will consume less tokens and thus less energy. That is, it is still a function of the tokens used.

comment 1w ago · link · parent

The Anthropic and OAI APIs report token usage (input, output, and in some cases reasoning/thinking). The input tokens consist of the system prompt, the user input/messages, and any other context data.

Given the same model the only variable is the token count. The more tokens, the more passes through the LLM (to generate the next output token), the more energy used.

It's well known that non-English text consumes more tokens [1], [2] and thus more energy. This is due to two factors:

1. Latin script languages having different character pairings to English and modified characters, including language features like modifying verbs for person/tense/etc. (e.g. Spanish);

2. Non-Latin scripts that take more bytes to represent in UTF-8 and (esp. for ideographic and syllabic languages like Chinese, Japanese, and Korean) have lower common character pair sequences, meaning shorter tokens for those scripts and thus more tokens for a given text sequence.

[1] https://ikriv.com/blog/?p=5322 "LLM tokens and foreign languages" (5 Aug 2025)

[2] https://medium.com/@programmerraja/how-your-llm-costs-5x-mor...

comment 1w ago · link · parent

The problem with Linear A is that we don't have a reference point like the Rosetta Stone to anchor it to other languages and scripts. It also has a small corpus, making it hard to find patterns in the texts.

comment 2w ago · link · parent

The codebase size will be limited to the LLM context window size. Once the codebase grows larger than the context window, some of the codebase will have to be removed from the context and thus not be known to that LLM instance.

There's also a well documented phenomena [1] where LLMs struggle to recall information in the middle of the context.

[1] https://charlesanthonybrowne.medium.com/how-llms-end-up-igno...

12345
23