-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathReactGenerator.h
More file actions
80 lines (70 loc) · 2.82 KB
/
ReactGenerator.h
File metadata and controls
80 lines (70 loc) · 2.82 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
/*
********************************************************************************************
********************************************************************************************
!! React Generator for Robots !!
!! -:Developed By:- !!
!! !!
!! Md. Rakibul Hasan || TheZeroHz !!
!! Github: https://github.com/TheZeroHz !!
!! Last Updated: 17 March,2024 !!
********************************************************************************** V-1.0 ***
********************************************************************************************
*/
#ifndef REACTGENERATOR_H
#define REACTGENERATOR_H
#include<Arduino.h>
#include<esp_random.h>
#include "smaPersonality.h"
#include "Vector.h"
#include "rewardDB.h"
#include "reactDB.h"
#include "CLI.h"
#include "EmotionRating.h"
class ReactGenerator {
private:
rewardDB rwdDB;
reactDB rctDB;
SMA smaAttitude;
Vector<Reaction> reaction_logs;
Vector<Mood> mood_logs;
int _WindowSize_=default_WindowSize;
int _FrameSize_=default_FrameSize;
public:
float positivity_P, negativity_P;
CLI CMD;
Vector<double> reward_logs;
CharacterState character;
double reward_Multiplier[num_of_personality];
int moodChangeCounter=0;
ReactGenerator();
void setFrameSize(int _size_);
int getFrameSize();
void setWindowSize(int _size_);
int getWindowSize();
void slideWindow(Vector<double> &arr, int _frameSize_, int _windowSize_);
void setReaction(Personality p, Mood m, Action a, Reaction e);
Reaction getReaction(Personality p, Mood m, Action a);
char *reactionName(Reaction R);
void addReactionLogs(Reaction R);
Reaction getReactionLog(int index);
int getReactionLogsCount();
void showReactionLogs();
void setRewardMultiplier(double achiever,double balanced,double creative,double distressed);
void addRewardLogs(double x);
double getRewardLog(int index);
Vector<double> getRewardLog();
int getRewardLogsCount();
void showRewardLogs();
Mood predictMood();
char *moodName(Mood M);
void showMoodDetails();
void addMoodLogs(Mood M);
void showMoodLogs();
Mood getMoodLog(int index);
int getMoodLogsCount();
Personality predictPersonality();
char *personalityName(Personality P);
char * getActionName(Action action);
Action getActionByName(const char* actionName);
};
#endif /* REACTGENERATOR_H */