-
-
Notifications
You must be signed in to change notification settings - Fork 102
Closed
Labels
Good first issueIdeal for your first contribution! (some Symfony experience may be required)Ideal for your first contribution! (some Symfony experience may be required)Hackathon 2025This issue or pull request was part of the Symfony AI Hackathon 2025This issue or pull request was part of the Symfony AI Hackathon 2025StoreIssues & PRs about the AI Store componentIssues & PRs about the AI Store component
Description
Summary
The Vectorizer
and VectorizerInterface
should be extended to support passing options to the underlying Platform->invoke()
calls. This will allow users to configure platform-specific options like temperature, top_k, etc. when vectorizing text documents.
Required Changes
1. Interface Updates
Add an optional $options = []
parameter to both methods in VectorizerInterface
:
vectorizeTextDocuments(array $documents, array $options = []): array
vectorize(string $string, array $options = []): Vector
2. Implementation Updates
Update the Vectorizer
class to:
- Accept the
$options
parameter in both methods - Pass these options as the third parameter to
$this->platform->invoke()
calls (lines 38, 47, 74)
3. Bundle Configuration
Make vectorizer options configurable through the AI bundle configuration, similar to how the model is currently configured. This should allow users to set default options that will be used for all vectorization operations.
Use Cases
This enhancement enables:
- Setting platform-specific embedding parameters (temperature, dimensions, etc.)
- Configuring retry strategies or timeouts for vectorization
Files to Modify
src/store/src/Document/VectorizerInterface.php
- Add $options parameter to method signaturessrc/store/src/Document/Vectorizer.php
- Implement $options parameter and pass to platform invoke calls- Bundle configuration files - Add vectorizer options configuration support
Metadata
Metadata
Assignees
Labels
Good first issueIdeal for your first contribution! (some Symfony experience may be required)Ideal for your first contribution! (some Symfony experience may be required)Hackathon 2025This issue or pull request was part of the Symfony AI Hackathon 2025This issue or pull request was part of the Symfony AI Hackathon 2025StoreIssues & PRs about the AI Store componentIssues & PRs about the AI Store component