Skip to content

Conversation

@dependabot
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Dec 20, 2023

Bumps transformers from 4.30.0 to 4.36.0.

Release notes

Sourced from transformers's releases.

v4.36: Mixtral, Llava/BakLlava, SeamlessM4T v2, AMD ROCm, F.sdpa wide-spread support

New model additions

Mixtral

Mixtral is the new open-source model from Mistral AI announced by the blogpost Mixtral of Experts. The model has been proven to have comparable capabilities to Chat-GPT according to the benchmark results shared on the release blogpost.

The architecture is a sparse Mixture of Experts with Top-2 routing strategy, similar as NllbMoe architecture in transformers. You can use it through AutoModelForCausalLM interface:

>>> import torch
>>> from transformers import AutoModelForCausalLM, AutoTokenizer
>>> model = AutoModelForCausalLM.from_pretrained("mistralai/Mixtral-8x7B", torch_dtype=torch.float16, device_map="auto")
>>> tokenizer = AutoTokenizer.from_pretrained("mistralai/Mistral-8x7B")
>>> prompt = "My favourite condiment is"
>>> model_inputs = tokenizer([prompt], return_tensors="pt").to(device)
>>> model.to(device)
>>> generated_ids = model.generate(**model_inputs, max_new_tokens=100, do_sample=True)
>>> tokenizer.batch_decode(generated_ids)[0]

The model is compatible with existing optimisation tools such Flash Attention 2, bitsandbytes and PEFT library. The checkpoints are release under mistralai organisation on the Hugging Face Hub.

Llava / BakLlava

Llava is an open-source chatbot trained by fine-tuning LlamA/Vicuna on GPT-generated multimodal instruction-following data. It is an auto-regressive language model, based on the transformer architecture. In other words, it is an multi-modal version of LLMs fine-tuned for chat / instructions.

The Llava model was proposed in Improved Baselines with Visual Instruction Tuning by Haotian Liu, Chunyuan Li, Yuheng Li and Yong Jae Lee.

The integration also includes BakLlava which is a Llava model trained with Mistral backbone.

The mode is compatible with "image-to-text" pipeline:

from transformers import pipeline
from PIL import Image    
import requests
model_id = "llava-hf/llava-1.5-7b-hf"
</tr></table>

... (truncated)

Commits

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    You can disable automated security fix PRs for this repo from the Security Alerts page.

Bumps [transformers](https://github.com/huggingface/transformers) from 4.30.0 to 4.36.0.
- [Release notes](https://github.com/huggingface/transformers/releases)
- [Commits](huggingface/transformers@v4.30.0...v4.36.0)

---
updated-dependencies:
- dependency-name: transformers
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot added the dependencies Pull requests that update a dependency file label Dec 20, 2023
@anuragoyar
Copy link

Potential Risks and Suggestions:

File: codegen1/requirements.txt
Code Snippet: +transformers==4.36.0
Comment: Ensure that the new version of the transformers library (4.36.0) is compatible with your existing codebase and dependencies. Test thoroughly in a staging environment before deploying to production to avoid runtime issues.

Summary:

  1. Summary of Changes:

    • Components: Python dependencies in requirements.txt
    • Types: Version update for the transformers library
    • Number of Changes: 1 change (version bump from 4.30.0 to 4.36.0)
  2. Potential Risks or Missing Dependencies:

    • Compatibility: The new version of the transformers library might introduce breaking changes or deprecate certain features. Ensure that all dependent code and integrations are compatible with this new version.
    • Testing: There is no indication of testing for this change. Ensure that comprehensive tests are run to verify that the new library version does not introduce any issues.
    • Dependencies: Check if the new version of transformers requires updates to other dependencies or introduces new ones.
  3. Suggestions to Improve Safety or Rollback Planning:

    • Staging Environment: Deploy this change to a staging environment first and run all relevant tests to ensure compatibility and stability.
    • Rollback Plan: Have a rollback plan in place to revert to the previous version (4.30.0) if any issues are encountered during or after deployment.
    • Documentation: Update any relevant documentation to reflect the change in the library version and any new features or changes in behavior.
  4. Suitability for Production Deployment:

    • This change can be suitable for production deployment if thorough testing is conducted in a staging environment and no issues are found. Ensure that all dependent systems and integrations are verified for compatibility with the new library version.

@anuragoyar
Copy link

Potential Risks and Suggestions:

File: codegen1/requirements.txt
Code Snippet: +transformers==4.36.0
Comment: Ensure that the new version of the transformers library (4.36.0) is compatible with the existing codebase and does not introduce breaking changes. Review the release notes for any significant updates or deprecations.

Summary:

  1. Summary of Changes:

    • Components: requirements.txt file
    • Types: Dependency version update
    • Number of Changes: 1 (updating the transformers library from version 4.30.0 to 4.36.0)
  2. Potential Risks or Missing Dependencies:

    • Compatibility: The new version of the transformers library might introduce changes that could affect the existing functionality. It is crucial to verify that the updated library is compatible with the current codebase.
    • Dependencies: Ensure that any dependencies of the transformers library are also compatible with the new version.
    • Testing: Verify that all existing tests pass with the new version of the library. Additional tests may be required to cover new features or changes introduced in the updated version.
  3. Suggestions to Improve Safety or Rollback Planning:

    • Review Release Notes: Carefully review the release notes for the transformers library version 4.36.0 to understand any breaking changes, new features, or deprecations.
    • Testing: Run a comprehensive suite of tests to ensure that the new version does not introduce any regressions or issues.
    • Staging Environment: Deploy the changes to a staging environment first to validate the behavior before promoting to production.
    • Rollback Plan: Have a rollback plan in place in case the new version causes issues. This includes being able to revert to the previous version (4.30.0) quickly.
  4. Suitability for Production Deployment:

    • Conditional: This change can be suitable for production deployment if thorough testing is conducted, and no compatibility issues are found. Ensure that the rollback plan is in place and that the deployment is first validated in a staging environment.

Overall, the change appears to be straightforward, but due diligence in testing and validation is necessary to ensure a smooth transition to the new library version.

@anuragoyar
Copy link

Potential Risks and Suggestions:

File: codegen1/requirements.txt
Code Snippet: transformers==4.36.0
Comment: Upgrading the transformers library from version 4.30.0 to 4.36.0 may introduce breaking changes or deprecations. Ensure that all dependent code is compatible with the new version. Review the release notes for any significant changes that could impact your application.

Summary:

  1. Summary of Changes:

    • Components: Python dependencies
    • Types: Library version update
    • Number of Changes: 1 (upgrade of transformers library from version 4.30.0 to 4.36.0)
  2. Potential Risks:

    • Compatibility: The new version of the transformers library may have breaking changes or deprecated features that could affect existing functionality.
    • Dependencies: Ensure that other dependencies that rely on transformers are compatible with version 4.36.0.
    • Testing: Verify that all unit and integration tests pass with the new library version to ensure no regressions.
  3. Suggestions for Safety and Rollback Planning:

    • Testing: Conduct thorough testing in a staging environment before deploying to production. Include both automated tests and manual testing of critical workflows.
    • Review Release Notes: Check the release notes for transformers version 4.36.0 to identify any breaking changes or new features that need attention.
    • Rollback Plan: Have a rollback plan in place to revert to the previous version (4.30.0) if any issues are encountered after deployment.
  4. Suitability for Production Deployment:

    • This change can be suitable for production deployment if thorough testing is conducted, and no compatibility issues are found. Ensure that a rollback plan is in place to mitigate any potential issues.

Additional Considerations:

  • Impact on Existing Integrations: Review any integrations that depend on the transformers library to ensure they are not adversely affected by the upgrade.
  • Data Migration Needs: Typically, library upgrades do not require data migration, but verify if any data processing logic is impacted.
  • Required Test Coverage: Ensure that your test coverage meets the minimum requirement of 75%, focusing on areas affected by the library upgrade.
  • Best Practices for Deployment Sequencing: Deploy the change in a lower environment first, monitor for issues, and then proceed to higher environments following a phased approach.

@anuragoyar
Copy link

Potential Risks and Suggestions:
1.
File: codegen1/requirements.txt
Code Snippet: +transformers==4.36.0
Comment: Upgrading the transformers library from version 4.30.0 to 4.36.0 may introduce breaking changes or deprecations. Ensure that all dependent code is compatible with the new version. Review the release notes for the transformers library to identify any significant changes that could impact your application.

Summary:

  1. Summary of Changes:

    • Components: Python dependencies
    • Types: Version upgrade for the transformers library
    • Number of Changes: 1 (upgrade from version 4.30.0 to 4.36.0)
  2. Potential Risks or Missing Dependencies:

    • Compatibility: The upgrade of the transformers library might introduce breaking changes or deprecations that could affect existing functionality.
    • Dependencies: Ensure that other dependencies that rely on transformers are compatible with the new version.
    • Testing: Verify that all tests pass with the new version of the transformers library to ensure there are no regressions.
  3. Suggestions to Improve Safety or Rollback Planning:

    • Compatibility Check: Review the release notes for transformers version 4.36.0 to identify any breaking changes or deprecations.
    • Testing: Run the full suite of automated tests to ensure compatibility and stability with the new version.
    • Rollback Plan: Have a rollback plan in place to revert to the previous version (4.30.0) if any issues are encountered after deployment.
  4. Suitability for Production Deployment:

    • Impact on Existing Integrations: Ensure that all integrations dependent on the transformers library are tested and validated with the new version.
    • Data Migration Needs: No data migration is needed for this change.
    • Required Test Coverage: Ensure that the test coverage is at least 75% and that all critical paths are tested.
    • Best Practices for Deployment Sequencing: Deploy the change in a staging environment first, validate the functionality, and then proceed to production deployment if no issues are found.

Overall, this change is suitable for production deployment provided that thorough testing is conducted to ensure compatibility and stability with the new version of the transformers library.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants