Skip to content

Commit c9dc6ed

Browse files
committed
Black formatting
1 parent 50d470b commit c9dc6ed

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

bin/benchmark_solver.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@ def test_solver_with_first_guess(first_guess: str) -> Dict:
3939

4040

4141
def test_first_guesses(
42-
start_idx: int = 0, num_workers: Optional[int] = None,
42+
start_idx: int = 0,
43+
num_workers: Optional[int] = None,
4344
) -> Iterator[Dict]:
4445
words = sorted(load_words())[start_idx:]
4546
if num_workers is None or num_workers > 1:

wordle/solver.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def _word_prob(word: str, options: Tuple[str, ...]) -> float:
4949
permutations = [perm(counts[c]) for c in word]
5050

5151
return prod(
52-
pp * op / ps ** 2
52+
pp * op / ps**2
5353
for pp, op, ps in zip(positional_probs, overall_probs, permutations)
5454
)
5555

@@ -86,7 +86,8 @@ def __init__(self, mode: str = "hybrid"):
8686
def recommend(self, max_alternatives: int = 5) -> WordRecommendations:
8787
if len(self.words) == len(load_words()):
8888
return WordRecommendations(
89-
recommended="blast", alternatives=["ralph", "tapir", "slate"],
89+
recommended="blast",
90+
alternatives=["ralph", "tapir", "slate"],
9091
)
9192
if self.mode == "hybrid":
9293
self.words = _rank_by_hybrid_approach(self.words)

0 commit comments

Comments
 (0)