Strong interaction of correlated electrons with phonons: A diagrammatic approach