(self, stop_indices: list)
| 5 | class StopWordsCriteria(StoppingCriteria): |
| 6 | |
| 7 | def __init__(self, stop_indices: list): |
| 8 | self.stop_indices = stop_indices |
| 9 | |
| 10 | def __call__(self, input_ids: torch.LongTensor, scores: torch.FloatTensor, **kwargs) -> bool: |
| 11 | # do not support batch inference |
nothing calls this directly
no outgoing calls
no test coverage detected