-
Notifications
You must be signed in to change notification settings - Fork 292
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Utility AI - framework and Editor [wip] #6323
base: master
Are you sure you want to change the base?
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #6323 +/- ##
============================================
- Coverage 28.60% 28.36% -0.24%
Complexity 14088 14088
============================================
Files 2784 2836 +52
Lines 273063 275337 +2274
Branches 48379 48565 +186
============================================
+ Hits 78100 78102 +2
- Misses 190983 193254 +2271
- Partials 3980 3981 +1 ☔ View full report in Codecov by Sentry. |
damageCache.clear(); | ||
} | ||
|
||
public abstract double getBonusFactor(DecisionContext<IN_GAME_OBJECT, TARGETABLE> lastContext); |
Check notice
Code scanning / CodeQL
Useless parameter Note
} | ||
} | ||
|
||
double getBonusFactor(Decision<IN_GAME_OBJECT, TARGETABLE> scoreEvaluator); |
Check notice
Code scanning / CodeQL
Useless parameter Note
|
||
public interface Intelligence<IN_GAME_OBJECT, TARGETABLE> { | ||
|
||
void update(Intelligence<IN_GAME_OBJECT, TARGETABLE> intelligence); |
Check notice
Code scanning / CodeQL
Useless parameter Note
void addDecisionScoreEvaluator(Decision<IN_GAME_OBJECT, TARGETABLE> scoreEvaluator); | ||
List<Decision<IN_GAME_OBJECT, TARGETABLE>> getDecisions(); | ||
DecisionMaker<IN_GAME_OBJECT, TARGETABLE> getDecisionMaker(); | ||
double getBonusFactor(Decision<IN_GAME_OBJECT, TARGETABLE> scoreEvaluator); |
Check notice
Code scanning / CodeQL
Useless parameter Note
return new LogitCurve(m, b, k, c); | ||
} | ||
|
||
public double evaluate(double x) { |
Check notice
Code scanning / CodeQL
Missing Override annotation Note
Curve.evaluate
return objects; | ||
} | ||
} | ||
logger.formattedErrorDialog("Invalid directory", "Input file {} is not a directory", inputFile); |
Check warning
Code scanning / CodeQL
Unused format argument Warning
try (MappingIterator<T> it = mapper.readerFor(clazz).readValues(file)) { | ||
return it.readAll(); | ||
} catch (IOException e) { | ||
logger.error(e, "Could not load file: {}", file); |
Check warning
Code scanning / CodeQL
Unused format argument Warning
82be31d
to
572a2a2
Compare
return new BandFilterCurve(m, b, k, c); | ||
} | ||
|
||
public double evaluate(double x) { |
Check notice
Code scanning / CodeQL
Missing Override annotation Note
Curve.evaluate
return new BandPassCurve(m, b, k, c); | ||
} | ||
|
||
public double evaluate(double x) { |
Check notice
Code scanning / CodeQL
Missing Override annotation Note
Curve.evaluate
} | ||
|
||
public static DefaultCurve fromCurve(Curve curve) { | ||
if (curve instanceof LinearCurve) { |
Check notice
Code scanning / CodeQL
Chain of 'instanceof' tests Note
return new LinearCurve(m, b); | ||
} | ||
|
||
public double evaluate(double x) { |
Check notice
Code scanning / CodeQL
Missing Override annotation Note
Curve.evaluate
return new LogisticCurve(m, b, k, c); | ||
} | ||
|
||
public double evaluate(double x) { |
Check notice
Code scanning / CodeQL
Missing Override annotation Note
Curve.evaluate
return new ParabolicCurve(m, b, k); | ||
} | ||
|
||
public double evaluate(double x) { |
Check notice
Code scanning / CodeQL
Missing Override annotation Note
Curve.evaluate
2f32e50
to
448b792
Compare
Development of a Utility AI framework to be implemented with a bot (preferably on top of princess, preferably creating a new way to have her make decisions).
This PR currently only implements a few considerations and an AI Editor, this PR intends to allow people to test and evaluate the usability of the AI Editor.
TODO: More information on the Utility AI, how it works, how it integrates with Princessm etc.