Le mar. 5 août 2025 à 10:40, Otavio Rodolfo Piske <angusyo...@gmail.com> a écrit :
> Hello, > > I'd like to bring to discussion that we add a set of a dedicated AI > instructions file (e.g., INSTRUCTIONS.ai) to the Apache Camel repository > (core and other sub-projects). > > The purpose of these files would be to define how AI-powered coding agents > and tools should behave when generating code for this project. I believe > this would be beneficial for a few key reasons: > > 1. > > *Enforce ASF Generative Tooling Guidelines:* It would help us formally > adopt and point to the standards defined by the ASF on the use of > generative AI, ensuring all contributions are compliant. > - > > Apache Software Foundation Legal - Generative Tooling > <https://www.apache.org/legal/generative-tooling.html> > Sounds good. > 2. > > *Maintain Project Coding Standards:* We can use it to instruct AI tools > on Camel's specific coding patterns, conventions, and architectural > principles. This will help maintain the consistency and quality of the > codebase. > I think it is nice to instruct the tool about coding standards. However, I think we should enforce things using maven plugins. If there are rules we want to enforce, this should apply to all our code, not just code generated by AI. IF needed, a first task could be given to an agent to fix all failures once the rules are enforced in the build. > 3. > > *Define Clear Guardrails:* It allows us to establish a reasonable set of > rules and constraints for generated code, promoting security, > reliability, > and adherence to best practices from the start. > This is becoming a standard practice in other major open-source projects. > For example, the Linux kernel community is already discussing and defining > similar guidelines to ensure AI-assisted contributions are constructive. > > - > > Linux Kernel Mailing List Discussion > < > https://lore.kernel.org/all/20250725175358.1989323-1-sas...@kernel.org/> > > I believe that taking this proactive step will help us harness the benefits > of AI tooling while safeguarding the integrity of the project. > I'm fine with guidelines / best practices about generated code. I'm not sure about the "promoting security, reliability, and adherence to best practices" part. Imho, this isn't specific to AI generated code and if we have guidelines, they should apply to generated *and* non-generated code. Guillaume > > I'd like to open a discussion on this. What are your thoughts? Any other > projects in the ASF that have defined these instructions and that we could > inspire our guidelines on? > > > Kind regards, > -- > Otavio R. Piske > http://orpiske.net > -- ------------------------ Guillaume Nodet