www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - duplication of code linting

reply monkyyy <crazymonkyyy gmail.com> writes:
Does anyone have a pre-existing method of detecting code 
duplication; as I experiment with vibe coding, ai slop duplicates 
code like crazy when it ever gets an import wrong.
Nov 11
parent reply Alexandru Ermicioi <alexandru.ermicioi gmail.com> writes:
On Wednesday, 12 November 2025 at 05:45:20 UTC, monkyyy wrote:
 Does anyone have a pre-existing method of detecting code 
 duplication; as I experiment with vibe coding, ai slop 
 duplicates code like crazy when it ever gets an import wrong.
ask it to dedupe.
Nov 11
parent reply monkyyy <crazymonkyyy gmail.com> writes:
On Wednesday, 12 November 2025 at 07:34:08 UTC, Alexandru 
Ermicioi wrote:
 On Wednesday, 12 November 2025 at 05:45:20 UTC, monkyyy wrote:
 Does anyone have a pre-existing method of detecting code 
 duplication; as I experiment with vibe coding, ai slop 
 duplicates code like crazy when it ever gets an import wrong.
ask it to dedupe.
its very slow at it and imperfect; while the code it copies are 1 to 1 copies. I think the ai control mechanisms that google and shit are push of more and more ai in the pile, is stupid, we have old proven tools, I would like to see unix file permissions so some ai doesn't delete a test because that will just work at preventing that common failure. etc.
Nov 12
parent Alexandru Ermicioi <alexandru.ermicioi gmail.com> writes:
On Wednesday, 12 November 2025 at 16:28:40 UTC, monkyyy wrote:
 its very slow at it and imperfect; while the code it copies are 
 1 to 1 copies.
ask it multiple times: are yo sure you de-duped it right? :D
 I think the ai control mechanisms that google and shit are push 
 of more and more ai in the pile, is stupid, we have old proven 
 tools, I would like to see unix file permissions so some ai 
 doesn't delete a test because that will just work at preventing 
 that common failure. etc.
you can always take control of that by implementing your own mcp server that will prevent llm from willy-nilly modify your files. I'm playing with spring ai (java) to enhance intellij idea support of local llms (it currently doesnt expose mcp commands to local llms), and is quite easy to expose commands to llm that you control.
Nov 12