Which is the best open model for [Julia] coding? And practical, and still reasonably good

I didnt see fable on this list, but its the production model I use for cross language work, opus is good for github handling like consolidating merges with low usage consumption. The best out the box for local is qwen for julia, these and deepseek can explain llvmcall from weights and other local models cant.

any chance you could benchmark Qwen3.8 Flash Next?

Thanks for running this! It mostly meshes with my experience (I run the GPT ones these days).

Please consider including the deepseek 4.0 pro in the benchmarks. I know it is more expensive, and better than the “flash” version, what I want to know is cost effectiveness.

Oops, I guess my post does read as if I ran the benchmarks over all the models, but I simply collated the results from the datasets that the original authors put on huggingface and added in some estimated costs. I thought people would find the cost-benefit results useful when considering using AI for Julia work and to see the differences between frontier and non-frontier models. My sincere apologies for the confusion! I certainly did not intend to claim credit for the work done by other people.

What I simply did is take their github repo: GitHub - SWE-rebench/LongTail-SWE · GitHub, and convert the docker parts plus send a prompt to opencode, so that I could run the benchmarks locally. I wanted to verify the results using my local AI and look through its reasoning traces to see how it approached the problems, and what additional prompts might nudge it towards a solution. It is also interesting to check AI-produced code that does pass the benchmark tests against the actual patches made by a human. They often differ, especially when the prompt is rather vague and the task is quite complicated. Does that point to multiple valid solutions or a failure of test coverage?

I think we’re spoiled for choice when it comes to LLMs that can do solid Julia work. Even the smaller models understand Julia and SWE well enough to be useful. I would always want to continually supervise them, but that’s just my preference.

Curious: where do you see Qwen lacking say vs Fable? I’ve been a Claude user for 6 months and have been amazed by its performance. I also have a local setup with 64C/128T, 32GB VRAM, 512GB RAM that could potentially run Qwen and am curious.

Fable could orchestrate 30 qwens. I did a test that impressed me with qwen, I generate bindings for alot of libraries and qwen is able to qrite programs in julia from those bindings. Its impressive because in order to do that it has to maintain julia ccall rules and gc for an entire wrapper, then I lower cpp through thunks and call them in julia and qwen can see that and use them without explanation. Thats tough for a 27b parameter model

I would compile everything with those threads

A related question: what would be the recommended options to

  1. work with/on local Julia code,
  2. using an openrouter.ai subscription,
  3. running local processes to evaluate Julia code,
  4. from the command line (or a terminal inside Emacs)?

I am currently using omp, and find it decent, but would like to learn about alternatives.

Curious: where do you see Qwen lacking say vs Fable?

I can’t comment on Qwen. But I can comment on Fable 5.2.

At research tasks, Fable is insanely strong, incomparably stronger than “cheap stupid tiny” models like Opus 5.5. Not the same ballpark, not even the same class of games.

If you have a problem, and need an algorithm, then Fable is perfectly able to do the lit-research on arxiv; and with even light prompting / human-intelligence-intuition-help is able to co-design / research algorithms or theorems that are “novel research”, going beyond what any human or AI has done before. Like, wtflol.

(Opus will do the lit-research as well; but it won’t actually understand the papers, and won’t be able to tell you “oh, paper x and paper y combine to a much stronger result, seems to be a gap in the literature :shrugs:”)

On the other hand, Riemann hypothesis is proven, also wtf. That was not supposed to happen in my lifetime.

If you don’t let it run autonomously and burn tokens, Fable is not even expensive; the glorious one week promo of Fable 5.2 access on Pro accounts was enough to test-drive that.

Letting Fable touch code is imo a waste; do design and “invent algorithm” / research / correctness proofs + complexity analysis for new algorithms together, and let it hand off implementation tasks to cheap models like Sonnet or (I guess?) Qwen, Kimi, deepseek.

Curious: where do you see Qwen lacking say vs Fable?

World knowledge first and foremost. Obviously it’s only possible to pack so much factual knowledge into a fixed file size. That, in turn, means that if you ask a small model to write some specific algorithm using just a name, not a step-by-step description (e.g., a Kalman filter or Dormand-Prince integrator), a smaller model is more prone to hallucinating parts of algorithm. In that respect, I’d recommend DeepSeek V4.1 Flash for your specs, it’s way larger and “knows” more.

Also, we don’t know how closed models are served. It is possible that they use web search, or RAG over some cached data etc. With local, you only get the raw model and have to build all enhancements yourself.

My recent experience – I wanted to optimize fixed-radius nearest neighbor search. Qwen 3.8 and DeepSeek Flash were both going in circles without real improvements, GPT Terra (Not even Sol) said that a path they reported as a dead end was in fact the most promising and went that way. In the end, it finished with a real optimization.

I wouldn’t say it means local models are not good for anything. But they do best when little creativity is required.

My takeaway is local models are going to be decent at boilerplate code. But I should stick to Fable/Opus for challenging work.

You can test this, but also be aware of a local models release and the julia version or pkg, the model only understands things up to the point it stopped training. So all those changes specific to your code and newer versions needs to given to the model upfront or it will waste time figuring it out. Its important with toolchain versions and api calls the model will be confused, I dont see you running out of context but I cant let them do whatever wasting context.

I think the results of LongTail-SWE (https://longtail-swe.com) show that local open-weight LLMs can do very well at Julia coding tasks (e.g. open-weight DeepSeek-V4.1-Flash is at 79.0% Pass@1 vs Claude Opus 5.5 86.4% / GPT-6.1-Sol 93.8% on the 27 Julia tasks).
The paper itself explains how the more trivial candidate tasks were excluded from the benchmark, so I would push back a little on the idea that local AI is only good for boilerplate.

I would encourage people to take a look at the paper, as well as the tasks, and decide for themselves. To give people an idea, this is one of the 27 Julia tasks: Read-only Queries · Issue #674 · ark-ecs/Ark.jl · GitHub → Add read only support for components in queries - Pull Request #677 - ark-ecs/Ark.jl - GitHub. Scoring uses hidden tests to evaluate passes and fails and my local model passes it on every attempt I’ve made.

I mostly agree with @Vasily_Pisarev’s comments and his core point about a world-knowledge gap. Personally, I want a capable assistant more than I need an oracle and I’m still happy (and have the time!) to research when world-knowledge is lacking. I’m also concerned with retaining data sovereignty and keeping running costs down and I’m prepared to pay the high up-front cost of the hardware.

When looking at the monthly subscriptions for frontier models, they certainly appear to be great value, but they’re also known to be heavily subsidized (Anthropic Subscriptions Offer 5x+ More Value Than OpenAI). I can’t predict future subscription prices and usage limits but how long can subsidies last now that Anthropic is a public company? :man_shrugging:

(wrote by me, a meatbag, FYI)
I took the repo and told my local LLM to run the 27 Julia tests.

LLM is Qwen 3.8 flash next GSQ-RCO IQ3_S, 256k int8 KV cache on Strata. Harness is opencode v2. First round scored 70.4% pass. (19/27)

A somewhat separate question would be: What are the best-for-julia models that are open and can be reasonably run locally?

Any experiences here? Would be fun to try out. Please do not forget to share the amount of VRAM needed for your setup (ie model weights + kv-cache).

Reasonable for private person having fun probably caps out at or below $10k hardware + $2k/yr electricity, depending on how rich people are. “reasonable for a small team/business” is also an interesting question!

I think “run locally for amateurs”-pricing kinda implies: unified memory APU on LPDDR, with 64, 96, 128 or 192g of ram; that would be products like a macbook pro, a strix-halo mini-pc/laptop or a dgx spark. 192g is stretching it for amateurs, pricing-wise.

Dedicated GPU with GDDR memory for amateur-prices probably restricts to small models that are useless for coding? APU on real DDR memory is also a thing, but afaiu no “big” LLM-capable APUs with unified memory on normal DDR exist?

Of these, strix halo on 128g is the cheapest by far, especially if you bought it last year; also happens to be my daily driver.

I suspect that my “light gaming-toy daily-driver mini-PC” 128g strix halo outperforms that “real machine” for coding LLMs by a mile: You have a far stronger GPU with much better memory bandwidth (GDDR, not lpddr); but a useful model doesn’t fit on 32g (?). You have a far stronger CPU; doesn’t matter for LLMs. You have far more (512g vs 128g), and faster memory (real ddr, not lpddr). But the RAM ↔ VRAM bandwidth will probably limit your machine to “useless for coding LLMs”.

Actual amount of memory available for LLM inference also depends on whether you want to use the machine for anything else: Turning your expensive shiny macbook-pro into an inference-server “brick in a closet” and doing daily work on an old thinkpad is a thing you can do, but probably not ideal for the kind of people who would buy a macbook pro with 128g in the first place. For me, migrating daily-driver from my mini-pc to an old thinkpad would not be worth it compared to just paying for inference; but I could imagine using 96g for inference and doing daily work on 32g.

I think that’s a great result!
Do you mind sharing the hardware you used in order to give people an idea of the resources required?

My set-up:
I run 2x Asus Ascent GX10s (DGX Sparks) headless. So 256GB unified memory combined over the built-in 200Gb/s ConnectX-7 network. One of them is the 2TB SSD model - thank goodness - and the other is 1TB. I have a very cheap mini-pc (16GB DDR4 RAM, 1TB SSD) that is solely for AI work. They live in the garage and I drive them remotely from another much older computer.
Electricity costs about USD 0.06 per kWh, all hydro, so that’s not an issue for me.

The dual GX10s give me flexibility to run larger, potentially more capable and larger token context, models or split into 2 smaller models. Prompt processing speed is very, very, good while token generation speed is variable but still solid and never an issue. The DGX Spark community is strong and IMO have made the Spark worth people’s attention.

I’d certainly consider the Strix Halo platform. There’s a 192GB version out that people might find interesting price-wise.

I understand that these are expensive now. I had to work hard to convince myself to spend the money. So, as you say, people should certainly consider the economics of purchasing vs using cloud providers. In the end, it also came down to other issues - data sovereignty, the potential for government restrictions etc.
As a very rough calculation, If I spread the hardware costs (albeit before the recent price jumps) of the GX10s evenly over 4 years, say, it works out at < USD 5 a day.

didn’t think my Ark.jl software would go into benchmark/post-training of LLMs, but I’m actually glad to indirectly contribute to improve open models, particularly in Julia, and I see the possibility of improving closed ones as a collateral damage :slight_smile:

Hey, that’s awesome. Thanks for your contribution :+1:
What do you make of the ability of non-frontier models to interpret your issue and produce code that passes in some way? It would be interesting I think for you to rate what was produced. Here’s the prompt they received:

# ISSUE DESCRIPTION

Read-only Queries
in some cases it could be useful to be able to restrict a query to return columns which are readonly, this can be useful to be able to analyze better structures for system-like usages of Ark.

`Query(world, (A, B))` could become e.g. `Query(world, (ReadOnly(A), B))`

### Additional contract requirements

## Read-only query components

The public marker for requesting a read-only component column is `Const{A}`, where `A` is the component type. It is a type-level query annotation;
`ReadOnly(A)` is not required query syntax.

- `Const{A}` is accepted for required components and for components supplied through the `optional` argument of both `Query` and `Filter`.
  This includes a filter created with `register=true` and subsequently passed to `Query`.
- The annotation affects only access to the returned column, not matching: entities continue to be matched using the underlying component type `A`.
- At the marked position in every query result, the column supports indexed reads but rejects mutation through `setindex!`.
  An unmarked component in the same query remains writable, and writes through that column continue to update the stored component.
- A nested field view obtained from a read-only component column is also read-only when that field view is available. 
  Read-only columns otherwise provide the usual read-only `AbstractVector` operations, including their element type, axes, size, and indexed reads.
- Query result ordering and optionality are unchanged. In particular, an optional `Const{A}` component produces either `nothing` or a read-only column in its normal result position.

Does the extra information make it a lot easier for an LLM to produce a correct result?

And here’s an example of the reasoning trace:

So the first thing: we need to unwrap `Const{A}` to `A` when looking up the component index, while tracking that the position is read-only.

Approach: define helpers:
- `_unwrap_const_type(::Type{Const{A}}) where {A} = A` and identity otherwise.
- `_is_const_type(::Type{Const{A}}) = true` and false otherwise.

Then modify:
- `_to_types` — maybe not; better handle at the point where query output types are computed.
- `_component_index` — could unwrap Const.

Let me think about where the storage types are computed for the query. In `_Query_from_filter_expr`:

```julia
component_storage_types = fieldtypes(_schema_storage_types(Storage))
query_storage_types = Any[all_component_storage_types[id] for id in output_ids]
QS = Tuple{query_storage_types...}
So `QS` is the tuple of storage types. Then `_get_columns` and `eltype` iterate over `fieldtypes(QS)`, computing `comp_types = map(_component_type, component_storage_types)` and `storage_array_types = map(_storage_array_type, component_storage_types)`.

For read-only, we need to know per-position whether it's read-only. This info is a compile-time constant. The `Query` struct has type params `QS, OF, M, K`. We could add a type parameter for the read-only mask, OR we could encode read-only in the storage type itself.

Hmm, actually a cleaner approach used by Ark (I recall) is to add a `_ReadOnlyArray` wrapper type. Let me think about the actual upstream solution — but I can't look it up. I need to design my own.

Let me think about how Ark actually implemented this. I recall Ark has `Const{T}` as a public API and a `_ReadOnlyArray` type. But I can't rely on that. Let me design from scratch.

Design:
1. Define `struct Const{T} end` in Ark.
2. In query/filter machinery, unwrap `Const{A}` → `A` for the underlying component type used in masks/index lookups.
3. Track read-only positions. The cleanest: add a read-only mask to the `Query` type parameters, or encode into storage type.

Given the Query struct is `Query{QS<:Tuple,OF,M,K}`, I could add a new type param `RQ` (read-only bit info). But changing the struct's type parameters might break many places. Let me check where `Query{QS,OF,M,K}` is referenced.

Actually, wait. Let me reconsider. The storage type for a component column is `_ComponentStorage{C,A}`. The read-only wrapper needs to wrap the *array* returned, i.e. `vec` in `_get_columns`. The returned column type is part of the eltype of the query. So `eltype` must produce a read-only array type for those positions.

and on and on it goes …

Actually here's a cleaner idea: store the read-only info in the output-ids tuple by using a different encoding. But I think the cleanest given the codebase structure is to add a type parameter to Filter.

Wait, actually, let me reconsider. What if instead of adding params, I make the *optional mask* or the ids carry this? No.

Let me just go with adding type params. Let me now carefully plan all the changes:

### Changes to `filter.jl`

1. `struct Filter{OM,IDS,M,K,RQ}` — add `RQ` (read-only mask) at the end.
2. Update `_filter_*` accessors — they use `{OM,IDS,M}` etc. patterns; they'd still work if I add a param at the end? `_filter_component_mask(::Type{<:Filter{OM,IDS,M}}) where {OM,IDS,M}` — this pattern requires exactly `Filter{OM,IDS,M}` with 4 params. Adding a 5th param breaks these. So I need to update them all to include `RQ` or use `Filter{OM,IDS,M,K,RQ}`.

So, you put the new type parameter in the 3rd position of the Filter struct rather than the 5th, and I think you did that because of what M and K represent, so it looks a cleaner approach. So, maybe you would grade the attempt as a fail? Or perhaps the LLM could have been given sharper context?

  • CPU: i9-13900KS (But I don’t think the CPU is the major bottleneck)
  • RAM: 128GB DDR5 (Size matters, as Strata fits cold experts of the LLM in RAM. RAM consumption after loading the LLM ~ 67GB)
  • GPU: Nvidia RTX 4090 (GPUs with >=12GB of VRAM work, but YMMV)
  • A fast NVME SSD to hold the n-gram table of the LLM (~30GB, plus model file ~ 55GB)
  • Model:ISTA-DASLab/Qwen3.8-Flash-Next-GSQ-RCO-GGUF · Hugging Face (You can try another quant like one of those in unsloth/Qwen3.8-Flash-Next · Hugging Face)
  • Inference engine: Strata. You can try basalt if you have Blackwell (50-series) cards.

Beware that Strata will take a substantial amount of system resources (basically GPU, RAM, CPU working together to output the tokens) It is recommended to run agents (where Julia runs) on another machine, accessing the LLM machine over LAN or VPN.

No, to me the additional requirements addition seems good, even if apart from the initial paragraph and the first point, all seem natural choices more or less.

So, you put the new type parameter in the 3rd position of the Filter struct rather than the 5th, and I think you did that because of what M and K represent, so it looks a cleaner approach. So, maybe you would grade the attempt as a fail? Or perhaps the LLM could have been given sharper context?

To me it seems okay to have it at the fifth position too. So, no points taken away for this :smiley:


Though, I see in the reasoning you posted this:

Hmm, actually a cleaner approach used by Ark (I recall) is to add a `_ReadOnlyArray` wrapper type. Let me think about the actual upstream solution — but I can't look it up. I need to design my own.

Let me think about how Ark actually implemented this. I recall Ark has `Const{T}` as a public API and a `_ReadOnlyArray` type. But I can't rely on that. Let me design from scratch.

It is a bit suspicious, is it looking something up? Or it just has already memories of it from training somehow?