radar

ONE Sentinel

smart_toyAI/PROMPT ENGINEERING

Can coding agents relicense open source through a “clean room” implementation of code?

sourceSimon Willison
calendar_todayMarch 5, 2026
schedule2 min read
lightbulb

EXECUTIVE SUMMARY

The Legal Quagmire of AI-Driven Code Rewrites: A Case Study

Summary

The article discusses the implications of coding agents creating a clean-room implementation of open-source code, focusing on the recent release of chardet 7.0.0, which has sparked legal and ethical debates regarding licensing. It highlights the challenges faced by maintainers when attempting to relicense a project originally under the LGPL.

Key Points

  • Chardet is a Python library created by Mark Pilgrim in 2006 and maintained by Dan Blanchard since 2012.
  • The recent release, chardet 7.0.0, claims to be a ground-up rewrite under the MIT license, raising questions about the legality of this re-licensing.
  • Mark Pilgrim argues that the maintainers do not have the right to relicense due to LGPL requirements, as the rewrite process did not adhere to traditional clean-room methodologies.
  • Dan Blanchard asserts that the new code is structurally independent, with a maximum similarity of 1.29% to previous versions, as shown by the JPlag tool.
  • The use of AI tools like Claude Code in the rewrite process complicates the legal landscape, as it may have been trained on the original codebase.
  • The situation reflects broader concerns regarding the use of AI in software development and its potential impact on intellectual property rights.

Analysis

This case illustrates the tension between innovation through AI and the legal frameworks governing open-source software. The outcome could set a precedent for how coding agents are utilized in both open-source and commercial environments, potentially leading to significant litigation.

Conclusion

IT professionals should remain vigilant about the evolving legal landscape surrounding AI-generated code and consider implementing stricter guidelines for code reuse and licensing to mitigate risks.