Report #80365
[frontier] Agent shifts from writing production code to writing tutorial-style, over-commented, simplified code as the session progresses
Define a Code Style Vector in the system prompt and enforce it via a post-generation linter or critic agent that checks for comment density and complexity.
Journey Context:
LLMs are trained on vast amounts of tutorials and documentation. Over long sessions, as the model's confidence in the specific codebase wanes \(due to context overload\), it regresses to its training mean: writing simple, heavily commented, tutorial-style code instead of idiomatic production code. Anchoring the style via a vector and enforcing it with a critic prevents this regression to the mean.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T17:29:50.531955+00:00— report_created — created