@@ -1646,12 +1646,18 @@ Create a new instance of TransformersGenerator from an already loaded model and
16461646 (` Any ` )
16471647 –The loaded model for text generation.
16481648* ** ` tokenizer ` **
1649+ (` AutoTokenizer ` )
16491650 –The tokenizer associated with the model.
16501651* ** ` pipeline ` **
16511652 (` TextGenerationPipeline | None ` , default:
16521653 ` None `
16531654 )
16541655 –The text generation pipeline. Defaults to None.
1656+ * ** ` params ` **
1657+ (` GenerateParams | None ` , default:
1658+ ` None `
1659+ )
1660+ –Generation parameters. Defaults to None.
16551661
16561662** Returns:**
16571663
@@ -1674,8 +1680,9 @@ def from_obj(
16741680
16751681 Args:
16761682 model: The loaded model for text generation.
1677- tokenizer : The tokenizer associated with the model.
1683+ tokenizer: The tokenizer associated with the model.
16781684 pipeline: The text generation pipeline. Defaults to None.
1685+ params: Generation parameters. Defaults to None.
16791686
16801687 Returns:
16811688 The TransformersGenerator instance.
@@ -2491,12 +2498,18 @@ Create a new instance of TransformersGenerator from an already loaded model and
24912498 (` Any ` )
24922499 –The loaded model for text generation.
24932500* ** ` tokenizer ` **
2501+ (` AutoTokenizer ` )
24942502 –The tokenizer associated with the model.
24952503* ** ` pipeline ` **
24962504 (` TextGenerationPipeline | None ` , default:
24972505 ` None `
24982506 )
24992507 –The text generation pipeline. Defaults to None.
2508+ * ** ` params ` **
2509+ (` GenerateParams | None ` , default:
2510+ ` None `
2511+ )
2512+ –Generation parameters. Defaults to None.
25002513
25012514** Returns:**
25022515
@@ -2519,8 +2532,9 @@ def from_obj(
25192532
25202533 Args:
25212534 model: The loaded model for text generation.
2522- tokenizer : The tokenizer associated with the model.
2535+ tokenizer: The tokenizer associated with the model.
25232536 pipeline: The text generation pipeline. Defaults to None.
2537+ params: Generation parameters. Defaults to None.
25242538
25252539 Returns:
25262540 The TransformersGenerator instance.
0 commit comments