UNPKG

@gueripep/wordle-solver

Version:

A Wordle solver using entropy maximization and information theory

55 lines 1.18 kB
import type { GuessFeedback } from '../core/types.js'; export interface GameState { solution: string; attempts: Array<{ guess: string; feedback: GuessFeedback; isCorrect: boolean; }>; isComplete: boolean; isWon: boolean; maxAttempts: number; } export declare class InteractiveWordleGame { private rl; private gameState; private wordList; constructor(solution: string, maxAttempts?: number); /** * Start the interactive game */ play(): Promise<GameState>; /** * Play a single turn */ private playTurn; /** * Get a guess from the player */ private getGuess; /** * Process a valid guess */ private processGuess; /** * Display all previous attempts */ private displayAttempts; /** * Provide an AI hint */ private provideHint; /** * Celebrate a win */ private celebrateWin; /** * Reveal the solution when the game is lost */ private revealSolution; /** * Get the current game state */ getGameState(): GameState; } //# sourceMappingURL=interactive-game.d.ts.map