The NYC CNC channel used a color-seeking Pixy Camera to build a working semi-autonomous sentry gun using a real AR-15.
The Pixy lens works by seeking designated color hues and patterns. The NYC CNC crew mounted one atop the Picatinny rail of a AR-15 (SBR?) attached to a Hog Saddle gun rest then powered the rest by mounting it to a lazy Susan type set up with some Stepper motors and gave it the brainpan of a Arduino UNO R3 hobby board.
The end result: a sentry gun that looks for green steel plates and automatically slews the muzzle to target the center mass of said plate.
Now there is still man-in-the-loop in the form of a trigger string attached to a human hand to keep the Sky Net concerns to a dull grumble.
And yes, they intend on getting with ATF about a letter, so there is a remote (get it) chance you could see more of these in the future.
Pro tip: minimize the amount of green you wear moving forward.