Skip to content

Commit ff85234

Browse files
committed
bug #1035 [Agent][SimilaritySearch] Fix iterable type (OskarStark)
This PR was squashed before being merged into the main branch. Discussion ---------- [Agent][SimilaritySearch] Fix iterable type | Q | A | ------------- | --- | Bug fix? | yes | New feature? | no | Docs? | no | Issues | Fix #1034 | License | MIT Commits ------- 314d97a [Agent][SimilaritySearch] Fix iterable type
2 parents 4596143 + 314d97a commit ff85234

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/agent/src/Bridge/SimilaritySearch/SimilaritySearch.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ public function __construct(
3939
public function __invoke(string $searchTerm): string
4040
{
4141
$vector = $this->vectorizer->vectorize($searchTerm);
42-
$this->usedDocuments = $this->store->query($vector);
42+
$this->usedDocuments = iterator_to_array($this->store->query($vector));
4343

4444
if ([] === $this->usedDocuments) {
4545
return 'No results found';

0 commit comments

Comments
 (0)