Media playback is not supported on this device
Two-time double Olympic champion Sir Mo Farah struggled on the Holyrood Park course, finishing in seventh.
Turkey's Yasemin Can, representing Europe, won the women's race, while Britain's Harriet Knowles-Jones claimed the junior women's title.
Captain Laura Muir anchored Britain to victory in the 4x1km mixed relay.
The team event was won by USA, with Europe second and Great Britain third.
Hawkins, 24, led for most of the men's race until he was passed in the final 15m by Kenyan-born Korir, who won in a time of 24 minutes three seconds.
"I put everything in to dropping him but he was the stronger man at the end," the Scot told BBC Sport.
Newly knighted Farah, 33, finished 46 seconds adrift of Korir, with 2016 champion Garrett Heath of the United States in sixth.
"It was a hard day at the office," Farah told BBC Sport. "I'm a little bit behind where I would usually be at this stage of the season.
"But I'm not panicking this early on in the year - I've got to get ready for London 2017."
With Farah out of contention early on in the 8km race, Hawkins took the initiative to break clear with Korir and Heath, before the latter faded.
Hawkins, who finished ninth in the marathon at last summer's Olympics in Rio, repeatedly tried to drop Korir on the small rises around the course and appeared to have a winning gap coming into the final straight.
But Korir, who finished 14th in the 10,000m final in Rio, won by Farah, had the greater kick in the final sprint to surge past the Scot and claim the title.
"I was really tired at the end and he just wouldn't leave me alone," joked Hawkins, who will run in the marathon at this summer's World Championships in London.
After breaking the 25-year-old British indoor 5,000m record on Wednesday, Muir produced a stellar final lap to secure Britain victory in the invitational Stewart Cup 4x1km mixed relay.
Muir took the baton from James West level with USA but quickly surged clear as Britain won in a time of 11 minutes, 10 seconds, with the first two legs run by James Bowness and Charlene Thomas respectively.
"In my role as captain I wanted to put out a good job for the team and when I saw the others placing well I had to bring it home for them," Muir told BBC Sport.
"I wasn't used to being the one to watch but I'm there now and it's great - people are recognising that I'm running fast and I want to keep it that way."
Elsewhere, Kenyan-born runner Can dominated the women's 6km event to win in a time of 20 minutes 36 seconds, with Ireland's Fionnuala McCormack, also racing for Europe, 21 seconds adrift in second.
Noah Affolder of the United States won the junior men's race, with Scott Beattie the highest-placed Briton in eighth.
Great Britain's Callum Hawkins was beaten into second by USA's Leonard Korir in a dramatic sprint finish at the Great Edinburgh Cross Country.