Skip to main content

Word puzzle solver library and CLI

Project description

Wordle Solver

This project provides a Wordle solver that can be used as a command-line interface (CLI) tool or imported as a module in your Python code. SOWPODS is used as lexicon.

Suggests new words that are most likely to reduce the total results. Can filter current list of words with

Installation

PyPI

pip install fwordlesolver

Manually

Clone the repository and navigate to the project directory:

git clone https://github.com/fmakdemir/fwordlesolver.git
cd fwordlesolver

Install Poetry if you haven't already. You can find the installation guide here.

Install the required dependencies using Poetry:

poetry install

Usage

Running as CLI

You can run the Wordle solver from the command line. Use the following command:

poetry run f-wordle-solver --word-size 6

You can select the size of the word with

Importing and Using the Solver

You can also import the solver into your Python code:

from fwordlesolver.solver import WordleSolver

solver = WordleSolver(6)
print(solver.get_suggestions())

solver.filter_word('blinks', '.x..x.')
print(solver.get_suggestions())

Running Tests

This package uses pytest for running tests.

To run the tests, use the following command:

pytest

This will execute all the test cases in the tests directory.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fwordlesolver-0.3.3.tar.gz (698.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fwordlesolver-0.3.3-py3-none-any.whl (698.0 kB view details)

Uploaded Python 3

File details

Details for the file fwordlesolver-0.3.3.tar.gz.

File metadata

  • Download URL: fwordlesolver-0.3.3.tar.gz
  • Upload date:
  • Size: 698.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.0.1 CPython/3.9.21 Linux/6.8.0-1020-azure

File hashes

Hashes for fwordlesolver-0.3.3.tar.gz
Algorithm Hash digest
SHA256 cb5c70dc5bb025fdb23cd19fda48411dc4f099c959a05268bd85094c499286fe
MD5 881ed811c46cfec91d6712ce8a4e5638
BLAKE2b-256 a25562dd26bd2590118b8b2d35670277b0c0f76aecf7e47b58d71766e5acf7d7

See more details on using hashes here.

File details

Details for the file fwordlesolver-0.3.3-py3-none-any.whl.

File metadata

  • Download URL: fwordlesolver-0.3.3-py3-none-any.whl
  • Upload date:
  • Size: 698.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.0.1 CPython/3.9.21 Linux/6.8.0-1020-azure

File hashes

Hashes for fwordlesolver-0.3.3-py3-none-any.whl
Algorithm Hash digest
SHA256 ed7fd63603bfe68a9ba18090b01e4915a969daa3869794b7b1a58b5c47d30998
MD5 7bea67c8158e228a69718e984f08ccf7
BLAKE2b-256 1e0a2dce77a6a304c5d51ea9935bf98242a1e4ca9e17e96f4c37a69a509f0760

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page