How you determine which words from the result you include in the summary is up to you. The problem with this it that in Lucene-land you have to store the content of the document inside in index verbatim (so you can get arbitrary portions of it out). This means your index will be larger than it really needs to be.
I usually just store the first 255 characters in the index and use this as a summary. It's not as good as Google, but it seems to work ok.
----- Original Message ----- From: "Ben" <[EMAIL PROTECTED]>
To: "Lucene" <[email protected]>
Sent: Friday, January 28, 2005 5:08 PM
Subject: Search results excerpt similar to Google
Hi
Is it hard to implement a function that displays the search results excerpts similar to Google?
Is it just string manipulations or there are some logic behind it? I like their excerpts.
Thanks
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
