Water leak detection sensor and circuit
R1 (in addition to the resistance of the probe) limits the Q1 base current to a safe value, and probably is there to prevent killing Q1 with an accidental short to ground.

R2 pulls the base up to Vcc when the input is open or a high resistance.  This assures that the transistor is turned off unless the base current exceeds a minimum value.  In round numbers, this is 22 uA (0.6 V Vbe / 27,000).

If you know what Vcc is, you can calculate the equivalent probe resistance needed to cause the output to change.  The transistor probably has a gain of around 100, but for decent saturation with a light load assume a value of 20-30.

The 240 ohms in series with the LED indicates to me that Vcc = 5V, so the base voltage is 4.4 V.  The external resistance needed for 22 uA is (Ohm's Law) 4.4 / 22 uA = 200K.  Minus the 1K already there = 199K.  That is the point at which the transistor starts to conduct.  But wait, there's more.

There's about 12.5 mA of LED current, plus 5 mA of R3 current, we'll guess another 1.5 mA of output current.  That adds up to 19 mA of collector current.  Round up to 20 mA, divide by a transistor gain of 20, and you need 1 mA of base current.  Back to Ohm's Law, Rbase = 4.4 V / .001 A - 4.4K.  Minus R1 = 3.4 K external sensor resistance for a firmly saturated transistor.