-
© Team ISCube, Kota, Hidetchi. All rights reserved.
-
Ruby 2.0~
-
Rails 4
-
IMPORTANT!! Change sfen column in positions table to be case sensitive: ALTER TABLE positions MODIFY sfen VARCHAR(255) CHARACTER SET utf8 COLLATE ctf8_bin
-
Run
rake db:seed
to insert initial data for GameSources, Handicaps, and initial Strategies and Positions. -
Kifu for statistics: Run script files in db/script (Set ‘pass’ column in GameSource table first.)
** 81Dojo: Run PHP script in 81dojo.com, then post the generaed file with register_***.rb ** Floodgate: Download kifu from official site, then run ***2csv.rb. Then post the generated file with register_***.rb ** FamousGames: Download kifu, then run ***2csv.rb. Then post the generated file with register_***.rb
-
Open config/initializers/asin.rb and set your Amazon AWS key
-
Open config/initializers/twitter.rb and set your Twitter app key and bot’s login key
-
Install ImageMagick to enable simple-captcha
-
Move some of the image files directly to public/assets/ to avoid linking failure, which happens when the file name is specified directly in CSS file or Helper functions.
-
Create an account and set user.role=2 to become Admin
-
Run
bin/delayed_jobs start
-
81Dojo
** Upload function is implemented on 81Dojo side. ** In rails c, Kifu.update_kyokumenpedia(‘2017-01-01’, ‘2017-02-01’) for example tests loading valid kifus in whole January. ** Then Kifu.update_kyokumenpedia(‘2017-01-01’, ‘2017-02-01’, false) really posts to Kyokumenpedia. ** The condition for a player to be valid for the upload is defined in Player.valid_for_kyokumenpedia? (Originally it was 4-Dan or higher, but now changed to 5-Dan or higher) Number of matching kifus should be less thant 5000 games per year.
-
Floodgate
** First create csv file containing all kifus to be uploaded. This procedure should be down in the following process on a local computer. ** Download yearly 7z file from wdoor.c.u-tokyo.ac.jp/shogi/ and unzip. ** Edit Kyokumenpedia/db/script/floodgate2csv.rb to have the player names that you want to consider valid. To do this, see wdoor.c.u-tokyo.ac.jp/shogi/logs/LATEST/players-floodgate.html and pick-up only high-rated names. (originally it was above 2600 but changed to 3000) Number of matching kifus should be less than 5000 games per year. ** After CSV file is made, move it to kyokumen.jp server, and run db/script/register_csv_floodgate.rb ** Update must be done yearly at longest, as the rating list keeps being more and more different from the players who played games several years ago.
-
FamousGames
** Shogidb2Entry model stores all hashes of shogidb2. Result=nil means it has not been registered to Game model yet. ** Shogidb2Entry.load_from_origin loads new hashes, and then registers to Game model. This runs by Whenever gem. ** Run rails runner -e production db/script/update_relations.rb manually to update positions-moves-games relation. Before doing this, check new Game data by tp Game.where(relation_update:false)
-
Restart bin/delayed_job with cron
-
Run Position.reduce_views_count occasionally