Add main method for backward compatibility