Indeed. Sorting by relevancy is absolutely required. This is the entire point of creating a relevancy concept in the first place.
Do note, however that when you "sort" is up to you. If you're clever about your index structure, you may be able to get it to return results to you in sorted order, requiring no further processing. However, if needed, you are free to run some fast (maybe "quick" would be a better word.... ;) ) sorting algorithm within retrievePages if this is necessary for your index structure. |