Spectroscopic signatures of infall in young protostellar systems