Automate Your 1C Code Reviews with a Self-Hosted AI Assistant
If you work with 1C:Enterprise, you know the drill. Code reviews, legacy module analysis, and hunting down those weird coding patterns can be a manual, time-consuming slog. What if you could offload some of that grunt work to an AI that actually understands your 1C codebase? That’s the idea behind the mini-ai-1c project.
It’s a self-hosted tool that plugs directly into your development workflow, acting like a dedicated AI pair programmer for your 1C (v7/v8) projects. No cloud API costs, no data leaving your server—just a local assistant focused on your code.
What It Does
In short, mini-ai-1c is a local web server that uses Ollama (a tool for running large language models locally) to analyze your 1C source code. You feed it a directory of your 1C files—whether they're in v7 .srp format, v8 .bsl/.os files, or even plain text exports. The AI then helps you understand, document, and review that code.
You can ask it questions in plain English (or Russian, as the model supports it). Think: "Summarize what this configuration module does," "Find all potential points of failure in this payment processing script," or "Explain the business logic in this report." It reads your code and gives you contextual answers.
Why It's Cool
The clever part is the setup. Instead of being a closed service, it’s a simple Python script that acts as a bridge between your code and a local LLM. You run the Ollama server separately, pull an open-source model (like deepseek-coder or llama3.2), and this tool handles the context building and prompting.
This means you own the entire pipeline. There’s no subscription, no sending proprietary business logic to a third-party API. It’s all on your machine. For developers in regulated industries or those working with sensitive ERP data, this is a huge plus.
It’s also zero-configuration for the analysis part. Point it at a folder, and it recursively reads all your 1C files, building a single context for the AI to work from. The web interface is bare-bones and functional—just a text box and a response area. It gets out of the way and lets you focus on the analysis.
How to Try It
Getting started is pretty straightforward if you're comfortable with the command line. You'll need Python and Ollama installed.
Set up Ollama: Follow the instructions on ollama.com to install it. Then, pull a model. A good starting point is:
ollama pull deepseek-coder:6.7bMake sure the Ollama server is running.