Commit 576dc1c4 authored by Piers Williams's avatar Piers Williams

Merge branch 'master' of git.fossgalaxy.com:hanabi/hanabi.fosslab.uk

parents 17e4f0e9 54f9dc43
Pipeline #995 passed with stages
in 2 minutes and 7 seconds
......@@ -219,7 +219,7 @@ function buildAgent() {
models.pop();
}
$.post("http://hammer.vps.livebytes.co.uk:8000/rule-evaluator-1.0-SNAPSHOT/", model, function(data, textStatus, jqXHR){
$.post("http://hanabi.fossgalaxy.com/rule-evaluator-1.0-SNAPSHOT/eval", model, function(data, textStatus, jqXHR){
updateData(data);
updateGraph();
updateTable();
......@@ -228,6 +228,33 @@ function buildAgent() {
});
}
function buildAgentFixed() {
if (testPending) {
return;
}
testPending = true;
$("#testBtn .fa-spinner").css("display", "inline");
var ruleList = [];
$("#agent .list-group-item .ruleid").each(function(x, i) {
ruleList.push(i.innerHTML);
});
var model = ruleList.join(",");
models.unshift(model);
if(models.length > 4){
models.pop();
}
$.post("http://hanabi.fossgalaxy.com/rule-evaluator-1.0-SNAPSHOT/bench", model, function(data, textStatus, jqXHR){
updateData(data);
updateGraph();
updateTable();
testPending = false;
$("#testBtn .fa-spinner").css("display", "none");
});
}
var chart = null;
var allData = [];
......
......@@ -23,6 +23,7 @@
<h2>My Agent</h2>
<ul class="list-inline pull-right">
<li><a href="#" id="testBtn" onclick="buildAgent()" class="btn btn-default"><i class="fa fa-spinner fa-spin fa-fw" style="display: none" aria-hidden="true"></i>Evaluate</a></li>
<li><a href="#" id="testBtn" onclick="buildAgentFixed()" class="btn btn-default"><i class="fa fa-spinner fa-spin fa-fw" style="display: none" aria-hidden="true"></i>Benchmark</a></li>
<!--<li><a href="#" class="btn btn-primary">Submit</a></li>-->
<li><a href="#" class="btn btn-success" id="saveBtn" data-toggle="modal" data-target="#saveModal">Save Model</a></li>
</ul>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment