package rsa
This package contains the implementation for the mathematical foundations of Rational Speech Act theory (Frank & Goodman, 2012).
- Alphabetic
- By Inheritance
- rsa
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
-
case class
Lexicon(vocabularySize: Int, contextSize: Int, data: Vector[Double], speakerDefinition: (Lexicon, Int) ⇒ Lexicon = Lexicon.asBlokpoeletalSpeaker, listenerDefinition: (Lexicon, Int) ⇒ Lexicon = Lexicon.asBlokpoelEtalListener) extends Serializable with Product
A lexicon as defined in the Rational Speech Act theory (Frank & Goodman, 2012).
A lexicon as defined in the Rational Speech Act theory (Frank & Goodman, 2012). This implementation supports both binary and graded lexicons. It also implements functions that constitute the Rational Speech Act model, i.e., to compute n-th order lexicons. The relationships between vocabulary and context are stored in a 1-dimensional vector. The following mapping:
R1
R2
R3
S1
0.8
0.2
0.0
S2
0.0
0.6
0.4
Is represented in data as a concatenation of the rows or length contextSize:
Vector[Double](0.8, 0.2, 0.0, 0.0, 0.6, 0.4)
Lexicons are immutable.
- vocabularySize
The size of the vocabulary of this lexicon.
- contextSize
The size of the context of this lexicon.
- data
A 1-dimensional vector representing the relations between the vocabulary and context.
- Annotations
- @SerialVersionUID()
-
class
StructuredLexicon extends Lexicon
A special type of Lexicon where signals and referents are represented by binary strings.
A special type of Lexicon where signals and referents are represented by binary strings. Signal-referent relations are based on a measure of representational similarity.
- Annotations
- @SerialVersionUID()
- sealed trait StructuredMappingFunction extends AnyRef
Value Members
-
object
EDIT_DISTANCE extends StructuredMappingFunction with Product with Serializable
Helper object that returns a function computing the edit distance between two binary string representations.
Helper object that returns a function computing the edit distance between two binary string representations.
- See also
See this Wikipedia entry on Edit Distance https://en.wikipedia.org/wiki/Edit_distance.
-
object
HAMMING_DISTANCE extends StructuredMappingFunction with Product with Serializable
Helper object that returns a function computing the hamming distance between two binary string representations.
Helper object that returns a function computing the hamming distance between two binary string representations.
- See also
See this Wikipedia entry on Hamming Distance https://en.wikipedia.org/wiki/Hamming_distance.
-
object
Lexicon extends Serializable
Companion object to Lexicon containing alternative constructors and generation functions.
-
object
StructuredLexicon extends Serializable
Companion object to StructuredLexicon containing functions to generate graded or binary structured lexicons.
Language Agents Simulation framework
For detailed documentation on using the framework please see the README.md file at the Github repository at https://github.com/markblokpoel/lanag-core.