New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
together[minor]: Update endpoint to non deprecated version #19649
together[minor]: Update endpoint to non deprecated version #19649
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎ 1 Ignored Deployment
|
together_api_key: SecretStr | ||
"""Together AI API key. Get it here: https://api.together.xyz/settings/api-keys""" | ||
model: str | ||
"""Model name. Available models listed here: | ||
https://docs.together.ai/docs/inference-models | ||
Base Models: https://docs.together.ai/docs/inference-models#language-models | ||
Chat Models: https://docs.together.ai/docs/inference-models#chat-models |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dev-yashmathur max_tokens
is now a required parameter (https://docs.together.ai/reference/completions).
also as a matter of style, I don't think these changes are minor :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @sepiatone , appreciate the feedback. I seem to have missed that, as even without it; i think a default of 20 is being set.
I have added a new commit which should take this into consideration.
Looking forward to any other feedback. Thanks :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't it be simpler to do this:
max_tokens: Optional[int] = None
to
max_tokens: int = 128
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @sepiatone . While that is the simpler solution, I have opted for this approach so as to inform the users of the requirement. Just setting it ourselves, would not include the warning. If you think that the warning can be skipped, then I'll make this change as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dev-yashmathur I checked the implementation of a few other models and we don't usually give a warning, that said, I'm ok with it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sepiatone So, can this PR be merged, or would you like me to make the modification?
P.S. I appreciate you taking the time to help me out with this :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dev-yashmathur lgtm! now the actual maintainers of the langchain-together package, @baskaryan & @efriis will have to be satisfied :)
…-ai#19649) - **Updating Together.ai Endpoint**: "langchain_together: Updated Deprecated endpoint for partner package" - Description: The inference API of together is deprecates, do replaced with completions and made corresponding changes. - Twitter handle: @dev_yashmathur --------- Co-authored-by: Bagatur <22008038+baskaryan@users.noreply.github.com> Co-authored-by: Bagatur <baskaryan@gmail.com>
- **Updating Together.ai Endpoint**: "langchain_together: Updated Deprecated endpoint for partner package" - Description: The inference API of together is deprecates, do replaced with completions and made corresponding changes. - Twitter handle: @dev_yashmathur --------- Co-authored-by: Bagatur <22008038+baskaryan@users.noreply.github.com> Co-authored-by: Bagatur <baskaryan@gmail.com>
Updating Together.ai Endpoint: "langchain_together: Updated Deprecated endpoint for partner package"
Description: The inference API of together is deprecates, do replaced with completions and made corresponding changes.
Twitter handle: @dev_yashmathur