package com.fribbels.core;

import com.fribbels.enums.Set;
import com.fribbels.enums.StatType;
import com.fribbels.handler.OptimizationRequestHandler;
import com.fribbels.model.AugmentedStats;
import com.fribbels.model.HeroStats;
import com.fribbels.request.OptimizationRequest;
import com.google.gson.Gson;
import org.apache.commons.lang3.StringUtils;
import org.bytedeco.javacpp.BytePointer;
import org.bytedeco.leptonica.PIX;
import org.bytedeco.tesseract.TessBaseAPI;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.Comparator;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
import java.util.stream.Stream;

import static org.bytedeco.leptonica.global.lept.pixDestroy;
import static org.bytedeco.leptonica.global.lept.pixRead;

public class OptimizationRequestHandlerTest {

    private OptimizationRequestHandler handler;
    // Basic
//    private static final String REQUEST_STRING = "{\"base\":{\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5},\"requestType\":\"OptimizationRequest\",\"extraField\":\"asdf\",\"items\":[{\"gear\":\"Weapon\",\"rank\":\"Normal\",\"set\":\"CriticalSet\",\"level\":30,\"enhance\":0,\"main\":{\"type\":\"Attack\",\"value\":40},\"substats\":[],\"name\":\"Rapier\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":40},\"id\":0},{\"gear\":\"Weapon\",\"rank\":\"Good\",\"set\":\"SpeedSet\",\"level\":44,\"enhance\":0,\"main\":{\"type\":\"Attack\",\"value\":57},\"substats\":[{\"type\":\"Speed\",\"value\":2}],\"name\":\"ImperialLongsword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":57,\"Speed\":2},\"id\":1},{\"gear\":\"Weapon\",\"rank\":\"Rare\",\"set\":\"DestructionSet\",\"level\":85,\"enhance\":0,\"main\":{\"type\":\"Attack\",\"value\":100},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":4},{\"type\":\"Health\",\"value\":148}],\"name\":\"HellishEssenceOrb\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":100,\"EffectResistancePercent\":4,\"Health\":148},\"id\":2},{\"gear\":\"Weapon\",\"rank\":\"Rare\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":3,\"main\":{\"type\":\"Attack\",\"value\":160},\"substats\":[{\"type\":\"AttackPercent\",\"value\":4},{\"type\":\"Speed\",\"value\":4}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":160,\"AttackPercent\":4,\"Speed\":4},\"id\":3},{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":3,\"main\":{\"type\":\"Attack\",\"value\":160},\"substats\":[{\"type\":\"Health\",\"value\":159},{\"type\":\"CriticalHitDamagePercent\",\"value\":13},{\"type\":\"Speed\",\"value\":4}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":160,\"Health\":159,\"CriticalHitDamagePercent\":13,\"Speed\":4},\"id\":4},{\"gear\":\"Weapon\",\"rank\":\"Rare\",\"set\":\"RageSet\",\"level\":85,\"enhance\":6,\"main\":{\"type\":\"Attack\",\"value\":220},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":5},{\"type\":\"Speed\",\"value\":10}],\"name\":\"IndomitableSpiderMace\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":220,\"CriticalHitDamagePercent\":5,\"Speed\":10},\"id\":5},{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"HitSet\",\"level\":85,\"enhance\":7,\"main\":{\"type\":\"Attack\",\"value\":240},\"substats\":[{\"type\":\"Speed\",\"value\":8},{\"type\":\"EffectResistancePercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":4}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":240,\"Speed\":8,\"EffectResistancePercent\":14,\"CriticalHitChancePercent\":4},\"id\":6},{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"UnitySet\",\"level\":85,\"enhance\":9,\"main\":{\"type\":\"Attack\",\"value\":280},\"substats\":[{\"type\":\"AttackPercent\",\"value\":11},{\"type\":\"Speed\",\"value\":8},{\"type\":\"EffectivenessPercent\",\"value\":12}],\"name\":\"IndomitableSpiderMace\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":280,\"AttackPercent\":11,\"Speed\":8,\"EffectivenessPercent\":12},\"id\":7},{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"HitSet\",\"level\":85,\"enhance\":10,\"main\":{\"type\":\"Attack\",\"value\":300},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":3},{\"type\":\"Speed\",\"value\":9},{\"type\":\"CriticalHitDamagePercent\",\"value\":14}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":300,\"CriticalHitChancePercent\":3,\"Speed\":9,\"CriticalHitDamagePercent\":14},\"id\":8},{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":12,\"main\":{\"type\":\"Attack\",\"value\":360},\"substats\":[{\"type\":\"Speed\",\"value\":10},{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"Health\",\"value\":187},{\"type\":\"EffectResistancePercent\",\"value\":7}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":360,\"Speed\":10,\"CriticalHitChancePercent\":8,\"Health\":187,\"EffectResistancePercent\":7},\"id\":9},{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":13,\"main\":{\"type\":\"Attack\",\"value\":390},\"substats\":[{\"type\":\"AttackPercent\",\"value\":15},{\"type\":\"HealthPercent\",\"value\":10},{\"type\":\"Speed\",\"value\":2},{\"type\":\"Health\",\"value\":155}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":390,\"AttackPercent\":15,\"HealthPercent\":10,\"Speed\":2,\"Health\":155},\"id\":10},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":67,\"enhance\":5,\"main\":{\"type\":\"Health\",\"value\":918},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"CriticalHitChancePercent\",\"value\":4},{\"type\":\"Attack\",\"value\":33},{\"type\":\"DefensePercent\",\"value\":5}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":918,\"HealthPercent\":6,\"CriticalHitChancePercent\":4,\"Attack\":33,\"DefensePercent\":5},\"id\":11},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"CounterSet\",\"level\":85,\"enhance\":13,\"main\":{\"type\":\"Defense\",\"value\":234},\"substats\":[{\"type\":\"EffectivenessPercent\",\"value\":12},{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"CriticalHitDamagePercent\",\"value\":11}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":234,\"EffectivenessPercent\":12,\"DefensePercent\":14,\"HealthPercent\":11,\"CriticalHitDamagePercent\":11},\"id\":12},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":67,\"enhance\":10,\"main\":{\"type\":\"Defense\",\"value\":150},\"substats\":[{\"type\":\"Speed\",\"value\":2},{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"DefensePercent\",\"value\":21},{\"type\":\"CriticalHitChancePercent\",\"value\":2}],\"name\":\"ArahakansChestplate\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":150,\"Speed\":2,\"HealthPercent\":6,\"DefensePercent\":21,\"CriticalHitChancePercent\":2},\"id\":13},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":7,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":31},\"substats\":[{\"type\":\"Attack\",\"value\":35},{\"type\":\"EffectResistancePercent\",\"value\":17},{\"type\":\"CriticalHitChancePercent\",\"value\":3},{\"type\":\"Speed\",\"value\":3}],\"name\":\"Corselium\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":31,\"Attack\":35,\"EffectResistancePercent\":17,\"CriticalHitChancePercent\":3,\"Speed\":3},\"id\":14},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"LifestealSet\",\"level\":57,\"enhance\":13,\"main\":{\"type\":\"AttackPercent\",\"value\":31},\"substats\":[{\"type\":\"HealthPercent\",\"value\":10},{\"type\":\"Speed\",\"value\":2},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"EffectivenessPercent\",\"value\":15}],\"name\":\"BloodBeastsRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":31,\"HealthPercent\":10,\"Speed\":2,\"CriticalHitChancePercent\":7,\"EffectivenessPercent\":15},\"id\":15}],\"inputAllowLockedItems\":false,\"inputAllowEquippedItems\":false,\"inputKeepCurrentItems\":false,\"inputNecklaceStat\":\"Cd\",\"inputRingStat\":\"Atk\",\"inputBootsStat\":\"Speed\",\"inputSetOne\":\"Speed\",\"inputSetTwo\":\"HP\",\"inputSetThree\":\"HP\",\"inputAllowBrokenSets\":false,\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5}";
    // 420 set
    private static final String REQUEST_STRING = "{\"base\":{\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5},\"requestType\":\"OptimizationRequest\",\"extraField\":\"asdf\",\"items\":[{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"HealthSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":27},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"Health\",\"value\":178}],\"name\":\"DarkSteelSaber\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"EffectivenessPercent\":4,\"HealthPercent\":27,\"AttackPercent\":14,\"Health\":178},\"id\":0},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":515},\"substats\":[{\"type\":\"Health\",\"value\":214},{\"type\":\"HealthPercent\",\"value\":25},{\"type\":\"CriticalHitDamagePercent\",\"value\":4},{\"type\":\"Speed\",\"value\":9}],\"name\":\"ArahakansFang\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":515,\"Health\":214,\"HealthPercent\":25,\"CriticalHitDamagePercent\":4,\"Speed\":9},\"id\":1},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"RageSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"AttackPercent\",\"value\":10},{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"ThornVineWhip\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"AttackPercent\":10,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":2},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":6},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":7}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"CriticalHitDamagePercent\":15,\"Speed\":6,\"CriticalHitChancePercent\":10,\"AttackPercent\":7},\"id\":3},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"EffectResistancePercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":20}],\"name\":\"ManaDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"CriticalHitChancePercent\":6,\"CriticalHitDamagePercent\":11,\"EffectResistancePercent\":12,\"AttackPercent\":20},\"id\":4},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":11},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"Speed\",\"value\":3}],\"name\":\"RoseCoronet\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"HealthPercent\":12,\"AttackPercent\":11,\"DefensePercent\":18,\"Speed\":3},\"id\":5},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2700},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":9},{\"type\":\"HealthPercent\",\"value\":26}],\"name\":\"AbyssDrakeMask\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2700,\"CriticalHitChancePercent\":6,\"AttackPercent\":4,\"EffectivenessPercent\":9,\"HealthPercent\":26},\"id\":6},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"HealthPercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"GladiatorsHelmofVictory\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"HealthPercent\":17,\"DefensePercent\":14,\"Speed\":6,\"EffectResistancePercent\":6},\"id\":7},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"AttackPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"TerrariaHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"AttackPercent\":13,\"Speed\":9,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":8},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Defense\",\"value\":34},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"HealthPercent\",\"value\":31}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"DefensePercent\":7,\"Defense\":34,\"AttackPercent\":14,\"HealthPercent\":31},\"id\":9},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2295},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":7}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2295,\"HealthPercent\":6,\"CriticalHitDamagePercent\":10,\"AttackPercent\":14,\"CriticalHitChancePercent\":7},\"id\":10},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":260},\"substats\":[{\"type\":\"HealthPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"CriticalHitDamagePercent\",\"value\":6}],\"name\":\"AncientShandranWarriorsArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":260,\"HealthPercent\":13,\"Speed\":12,\"CriticalHitChancePercent\":8,\"CriticalHitDamagePercent\":6},\"id\":11},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"DefensePercent\",\"value\":21},{\"type\":\"Speed\",\"value\":10},{\"type\":\"CriticalHitChancePercent\",\"value\":4}],\"name\":\"AzimanusFightersArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"HealthPercent\":12,\"DefensePercent\":21,\"Speed\":10,\"CriticalHitChancePercent\":4},\"id\":12},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"CriticalHitDamagePercent\",\"value\":11}],\"name\":\"ArahakansChestplate\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"CriticalHitChancePercent\":8,\"DefensePercent\":12,\"HealthPercent\":11,\"CriticalHitDamagePercent\":11},\"id\":13},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"CriticalHitDamagePercent\":9,\"CriticalHitChancePercent\":9,\"DefensePercent\":12,\"EffectivenessPercent\":18},\"id\":14},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":13},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":13,\"EffectivenessPercent\":17},\"id\":15},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":78,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":19}],\"name\":\"ConstellasPearlNecklace\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"DefensePercent\":12,\"CriticalHitChancePercent\":10,\"Speed\":6,\"EffectResistancePercent\":19},\"id\":16},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"EffectivenessPercent\",\"value\":6}],\"name\":\"PendantofLuminescence\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":15,\"Speed\":5,\"CriticalHitChancePercent\":10,\"EffectivenessPercent\":6},\"id\":17},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitChancePercent\",\"value\":45},\"substats\":[{\"type\":\"Speed\",\"value\":13},{\"type\":\"AttackPercent\",\"value\":5},{\"type\":\"HealthPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":13}],\"name\":\"TreasureCollectorsCharm\",\"augmentedStats\":{\"mainType\":\"CriticalHitChancePercent\",\"mainValue\":45,\"Speed\":13,\"AttackPercent\":5,\"HealthPercent\":4,\"EffectivenessPercent\":13},\"id\":18},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"ResistSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":21},{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":5}],\"name\":\"ObsidianAmulet\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"AttackPercent\":14,\"CriticalHitChancePercent\":21,\"EffectivenessPercent\":4,\"HealthPercent\":5},\"id\":19},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"Speed\",\"value\":14},{\"type\":\"Attack\",\"value\":29},{\"type\":\"AttackPercent\",\"value\":6}],\"name\":\"BoldGeneralsNecklace\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"CriticalHitChancePercent\":8,\"Speed\":14,\"Attack\":29,\"AttackPercent\":6},\"id\":20},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"DefensePercent\",\"value\":50},\"substats\":[{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"Speed\",\"value\":11},{\"type\":\"CriticalHitChancePercent\",\"value\":4},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"OathRing\",\"augmentedStats\":{\"mainType\":\"DefensePercent\",\"mainValue\":50,\"HealthPercent\":11,\"Speed\":11,\"CriticalHitChancePercent\":4,\"EffectResistancePercent\":6},\"id\":21},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"LifestealSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"Speed\",\"value\":4},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"GaveleetsRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":12,\"Speed\":4,\"CriticalHitChancePercent\":12,\"EffectivenessPercent\":18},\"id\":22},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"EffectResistancePercent\",\"value\":9}],\"name\":\"LightofaMillion\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":14,\"Speed\":5,\"CriticalHitChancePercent\":7,\"EffectResistancePercent\":9},\"id\":23},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"EffectivenessPercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"CriticalHitDamagePercent\",\"value\":18},{\"type\":\"DefensePercent\",\"value\":19},{\"type\":\"AttackPercent\",\"value\":9}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"EffectivenessPercent\",\"mainValue\":65,\"CriticalHitChancePercent\":9,\"CriticalHitDamagePercent\":18,\"DefensePercent\":19,\"AttackPercent\":9},\"id\":24},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"EffectResistancePercent\",\"value\":50},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"HealthPercent\",\"value\":5},{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Speed\",\"value\":8}],\"name\":\"EmergencyRing\",\"augmentedStats\":{\"mainType\":\"EffectResistancePercent\",\"mainValue\":50,\"CriticalHitDamagePercent\":11,\"HealthPercent\":5,\"DefensePercent\":7,\"Speed\":8},\"id\":25},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":65},\"substats\":[{\"type\":\"Speed\",\"value\":3},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"CriticalHitDamagePercent\",\"value\":21},{\"type\":\"Attack\",\"value\":51}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":65,\"Speed\":3,\"DefensePercent\":18,\"CriticalHitDamagePercent\":21,\"Attack\":51},\"id\":26},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":77,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"CriticalHitDamagePercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"VerdantBoots\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":7,\"CriticalHitChancePercent\":12,\"CriticalHitDamagePercent\":6,\"EffectivenessPercent\":17},\"id\":27},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":35},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":19},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"SocksofSmallMiracles\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":35,\"HealthPercent\":6,\"AttackPercent\":19,\"DefensePercent\":12,\"CriticalHitChancePercent\":8},\"id\":28},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":7},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"Speed\",\"value\":8},{\"type\":\"CriticalHitChancePercent\",\"value\":11}],\"name\":\"AbyssDrakeBoots\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"EffectResistancePercent\":7,\"DefensePercent\":12,\"Speed\":8,\"CriticalHitChancePercent\":11},\"id\":29},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"AttackPercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":14},{\"type\":\"EffectResistancePercent\",\"value\":28},{\"type\":\"HealthPercent\",\"value\":13}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"AttackPercent\":6,\"EffectivenessPercent\":14,\"EffectResistancePercent\":28,\"HealthPercent\":13},\"id\":30},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":17},{\"type\":\"Attack\",\"value\":43},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"EffectResistancePercent\":17,\"DefensePercent\":17,\"Attack\":43,\"CriticalHitChancePercent\":8},\"id\":31}],\"inputAllowLockedItems\":false,\"inputAllowEquippedItems\":false,\"inputKeepCurrentItems\":false,\"inputSets\":[[\"SpeedSet\"],[],[]],\"inputSetsOne\":[\"SpeedSet\",\"DestructionSet\"],\"inputSetsTwo\":[\"HealthSet\",\"ImmunitySet\"],\"inputSetsThree\":[],\"inputAllowBrokenSets\":false,\"setFormat\":1,\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5}";
    // 222 set
//    private static final String REQUEST_STRING = "{\"base\":{\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5},\"requestType\":\"OptimizationRequest\",\"extraField\":\"asdf\",\"items\":[{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"HealthSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":27},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"Health\",\"value\":178}],\"name\":\"DarkSteelSaber\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"EffectivenessPercent\":4,\"HealthPercent\":27,\"AttackPercent\":14,\"Health\":178},\"id\":0},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":515},\"substats\":[{\"type\":\"Health\",\"value\":214},{\"type\":\"HealthPercent\",\"value\":25},{\"type\":\"CriticalHitDamagePercent\",\"value\":4},{\"type\":\"Speed\",\"value\":9}],\"name\":\"ArahakansFang\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":515,\"Health\":214,\"HealthPercent\":25,\"CriticalHitDamagePercent\":4,\"Speed\":9},\"id\":1},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"RageSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"AttackPercent\",\"value\":10},{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"ThornVineWhip\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"AttackPercent\":10,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":2},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":6},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":7}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"CriticalHitDamagePercent\":15,\"Speed\":6,\"CriticalHitChancePercent\":10,\"AttackPercent\":7},\"id\":3},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"EffectResistancePercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":20}],\"name\":\"ManaDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"CriticalHitChancePercent\":6,\"CriticalHitDamagePercent\":11,\"EffectResistancePercent\":12,\"AttackPercent\":20},\"id\":4},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":11},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"Speed\",\"value\":3}],\"name\":\"RoseCoronet\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"HealthPercent\":12,\"AttackPercent\":11,\"DefensePercent\":18,\"Speed\":3},\"id\":5},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2700},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":9},{\"type\":\"HealthPercent\",\"value\":26}],\"name\":\"AbyssDrakeMask\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2700,\"CriticalHitChancePercent\":6,\"AttackPercent\":4,\"EffectivenessPercent\":9,\"HealthPercent\":26},\"id\":6},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"HealthPercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"GladiatorsHelmofVictory\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"HealthPercent\":17,\"DefensePercent\":14,\"Speed\":6,\"EffectResistancePercent\":6},\"id\":7},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"AttackPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"TerrariaHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"AttackPercent\":13,\"Speed\":9,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":8},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Defense\",\"value\":34},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"HealthPercent\",\"value\":31}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"DefensePercent\":7,\"Defense\":34,\"AttackPercent\":14,\"HealthPercent\":31},\"id\":9},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2295},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":7}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2295,\"HealthPercent\":6,\"CriticalHitDamagePercent\":10,\"AttackPercent\":14,\"CriticalHitChancePercent\":7},\"id\":10},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":260},\"substats\":[{\"type\":\"HealthPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"CriticalHitDamagePercent\",\"value\":6}],\"name\":\"AncientShandranWarriorsArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":260,\"HealthPercent\":13,\"Speed\":12,\"CriticalHitChancePercent\":8,\"CriticalHitDamagePercent\":6},\"id\":11},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"DefensePercent\",\"value\":21},{\"type\":\"Speed\",\"value\":10},{\"type\":\"CriticalHitChancePercent\",\"value\":4}],\"name\":\"AzimanusFightersArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"HealthPercent\":12,\"DefensePercent\":21,\"Speed\":10,\"CriticalHitChancePercent\":4},\"id\":12},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"CriticalHitDamagePercent\",\"value\":11}],\"name\":\"ArahakansChestplate\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"CriticalHitChancePercent\":8,\"DefensePercent\":12,\"HealthPercent\":11,\"CriticalHitDamagePercent\":11},\"id\":13},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"CriticalHitDamagePercent\":9,\"CriticalHitChancePercent\":9,\"DefensePercent\":12,\"EffectivenessPercent\":18},\"id\":14},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":13},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":13,\"EffectivenessPercent\":17},\"id\":15},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":78,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":19}],\"name\":\"ConstellasPearlNecklace\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"DefensePercent\":12,\"CriticalHitChancePercent\":10,\"Speed\":6,\"EffectResistancePercent\":19},\"id\":16},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"EffectivenessPercent\",\"value\":6}],\"name\":\"PendantofLuminescence\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":15,\"Speed\":5,\"CriticalHitChancePercent\":10,\"EffectivenessPercent\":6},\"id\":17},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitChancePercent\",\"value\":45},\"substats\":[{\"type\":\"Speed\",\"value\":13},{\"type\":\"AttackPercent\",\"value\":5},{\"type\":\"HealthPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":13}],\"name\":\"TreasureCollectorsCharm\",\"augmentedStats\":{\"mainType\":\"CriticalHitChancePercent\",\"mainValue\":45,\"Speed\":13,\"AttackPercent\":5,\"HealthPercent\":4,\"EffectivenessPercent\":13},\"id\":18},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"ResistSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":21},{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":5}],\"name\":\"ObsidianAmulet\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"AttackPercent\":14,\"CriticalHitChancePercent\":21,\"EffectivenessPercent\":4,\"HealthPercent\":5},\"id\":19},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"Speed\",\"value\":14},{\"type\":\"Attack\",\"value\":29},{\"type\":\"AttackPercent\",\"value\":6}],\"name\":\"BoldGeneralsNecklace\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"CriticalHitChancePercent\":8,\"Speed\":14,\"Attack\":29,\"AttackPercent\":6},\"id\":20},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"DefensePercent\",\"value\":50},\"substats\":[{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"Speed\",\"value\":11},{\"type\":\"CriticalHitChancePercent\",\"value\":4},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"OathRing\",\"augmentedStats\":{\"mainType\":\"DefensePercent\",\"mainValue\":50,\"HealthPercent\":11,\"Speed\":11,\"CriticalHitChancePercent\":4,\"EffectResistancePercent\":6},\"id\":21},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"LifestealSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"Speed\",\"value\":4},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"GaveleetsRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":12,\"Speed\":4,\"CriticalHitChancePercent\":12,\"EffectivenessPercent\":18},\"id\":22},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"EffectResistancePercent\",\"value\":9}],\"name\":\"LightofaMillion\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":14,\"Speed\":5,\"CriticalHitChancePercent\":7,\"EffectResistancePercent\":9},\"id\":23},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"EffectivenessPercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"CriticalHitDamagePercent\",\"value\":18},{\"type\":\"DefensePercent\",\"value\":19},{\"type\":\"AttackPercent\",\"value\":9}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"EffectivenessPercent\",\"mainValue\":65,\"CriticalHitChancePercent\":9,\"CriticalHitDamagePercent\":18,\"DefensePercent\":19,\"AttackPercent\":9},\"id\":24},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"EffectResistancePercent\",\"value\":50},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"HealthPercent\",\"value\":5},{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Speed\",\"value\":8}],\"name\":\"EmergencyRing\",\"augmentedStats\":{\"mainType\":\"EffectResistancePercent\",\"mainValue\":50,\"CriticalHitDamagePercent\":11,\"HealthPercent\":5,\"DefensePercent\":7,\"Speed\":8},\"id\":25},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":65},\"substats\":[{\"type\":\"Speed\",\"value\":3},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"CriticalHitDamagePercent\",\"value\":21},{\"type\":\"Attack\",\"value\":51}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":65,\"Speed\":3,\"DefensePercent\":18,\"CriticalHitDamagePercent\":21,\"Attack\":51},\"id\":26},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":77,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"CriticalHitDamagePercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"VerdantBoots\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":7,\"CriticalHitChancePercent\":12,\"CriticalHitDamagePercent\":6,\"EffectivenessPercent\":17},\"id\":27},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":35},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":19},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"SocksofSmallMiracles\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":35,\"HealthPercent\":6,\"AttackPercent\":19,\"DefensePercent\":12,\"CriticalHitChancePercent\":8},\"id\":28},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":7},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"Speed\",\"value\":8},{\"type\":\"CriticalHitChancePercent\",\"value\":11}],\"name\":\"AbyssDrakeBoots\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"EffectResistancePercent\":7,\"DefensePercent\":12,\"Speed\":8,\"CriticalHitChancePercent\":11},\"id\":29},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"AttackPercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":14},{\"type\":\"EffectResistancePercent\",\"value\":28},{\"type\":\"HealthPercent\",\"value\":13}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"AttackPercent\":6,\"EffectivenessPercent\":14,\"EffectResistancePercent\":28,\"HealthPercent\":13},\"id\":30},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":17},{\"type\":\"Attack\",\"value\":43},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"EffectResistancePercent\":17,\"DefensePercent\":17,\"Attack\":43,\"CriticalHitChancePercent\":8},\"id\":31}],\"inputAllowLockedItems\":false,\"inputAllowEquippedItems\":false,\"inputKeepCurrentItems\":false,\"inputSets\":[[\"SpeedSet\"],[],[]],\"inputSetsOne\":[\"HealthSet\",\"HitSet\"],\"inputSetsTwo\":[\"HealthSet\",\"CriticalSet\"],\"inputSetsThree\":[\"DefenseSet\"],\"inputAllowBrokenSets\":false,\"setFormat\":5,\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5}";
    // 222 All immunity
//    private static final String REQUEST_STRING = "{\"base\":{\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5},\"requestType\":\"OptimizationRequest\",\"extraField\":\"asdf\",\"items\":[{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"HealthSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":27},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"Health\",\"value\":178}],\"name\":\"DarkSteelSaber\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"EffectivenessPercent\":4,\"HealthPercent\":27,\"AttackPercent\":14,\"Health\":178},\"id\":0},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":515},\"substats\":[{\"type\":\"Health\",\"value\":214},{\"type\":\"HealthPercent\",\"value\":25},{\"type\":\"CriticalHitDamagePercent\",\"value\":4},{\"type\":\"Speed\",\"value\":9}],\"name\":\"ArahakansFang\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":515,\"Health\":214,\"HealthPercent\":25,\"CriticalHitDamagePercent\":4,\"Speed\":9},\"id\":1},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"RageSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"AttackPercent\",\"value\":10},{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"ThornVineWhip\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"AttackPercent\":10,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":2},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":6},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":7}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"CriticalHitDamagePercent\":15,\"Speed\":6,\"CriticalHitChancePercent\":10,\"AttackPercent\":7},\"id\":3},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"EffectResistancePercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":20}],\"name\":\"ManaDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"CriticalHitChancePercent\":6,\"CriticalHitDamagePercent\":11,\"EffectResistancePercent\":12,\"AttackPercent\":20},\"id\":4},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":11},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"Speed\",\"value\":3}],\"name\":\"RoseCoronet\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"HealthPercent\":12,\"AttackPercent\":11,\"DefensePercent\":18,\"Speed\":3},\"id\":5},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2700},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":9},{\"type\":\"HealthPercent\",\"value\":26}],\"name\":\"AbyssDrakeMask\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2700,\"CriticalHitChancePercent\":6,\"AttackPercent\":4,\"EffectivenessPercent\":9,\"HealthPercent\":26},\"id\":6},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"HealthPercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"GladiatorsHelmofVictory\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"HealthPercent\":17,\"DefensePercent\":14,\"Speed\":6,\"EffectResistancePercent\":6},\"id\":7},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"AttackPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"TerrariaHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"AttackPercent\":13,\"Speed\":9,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":8},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Defense\",\"value\":34},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"HealthPercent\",\"value\":31}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"DefensePercent\":7,\"Defense\":34,\"AttackPercent\":14,\"HealthPercent\":31},\"id\":9},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2295},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":7}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2295,\"HealthPercent\":6,\"CriticalHitDamagePercent\":10,\"AttackPercent\":14,\"CriticalHitChancePercent\":7},\"id\":10},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":260},\"substats\":[{\"type\":\"HealthPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"CriticalHitDamagePercent\",\"value\":6}],\"name\":\"AncientShandranWarriorsArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":260,\"HealthPercent\":13,\"Speed\":12,\"CriticalHitChancePercent\":8,\"CriticalHitDamagePercent\":6},\"id\":11},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"DefensePercent\",\"value\":21},{\"type\":\"Speed\",\"value\":10},{\"type\":\"CriticalHitChancePercent\",\"value\":4}],\"name\":\"AzimanusFightersArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"HealthPercent\":12,\"DefensePercent\":21,\"Speed\":10,\"CriticalHitChancePercent\":4},\"id\":12},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"CriticalHitDamagePercent\",\"value\":11}],\"name\":\"ArahakansChestplate\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"CriticalHitChancePercent\":8,\"DefensePercent\":12,\"HealthPercent\":11,\"CriticalHitDamagePercent\":11},\"id\":13},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"CriticalHitDamagePercent\":9,\"CriticalHitChancePercent\":9,\"DefensePercent\":12,\"EffectivenessPercent\":18},\"id\":14},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":13},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":13,\"EffectivenessPercent\":17},\"id\":15},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":78,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":19}],\"name\":\"ConstellasPearlNecklace\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"DefensePercent\":12,\"CriticalHitChancePercent\":10,\"Speed\":6,\"EffectResistancePercent\":19},\"id\":16},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"EffectivenessPercent\",\"value\":6}],\"name\":\"PendantofLuminescence\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":15,\"Speed\":5,\"CriticalHitChancePercent\":10,\"EffectivenessPercent\":6},\"id\":17},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitChancePercent\",\"value\":45},\"substats\":[{\"type\":\"Speed\",\"value\":13},{\"type\":\"AttackPercent\",\"value\":5},{\"type\":\"HealthPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":13}],\"name\":\"TreasureCollectorsCharm\",\"augmentedStats\":{\"mainType\":\"CriticalHitChancePercent\",\"mainValue\":45,\"Speed\":13,\"AttackPercent\":5,\"HealthPercent\":4,\"EffectivenessPercent\":13},\"id\":18},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"ResistSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":21},{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":5}],\"name\":\"ObsidianAmulet\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"AttackPercent\":14,\"CriticalHitChancePercent\":21,\"EffectivenessPercent\":4,\"HealthPercent\":5},\"id\":19},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"Speed\",\"value\":14},{\"type\":\"Attack\",\"value\":29},{\"type\":\"AttackPercent\",\"value\":6}],\"name\":\"BoldGeneralsNecklace\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"CriticalHitChancePercent\":8,\"Speed\":14,\"Attack\":29,\"AttackPercent\":6},\"id\":20},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"DefensePercent\",\"value\":50},\"substats\":[{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"Speed\",\"value\":11},{\"type\":\"CriticalHitChancePercent\",\"value\":4},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"OathRing\",\"augmentedStats\":{\"mainType\":\"DefensePercent\",\"mainValue\":50,\"HealthPercent\":11,\"Speed\":11,\"CriticalHitChancePercent\":4,\"EffectResistancePercent\":6},\"id\":21},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"LifestealSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"Speed\",\"value\":4},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"GaveleetsRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":12,\"Speed\":4,\"CriticalHitChancePercent\":12,\"EffectivenessPercent\":18},\"id\":22},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"EffectResistancePercent\",\"value\":9}],\"name\":\"LightofaMillion\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":14,\"Speed\":5,\"CriticalHitChancePercent\":7,\"EffectResistancePercent\":9},\"id\":23},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"EffectivenessPercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"CriticalHitDamagePercent\",\"value\":18},{\"type\":\"DefensePercent\",\"value\":19},{\"type\":\"AttackPercent\",\"value\":9}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"EffectivenessPercent\",\"mainValue\":65,\"CriticalHitChancePercent\":9,\"CriticalHitDamagePercent\":18,\"DefensePercent\":19,\"AttackPercent\":9},\"id\":24},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"EffectResistancePercent\",\"value\":50},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"HealthPercent\",\"value\":5},{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Speed\",\"value\":8}],\"name\":\"EmergencyRing\",\"augmentedStats\":{\"mainType\":\"EffectResistancePercent\",\"mainValue\":50,\"CriticalHitDamagePercent\":11,\"HealthPercent\":5,\"DefensePercent\":7,\"Speed\":8},\"id\":25},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":65},\"substats\":[{\"type\":\"Speed\",\"value\":3},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"CriticalHitDamagePercent\",\"value\":21},{\"type\":\"Attack\",\"value\":51}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":65,\"Speed\":3,\"DefensePercent\":18,\"CriticalHitDamagePercent\":21,\"Attack\":51},\"id\":26},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":77,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"CriticalHitDamagePercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"VerdantBoots\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":7,\"CriticalHitChancePercent\":12,\"CriticalHitDamagePercent\":6,\"EffectivenessPercent\":17},\"id\":27},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":35},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":19},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"SocksofSmallMiracles\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":35,\"HealthPercent\":6,\"AttackPercent\":19,\"DefensePercent\":12,\"CriticalHitChancePercent\":8},\"id\":28},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":7},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"Speed\",\"value\":8},{\"type\":\"CriticalHitChancePercent\",\"value\":11}],\"name\":\"AbyssDrakeBoots\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"EffectResistancePercent\":7,\"DefensePercent\":12,\"Speed\":8,\"CriticalHitChancePercent\":11},\"id\":29},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"AttackPercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":14},{\"type\":\"EffectResistancePercent\",\"value\":28},{\"type\":\"HealthPercent\",\"value\":13}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"AttackPercent\":6,\"EffectivenessPercent\":14,\"EffectResistancePercent\":28,\"HealthPercent\":13},\"id\":30},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":17},{\"type\":\"Attack\",\"value\":43},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"EffectResistancePercent\":17,\"DefensePercent\":17,\"Attack\":43,\"CriticalHitChancePercent\":8},\"id\":31}],\"inputAllowLockedItems\":false,\"inputAllowEquippedItems\":false,\"inputKeepCurrentItems\":false,\"inputSets\":[[\"SpeedSet\"],[],[]],\"inputSetsOne\":[\"ImmunitySet\"],\"inputSetsTwo\":[\"ImmunitySet\"],\"inputSetsThree\":[\"ImmunitySet\"],\"inputAllowBrokenSets\":false,\"setFormat\":5,\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5}";
    // 400 set
//    private static final String REQUEST_STRING = "{\"base\":{\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5},\"requestType\":\"OptimizationRequest\",\"extraField\":\"asdf\",\"items\":[{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"HealthSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":27},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"Health\",\"value\":178}],\"name\":\"DarkSteelSaber\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"EffectivenessPercent\":4,\"HealthPercent\":27,\"AttackPercent\":14,\"Health\":178},\"id\":0},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":515},\"substats\":[{\"type\":\"Health\",\"value\":214},{\"type\":\"HealthPercent\",\"value\":25},{\"type\":\"CriticalHitDamagePercent\",\"value\":4},{\"type\":\"Speed\",\"value\":9}],\"name\":\"ArahakansFang\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":515,\"Health\":214,\"HealthPercent\":25,\"CriticalHitDamagePercent\":4,\"Speed\":9},\"id\":1},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"RageSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"AttackPercent\",\"value\":10},{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"ThornVineWhip\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"AttackPercent\":10,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":2},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":6},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":7}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"CriticalHitDamagePercent\":15,\"Speed\":6,\"CriticalHitChancePercent\":10,\"AttackPercent\":7},\"id\":3},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"EffectResistancePercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":20}],\"name\":\"ManaDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"CriticalHitChancePercent\":6,\"CriticalHitDamagePercent\":11,\"EffectResistancePercent\":12,\"AttackPercent\":20},\"id\":4},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":11},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"Speed\",\"value\":3}],\"name\":\"RoseCoronet\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"HealthPercent\":12,\"AttackPercent\":11,\"DefensePercent\":18,\"Speed\":3},\"id\":5},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2700},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":9},{\"type\":\"HealthPercent\",\"value\":26}],\"name\":\"AbyssDrakeMask\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2700,\"CriticalHitChancePercent\":6,\"AttackPercent\":4,\"EffectivenessPercent\":9,\"HealthPercent\":26},\"id\":6},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"HealthPercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"GladiatorsHelmofVictory\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"HealthPercent\":17,\"DefensePercent\":14,\"Speed\":6,\"EffectResistancePercent\":6},\"id\":7},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"AttackPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"TerrariaHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"AttackPercent\":13,\"Speed\":9,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":8},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Defense\",\"value\":34},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"HealthPercent\",\"value\":31}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"DefensePercent\":7,\"Defense\":34,\"AttackPercent\":14,\"HealthPercent\":31},\"id\":9},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2295},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":7}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2295,\"HealthPercent\":6,\"CriticalHitDamagePercent\":10,\"AttackPercent\":14,\"CriticalHitChancePercent\":7},\"id\":10},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":260},\"substats\":[{\"type\":\"HealthPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"CriticalHitDamagePercent\",\"value\":6}],\"name\":\"AncientShandranWarriorsArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":260,\"HealthPercent\":13,\"Speed\":12,\"CriticalHitChancePercent\":8,\"CriticalHitDamagePercent\":6},\"id\":11},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"DefensePercent\",\"value\":21},{\"type\":\"Speed\",\"value\":10},{\"type\":\"CriticalHitChancePercent\",\"value\":4}],\"name\":\"AzimanusFightersArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"HealthPercent\":12,\"DefensePercent\":21,\"Speed\":10,\"CriticalHitChancePercent\":4},\"id\":12},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"CriticalHitDamagePercent\",\"value\":11}],\"name\":\"ArahakansChestplate\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"CriticalHitChancePercent\":8,\"DefensePercent\":12,\"HealthPercent\":11,\"CriticalHitDamagePercent\":11},\"id\":13},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"CriticalHitDamagePercent\":9,\"CriticalHitChancePercent\":9,\"DefensePercent\":12,\"EffectivenessPercent\":18},\"id\":14},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":13},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":13,\"EffectivenessPercent\":17},\"id\":15},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":78,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":19}],\"name\":\"ConstellasPearlNecklace\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"DefensePercent\":12,\"CriticalHitChancePercent\":10,\"Speed\":6,\"EffectResistancePercent\":19},\"id\":16},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"EffectivenessPercent\",\"value\":6}],\"name\":\"PendantofLuminescence\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":15,\"Speed\":5,\"CriticalHitChancePercent\":10,\"EffectivenessPercent\":6},\"id\":17},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitChancePercent\",\"value\":45},\"substats\":[{\"type\":\"Speed\",\"value\":13},{\"type\":\"AttackPercent\",\"value\":5},{\"type\":\"HealthPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":13}],\"name\":\"TreasureCollectorsCharm\",\"augmentedStats\":{\"mainType\":\"CriticalHitChancePercent\",\"mainValue\":45,\"Speed\":13,\"AttackPercent\":5,\"HealthPercent\":4,\"EffectivenessPercent\":13},\"id\":18},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"ResistSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":21},{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":5}],\"name\":\"ObsidianAmulet\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"AttackPercent\":14,\"CriticalHitChancePercent\":21,\"EffectivenessPercent\":4,\"HealthPercent\":5},\"id\":19},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"Speed\",\"value\":14},{\"type\":\"Attack\",\"value\":29},{\"type\":\"AttackPercent\",\"value\":6}],\"name\":\"BoldGeneralsNecklace\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"CriticalHitChancePercent\":8,\"Speed\":14,\"Attack\":29,\"AttackPercent\":6},\"id\":20},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"DefensePercent\",\"value\":50},\"substats\":[{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"Speed\",\"value\":11},{\"type\":\"CriticalHitChancePercent\",\"value\":4},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"OathRing\",\"augmentedStats\":{\"mainType\":\"DefensePercent\",\"mainValue\":50,\"HealthPercent\":11,\"Speed\":11,\"CriticalHitChancePercent\":4,\"EffectResistancePercent\":6},\"id\":21},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"LifestealSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"Speed\",\"value\":4},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"GaveleetsRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":12,\"Speed\":4,\"CriticalHitChancePercent\":12,\"EffectivenessPercent\":18},\"id\":22},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"EffectResistancePercent\",\"value\":9}],\"name\":\"LightofaMillion\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":14,\"Speed\":5,\"CriticalHitChancePercent\":7,\"EffectResistancePercent\":9},\"id\":23},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"EffectivenessPercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"CriticalHitDamagePercent\",\"value\":18},{\"type\":\"DefensePercent\",\"value\":19},{\"type\":\"AttackPercent\",\"value\":9}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"EffectivenessPercent\",\"mainValue\":65,\"CriticalHitChancePercent\":9,\"CriticalHitDamagePercent\":18,\"DefensePercent\":19,\"AttackPercent\":9},\"id\":24},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"EffectResistancePercent\",\"value\":50},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"HealthPercent\",\"value\":5},{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Speed\",\"value\":8}],\"name\":\"EmergencyRing\",\"augmentedStats\":{\"mainType\":\"EffectResistancePercent\",\"mainValue\":50,\"CriticalHitDamagePercent\":11,\"HealthPercent\":5,\"DefensePercent\":7,\"Speed\":8},\"id\":25},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":65},\"substats\":[{\"type\":\"Speed\",\"value\":3},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"CriticalHitDamagePercent\",\"value\":21},{\"type\":\"Attack\",\"value\":51}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":65,\"Speed\":3,\"DefensePercent\":18,\"CriticalHitDamagePercent\":21,\"Attack\":51},\"id\":26},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":77,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"CriticalHitDamagePercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"VerdantBoots\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":7,\"CriticalHitChancePercent\":12,\"CriticalHitDamagePercent\":6,\"EffectivenessPercent\":17},\"id\":27},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":35},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":19},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"SocksofSmallMiracles\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":35,\"HealthPercent\":6,\"AttackPercent\":19,\"DefensePercent\":12,\"CriticalHitChancePercent\":8},\"id\":28},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":7},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"Speed\",\"value\":8},{\"type\":\"CriticalHitChancePercent\",\"value\":11}],\"name\":\"AbyssDrakeBoots\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"EffectResistancePercent\":7,\"DefensePercent\":12,\"Speed\":8,\"CriticalHitChancePercent\":11},\"id\":29},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"AttackPercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":14},{\"type\":\"EffectResistancePercent\",\"value\":28},{\"type\":\"HealthPercent\",\"value\":13}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"AttackPercent\":6,\"EffectivenessPercent\":14,\"EffectResistancePercent\":28,\"HealthPercent\":13},\"id\":30},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":17},{\"type\":\"Attack\",\"value\":43},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"EffectResistancePercent\":17,\"DefensePercent\":17,\"Attack\":43,\"CriticalHitChancePercent\":8},\"id\":31}],\"inputAllowLockedItems\":false,\"inputAllowEquippedItems\":false,\"inputKeepCurrentItems\":false,\"inputSets\":[[\"SpeedSet\"],[],[]],\"inputSetsOne\":[\"SpeedSet\", \"AttackSet\"],\"inputSetsTwo\":[],\"inputSetsThree\":[],\"inputAllowBrokenSets\":false,\"setFormat\":2,\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5}";
    // 200 set
//    private static final String REQUEST_STRING = "{\"base\":{\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5},\"requestType\":\"OptimizationRequest\",\"extraField\":\"asdf\",\"items\":[{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"HealthSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":27},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"Health\",\"value\":178}],\"name\":\"DarkSteelSaber\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"EffectivenessPercent\":4,\"HealthPercent\":27,\"AttackPercent\":14,\"Health\":178},\"id\":0},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":515},\"substats\":[{\"type\":\"Health\",\"value\":214},{\"type\":\"HealthPercent\",\"value\":25},{\"type\":\"CriticalHitDamagePercent\",\"value\":4},{\"type\":\"Speed\",\"value\":9}],\"name\":\"ArahakansFang\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":515,\"Health\":214,\"HealthPercent\":25,\"CriticalHitDamagePercent\":4,\"Speed\":9},\"id\":1},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"RageSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"AttackPercent\",\"value\":10},{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"ThornVineWhip\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"AttackPercent\":10,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":2},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":6},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":7}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"CriticalHitDamagePercent\":15,\"Speed\":6,\"CriticalHitChancePercent\":10,\"AttackPercent\":7},\"id\":3},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"EffectResistancePercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":20}],\"name\":\"ManaDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"CriticalHitChancePercent\":6,\"CriticalHitDamagePercent\":11,\"EffectResistancePercent\":12,\"AttackPercent\":20},\"id\":4},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":11},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"Speed\",\"value\":3}],\"name\":\"RoseCoronet\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"HealthPercent\":12,\"AttackPercent\":11,\"DefensePercent\":18,\"Speed\":3},\"id\":5},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2700},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":9},{\"type\":\"HealthPercent\",\"value\":26}],\"name\":\"AbyssDrakeMask\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2700,\"CriticalHitChancePercent\":6,\"AttackPercent\":4,\"EffectivenessPercent\":9,\"HealthPercent\":26},\"id\":6},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"HealthPercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"GladiatorsHelmofVictory\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"HealthPercent\":17,\"DefensePercent\":14,\"Speed\":6,\"EffectResistancePercent\":6},\"id\":7},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"AttackPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"TerrariaHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"AttackPercent\":13,\"Speed\":9,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":8},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Defense\",\"value\":34},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"HealthPercent\",\"value\":31}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"DefensePercent\":7,\"Defense\":34,\"AttackPercent\":14,\"HealthPercent\":31},\"id\":9},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2295},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":7}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2295,\"HealthPercent\":6,\"CriticalHitDamagePercent\":10,\"AttackPercent\":14,\"CriticalHitChancePercent\":7},\"id\":10},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":260},\"substats\":[{\"type\":\"HealthPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"CriticalHitDamagePercent\",\"value\":6}],\"name\":\"AncientShandranWarriorsArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":260,\"HealthPercent\":13,\"Speed\":12,\"CriticalHitChancePercent\":8,\"CriticalHitDamagePercent\":6},\"id\":11},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"DefensePercent\",\"value\":21},{\"type\":\"Speed\",\"value\":10},{\"type\":\"CriticalHitChancePercent\",\"value\":4}],\"name\":\"AzimanusFightersArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"HealthPercent\":12,\"DefensePercent\":21,\"Speed\":10,\"CriticalHitChancePercent\":4},\"id\":12},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"CriticalHitDamagePercent\",\"value\":11}],\"name\":\"ArahakansChestplate\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"CriticalHitChancePercent\":8,\"DefensePercent\":12,\"HealthPercent\":11,\"CriticalHitDamagePercent\":11},\"id\":13},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"CriticalHitDamagePercent\":9,\"CriticalHitChancePercent\":9,\"DefensePercent\":12,\"EffectivenessPercent\":18},\"id\":14},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":13},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":13,\"EffectivenessPercent\":17},\"id\":15},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":78,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":19}],\"name\":\"ConstellasPearlNecklace\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"DefensePercent\":12,\"CriticalHitChancePercent\":10,\"Speed\":6,\"EffectResistancePercent\":19},\"id\":16},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"EffectivenessPercent\",\"value\":6}],\"name\":\"PendantofLuminescence\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":15,\"Speed\":5,\"CriticalHitChancePercent\":10,\"EffectivenessPercent\":6},\"id\":17},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitChancePercent\",\"value\":45},\"substats\":[{\"type\":\"Speed\",\"value\":13},{\"type\":\"AttackPercent\",\"value\":5},{\"type\":\"HealthPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":13}],\"name\":\"TreasureCollectorsCharm\",\"augmentedStats\":{\"mainType\":\"CriticalHitChancePercent\",\"mainValue\":45,\"Speed\":13,\"AttackPercent\":5,\"HealthPercent\":4,\"EffectivenessPercent\":13},\"id\":18},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"ResistSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":21},{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":5}],\"name\":\"ObsidianAmulet\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"AttackPercent\":14,\"CriticalHitChancePercent\":21,\"EffectivenessPercent\":4,\"HealthPercent\":5},\"id\":19},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"Speed\",\"value\":14},{\"type\":\"Attack\",\"value\":29},{\"type\":\"AttackPercent\",\"value\":6}],\"name\":\"BoldGeneralsNecklace\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"CriticalHitChancePercent\":8,\"Speed\":14,\"Attack\":29,\"AttackPercent\":6},\"id\":20},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"DefensePercent\",\"value\":50},\"substats\":[{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"Speed\",\"value\":11},{\"type\":\"CriticalHitChancePercent\",\"value\":4},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"OathRing\",\"augmentedStats\":{\"mainType\":\"DefensePercent\",\"mainValue\":50,\"HealthPercent\":11,\"Speed\":11,\"CriticalHitChancePercent\":4,\"EffectResistancePercent\":6},\"id\":21},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"LifestealSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"Speed\",\"value\":4},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"GaveleetsRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":12,\"Speed\":4,\"CriticalHitChancePercent\":12,\"EffectivenessPercent\":18},\"id\":22},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"EffectResistancePercent\",\"value\":9}],\"name\":\"LightofaMillion\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":14,\"Speed\":5,\"CriticalHitChancePercent\":7,\"EffectResistancePercent\":9},\"id\":23},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"EffectivenessPercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"CriticalHitDamagePercent\",\"value\":18},{\"type\":\"DefensePercent\",\"value\":19},{\"type\":\"AttackPercent\",\"value\":9}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"EffectivenessPercent\",\"mainValue\":65,\"CriticalHitChancePercent\":9,\"CriticalHitDamagePercent\":18,\"DefensePercent\":19,\"AttackPercent\":9},\"id\":24},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"EffectResistancePercent\",\"value\":50},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"HealthPercent\",\"value\":5},{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Speed\",\"value\":8}],\"name\":\"EmergencyRing\",\"augmentedStats\":{\"mainType\":\"EffectResistancePercent\",\"mainValue\":50,\"CriticalHitDamagePercent\":11,\"HealthPercent\":5,\"DefensePercent\":7,\"Speed\":8},\"id\":25},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":65},\"substats\":[{\"type\":\"Speed\",\"value\":3},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"CriticalHitDamagePercent\",\"value\":21},{\"type\":\"Attack\",\"value\":51}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":65,\"Speed\":3,\"DefensePercent\":18,\"CriticalHitDamagePercent\":21,\"Attack\":51},\"id\":26},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":77,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"CriticalHitDamagePercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"VerdantBoots\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":7,\"CriticalHitChancePercent\":12,\"CriticalHitDamagePercent\":6,\"EffectivenessPercent\":17},\"id\":27},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":35},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":19},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"SocksofSmallMiracles\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":35,\"HealthPercent\":6,\"AttackPercent\":19,\"DefensePercent\":12,\"CriticalHitChancePercent\":8},\"id\":28},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":7},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"Speed\",\"value\":8},{\"type\":\"CriticalHitChancePercent\",\"value\":11}],\"name\":\"AbyssDrakeBoots\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"EffectResistancePercent\":7,\"DefensePercent\":12,\"Speed\":8,\"CriticalHitChancePercent\":11},\"id\":29},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"AttackPercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":14},{\"type\":\"EffectResistancePercent\",\"value\":28},{\"type\":\"HealthPercent\",\"value\":13}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"AttackPercent\":6,\"EffectivenessPercent\":14,\"EffectResistancePercent\":28,\"HealthPercent\":13},\"id\":30},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":17},{\"type\":\"Attack\",\"value\":43},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"EffectResistancePercent\":17,\"DefensePercent\":17,\"Attack\":43,\"CriticalHitChancePercent\":8},\"id\":31}],\"inputAllowLockedItems\":false,\"inputAllowEquippedItems\":false,\"inputKeepCurrentItems\":false,\"inputSets\":[[\"SpeedSet\"],[],[]],\"inputSetsOne\":[\"ImmunitySet\", \"HealthSet\"],\"inputSetsTwo\":[],\"inputSetsThree\":[],\"inputAllowBrokenSets\":false,\"setFormat\":3,\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5}";
    // 220 set
//    private static final String REQUEST_STRING = "{\"base\":{\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5},\"requestType\":\"OptimizationRequest\",\"extraField\":\"asdf\",\"items\":[{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"HealthSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":27},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"Health\",\"value\":178}],\"name\":\"DarkSteelSaber\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"EffectivenessPercent\":4,\"HealthPercent\":27,\"AttackPercent\":14,\"Health\":178},\"id\":0},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":515},\"substats\":[{\"type\":\"Health\",\"value\":214},{\"type\":\"HealthPercent\",\"value\":25},{\"type\":\"CriticalHitDamagePercent\",\"value\":4},{\"type\":\"Speed\",\"value\":9}],\"name\":\"ArahakansFang\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":515,\"Health\":214,\"HealthPercent\":25,\"CriticalHitDamagePercent\":4,\"Speed\":9},\"id\":1},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"RageSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"AttackPercent\",\"value\":10},{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"ThornVineWhip\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"AttackPercent\":10,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":2},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":6},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":7}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"CriticalHitDamagePercent\":15,\"Speed\":6,\"CriticalHitChancePercent\":10,\"AttackPercent\":7},\"id\":3},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"EffectResistancePercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":20}],\"name\":\"ManaDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"CriticalHitChancePercent\":6,\"CriticalHitDamagePercent\":11,\"EffectResistancePercent\":12,\"AttackPercent\":20},\"id\":4},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":11},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"Speed\",\"value\":3}],\"name\":\"RoseCoronet\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"HealthPercent\":12,\"AttackPercent\":11,\"DefensePercent\":18,\"Speed\":3},\"id\":5},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2700},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":9},{\"type\":\"HealthPercent\",\"value\":26}],\"name\":\"AbyssDrakeMask\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2700,\"CriticalHitChancePercent\":6,\"AttackPercent\":4,\"EffectivenessPercent\":9,\"HealthPercent\":26},\"id\":6},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"HealthPercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"GladiatorsHelmofVictory\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"HealthPercent\":17,\"DefensePercent\":14,\"Speed\":6,\"EffectResistancePercent\":6},\"id\":7},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"AttackPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"TerrariaHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"AttackPercent\":13,\"Speed\":9,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":8},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Defense\",\"value\":34},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"HealthPercent\",\"value\":31}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"DefensePercent\":7,\"Defense\":34,\"AttackPercent\":14,\"HealthPercent\":31},\"id\":9},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2295},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":7}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2295,\"HealthPercent\":6,\"CriticalHitDamagePercent\":10,\"AttackPercent\":14,\"CriticalHitChancePercent\":7},\"id\":10},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":260},\"substats\":[{\"type\":\"HealthPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"CriticalHitDamagePercent\",\"value\":6}],\"name\":\"AncientShandranWarriorsArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":260,\"HealthPercent\":13,\"Speed\":12,\"CriticalHitChancePercent\":8,\"CriticalHitDamagePercent\":6},\"id\":11},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"DefensePercent\",\"value\":21},{\"type\":\"Speed\",\"value\":10},{\"type\":\"CriticalHitChancePercent\",\"value\":4}],\"name\":\"AzimanusFightersArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"HealthPercent\":12,\"DefensePercent\":21,\"Speed\":10,\"CriticalHitChancePercent\":4},\"id\":12},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"CriticalHitDamagePercent\",\"value\":11}],\"name\":\"ArahakansChestplate\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"CriticalHitChancePercent\":8,\"DefensePercent\":12,\"HealthPercent\":11,\"CriticalHitDamagePercent\":11},\"id\":13},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"CriticalHitDamagePercent\":9,\"CriticalHitChancePercent\":9,\"DefensePercent\":12,\"EffectivenessPercent\":18},\"id\":14},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":13},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":13,\"EffectivenessPercent\":17},\"id\":15},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":78,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":19}],\"name\":\"ConstellasPearlNecklace\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"DefensePercent\":12,\"CriticalHitChancePercent\":10,\"Speed\":6,\"EffectResistancePercent\":19},\"id\":16},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"EffectivenessPercent\",\"value\":6}],\"name\":\"PendantofLuminescence\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":15,\"Speed\":5,\"CriticalHitChancePercent\":10,\"EffectivenessPercent\":6},\"id\":17},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitChancePercent\",\"value\":45},\"substats\":[{\"type\":\"Speed\",\"value\":13},{\"type\":\"AttackPercent\",\"value\":5},{\"type\":\"HealthPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":13}],\"name\":\"TreasureCollectorsCharm\",\"augmentedStats\":{\"mainType\":\"CriticalHitChancePercent\",\"mainValue\":45,\"Speed\":13,\"AttackPercent\":5,\"HealthPercent\":4,\"EffectivenessPercent\":13},\"id\":18},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"ResistSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":21},{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":5}],\"name\":\"ObsidianAmulet\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"AttackPercent\":14,\"CriticalHitChancePercent\":21,\"EffectivenessPercent\":4,\"HealthPercent\":5},\"id\":19},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"Speed\",\"value\":14},{\"type\":\"Attack\",\"value\":29},{\"type\":\"AttackPercent\",\"value\":6}],\"name\":\"BoldGeneralsNecklace\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"CriticalHitChancePercent\":8,\"Speed\":14,\"Attack\":29,\"AttackPercent\":6},\"id\":20},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"DefensePercent\",\"value\":50},\"substats\":[{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"Speed\",\"value\":11},{\"type\":\"CriticalHitChancePercent\",\"value\":4},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"OathRing\",\"augmentedStats\":{\"mainType\":\"DefensePercent\",\"mainValue\":50,\"HealthPercent\":11,\"Speed\":11,\"CriticalHitChancePercent\":4,\"EffectResistancePercent\":6},\"id\":21},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"LifestealSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"Speed\",\"value\":4},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"GaveleetsRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":12,\"Speed\":4,\"CriticalHitChancePercent\":12,\"EffectivenessPercent\":18},\"id\":22},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"EffectResistancePercent\",\"value\":9}],\"name\":\"LightofaMillion\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":14,\"Speed\":5,\"CriticalHitChancePercent\":7,\"EffectResistancePercent\":9},\"id\":23},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"EffectivenessPercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"CriticalHitDamagePercent\",\"value\":18},{\"type\":\"DefensePercent\",\"value\":19},{\"type\":\"AttackPercent\",\"value\":9}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"EffectivenessPercent\",\"mainValue\":65,\"CriticalHitChancePercent\":9,\"CriticalHitDamagePercent\":18,\"DefensePercent\":19,\"AttackPercent\":9},\"id\":24},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"EffectResistancePercent\",\"value\":50},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"HealthPercent\",\"value\":5},{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Speed\",\"value\":8}],\"name\":\"EmergencyRing\",\"augmentedStats\":{\"mainType\":\"EffectResistancePercent\",\"mainValue\":50,\"CriticalHitDamagePercent\":11,\"HealthPercent\":5,\"DefensePercent\":7,\"Speed\":8},\"id\":25},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":65},\"substats\":[{\"type\":\"Speed\",\"value\":3},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"CriticalHitDamagePercent\",\"value\":21},{\"type\":\"Attack\",\"value\":51}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":65,\"Speed\":3,\"DefensePercent\":18,\"CriticalHitDamagePercent\":21,\"Attack\":51},\"id\":26},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":77,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"CriticalHitDamagePercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"VerdantBoots\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":7,\"CriticalHitChancePercent\":12,\"CriticalHitDamagePercent\":6,\"EffectivenessPercent\":17},\"id\":27},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":35},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":19},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"SocksofSmallMiracles\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":35,\"HealthPercent\":6,\"AttackPercent\":19,\"DefensePercent\":12,\"CriticalHitChancePercent\":8},\"id\":28},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":7},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"Speed\",\"value\":8},{\"type\":\"CriticalHitChancePercent\",\"value\":11}],\"name\":\"AbyssDrakeBoots\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"EffectResistancePercent\":7,\"DefensePercent\":12,\"Speed\":8,\"CriticalHitChancePercent\":11},\"id\":29},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"AttackPercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":14},{\"type\":\"EffectResistancePercent\",\"value\":28},{\"type\":\"HealthPercent\",\"value\":13}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"AttackPercent\":6,\"EffectivenessPercent\":14,\"EffectResistancePercent\":28,\"HealthPercent\":13},\"id\":30},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":17},{\"type\":\"Attack\",\"value\":43},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"EffectResistancePercent\":17,\"DefensePercent\":17,\"Attack\":43,\"CriticalHitChancePercent\":8},\"id\":31}],\"inputAllowLockedItems\":false,\"inputAllowEquippedItems\":false,\"inputKeepCurrentItems\":false,\"inputSets\":[[\"SpeedSet\"],[],[]],\"inputSetsOne\":[\"ImmunitySet\", \"HealthSet\"],\"inputSetsTwo\":[\"HealthSet\",\"DefenseSet\"],\"inputSetsThree\":[],\"inputAllowBrokenSets\":false,\"setFormat\":4,\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5}";
    // 400 Speed only set
//    private static final String REQUEST_STRING = "{\"base\":{\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5},\"requestType\":\"OptimizationRequest\",\"extraField\":\"asdf\",\"items\":[{\"gear\":\"Weapon\",\"rank\":\"Heroic\",\"set\":\"HealthSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":27},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"Health\",\"value\":178}],\"name\":\"DarkSteelSaber\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"EffectivenessPercent\":4,\"HealthPercent\":27,\"AttackPercent\":14,\"Health\":178},\"id\":0},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":515},\"substats\":[{\"type\":\"Health\",\"value\":214},{\"type\":\"HealthPercent\",\"value\":25},{\"type\":\"CriticalHitDamagePercent\",\"value\":4},{\"type\":\"Speed\",\"value\":9}],\"name\":\"ArahakansFang\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":515,\"Health\":214,\"HealthPercent\":25,\"CriticalHitDamagePercent\":4,\"Speed\":9},\"id\":1},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"RageSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"AttackPercent\",\"value\":10},{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"ThornVineWhip\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"AttackPercent\":10,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":2},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":500},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":6},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":7}],\"name\":\"AbyssDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":500,\"CriticalHitDamagePercent\":15,\"Speed\":6,\"CriticalHitChancePercent\":10,\"AttackPercent\":7},\"id\":3},{\"gear\":\"Weapon\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Attack\",\"value\":440},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"EffectResistancePercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":20}],\"name\":\"ManaDrakeBonesword\",\"augmentedStats\":{\"mainType\":\"Attack\",\"mainValue\":440,\"CriticalHitChancePercent\":6,\"CriticalHitDamagePercent\":11,\"EffectResistancePercent\":12,\"AttackPercent\":20},\"id\":4},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"AttackPercent\",\"value\":11},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"Speed\",\"value\":3}],\"name\":\"RoseCoronet\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"HealthPercent\":12,\"AttackPercent\":11,\"DefensePercent\":18,\"Speed\":3},\"id\":5},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2700},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":9},{\"type\":\"HealthPercent\",\"value\":26}],\"name\":\"AbyssDrakeMask\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2700,\"CriticalHitChancePercent\":6,\"AttackPercent\":4,\"EffectivenessPercent\":9,\"HealthPercent\":26},\"id\":6},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"HealthPercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"GladiatorsHelmofVictory\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"HealthPercent\":17,\"DefensePercent\":14,\"Speed\":6,\"EffectResistancePercent\":6},\"id\":7},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":70,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2360},\"substats\":[{\"type\":\"AttackPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":9}],\"name\":\"TerrariaHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2360,\"AttackPercent\":13,\"Speed\":9,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":9},\"id\":8},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2765},\"substats\":[{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Defense\",\"value\":34},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"HealthPercent\",\"value\":31}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2765,\"DefensePercent\":7,\"Defense\":34,\"AttackPercent\":14,\"HealthPercent\":31},\"id\":9},{\"gear\":\"Helmet\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Health\",\"value\":2295},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"CriticalHitDamagePercent\",\"value\":10},{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":7}],\"name\":\"KarkanissDecisionHelm\",\"augmentedStats\":{\"mainType\":\"Health\",\"mainValue\":2295,\"HealthPercent\":6,\"CriticalHitDamagePercent\":10,\"AttackPercent\":14,\"CriticalHitChancePercent\":7},\"id\":10},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":260},\"substats\":[{\"type\":\"HealthPercent\",\"value\":13},{\"type\":\"Speed\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"CriticalHitDamagePercent\",\"value\":6}],\"name\":\"AncientShandranWarriorsArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":260,\"HealthPercent\":13,\"Speed\":12,\"CriticalHitChancePercent\":8,\"CriticalHitDamagePercent\":6},\"id\":11},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"DefensePercent\",\"value\":21},{\"type\":\"Speed\",\"value\":10},{\"type\":\"CriticalHitChancePercent\",\"value\":4}],\"name\":\"AzimanusFightersArmor\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"HealthPercent\":12,\"DefensePercent\":21,\"Speed\":10,\"CriticalHitChancePercent\":4},\"id\":12},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":67,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":250},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"CriticalHitDamagePercent\",\"value\":11}],\"name\":\"ArahakansChestplate\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":250,\"CriticalHitChancePercent\":8,\"DefensePercent\":12,\"HealthPercent\":11,\"CriticalHitDamagePercent\":11},\"id\":13},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":9},{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"CriticalHitDamagePercent\":9,\"CriticalHitChancePercent\":9,\"DefensePercent\":12,\"EffectivenessPercent\":18},\"id\":14},{\"gear\":\"Armor\",\"rank\":\"Epic\",\"set\":\"ImmunitySet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Defense\",\"value\":300},\"substats\":[{\"type\":\"Speed\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"CriticalHitDamagePercent\",\"value\":13},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"Corimescent\",\"augmentedStats\":{\"mainType\":\"Defense\",\"mainValue\":300,\"Speed\":7,\"CriticalHitChancePercent\":7,\"CriticalHitDamagePercent\":13,\"EffectivenessPercent\":17},\"id\":15},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"HealthSet\",\"level\":78,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"Speed\",\"value\":6},{\"type\":\"EffectResistancePercent\",\"value\":19}],\"name\":\"ConstellasPearlNecklace\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"DefensePercent\":12,\"CriticalHitChancePercent\":10,\"Speed\":6,\"EffectResistancePercent\":19},\"id\":16},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":15},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":10},{\"type\":\"EffectivenessPercent\",\"value\":6}],\"name\":\"PendantofLuminescence\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":15,\"Speed\":5,\"CriticalHitChancePercent\":10,\"EffectivenessPercent\":6},\"id\":17},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"AttackSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitChancePercent\",\"value\":45},\"substats\":[{\"type\":\"Speed\",\"value\":13},{\"type\":\"AttackPercent\",\"value\":5},{\"type\":\"HealthPercent\",\"value\":4},{\"type\":\"EffectivenessPercent\",\"value\":13}],\"name\":\"TreasureCollectorsCharm\",\"augmentedStats\":{\"mainType\":\"CriticalHitChancePercent\",\"mainValue\":45,\"Speed\":13,\"AttackPercent\":5,\"HealthPercent\":4,\"EffectivenessPercent\":13},\"id\":18},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"ResistSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"AttackPercent\",\"value\":14},{\"type\":\"CriticalHitChancePercent\",\"value\":21},{\"type\":\"EffectivenessPercent\",\"value\":4},{\"type\":\"HealthPercent\",\"value\":5}],\"name\":\"ObsidianAmulet\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"AttackPercent\":14,\"CriticalHitChancePercent\":21,\"EffectivenessPercent\":4,\"HealthPercent\":5},\"id\":19},{\"gear\":\"Necklace\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"CriticalHitDamagePercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":8},{\"type\":\"Speed\",\"value\":14},{\"type\":\"Attack\",\"value\":29},{\"type\":\"AttackPercent\",\"value\":6}],\"name\":\"BoldGeneralsNecklace\",\"augmentedStats\":{\"mainType\":\"CriticalHitDamagePercent\",\"mainValue\":65,\"CriticalHitChancePercent\":8,\"Speed\":14,\"Attack\":29,\"AttackPercent\":6},\"id\":20},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"DefensePercent\",\"value\":50},\"substats\":[{\"type\":\"HealthPercent\",\"value\":11},{\"type\":\"Speed\",\"value\":11},{\"type\":\"CriticalHitChancePercent\",\"value\":4},{\"type\":\"EffectResistancePercent\",\"value\":6}],\"name\":\"OathRing\",\"augmentedStats\":{\"mainType\":\"DefensePercent\",\"mainValue\":50,\"HealthPercent\":11,\"Speed\":11,\"CriticalHitChancePercent\":4,\"EffectResistancePercent\":6},\"id\":21},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"LifestealSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":12},{\"type\":\"Speed\",\"value\":4},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"EffectivenessPercent\",\"value\":18}],\"name\":\"GaveleetsRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":12,\"Speed\":4,\"CriticalHitChancePercent\":12,\"EffectivenessPercent\":18},\"id\":22},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":50},\"substats\":[{\"type\":\"DefensePercent\",\"value\":14},{\"type\":\"Speed\",\"value\":5},{\"type\":\"CriticalHitChancePercent\",\"value\":7},{\"type\":\"EffectResistancePercent\",\"value\":9}],\"name\":\"LightofaMillion\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":50,\"DefensePercent\":14,\"Speed\":5,\"CriticalHitChancePercent\":7,\"EffectResistancePercent\":9},\"id\":23},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"EffectivenessPercent\",\"value\":65},\"substats\":[{\"type\":\"CriticalHitChancePercent\",\"value\":9},{\"type\":\"CriticalHitDamagePercent\",\"value\":18},{\"type\":\"DefensePercent\",\"value\":19},{\"type\":\"AttackPercent\",\"value\":9}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"EffectivenessPercent\",\"mainValue\":65,\"CriticalHitChancePercent\":9,\"CriticalHitDamagePercent\":18,\"DefensePercent\":19,\"AttackPercent\":9},\"id\":24},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":65,\"enhance\":15,\"main\":{\"type\":\"EffectResistancePercent\",\"value\":50},\"substats\":[{\"type\":\"CriticalHitDamagePercent\",\"value\":11},{\"type\":\"HealthPercent\",\"value\":5},{\"type\":\"DefensePercent\",\"value\":7},{\"type\":\"Speed\",\"value\":8}],\"name\":\"EmergencyRing\",\"augmentedStats\":{\"mainType\":\"EffectResistancePercent\",\"mainValue\":50,\"CriticalHitDamagePercent\":11,\"HealthPercent\":5,\"DefensePercent\":7,\"Speed\":8},\"id\":25},{\"gear\":\"Ring\",\"rank\":\"Epic\",\"set\":\"DefenseSet\",\"level\":88,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":65},\"substats\":[{\"type\":\"Speed\",\"value\":3},{\"type\":\"DefensePercent\",\"value\":18},{\"type\":\"CriticalHitDamagePercent\",\"value\":21},{\"type\":\"Attack\",\"value\":51}],\"name\":\"GreaterAzimanusFightersRing\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":65,\"Speed\":3,\"DefensePercent\":18,\"CriticalHitDamagePercent\":21,\"Attack\":51},\"id\":26},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"CriticalSet\",\"level\":77,\"enhance\":15,\"main\":{\"type\":\"AttackPercent\",\"value\":60},\"substats\":[{\"type\":\"HealthPercent\",\"value\":7},{\"type\":\"CriticalHitChancePercent\",\"value\":12},{\"type\":\"CriticalHitDamagePercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":17}],\"name\":\"VerdantBoots\",\"augmentedStats\":{\"mainType\":\"AttackPercent\",\"mainValue\":60,\"HealthPercent\":7,\"CriticalHitChancePercent\":12,\"CriticalHitDamagePercent\":6,\"EffectivenessPercent\":17},\"id\":27},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":71,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":35},\"substats\":[{\"type\":\"HealthPercent\",\"value\":6},{\"type\":\"AttackPercent\",\"value\":19},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"SocksofSmallMiracles\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":35,\"HealthPercent\":6,\"AttackPercent\":19,\"DefensePercent\":12,\"CriticalHitChancePercent\":8},\"id\":28},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"HealthPercent\",\"value\":60},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":7},{\"type\":\"DefensePercent\",\"value\":12},{\"type\":\"Speed\",\"value\":8},{\"type\":\"CriticalHitChancePercent\",\"value\":11}],\"name\":\"AbyssDrakeBoots\",\"augmentedStats\":{\"mainType\":\"HealthPercent\",\"mainValue\":60,\"EffectResistancePercent\":7,\"DefensePercent\":12,\"Speed\":8,\"CriticalHitChancePercent\":11},\"id\":29},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"AttackPercent\",\"value\":6},{\"type\":\"EffectivenessPercent\",\"value\":14},{\"type\":\"EffectResistancePercent\",\"value\":28},{\"type\":\"HealthPercent\",\"value\":13}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"AttackPercent\":6,\"EffectivenessPercent\":14,\"EffectResistancePercent\":28,\"HealthPercent\":13},\"id\":30},{\"gear\":\"Boots\",\"rank\":\"Epic\",\"set\":\"SpeedSet\",\"level\":85,\"enhance\":15,\"main\":{\"type\":\"Speed\",\"value\":40},\"substats\":[{\"type\":\"EffectResistancePercent\",\"value\":17},{\"type\":\"DefensePercent\",\"value\":17},{\"type\":\"Attack\",\"value\":43},{\"type\":\"CriticalHitChancePercent\",\"value\":8}],\"name\":\"PracticalBoots\",\"augmentedStats\":{\"mainType\":\"Speed\",\"mainValue\":40,\"EffectResistancePercent\":17,\"DefensePercent\":17,\"Attack\":43,\"CriticalHitChancePercent\":8},\"id\":31}],\"inputAllowLockedItems\":false,\"inputAllowEquippedItems\":false,\"inputKeepCurrentItems\":false,\"inputSets\":[[\"SpeedSet\"],[],[]],\"inputSetsOne\":[\"SpeedSet\"],\"inputSetsTwo\":[],\"inputSetsThree\":[],\"inputAllowBrokenSets\":false,\"setFormat\":2,\"atk\":576,\"hp\":5700,\"def\":743,\"cr\":15,\"cd\":150,\"eff\":0,\"res\":0,\"spd\":88,\"dac\":5}";

    // 7.1, 9.6
    private final HeroStats baseAngelica = HeroStats.builder()
            .atk(576)
            .hp(5700)
            .spd(88)
            .def(743)
            .cr(15)
            .cd(150)
            .eff(0)
            .res(0)
            .dac(5)
            .build();

    @BeforeEach
    public void setup() {
        handler = new OptimizationRequestHandler(null, null, null);
    }

    @Test
    public void ocr1image() {
        BytePointer outText = null;

        TessBaseAPI api = new TessBaseAPI();
        //        api.Init("C:/Users/ivanc/optimizer/app/tessdata/eng.traineddata", "eng");
        // Initialize tesseract-ocr with English, without specifying tessdata path
        // OEM 0 for Legecy engine, otherwise whitelist doesnt work
        if (api.Init("C:/Users/ivanc/optimizer/app/tessdata/eng.traineddata", "eng", 0) != 0) {
            System.err.println("Could not initialize tesseract.");
            System.exit(1);
        }

        api.SetVariable("tessedit_char_whitelist", "0123456789%,");
        api.SetVariable("load_system_dawg", "false");
        api.SetVariable("load_freq_dawg", "false");
        api.SetVariable("classify_enable_learning", "0");
        // Open input image with leptonica library
        PIX image = pixRead("C:\\Users\\ivanc\\Documents\\XuanZhi\\Pictures\\Screenshots\\" +
                "bugs\\Screenshot_20201206-041200.png");
        //        PIX image = pixRead("C:\\Users\\ivanc\\Documents\\ShareX\\Screenshots\\2020-12\\mspaint_BdrQa2bXvO.png");
        api.SetImage(image);


        api.SetRectangle(311, 444, 85, 144);
        outText = api.GetUTF8Text();

        System.out.println(outText.getString());
    }


    @Test
    public void ocrtest() {
        BytePointer outText = null;

        TessBaseAPI api = new TessBaseAPI();
//        api.Init("C:/Users/ivanc/optimizer/app/tessdata/eng.traineddata", "eng");
        // Initialize tesseract-ocr with English, without specifying tessdata path
        // OEM 0 for Legecy engine, otherwise whitelist doesnt work
        if (api.Init("C:/Users/ivanc/optimizer/app/tessdata/eng.traineddata", "eng", 0) != 0) {
            System.err.println("Could not initialize tesseract.");
            System.exit(1);
        }

        api.SetVariable("tessedit_char_whitelist", "0123456789+");
        api.SetVariable("load_system_dawg", "false");
        api.SetVariable("load_freq_dawg", "false");
        api.SetVariable("classify_enable_learning", "0");
        // Open input image with leptonica library
        PIX image = pixRead("C:\\Users\\ivanc\\Documents\\XuanZhi\\Pictures\\Screenshots\\newocr\\y.png");
//        PIX image = pixRead("C:\\Users\\ivanc\\Documents\\ShareX\\Screenshots\\2020-12\\mspaint_BdrQa2bXvO.png");
        api.SetImage(image);


        int x = 130;
        int y = 171;
        int w = 40;
        int h = 22;

        int d = 2;

        Map<String, List<Integer>> map = new HashMap<>();

        int[] b = new int[]{1,3,4,5,6,7,8,9,10,11,12,13,14,15};
//        int[] b = new int[]{47, 55, 57, 60, 65, 67, 70, 71, 75, 78, 85, 88, 90};

        for (int c = 0; c < b.length; c++) {
            int a = b[c];

            System.out.println(a);

            PIX img = pixRead("C:\\Users\\ivanc\\Documents\\XuanZhi\\Pictures\\Screenshots\\newocr\\" + a + ".png");
            api.SetImage(img);

            for (int i = x-d; i < x+d; i++) {
                for (int j = y-d; j < y+d; j++) {
                    for (int k = w-d; k < w+d; k++) {
                        for (int l = h-d; l < h+d; l++) {
                            api.SetRectangle(i, j, k, l);
                            try {
                                outText = api.GetUTF8Text();
                            } catch (final Exception e) {
                                outText.deallocate();
                                continue;
                            }
                            if (outText == null || outText.getString() == null || outText.getString().length() == 0) continue;

                            String key = i + " " + j + " " + k + " " + l;
                            String value = outText.getString().replaceAll("\n", "").replaceAll(" ", "");

                            if (StringUtils.equals("+" + a, value) || StringUtils.equals("" + a, value) ) {
                                if (!map.containsKey(key)) {
                                    map.put(key, new ArrayList<>());
                                    map.get(key).add(a);
                                } else {
                                    map.get(key).add(a);
                                }
                            }

                            //                        System.out.println(outText.getString().replaceAll("\n", "").replaceAll(" ", "") + " | " + i + " " + j + " " + k + " " + l);
                            outText.deallocate();
                        }
                    }
                }
            }
        }

        System.out.println(map.entrySet().stream()
                .sorted(Comparator.comparingInt(a -> a.getValue().size()))
                .collect(Collectors.toList()));



        // Destroy used object and release memory
        api.End();
        outText.deallocate();
        pixDestroy(image);
    }

    @Test
    public void test() {
        final List<String> s = Stream.of(Set.values()).map(Set::getName).collect(Collectors.toList());
        s.forEach(System.out::println);

        final Map<Set, Integer> distances = Stream.of(Set.values()).collect(Collectors.toMap(
                x -> x,
                x -> StringUtils.getLevenshteinDistance(x.getName(), "Unity Set (2/2)")));

        final Set likelySet = distances.entrySet().stream()
                .min(Comparator.comparingInt(Map.Entry::getValue)).get().getKey();



//        System.out.println(s);
    }

    @Test
    public void testIndex() {
        final int[] setsArray = new int[]{0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 2, 1, 1};
        final int[] indexArray = handler.convertSetsArrayIntoIndexArray(setsArray);

        System.out.println(Arrays.toString(indexArray));
    }

    @Test
    public void testHash() {
        System.out.println(AugmentedStats.builder().attack(3).mainType(StatType.ATTACKPERCENT).build().hashCode());
        System.out.println(AugmentedStats.builder().attack(3).mainType(StatType.ATTACKPERCENT).build().hashCode());
        System.out.println(AugmentedStats.builder().attack(3).mainType(StatType.DEFENSEPERCENT).build().hashCode());
    }
}
