macosxhints - An AppleScript to copy iPod ratings back to iTunes
"you navigate to your (manually updated) iPod inside of iTunes, select the tracks from which you want to copy ratings, played count, and last played for, and the script finds the corresponding track in your library and copies the data."