Added much of the patching interface