-
Notifications
You must be signed in to change notification settings - Fork 644
Open
Description
A v0 would be allowing users to instantiate the logits processor ThinkingLogitsProcessor with the end of thinking token and pass it to the generator.
model = ...
logits_processor = ThinkingLogitsProcessor("</think>", output_type)
generator = Generator(model, processor=logits_processor)The implementation is simple:
- While
</think>has not been observed,__call__is a pass-through. - After
<think>has been generated, mask the logits to generate the type passed by the user.
torchss, TheooJ, CrustyCode and lsb
Metadata
Metadata
Assignees
Labels
No labels