This is the role of design documents which get heavily reviewed by the team before even the first line of code is written.
Edit: broken leftover line
"In preparing for battle I have always found that plans are useless, but planning is indispensable." - Dwight D. Eisenhower
I know that's how it sounds. But in my experience it turns out to be a lot more effective than planning.