AOSSIE-Org / AOSSIE-Org/EduAid

Update deprecated pad_to_max_length argument in tokenization pipeline

オープン
#511 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
JavaScript
スター
171
フォーク
423
PR マージ指標
30日以内にマージされた PR はありません

説明

## Description

While running EduAid locally, warnings appear from the HuggingFace Transformers library related to deprecated parameters used in the tokenization pipeline.

The following warning is shown during execution:

FutureWarning: The `pad_to_max_length` argument is deprecated and will be removed in future versions.

The current implementation uses:

pad_to_max_length=True

This parameter has been deprecated and should be replaced with the newer argument format recommended by the Transformers library.

## Expected Behavior

Tokenization should use the updated padding parameter recommended by the Transformers library.

## Current Behavior

The code currently uses deprecated arguments which trigger warnings during execution.

## Proposed Improvement

Replace the deprecated parameter:

pad_to_max_length=True

with the updated format:

padding='max_length'

This will align the codebase with the latest Transformers API.

## Benefits

• removes deprecation warnings
• ensures compatibility with future Transformers versions
• improves long-term maintainability of the codebase

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。