When we think about unmanned vehicles generally what comes up to our minds are predator like propeller driven drones.
While research is going on to make the aerial vehicles more stealthy this can already be achieved with underwater smaller vehicles that can be modified or converted for anti ship roles.
Small changes in bouyancy and for example a lifting flying wing triangle structure makes these devices travel very long distances. What they lack is a sensor(active sonar or a passive sonar and infrared) to detect large ships like aegis and carrier groups.
Ofcourse they should be armed with VA-111 Shkval type of fast torpedos.
For unmanned operation they can travel predetermined routes. Possibly when target is detected they can throw a radio data transfer beacon on water surface and operator can control the exact targeting and escape of the vehicle realtime.
Or if software and friend foe identification is good enough it can handle itself and return back all under stealth with very little or no radar sonar and ir signature .
For example usa sometimes enters close to China with its large vessels also after the ukraine issue usa ships regularly enter black sea. The large easy targets like ships whether carrier aegis etc. wont be of any threat value if stealthy platforms like these enter into scene with large numbers.