Fixed bug in relevance function by SP. The cutting threshold was not being taken into account.