Using transistor as negative input to esp32 gpio

After disassemble and assembling again your modificatiom works but the gpio vibrating between on and off for half second while the load is on
I draw the circuit power from esp32. 3.3v pin