MCPcopy Create free account
hub / github.com/Paper2Poster/Paper2Poster / token_counter

Method token_counter

camel/models/model_manager.py:130–137  ·  view source on GitHub ↗

r"""Return token_counter of the current model. Returns: BaseTokenCounter: The token counter following the model's tokenization style.

(self)

Source from the content-addressed store, hash-verified

128
129 @property
130 def token_counter(self) -> BaseTokenCounter:
131 r"""Return token_counter of the current model.
132
133 Returns:
134 BaseTokenCounter: The token counter following the model's
135 tokenization style.
136 """
137 return self.current_model.token_counter
138
139 def add_strategy(self, name: str, strategy_fn: Callable):
140 r"""Add a scheduling strategy method provided by user in case when none

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected