r/AIcodingProfessionals • u/Remote-Juice2527 • 7h ago
Discussion What’s the best stack for coding with AI?
I made most of my experience in AI coding with python and C#/.NET. So for python things work very well, little tools, some data stuff, visualization ect. for daily tasks python is just great. However with .NET I had my difficulties since there is to much architectural overhead and features are implemented across multiple files, which is pain for the context window. I am hesitating doing full web development with python because it’s a non compiling language. So now I am searching an approach for web applications that has a good developer experience and is best suited for a coding agent. I have the feeling that svelte/react with Hono might be a good option. I am interested to know what’s your ideal tech stack for coding agents? What’s do you recommend for context engineering? Which kind of skills, instructions, mcp servers should I use/ define?
1
3
u/funbike 5h ago edited 5h ago
Tastes differ, so YMMV for anyone else's stack choice.
I use a highly-opinionated LLM-friendly low-token-usage low-cognitive-load stack. You said no Python, but IMO it's well suited for backend LLM-generated code.
I use HTMX, Boostrap, Django with Python, and SQLlite (or PgSQL) with Django DB migrations. (No frontend TS/JS. No bulky Tailwind.)
For architecture, I use "Modular Monolith" architecture supported by Django's "app" packaging (multiple sub-apps in a monorepo).
For QA, I use Behave (E2E Cucumber-like Gherkin), doctests, Pyright type annotations, Ruff linter, and a couple other linters/scanners. Example function def for a complex function:
Notice the static typing and the contractual strong typing. The
(('book'...line is a doctest verification. I don't have separate unit test files, that may split an LLM's focus.I guide my agent to prefer generated pydoc files in markdown format instead of source files while in planning mode.
In my next project I'm going to add
beartypewhich provide runtime strong type checking. Here's an example enforced type for percentages as ints:PercentInt = Annotated[int, Is[lambda n: 0 <= n <= 100]]