Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion codeflash/code_utils/code_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
def encoded_tokens_len(s: str) -> int:
'''Function for returning the approximate length of the encoded tokens
It's an approximation of BPE encoding (https://cdn.openai.com/better-language-models/language_models_are_unsupervised_multitask_learners.pdf)'''
return len(s)//2
return int(len(s)*0.3)

def get_qualified_name(module_name: str, full_qualified_name: str) -> str:
if not full_qualified_name:
Expand Down
Loading