In the fancy new versions of OpenGL (3.0 and 4.0 up), built-in vertex attributes like gl_Vertex are being deprecated. The "new way" to actually render anything is to specify your own vertex attributes for position, color, etc., and then bind these custom attributes to buffers.
My question is this: how can one do this without closely coupling the rendering code and the shader? If I write a shader that uses "position" as the vertex position, the host code using the shader has to know that and pass vertex data as "position". If I want to use a different shader that was written to take vertex data in "vertex_pos", I have to either rewrite that shader first, or modify my host code to send vertex data as "vertex_pos" instead.
Is there a set of best-practice names for standard vertex and fragment attributes that all shaders should be using? Or are there Balkanized engine-specific standards, such that a shader written for one engine cannot work on another without modification? Or are there no standards at all, such that, in general, every object needs its own custom rendering code to match its custom shader?