Closed mihail911 closed 7 years ago
Thanks! I think we can assume a KB will always be given.
I should have mentioned this earlier, but we're not really using uuid to
look up a KB except for data collection. Now every example is loaded with
its KB, so when I call link_entity
I can directly give it a KB object.
Does this make it easier?
On Thu, Dec 8, 2016 at 3:56 PM, Mihail Eric notifications@github.com wrote:
@mihail911 commented on this pull request.
In src/basic/lexicon.py https://github.com/stanfordnlp/game-dialogue/pull/18:
@@ -269,10 +275,14 @@ def link_entity(self, raw_tokens, return_entities=False, agent=1, uuid="NONE", k Note: Linking works differently here because we are considering intersection of lists across
I refactored this function a bit so you don't explicitly have to pass in kb_entities, but rather the scenarios are processed at the beginning when the lexicon is constructed. I still have to do something a bit more sensible if no scenarios file is given, in which case right now a random candidate is returned (i might do something a little better like return the entity for which the span is a substring, but this case is not crucial, since the hope is we'll be using primarily a heuristic or a learned system, and not really have a need for anything else).
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/stanfordnlp/game-dialogue/pull/18, or mute the thread https://github.com/notifications/unsubscribe-auth/ABJYpv_koqNE6YXPVbNh6cGucvW92Ywbks5rGJkrgaJpZM4LGDEI .
Added documentation, provide support for choosing between learned vs. heuristic systems, and returning entities in (canonical, (surface, type)) form