Skip to content
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

_dist in Meaning: either make tuple or eliminate #31

Open
shanest opened this issue Feb 5, 2024 · 5 comments
Open

_dist in Meaning: either make tuple or eliminate #31

shanest opened this issue Feb 5, 2024 · 5 comments
Assignees

Comments

@shanest
Copy link
Collaborator

shanest commented Feb 5, 2024

_dist in Meaning is still a dict. I thought about quickly changing it to a tuple, but wanted to discuss another possibility: just eliminating it all together. A Meaning still has a Universe, which itself has a prior, so we can get a distribution for the Meaning from the Universes. Are there situations where we want the Meaning to be a distribution that comes from some other source than this?

@nathimel
Copy link
Collaborator

nathimel commented Feb 6, 2024

Ah, I tend towards making it a tuple. I had similar thought process when recently working on the recent hashability issues but for whatever reason forgot to implement.

And yeah, while I think letting a Meaning encode the literal distribution over referents for its expression is clearly an important distinction from the prior ( e.g., color names), we haven't had a use case for this yet since the research ultk supports mainly assumes that every referent is equally, for each Expression/Meaning. But it's nice to have since much of the effcomm research does not make this assumption.

@nathimel nathimel self-assigned this Feb 6, 2024
@shanest
Copy link
Collaborator Author

shanest commented Feb 6, 2024

Yeah, I totally agree that hard-coding the uniform distribution is the "worst" solution. So I think the options are (i) dist is an arbitrary tuple; if it's not specified in __init__, we could default to initialize it according to self.universe.prior; or (ii) no dist at all in Meaning, always just appealing to the Universe. The question is whether (ii) is also too restrictive 🤔

@nathimel
Copy link
Collaborator

nathimel commented Feb 6, 2024

Oh, I see. What does it mean to initialize according to self.universe.prior? To take only the subset of probabilities from the universe prior corresponding to the Meaning.referents, and then renormalize?

@nathimel
Copy link
Collaborator

nathimel commented Feb 6, 2024

This commit has the tuple implementation, but defaults to the uniform distribution.

N.B.: the current modals implementation and indefinites example results assume the uniform distribution even if that is the 'worst', so maybe I'd add a kwarg for uniform initialization to replicate that behavior if we chose not to uniform initialize meanings by default

@nathimel
Copy link
Collaborator

nathimel commented Feb 7, 2024

After further consideration we have decided to explore letting _dist be a frozenset of (Referent, float) tuples. See #33

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants