class documentation
class TokenVersionExtractor(ABC): (source)
Known subclasses: nebius.base.token_sanitizer.DefaultTokenVersionExtractor
Abstract base class for extracting token version from a token string.
Subclasses must implement the extract method to identify the token format and return the corresponding TokenVersion along with recognition status.
| Method | extract |
Extract the token version from a token string. |
overridden in
nebius.base.token_sanitizer.DefaultTokenVersionExtractorExtract the token version from a token string.
| Parameters | |
token:str | The token string to analyze. |
| Returns | |
tuple[ | A tuple containing the TokenVersion and a boolean indicating whether the token was recognized. |