NEW YORK — Toni Morrison praised the power of literature and the “community” of writers. James Patterson told some jokes, and even sang.

Both received Distinguished Service Awards on Wednesday night at the 25th annual Authors Guild dinner gala, held in Manhattan. The Guild, which represents thousands of published writers, also gave a service award to the heads of the self-publishing platform IngramSpark.

The 86-year-old Morrison, who won the Nobel literature prize in 1993, was cited by longtime editor Robert Gottlieb for literary achievements in novels such as “Beloved” and “Song of Solomon,” and for her contributions as an editor and educator.

“We’re all here together,” Morrison reminded the audience, which included fellow authors such as Erica Jong and Walter Mosley. “We are a necessary community.”

Morrison warned of the dangers of “ignorance,” and called for language to be given its rightful place as a force of “power” and “eloquence,” rendered “one book at a time.”

Patterson, 70, was honored not only for his extraordinary commercial success, more than 300 million books sold worldwide, but also for donating millions of dollars to librarians, booksellers and schools.

Patterson sometimes turns out best-sellers on a monthly basis. The man who negotiates his book deals, Washington attorney Robert Barnett, was not kidding Wednesday night when he said that Patterson’s latest contract called for 22 books, to come out in two years.

There were jokes about President Trump, and a gag about writing a “truer than truer crime” book with Russian President Vladimir Putin.