you can ask for the knowledge you need. like, okay maybe I know that if I want to detect a ledge I can raycast forward, then raycast up in front of the hit point and dot the normals' to find a valid ledge because I know maths.