Show HN: JavaFactory – IntelliJ plugin to generate Java code
44 points| javafactory | 9 months ago |github.com
I built a code generator plugin for IntelliJ that uses LLMs to create repetitive Java code like implementations, tests, and fixtures — based on custom natural-language patterns and annotation-based references.
Most tools like Copilot or Cursor aim to be general, but fail to produce code that actually fits a project structure or passes tests.
So I made something more explicit: define patterns + reference scope, and generate code consistently.
In this demo, 400 lines of Java were generated in 20 seconds — and all tests passed: https://www.youtube.com/watch?v=ReBCXKOpW3M
GitHub: https://github.com/JavaFactoryPluginDev/javafactory-plugin
AugustoCAS|9 months ago
Structural refactoring is another amazing feature that is worth knowing.
zikani_03|9 months ago
[0]: https://github.com/nndi-oss/intellij-gensett
javafactory|9 months ago
I can’t help but wonder if the folks at JetBrains are starting to feel a bit of pressure from tools like Cursor or Windsurf
geodel|9 months ago
javafactory|9 months ago
asdffdasy|9 months ago
cess11|9 months ago
"404 - page not found The
master branch of
javafactory-plugin does not contain the path
docs/how-to-use.md."
How do I hook it into local models? Does it support Ollama, Continue, that kind of thing? Do you collect telemetry?
javafactory|9 months ago
2. from now, i only allow to use gpt-4o, because the requests involve relatively long context windows, which require high-quality reasoning. Only recent high-performance models like GPT-4o or Claude Sonnet are capable of reducing the manual workload for this kind of task.
___
but still, if user want to use other models , i can make adapter features for various models
simpaticoder|9 months ago
winrid|9 months ago
javafactory|9 months ago
Actually, I'm currently thinking about creating a small community for sharing pattern definitions.
likis|9 months ago
But the project looks interesting, I have been looking for something similar.
javafactory|9 months ago
The requests involve relatively long context windows, which require high-quality reasoning. Only recent high-performance models like GPT-4o or Claude Sonnet are capable of reducing the manual workload for this kind of task.
trollied|9 months ago
p0w3n3d|9 months ago
javafactory|9 months ago
That said, what I wanted to highlight in the example was a contrast — tools like Cursor and other general-purpose models often fail to even generate simple tests correctly, or can't produce tests that pass. So the goal was to show the difference in reliability.
diggernet|9 months ago
unknown|9 months ago
[deleted]
unknown|9 months ago
[deleted]
huksley|9 months ago
[deleted]
unknown|9 months ago
[deleted]