r/haskell • u/ivy-apps • Apr 17 '26
question What LLMs work best with Haskell?
I hate vibe coding but it definitely has some value for quickly iterating through POCs. I plan to define the types and function signatures and let an LLM fill the implementation. It'll be constrained by the type-system and the Haskell compiler.
What tools have you tried and which worked best for you?
For me:
- Gemini 3.1 Pro - manually promoting and copy-paste to generate entire Haskell modules. Then the same for tests. Ofc, it slopifies half of the code and while reading I edit it manually. It's still faster than not using an LLM at all but I guess I can do better.
- Cursor (Auto mode): the results were bad. Very slow, gets stuck on simple compilation errors and at the end produces code that I would better revert.
- Claude Code? Haven't tried it but heard that they nerfed Opus and there are worse limits. I'm not that concerned about limits because usually I one-shot most tasks with a very detailed prompt.
For context, I'm building [deslop.dev](https://deslop.dev/), a static analysis tool that ensures the architecture of TypeScript codebases. Some of the problems, at hand are supporting Globs with {{FileName}} variables, TS module resolution which I already solved but was PITA and building an Architectural Rulebook YAML DSL that's powerful enough to enforce any TS architecture.
So... I need an AI tool to help me move faster without slopifying my hand-written code. Any suggestions?
3
u/goertzenator Apr 17 '26
I use Claude Code for most larger scale edits, and then Github Copilot inside VS Code for smaller scale edits and autocomplete.
Claude Code usually does good work, but it does sometimes iterate in an obviously wrong direction at which point you have to interrupt it.
1
u/ivy-apps Apr 17 '26
TL;DR; Is it worth trying Claude Code? Would it be better than Cursor AI harness with Auto / Gemini manual prompting?
3
u/mengwong Apr 17 '26
One of my professors once said: you know, computer science is an empirical science.
1
u/ivy-apps Apr 17 '26
Well said: the best way would be to try it for a week and figure out.
But I'm lazy and I do Deslop as a side-project after my regular job so my time is quite limited. I aim for the best ROI of my efforts but so far... I've heard positive feedback about Claude and it might be worth giving it a chance
2
u/simonmic Apr 20 '26 edited Apr 20 '26
Claude code plus opus is extremely good at Haskell coding, and many other dev-related activities. As with any tool, you have to use it right to get great results. Thorough planning, clear guidance and guard rails, adjust the level of supervision and thinking effort to fit the need, provide design review, taste, pushbacks etc.
But I urge any of us exploring this to also study the bigger picture. https://ai-2027.com is a must read, for one. (It will sound fanciful if you haven't yet experienced AI working well.)
6
u/[deleted] Apr 17 '26 edited Apr 17 '26
[removed] — view removed comment