nbw
How are you using AI with Elixir at work on production-ready apps?
This is an open discussion to anyone using AI to help them work with Elixir in production-ready apps.
I work on an Elixir app at work that’s mostly backend with no customer facing UI parts, but I haven’t found good ways to use AI in my workflow beyond the obvious things. I’ve talked with my coworkers there seems to a pattern of not trusting generated code that’s larger than a single function, generated tests are inconsistent unless they’re unit tests, etc.. Ultimately your ass is on the line when you ship it so you want to trust what you’ve written.
On a positive note, asking AI to explain something works nicely
. But beyond talking to an LLM and having it clarify or refine things, I’m left wondering if I’m misunderstanding the hype.
There are lots of tools out there (Cursor IDE, Cursor PR review bot, Copilot, Claude, <%= insert your favorite LLM here %>), and apparently LLM’s work quite well with Elixir. The auto-complete from these tools can be really nice (but to me, it’s just nice).
We even have Elixir specific tools like:
Some of these are great if you’re starting a new project, if you want to prove an idea at the surface level, if you’re following Phoenix best practices to make a LiveView CRUD app, etc.. But if you’re working on an existing complicated code base, what tools/workflows are you finding make you more productive?
I’m genuinely looking interested in using AI in a net-positive way (for me and for the company I work for) and would love to hear what works for you beyond creating a new phoenix app.
Most Liked
martosaur
I’m using chat panel in Zed for asking arbitrary questions but that’s about this. I tried agent mode couple of times and it’s not for me. Writing is thinking, and when I don’t write code by hand I find myself out of the feedback loop. Tests IMO is a great example of this. If testing your code is hard, you know something is not right with how you do things. But if you outsource tests to AI, you won’t feel this.
odd
I immediately thought of this tweet after reading this thread.
Anyway, we’ve been using Claude Code to swap deprecated dependencies, add documentation, write missing tests and even implement small features. It does a pretty good job, especially after adding project specific guidelines to CLAUDE.md.
I asked Claude itself to create the guidelines with a focus on code conventions and patterns, which it did surprisingly well. Then I went through the file, adding, removing and fixing things here and there. For example there’s a section dedicated to testing, explaining how we use our test factory, how we use PhoenixTest for UI tests and so forth. The tests it generates follow our conventions and besides some minor issues like naming, I rarely have to fix anything. The documentation it generates is usually way too verbose and focuses on minute details. Usually it either gets it right the first time, or I have to spend more time talking to it than it would take to do the thing myself. Interesting times, to say the least.
GitHub - ash-project/usage_rules: A tool for synchronizing LLM rules files with your dependencies. · GitHub is definitely worth a read.
eddy147
Elixir dev, but 95% only backend, hardly any Phoenix code.
I am using AI mostly with the CLI: gemini or OpenAI’s codex. I use it mostly for analyzing bugs, and acutally never to generate any code. I did that once, and it became a enormous mess and I did not understand the generated code because it was not my own.
If I would generate any code, it would be very small fragments so I can keep control of the big picture.
I mix my editing by using vscode – (actually codium, because the copilot setup message, even though i did not have it installed and not want to, started to bother me) and lazyvim. Both options work good for me, having the windsurf plugin installed, and using that for code completion, not using the chat functionality (in neovim not installed).
Popular in AI / LLMs
How does the Elixir community feel about the ethical complexities of AI, OSS, and learning/teaching?
Other popular topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #websockets
- #supervisor
- #advent-of-code
- #elixirconf-us
- #distillery
- #processes
- #forms
- #api
- #metaprogramming
- #security
- #performance










