feat(embed-many): respect supportsParallelCalls & concurrency#6108
Merged
feat(embed-many): respect supportsParallelCalls & concurrency#6108
Conversation
lgrammel
reviewed
May 2, 2025
lgrammel
reviewed
May 2, 2025
lgrammel
approved these changes
May 2, 2025
lgrammel
reviewed
May 2, 2025
Comment on lines
-89
to
-95
| it('should handle multiple input values and extract usage', async () => { | ||
| const { usage } = await model.doEmbed({ | ||
| values: testValues, | ||
| }); | ||
|
|
||
| expect(usage?.tokens).toStrictEqual(16); | ||
| }); |
Collaborator
There was a problem hiding this comment.
why was this test removed?
Contributor
Author
samdenty
added a commit
that referenced
this pull request
May 5, 2025
* origin/v5: (23 commits) chore (ai): remove StreamData and mergeStreams (#6150) chore (build): fix typecheck setup (#6151) chore (ai): remove IdGenerator duplication (#6147) chore (ai): remove content from ui messages (#6145) Version Packages (canary) (#6115) feat (provider): support reasoning tokens, cached input tokens, total token in usage information (#6140) test (ai): use `mock-provider` instead of `openai` to match used `MockImageModelV2` (#6132) fix(providers): always use optional instead of mix of nullish for providerOptions (#6122) chore (ai): remove sendExtraMessageFields (#6120) chore(provider-utils): move ToolResultContent to provider-utils (#6121) feat(embed-many): respect supportsParallelCalls & concurrency (#6108) chore (provider-utils): return IdGenerator interface (#6118) chore (provider): improve jsdoc comments (#6117) chore (ai): remove outdated typecasts (#6116) chore (ai): remove useChat keepLastMessageOnError (#6114) fix(providers/openai): logprobs for stream alongside completion model (#6091) chore (ai): move maxSteps into UseChatOptions (#6113) docs (ai): add notes on schema .optional() (#6111) chore: update references to use ai-sdk.dev (#6076) (#6107) Version Packages (canary) (#6069) ...
iteratetograceness
pushed a commit
to iteratetograceness/ai
that referenced
this pull request
May 9, 2025
…#6108) ## Background We didn't actually read the supportsParallelCalls field at all, and we did everything serially in embedding model ## Summary This makes the embedding model actually respect supportsParallel calls Co-authored-by: Lars Grammel <lars.grammel@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Background
We didn't actually read the supportsParallelCalls field at all, and we did everything serially in embedding model
Summary
This makes the embedding model actually respect supportsParallel calls
Verification
Tasks
pnpm changesetin the project root)pnpm prettier-fixin the project root)Future Work
Related Issues