Runner#

class FlagEmbedding.finetune.reranker.decoder_only.base.DecoderOnlyRerankerRunner(model_args: RerankerModelArguments, data_args: AbsRerankerDataArguments, training_args: AbsRerankerTrainingArguments)[source]#

Decoder only reranker runner for finetuning.

Parameters:
load_tokenizer_and_model() Tuple[PreTrainedTokenizer, AbsRerankerModel][source]#

Load the tokenizer and model.

Returns:

Tokenizer and model instances.

Return type:

Tuple[PreTrainedTokenizer, AbsEmbedderModel]

load_trainer() DecoderOnlyRerankerTrainer[source]#

Load the trainer.

Returns:

Loaded trainer instance.

Return type:

DecoderOnlyRerankerTrainer

run()[source]#

Run the finetuning.