fix 3
This commit is contained in:
@@ -14,9 +14,7 @@ final readonly class QueryEnricher
|
||||
* The enriched semantic query should help vector retrieval,
|
||||
* but must not become bloated enough to dilute the original user intent.
|
||||
*/
|
||||
private const MAX_EXPANSIONS = 4;
|
||||
|
||||
public function __construct(
|
||||
public function __construct(
|
||||
private QueryEnricherConfig $config
|
||||
) {
|
||||
}
|
||||
@@ -95,7 +93,7 @@ final readonly class QueryEnricher
|
||||
$matches[] = $mappedValue;
|
||||
$seenNormalizedExpansions[$normalizedMappedValue] = true;
|
||||
|
||||
if (count($matches) >= self::MAX_EXPANSIONS) {
|
||||
if (count($matches) >= $this->config->getMaxExpansions()) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user