It is generally accepted that 2/32-inch is the minimum tread depth for successful rain traction. Hence, it’s illegal to drive with tires that have less than 2/32-inch tread depth in most countries on earth.
Furthermore, tire manufacturers employ tread wear indicators (TWIs), which are narrow rubber bars that sit in the circumferential grooves of the tire. When your tire reaches the minimum tread depth, these indicators will be flush with the rest of the tread.
Naturally, I’d recommend replacing your tires even sooner, especially if you live in an area where it rains frequently. Ask your mechanic to check the remaining tread depth (my recommendation is a 4/32-inch minimum for safe rain driving), or purchase a simple tread depth gauge and measure it yourself.