Answers.Body: <p>Send an UCI command <code>Skill Level</code>. Something like <code>setoption name Skill Level value 10</code>.</p>
  <p>EDIT:</p>
  <p><a href="https://python-chess.readthedocs.io/en/v0.25.0/uci.html" rel="nofollow noreferrer">https://python-chess.readthedocs.io/en/v0.25.0/uci.html</a>. Please look at <code>setoption</code>.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-03-15T16:57:25.797Z
Answers.Text: HI. Yes i know that syntax but i dont know how implement it on python chess. :-(
Answers.UserDisplayName: 9acca9
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-03-15T17:11:09.787Z
Answers.Text: Updated. Please give a try.
Answers.UserDisplayName: SmallChess
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-03-15T16:26:00.250Z
Answers.LastActivityDate: 2021-03-15T17:01:29.173Z
Answers.LastEditDate: 2021-03-15T17:01:29.173Z
Answers.UserDisplayName: SmallChess
Answers.Body: <p>Thanks.
  With this syntax you can set the skill level:</p>
  <pre><code>engine.configure({&quot;Skill Level&quot;: 7})
  </code></pre>
  <p><a href="https://python-chess.readthedocs.io/en/latest/engine.html#options" rel="nofollow noreferrer">https://python-chess.readthedocs.io/en/latest/engine.html#options</a></p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-03-16T16:40:08.793Z
Answers.LastActivityDate: 2021-03-16T16:40:08.793Z
Answers.UserDisplayName: 9acca9
Answers.Body: <p>The simplest way I can think of is through a dilution method. You either get a weaker chess AI that you have created yourself or someone else has created and use that bot to dilute the stockfish bot.</p>
  <p>for example a 35% stockfish 12 (~3500 elo) and 65% my custom chess ai (~1500 elo) would theoretically be 0.35 * 3500 + 0.65 * 1500 elo or 2200. This is just an estimate of level as chess elo progression isn't linear (i.e the difference between a 1000 and 1200 isn't the same as a 2000 and 2200)</p>
  <p>The way the dilution occurs is by randomly picking which bot will make which moves. So 35% of moves will be made by stockfish 12 and 65% will be made by my bot.</p>
  <p>if you want to increase or decrease the difficulty just adjust the the concentration of the two bots.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2021-03-15T20:55:47.783Z
Answers.LastActivityDate: 2021-03-15T20:55:47.783Z
Answers.UserDisplayName: ALK003
Body: <p>I'm using this library and I couldn't find how to modify that value (skill).
  In any case, what I want is to be able to vary the level of difficulty of stockfish using python chess.</p>
  
Tags: <stockfish>
Title: How to modify stockfish "skill" with python chess
ThreadText: # How to modify stockfish "skill" with python chess
  
  (Asked by: username_0 on 2021-03-15)
  
  I'm using this library and I couldn't find how to modify that value (skill).
  In any case, what I want is to be able to vary the level of difficulty of stockfish using python chess.
  
  **Tags:** stockfish
  
  
  ---
  
  ## 3 answers
  
  ### Answer by username_1 on 2021-03-15. Score: 2
  
  Send an UCI command `Skill Level`. Something like `setoption name Skill Level value 10`.
  
  EDIT:
  
  <https://python-chess.readthedocs.io/en/v0.25.0/uci.html>. Please look at `setoption`.
  
  > **Comments:**
  > **username_0**: HI. Yes i know that syntax but i dont know how implement it on python chess. :-(  
  > **username_1**: Updated. Please give a try.  
  
  ---
  
  ### Answer by username_0 on 2021-03-16. Score: 2
  
  Thanks.
  With this syntax you can set the skill level:
  engine.configure({"Skill Level": 7})
  
  https://python-chess.readthedocs.io/en/latest/engine.html#options
  
  
  ---
  
  ### Answer by username_2 on 2021-03-15. Score: 1
  
  The simplest way I can think of is through a dilution method. You either get a weaker chess AI that you have created yourself or someone else has created and use that bot to dilute the stockfish bot.
  
  for example a 35% stockfish 12 (~3500 elo) and 65% my custom chess ai (~1500 elo) would theoretically be 0.35 \* 3500 + 0.65 \* 1500 elo or 2200. This is just an estimate of level as chess elo progression isn't linear (i.e the difference between a 1000 and 1200 isn't the same as a 2000 and 2200)
  
  The way the dilution occurs is by randomly picking which bot will make which moves. So 35% of moves will be made by stockfish 12 and 65% will be made by my bot.
  
  if you want to increase or decrease the difficulty just adjust the the concentration of the two bots.
  
  
  ---
  
  