Automating .NET C# Code Generation with LLMs

I’m working on Project for generating .NET C# code using Large Language Models (LLMs), primarily GPT-4. My goal is to create or modify existing Visual Studio project solutions automatically. My current approach involves:

  1. System Prompt: Providing definitions like database schemas. Ect
  2. User Prompt: Describing the app’s goals (e.g., API, frontend, business logic).

The model generates code, structures, updates files, or adds new functionalities.

Questions:

  1. Communities: Are there forums or groups focused on AI-driven code generation, especially for .NET or Visual Studio?

  2. Alternative models: Besides GPT-4, what other models or tools are suitable for .NET developers?

  3. Best Practices: How can LLMs be used more effectively for code generation and adapting existing project

Thanks!

1 Like

Alternative models: Besides GPT-4, what other models or tools are suitable for .NET developers?

I think Qwen 2.5 Coder 32B is small for this type of model, but it has a good reputation among coders in general. It seems to have a certain level of understanding of Visual Studio. I see people training models on the Hub for coding, but I don’t collect them myself. I’ll bring them if I remember anything.