Skip to content

fix bug with all caps tokens - #96

Open
chellipse wants to merge 1 commit into
shssoichiro:masterfrom
chellipse:master
Open

fix bug with all caps tokens#96
chellipse wants to merge 1 commit into
shssoichiro:masterfrom
chellipse:master

Conversation

@chellipse

Copy link
Copy Markdown

previously tokens where all letters are uppercase but the string contains chars where char::is_uppercase isn't true (ie numbers or w/e) would get scored an incorrectly low variations number by uppercase_variations due to passing a token to n_ck which it isn't designed to score correctly.

here are calculated guess numbers for test tokens i used while confirming behavior.
before:

"alice123" => 15100
"ALICE123" => 2

after:

"alice123" => 15100
"ALICE123" => 20200

fix was mirrored to uppercase_variations_log10 as well, and a test was added

@kilo-code-bot

kilo-code-bot Bot commented Jul 22, 2026

Copy link
Copy Markdown

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Files Reviewed (1 file)
  • src/scoring.rs

Reviewed by kimi-k2.7-code · Input: 34.1K · Output: 6.4K · Cached: 107.5K

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant