Informatik Student, lerne 日本語, Strategiespiele

  • 1 Post
  • 11 Comments
Joined 2 years ago
cake
Cake day: June 12th, 2023

help-circle


  • I’ve started building a wordle-analyzer. I got nerdsniped, and now I’m implementing the game (already did a game and a cli implementation using the abstracted interface) and a solver.

    The idea is to provide:

    • game - a wordle game that can be used to implement the game in many frontends, a cli version and exists already
    • solver - something that can solve the game
    • wordlist - any wordlist people might want.
    • bench - if you want to know how good your solver is

    I’m providing built-in versions, but anyone could implement the traits.

    I currently have two solver implementations;

    • stupid - literally tries words at random
    • naive - checks which letters matched and reuse them, require letters that are included but not matched in other words, then use the most common word that matches

    The naive solver can actually solve the game in less then 10 steps most of the time. Mathematically, the optimum is about 3,4 steps. There are two amazing 3blue1brown videos going into details, and my eventual goal is implementing solvers making use of that math.

    I’ve been using generics and traits like never before for that project. Solver? It’s a trait. Game? It’s a trait. Word lists? It’s a trait.

    And all my structs have generics <'wl, WL> so that I only need to have the word list once to save resources. You get a little crazy from the lifetime errors but it’s fun.

    Besides that, my homeserver got janky this month, and today I started migrating it to proxmox. It’s hard, because I need to do a lot more thinking than just docker go brr now.

    In case you want to check my wordle-analyzer out: https://git.cscherr.de/PlexSheep/wordle-analyzer I need to update the readme before publishing.










  • Earlier today I thought about making a post asking about a design choice for one of my pet projects, but then i thought: Is that really relevant?

    There is a lot of generally informative content here, like the talks or blog entries, so I thought it didn’t quite fit. Maybe we should start just sharing thoughts on our pet projects and design choices?

    I’m building something that will help me create releases for projects on git servers, publish crates, generate change logs and so on. Up to now I was using git2 as a dependency and pushing, tagging and so on with the API, but then I thought “maybe I can just use the cli interface of git”, reducing the dependency chain of my crate and not having to worry about finding the right API calls. I’m not sure what the better choice would be. (I’m only using porcelain commands, for now)