I stupid : FastBuffers is the same as FlatBuffers (google was correcting my 
typos ;) ) 

Additional thoughts. If JSON is preferred using an XGID like is preferable 
because it is a single string. Something like this:

{
"type”:"EvalRequest",
"id":"yz234",
"noise":0.05,
"cubeful":true,  
"gammons":"on",
"backgammons":"on",
"noOfMoves":"3",
"ply":2,
  "position": {
    "whosOn":"red",
    "usecube":true,
    "crawford":true,
    "jacoby":true,    
    "dice":  { "red":1, "green":2},    
    "score": { "red":0, "green":0},        
    "board" : {
      "cube":2, 
      "cubeowner":"green",      
      "points": [2,0,0,0,0,-5,0,-4,0,0,0,5,-4,0,0,0,3,0,5,-1,0,0,0,-1]
    }
  }
}

would be slower and bigger. For protocol buffers/Fory/FlatBuffers it would much 
make less difference.

If several request can come over one connection, encoding things like ply, 
noise or cubeful should be set in every request otherwise things like

Host-Thread 1
   setSearchDepth 2   
   eval xy

Host-Thread 2 
   setSearchDepth 3   
   eval yz

could be executed on the AI in this order:
   setSearchDepth 2   
   setSearchDepth 3   
   eval xy
   eval yz

which is clearly not intended. Here it doesn’t matter much but if it is noise 
(useful for a bot) the evaluation or analysis  might be affected and not the 
intended move.

best
Frank
 

Reply via email to