2 wire smoke detectors can use the same wire pair to provide both power to the detector as well as carrying the signal back in case smoke is detected. The wires connect to the PGM terminals on your fire alarm system. As a general rule, 2 wire smoke detectors are much easier to use and install. But keep in mind that 2 wire smoke detectors must be used on a designated zone.
A 2 wire smoke detector will receive automatic reset commands from the panel. But with that in mind, you can only use a 2 wire smoke detector with a hardwired zone that will automatically reset the sensor after a fire alarm is cleared. As long as you save the designated smoke reset zone for your 2 wire smoke detectors, then there should be no issue.
The major downside to using a 4-wire smoke detector is that a lot of extra equipment is required. This extra equipment is needed to reset the smoke detectors after an alarm is cleared. This required equipment includes a power supply and a relay. This extra equipment makes the setup process more difficult. For that reason, most DIY users prefer 2 wire smoke detectors that can just be wired to the panel directly.
Both 2 wire and 4 wire smoke detectors require the power reset after an alarm is cleared. This is necessary for stopping the smoke detector from sounding. Once the smoke detector is reset, it will go back into its quiet default state. It will only begin sounding its alarm when it detects smoke, or when the device is being tested. Since 2 wire and 4 wire smoke detectors really do the exact same thing, you should just go with whichever one is easier to set up. This is usually a 2 wire smoke detector.