Earlier quoted context omitted.
No, because Hebrew words are read right-to-left in Hebrew letters, but numbers are read left-to-right in Arabaic numerals. The direction of reading switches mid-sentence, but typewriters only type in one direction.
Arguably Arabic numbers must always be read right-to-left, even in English, because the least significant digits can be read in order, while the value of the most significant digit depends on the number of less significant digits to the right. So in Hebrew the general reading direction actually fits Arabic numbers better.
Why LLMs Can't Write Q/Kdb+: Writing Code Right-to-Left
141–150 of 154 posts
Re: Why LLMs Can't Write Q/Kdb+: Writing Code Right-to-Left
#142Earlier quoted context omitted.
Arguably Arabic numbers must always be read right-to-left, even in English, because the least significant digits can be read in order, while the value of the most significant digit depends on the number of less significant digits to the right. So in Hebrew the general reading direction actually fits Arabic numbers better.
And the Arabs actually say the numbers from right to left. It's "one and fifty", not "fifty one".
1: https://www.thoughtco.com/given-before-new-principle-linguis...
Re: Why LLMs Can't Write Q/Kdb+: Writing Code Right-to-Left
#143Earlier quoted context omitted.
It's possible that LLMs build ASTs internally for programming. I have no 1st hand data on this, but it would not surprise me at all.
LLMs don't have memory, so they can't build anything. Insofar as they produce correct results, they have implicit structures corresponding to ASTs built into their networks during training time.
That's interesting. Is there research into adding memory or has it been proven that it provides no pragmatic value over any context it outputs?
Re: Why LLMs Can't Write Q/Kdb+: Writing Code Right-to-Left
#144Re: Why LLMs Can't Write Q/Kdb+: Writing Code Right-to-Left
#145Earlier quoted context omitted.
That does happen, but not frequently in the common libraries that are going to be in public training data. Is there a top 100 package that does something funny on import?
Well “import torch” for example will resolve certain dynamically linked symbols, which must be done first before importing your own .so code that uses libtorch and pybind11. If not you will get a super fun to debug segfault, leaving you staring at gdb backtrace output while you ponder your career choice. This is buried deep in the PyTorch docs and I don’t have the willpower to go find it right now, sorry.
Re: Why LLMs Can't Write Q/Kdb+: Writing Code Right-to-Left
#146Earlier quoted context omitted.
> That's not really an experiment is it? You basically just used them to create a hypothesis but you never actually proved anything The experiment was checking how well another unrelated LLM could write code using the syntax. And then in the reverse direction in new sessions. > They're great at writing text and code so the fact that the other LLM was able to use that syntax to presumably write code that worked (which…
> And it influenced how I use LLMs for work, for the better How so?
Re: Why LLMs Can't Write Q/Kdb+: Writing Code Right-to-Left
#147Cognitive load in LLMs: When LLMs are faced with syntactic complexity (Lisp/J parentheses/RL-NOP), distractors (cat facts), or unfamiliar paradigms (right-to-left evaluation), the model’s performance degrades because its "attention bandwidth" is split or overwhelmed. This mirrors human cognitive overload. My question: is there a way to reduce cognitive load in LLMs?, one solution seems to be process the input and out…
Isn't the whole idea of Lisp that there is _no_ syntactic complexity? Lisp programs are roughly a serialized AST.
There can be considerable complexity in Lisp abstract syntax.
Re: Why LLMs Can't Write Q/Kdb+: Writing Code Right-to-Left
#148Earlier quoted context omitted.
Isn't the whole idea of Lisp that there is _no_ syntactic complexity? Lisp programs are roughly a serialized AST.
LLMs use tokens, with 1d positions and rich complex fuzzy meanings, as their native "syntax", so for them LISP is alien and hard to process. That's like reading binary for humans. 1s and 0s may be the simplest possible representation of information, but not the one your wet neural network recognizes.
Re: Why LLMs Can't Write Q/Kdb+: Writing Code Right-to-Left
#149Earlier quoted context omitted.
Isn't the whole idea of Lisp that there is _no_ syntactic complexity? Lisp programs are roughly a serialized AST.
The idea in Lisp is that there is low complexity in encoding abstract syntax into surface syntax. There can be considerable complexity in Lisp abstract syntax.
Re: Why LLMs Can't Write Q/Kdb+: Writing Code Right-to-Left
#150It's not because of the left of right evaluation. If the difference was that simple, most humans, let alone LLMs, wouldn't struggle with picking up q when they come from the common languages. Usually when someone solves problems with q, they don't use the way one would for Python/Java/C/C++/C#/etc. This is probably a poor example, if I asked someone to write a function to create an nxn identity matrix for a given num…
Or, even better, also from the cookbook: {(2#x)#1,x#0} But this really borders on obfuscation :P
I think this form might be a bit easier: {(x,x)#(x*x)#1,x#0}