feat: Add Be and tbd skill, also added Roadmap file

This commit is contained in:
2026-05-10 16:32:12 -04:00
parent 3500ade13f
commit 0bb8885802
29587 changed files with 10611695 additions and 0 deletions

View File

@@ -0,0 +1,96 @@
/**
* Jibo's emotion has changed. Gives the last available emotion.
* @type {Event<jibo.emotion.Emotion>}
* @name jibo.emotion.EmotionEvents#emotionChanged
*/
/**
* @class EmotionSystem
* @description The entire Emotion System and management of Jibo's internal emotional state,
* including the Appraisal System, Expression System, Sensory System, and Emotional Space.
* @memberof jibo.emotion
* @private
* @internal
*/
/**
* This is a record of all emotional events Jibo is aware of, containing Sensor data, appraisal rules
* the previous and new emotional states, and what expressions if any occurred as a result
* @type {Array<jibo.emotion.emotionTrace>}
* @name jibo.emotion.EmotionSystem#history
* @private
*/
/**
* The emotional events of the EmotionSystem
* @type {jibo.emotion.EmotionEvents}
* @name jibo.emotion.EmotionSystem#events
* @private
*/
/**
* Emotion Wrappers
* @type {jibo.emotion.Emotion[]}
* @name jibo.emotion.EmotionSystem#emotions
* @private
*/
/**
* Provides default rules given a sensory system
* @type {jibo.emotion.appraisal.AppraisalRule[]}
* @name jibo.emotion.EmotionSystem#rules
* @private
*/
/**
* The various sensors used to input emotional data and affect Jibo's
* emotional landscape.
* @const {Array.<Sensor>}
* @memberOf jibo.emotion
* @private
*/
/**
* This should not be a part of the external API
* @internal
* @int-docs
* @private
*/
/**
* The current emotional P.A.D. space that represents what Jibo is feeling
* in relation to his other possible emotional states.
* @type {jibo.emotion.EmotionSpace}
* @private
* @memberOf jibo.emotion
*/
/**
* The sensory system that aggregates all sensors and provides a single
* point of interactions for events.
* @type {jibo.emotion.SensorySystem}
* @private
* @memberOf jibo.emotion
*/
/**
* The perceptual appraisal system that interprets sensory input that
* affects Jibo.
* @type {jibo.emotion.AppraisalSystem}
* @private
* @memberOf jibo.emotion
*/
/**
* The system that maps emotions and emotional impacts to actions via the Action System plugin
* @type {jibo.emotion.ExpressionSystem}
* @private
* @memberOf jibo.emotion
*/
/**
* Map of expression names to Expression objects
* @type {Map<jibo.emotion.EmotionName, jibo.emotion.EmotionalExpression>}
* @private
* @memberOf jibo.emotion
*/

View File

@@ -0,0 +1,7 @@
/**
* The instance of the runtime. We expose it on the API just for
* testing and special circumstances. Not meant to be accessed for standard use.
* @type {jibo.emotion.EmotionSystem}
* @internal
* @private
*/

View File

@@ -0,0 +1,49 @@
/**
* @description Events related to the appraisal system
* @namespace jibo.emotion.appraisal.events
* @private
* @internal
*/
/**
* An event triggered whenever when Jibo's emotions should be repositioned.
* For example, if Jibo's sensors have detected some new change, Jibo needs
* to interpret those events.
* @type {Event}
* @name jibo.emotion.appraisal.events#impactTriggered
*/
/**
* @description The system which registers and manages incoming sensory inputs
* against appraisal rules to determine if and how they should impact Jibo's internal
* emotional state.
* @namespace jibo.emotion.appraisal
* @internal
* @private
*/
/**
* The events that the system can use.
* @type {jibo.emotion.appraisal.events}
* @name jibo.emotion.appraisal#events
*/
/**
* A set of rules that the system relies on to generate emotional impact.
* @type {Set<AppraisalRule>}
* @name jibo.emotion.appraisal#_rules
* @private
*/
/** @override */
/**
* Cleans up and disconnects all allocated resources.
* @method jibo.emotion.appraisal#dispose
*/
/**
* Takes all the rules and registers them on the system.
* @name jibo.emotion.appraisal#_registerRules
* @private
*/

View File

@@ -0,0 +1,36 @@
/**
* A list of words that Jibo should assume is good.
* @const {Array.<String>}
* @internal
*/
/**
* Pattern used to detect words that Jibo inteprets as good and desirable.
* @const {RegExp}
* @internal
*/
/**
* A list of words that Jibo should assume is bad.
* @const {Array.<String>}
* @internal
*/
/**
* Pattern used to detect words that Jibo interprets as negative/bad.
* @const {RegExp}
* @internal
*/
/**
* @internal
*/
/** @override */
/**
* Function that receives a sensorDataWrapper from a sensor
* @param sensorDataWrapper
*/
/** @override */

View File

@@ -0,0 +1,18 @@
/**
* @internal
*/
/**
* @internal
*/
/**
* @param {*} data Any data to initialize rule.
*/
/**
*/
/**
* @param {*} data Any input data to appraise.
*/

View File

@@ -0,0 +1,12 @@
/**
* @internal
*/
/** @override */
/**
* Function that receives a sensorDataWrapper from a sensor
* @param sensorDataWrapper
*/
/** @override */

View File

@@ -0,0 +1,7 @@
/**
* @internal
*/
/** @override */
/** @override */

View File

@@ -0,0 +1,7 @@
/**
* @internal
*/
/** @override */
/** @override */

View File

@@ -0,0 +1,7 @@
/**
* @internal
*/
/** @override */
/** @override */

View File

@@ -0,0 +1,7 @@
/**
* @internal
*/
/** @override */
/** @override */

View File

@@ -0,0 +1,43 @@
/**
* Options we send to jibo.action.addPlayAnimationGoal
* @memberof jibo.emotion
* @interface AnimationOptions
* @property {string} [category] The category of anim to be selected
* @property {string} [name] The name of the goal to be played
* @property {string[]} [includeMeta] Any additional metadata around selection of animations
* @property {boolean} [randomOrientation] Whether orientation should be random
* @internal
* @private
*/
/**
* Options for touch events
* @memberof jibo.emotion
* @interface TouchOptions
* @property {jibo.emotion.TouchTypes} [type] The type of touch detected
* @property {boolean} [randomOrientation] Whether orientation should be random
* @internal
* @private
*/
/**
* Constant impacts of appraisal rules, in one central location
* @memberof jibo.emotion
* @typedef RuleImpactValues
* @property {number} PRESENCE_STARTED_VALENCE the VALENCE impact of a PRESENCE_STARTED event.
* @property {number} PRESENCE_STARTED_CONFIDENCE the CONFIDENCE impact of a PRESENCE_STARTED event.
* @property {number} VISIBLE_FACE_STARTED_VALENCE the VALENCE impact of a VISIBLE_FACE_STARTED event.
* @property {number} VISIBLE_FACE_STARTED_CONFIDENCE the CONFIDENCE impact of a VISIBLE_FACE_STARTED event.
* @property {number} ID_ACQUIRED_VALENCE the VALENCE impact of a ID_ACQUIRED event.
* @property {number} ID_ACQUIRED_CONFIDENCE the CONFIDENCE impact of a ID_ACQUIRED event.
* @property {number} HEAD_TOUCH_VALENCE the VALENCE impact of a HEAD_TOUCH event.
* @property {number} HEAD_TOUCH_CONFIDENCE the CONFIDENCE impact of a HEAD_TOUCH event.
* @property {number} TICKLE_VALENCE the VALENCE impact of a TICKLE event.
* @property {number} TICKLE_CONFIDENCE the CONFIDENCE impact of a TICKLE event.
* @property {number} MOTOR_FAULT_VALENCE the VALENCE impact of a MOTOR_FAULT event.
* @property {number} MOTOR_FAULT_CONFIDENCE the CONFIDENCE impact of a MOTOR_FAULT event.
* @property {number} MIM_ERROR_VALENCE the VALENCE impact of a MIM_ERROR event.
* @property {number} MIM_ERROR_CONFIDENCE the CONFIDENCE impact of a MIM_ERROR event.
* @internal
* @private
*/

View File

@@ -0,0 +1,18 @@
/**
* Takes a value and makes sure that it doesn't exceed the min or max value
* defined.
* @param {Number} value Numeric value to normalize within range.
* @param {Number} min The minimum value to not exceed downward.
* @param {Number} max The maximum value to not exceed upwards.
* @return {Number} The normalized value within the min and max range.
*/
/**
* Gets the Euclidean distance for 2 objects, given a list of properties
* to calculate the score with.
* @param {Object} a The first item to compare.
* @param {Object} b The second item to compare.
* @param {Array.<String>} properties A list of property names that exist
* on both objects that contain the dimension values to include in score.
* @return {Number} The distance between the 2 objects.
*/

View File

@@ -0,0 +1,20 @@
/**
* @internal
*/
/**
* The number of seconds between emotion decays.
* @internal
*/
/**
* @internal
*/
/**
* @internal
*/
/**
* @internal
*/

View File

@@ -0,0 +1,139 @@
/**
* @description Events related to Jibo's emotional space.
* @namespace jibo.emotion.emotionSpace.events
* @private
* @internal
*/
/**
* Triggered whenever the current emotion has changed.
* Emits the new emotional state.
* @type {jibo.emotion.Emotion}
* @name jibo.emotion.emotionSpace.events#changeEvent
*/
/**
* Triggers every emotional update.
* Emits the trace with which it was updated
* @type {jibo.emotion.EmotionTrace}
* @name jibo.emotion.emotionSpace.events#updated
*/
/**
* @description The management and coordination of Jibo's current internal emotional state.
* @namespace jibo.emotion.emotionSpace
* @private
* @internal
*/
/**
* Events related to changes in jibo's internal emotional state.
* @type {jibo.emotion.emotionSpace.events}
* @name jibo.emotion.emotionSpace#events
*/
/**
* All registered emotions that the system is aware of.
* @type {Set<jibo.emotion.Emotion>}
* @name jibo.emotion.emotionSpace#emotions
*/
/**
* The current emotional position of Jibo, aka his current emotional state.
* @type {Set<jibo.emotion.EmotionPoint>}
* @name jibo.emotion.emotionSpace#currentEmotionPoint
* @private
*/
/**
* The last known position of Jibo's emotional state.
* @type {Set<jibo.emotion.EmotionPoint>}
* @name jibo.emotion.emotionSpace#lastEmotionPoint
* @private
*/
/**
* The rate by which the emotion will normalize back to a neutral state
* after impact in any direction.
* @type {number}
* @name jibo.emotion.emotionSpace#_decayImpactPerHour
* @private
*/
/**
* The unique ID of the setInterval timer for updating the decay rate tick.
* @type {number}
* @name jibo.emotion.emotionSpace#_decayTimerId
* @private
*/
/**
* The type of timeout we'll be setting -- either jibo internal or sinon for tests
* @name jibo.emotion.emotionSpace#setTimeout
* @private
*/
/**
* The type of timeout we'll be setting -- either jibo internal or sinon for tests
* @name jibo.emotion.emotionSpace#setTimeout
* @private
*/
/**
* The most recent emotion trace that impacted this space.
* @name jibo.emotion.emotionSpace#lastEmotionTrace
* @private
*/
/** @override */
/**
* Initialize Emotional Space
* @param {Array<jibo.emotion.Emotion>} emotions Emotions to initialize Jibo's emotional
* space with.
* @method jibo.emotion.emotionSpace#init
*/
/**
* Retrieves the emotion closest to the current state given a threshold.
* @param {jibo.emotion.Emotion} referenceEmotion An emotion to find the neighbor of.
* @return {jibo.emotion.Emotion} The emotional state or null if under threshold.
* @method jibo.emotion.emotionSpace#getNearestEmotion
*/
/**
* Returns the current Emotional State
* @return {jibo.emotion.EmotionPoint} The current emotional state.
* @method jibo.emotion.emotionSpace#getCurrentPosition
*/
/**
* Get the most recent emotion trace that impacted this space.
* @return {jibo.emotion.EmotionTrace} The most recent impacting emotional trace.
* @method jibo.emotion.emotionSpace#getLastTrace
*/
/**
* Cleans up and disconnects all allocated resources.
* @method jibo.emotion.emotionSpace#dispose
*/
/**
* Updates the current emotional state of Jibo in a P.A.D space.
* Emits an event to the Expression System if a change in Emotion occurs
* @param {jibo.emotion.emotionTrace} emotionTrace. The trace of the emotion events that led to this
* @method jibo.emotion.emotionSpace#update
*/
/**
* Resets the current emotion state to jibo baseline values
* @returns {jibo.emotion.emotionTrace} Updated emotionTrace that caused neutral state
* @method jibo.emotion.emotionSpace#_resetToNeutral
*/
/**
* Begins the process of decaying Jibo's emotions, which will return his
* emotions back to a neutral state over time.
* @method jibo.emotion.emotionSpace#_startToDecayEmotions
* @private
*/

View File

@@ -0,0 +1,54 @@
/**
* @description Trace of an emotional impact transition.
* @namespace jibo.emotion.emotionTrace
* @private
* @internal
*/
/**
* A list of the sensors involved in this emotional event.
* @type {Array<SensorDataWrapper>}
* @name jibo.emotion.emotionTrace#sensorDataWrappers
*/
/**
* The rule whicsh applies in this emotional event.
* @type {AppraisalRule}
* @name jibo.emotion.emotionTrace#appraisalRule
*/
/**
* The impact on Jibo's emotional state of this emotional event.
* @type {jibo.emotion.EmotionPoint}
* @name jibo.emotion.emotionTrace#emotionalImpact
*/
/**
* The starting position of Jibo's emotional state before this emotional event.
* @type {jibo.emotion.Emotion}
* @name jibo.emotion.emotionTrace#startingPosition
*/
/**
* The ending position of Jibo's emotional state after this emotional event.
* @type {jibo.emotion.Emotion}
* @name jibo.emotion.emotionTrace#newPosition
*/
/**
* The nearest categorized emotion after this emotional event.
* @type {jibo.emotion.Emotion}
* @name jibo.emotion.emotionTrace#nearestEmotionAfterImpact
*/
/**
* The nearest categorized emotion before this emotional event.
* @type {jibo.emotion.Emotion}
* @name jibo.emotion.emotionTrace#emotionBeforeImpact
*/
/**
* The expression of the nearest emotion after impact.
* @type {EmotionalExpression}
* @name jibo.emotion.emotionTrace#expression
*/

View File

@@ -0,0 +1,13 @@
/**
* The name of the emotion which this expression represents
* @type {string}
* @name jibo.emotion.expression.EmotionalExpression#name
*/
/** @override */
/**
* @param {jibo.emotion.Emotion} emotion The emotion which Jibo will attempt to express.
* @return {Promise} Resolved when the emotional action is finished being performed.
* @method jibo.emotion.expression.EmotionalExpression#run
*/

View File

@@ -0,0 +1,4 @@
/**
* @enum jibo.emotion.TouchExpressions
* @internal
*/

View File

@@ -0,0 +1,38 @@
/**
* @description Management and coordination of jibo's expressions.
* @namespace jibo.emotion.expression
* @private
* @internal
*/
/**
* Verify that all emotions in a given emotional space have valid expressions
* in this expression system instance.
* @param {jibo.emotion.emotionSpace} emotionSpace emotionSpace to verify against
* @method jibo.emotion.expression#verifyExpressionsExist
*/
/**
* Track a snuggle.
* Previously this is where an emotional trace was expressed, it would result in animations for snuggles and emotion changes.
* all that's gone now, but should be put back in to the phoenix/v2 emotion system
* @param {jibo.emotion.EmotionTrace} emotionTrace The emotion to express in expressions.
* @method jibo.emotion.expression#trackSnuggle
*/
/**
* Express a given emotion
* @param {jibo.emotion.Emotion} emotion The emotion to express in expressions.
* @return {Promise} Promise that is resolved when Jibo's expression has
* finished.
* @method jibo.emotion.expression#expressEmotion
*/
/**
* Cleans up and disconnects all allocated resources.
* @method jibo.emotion.expression#dispose
*/
/**
* Cache snuggle animations
*/

View File

@@ -0,0 +1,26 @@
/**
* @description Sensory management of Jibo's sensory inputs.
* @namespace jibo.emotion.sensors
* @private
* @internal
*/
/**
* A list of the sensors involved in this emotional event.
* @type {Map<string, Sensor>}
* @name jibo.emotion.sensors#sensorMap
* @private
*/
/**
* Initialize the sensory system with an array of sensors to be installed.
* @param {Sensor[]} sensors Sensors that will be installed as part of Jibo's sensory system
* @method jibo.emotion.sensors#init
*/
/**
* Returns an installed sensor of a given name if it exists
* @param {String} name Name of sensor to get
* @returns {Sensor<any>} The corresponding sensor
* @method jibo.emotion.sensors#getSensor
*/

View File

@@ -0,0 +1,7 @@
/**
* @internal
*/
/**
* Clean up any resources we left around
*/

View File

@@ -0,0 +1,3 @@
/**
* @internal
*/

View File

@@ -0,0 +1,11 @@
/**
* @internal
*/
/**
* @internal
*/
/**
* Deallocate and clean up any resources that were created.
*/

View File

@@ -0,0 +1,7 @@
/**
* @internal
*/
/**
* Clean up any resources we left around
*/

View File

@@ -0,0 +1,15 @@
/**
* @internal
*/
/**
* @internal
*/
/**
* @internal
*/
/**
* Deallocate and clean up any resources that were created.
*/

View File

@@ -0,0 +1,31 @@
/**
* @internal
*/
/**
* @internal
*/
/**
* @internal
*/
/**
* Can be used to retrieve the last supplied data point
* @returns {T}
*/
/**
* This method should be called to provide the latest data available to
* this sensor
* @param {T} data
*/
/**
* life cycle of the sensor.
*/
/**
* Cleans up components, listeners, that were attached during setup or
* life cycle of the sensor.
*/

View File

@@ -0,0 +1,25 @@
/**
* @internal
*/
/**
* @internal
*/
/**
* Deallocate and clean up any resources that were created.
*/
/**
* React to a set head of head pads being touched and return the animation that should be played
* @param {boolean[]} pads which head pads were touched
* @returns {AnimQuery | null} query to be played, null if none applies
*/
/**
* Triggered whenever multiple jibo touch sensors are activated.
*/
/**
* Triggered whenever only pad 5 is touched.
*/

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long