``` 在为 Linux 内核贡献代码时的人工智能辅助 ```
AI assistance when contributing to the Linux kernel

原始链接: https://github.com/torvalds/linux/blob/master/Documentation/process/coding-assistants.rst

## AI 对 Linux 内核的贡献:摘要 本指南概述了如何负责任地将 AI 辅助集成到 Linux 内核开发中。至关重要的是,所有 AI 辅助的贡献**必须遵守现有的内核开发流程**(开发流程、编码风格、提交补丁)和**许可要求**(GPL-2.0、SPDX 标识符)。 AI 工具可以*辅助*,但**不能合法地认证贡献**。人类仍然完全负责审查所有 AI 生成的代码,确保许可合规性,并添加他们自己的“Signed-off-by”标签以确认开发者来源证书(DCO)。 为了跟踪 AI 的作用,利用 AI 辅助的贡献**必须包含一个“Assisted-by”标签**,格式如下:`Assisted-by: AGENT_NAME:MODEL_VERSION [TOOL1] [TOOL2]`。此标签详细说明了 AI 代理、模型版本以及使用的任何专用分析工具——不包括基本的开发工具,如 Git 或 GCC。适当的署名是了解 AI 对内核开发影响的关键。

Hacker News新 | 过去 | 评论 | 提问 | 展示 | 工作 | 提交登录 AI 协助参与 Linux 内核贡献 (github.com/torvalds) 23 分,由 hmokiguess 1 小时前发布 | 隐藏 | 过去 | 收藏 | 4 条评论 帮助 qsort 5 分钟前 | 下一个 [–] 基本上规则是你可以使用 AI,但你需要对你的提交承担全部责任,并且代码必须满足许可证要求。 这…令人耳目一新? 相信大多数善意的人都可以接受。回复 ipython 5 分钟前 | 上一个 | 下一个 [–] 很高兴看到常识性的规则,即只有人类才能对 AI 代理生成的代码负责。回复 baggy_trough 11 分钟前 | 上一个 | 下一个 [–] 听起来很合理。回复 bitwize 18 分钟前 | 上一个 [–] 很好。BSD 也应该效仿。在 2026 年,期望任何开发者不使用 AI 都是不合理的。回复 指南 | 常见问题 | 列表 | API | 安全 | 法律 | 申请 YC | 联系 搜索:
相关文章

原文

This document provides guidance for AI tools and developers using AI assistance when contributing to the Linux kernel.

AI tools helping with Linux kernel development should follow the standard kernel development process:

  • Documentation/process/development-process.rst
  • Documentation/process/coding-style.rst
  • Documentation/process/submitting-patches.rst

All contributions must comply with the kernel's licensing requirements:

  • All code must be compatible with GPL-2.0-only
  • Use appropriate SPDX license identifiers
  • See Documentation/process/license-rules.rst for details

AI agents MUST NOT add Signed-off-by tags. Only humans can legally certify the Developer Certificate of Origin (DCO). The human submitter is responsible for:

  • Reviewing all AI-generated code
  • Ensuring compliance with licensing requirements
  • Adding their own Signed-off-by tag to certify the DCO
  • Taking full responsibility for the contribution

When AI tools contribute to kernel development, proper attribution helps track the evolving role of AI in the development process. Contributions should include an Assisted-by tag in the following format:

Assisted-by: AGENT_NAME:MODEL_VERSION [TOOL1] [TOOL2]

Where:

  • AGENT_NAME is the name of the AI tool or framework
  • MODEL_VERSION is the specific model version used
  • [TOOL1] [TOOL2] are optional specialized analysis tools used (e.g., coccinelle, sparse, smatch, clang-tidy)

Basic development tools (git, gcc, make, editors) should not be listed.

Example:

Assisted-by: Claude:claude-3-opus coccinelle sparse
联系我们 contact @ memedata.com