This post originated from an RSS feed registered with Python Buzz
by Carlos de la Guardia.
Original Post: Automatic news summaries with Plone using Haystack
Feed Title: I blog therefore I am
Feed URL: http://blog.delaguardia.com.mx/feed.atom
Feed Description: A space to put my thoughts into writing.
On the Mexican presidential election web site that we set up using Plone (see my previous post about this), we wanted to have a front page with the title of each news item and a small summary below that. The problem: the news staff needed to work fast and couldn't be bothered to type a summary themselves.
The Haystack product, by Benjamin Saller, is a Plone product for automatic content linguistic and relation analysis, which, among other things, can summarize written content with a simple method call. This product solved the problem for us.
After successfully installing it, we simply modified Archetypes' content_edit script to call Haystack's summarize method after creation of a news item and set its description with the returned value. Voila! Automatic news summaries.
By the way, libots, which Haystack uses for its linguistic magic, supports multiple languages. Our site is in Spanish, for example.