getSimpleBestInfGainUttPreferences: Get the utterances for the speaker's best information gain

Description Usage Arguments Details Value Examples

View source: R/SRSA_UttChoiceOptimization.R

Description

Simple RSA

Determines the optimal utterance for the best information gain.

These are based on the valid utterances determined from the current objects in the scene.

The inferred listener's object preferences are computed assuming the listener picks a certain object and has certain object preferences.

Usage

1
2
3
4
5
6
getSimpleBestInfGainUttPreferences(
  currentObjects,
  softPrefValue,
  notObeyInst,
  klValueFactor
)

Arguments

currentObjects

A vector of three values in {1,...,27} specifying the target and the other two objects in the scene.

The target is the first object in the vector (index = 1).

softPrefValue

A parameter value between [0,infinity) (The larger the value the higher the tendency towards uniform liking).

Value reflects how categorical the listener's preferences are:

0: The listener always picks her preferred object.

If the listener prefers red objects, she will always pick the red object in the scene.

infinity: It is as likely for the listener to pick green, blue or red objects.

notObeyInst

Determines the extent to which the instruction of the speaker is obeyed by the listener.

(0 = full obedience, infinity = full instruction ignorance).

Example:

0: Listener always picks red objects following the utterance "red".

infinity: Listener as likely to pick green, blue or red objects even if the utterance is "red".

klValueFactor

A parameter that can be negative, zero or positive:

zero

Don't care about learning about feature preferences of the listener

positive

Care about learning about feature preferences of the listener

negative

Trying to pick non-ambiguous utterances

Details

This function uses the function simpleBestInfGainUtterance.

Value

A vector containing the normalized probability over utterances given the listener's object preference priors.

The utterance with the highest probability is the one that maximizes the information gain for the speaker.

The vector has the same length as the validUtterances vector.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
In the case of these objects being in a scene:

     [shape] [pattern] [color]
[1,] "cloud"  "solid" "blue"
[2,] "circle" "solid" "blue"
[3,] "square" "solid" "blue"

and these being the indices for the valid utterances:

[1] 1 2 3 4 7 (cloud, circle, square, solid, blue)

Then uttering solid or blue would be best in order to gain
information about the shape preferences of the listener:
getSimpleBestInfGainUttPreferences(currentObjects, softPrefValue,
notObeyInst, klValueFactor)

output:
[1] 0.0 0.0 0.0 0.5 0.5

You can see here that the indices with the highest probability, namely 4 and 5,
correspond to the indices in the validUtterance vector for the feature
values 4 (solid) (index = 4) and 7 (blue) (index = 5).

haniaelkersh/rsa-publish-test documentation built on Jan. 31, 2021, 2:02 a.m.