8000 Simplified GrammarStatelet, made a new LambdaGrammarStatelet class for WikiTables by matt-gardner · Pull Request #1829 · allenai/allennlp · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Dec 16, 2022. It is now read-only.

Simplified GrammarStatelet, made a new LambdaGrammarStatelet class for WikiTables #1829

Merged
merged 8 commits into from
Oct 3, 2018

Conversation

matt-gardner
Copy link
Contributor

In writing a tutorial for the framework, I decided that we really don't need to worry about lambdas in the main GrammarStatelet class. So I made a new one that handled lambdas, and greatly simplified the main one. @OyvindTafjord @rajasagashe, this just means that when you create your initial state, you don't need to pass in empty objects for the lambda_stacks and context_actions arguments, because those arguments are now gone. Nothing else in your code should have to change.

@matt-gardner matt-gardner requested a review from pdasigi October 1, 2018 23:56
from allennlp.nn import util


# We're not actually inhereting from `GrammarStatelet` here because there's very little logic that
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This class is basically unmodified from the previous GrammarStatelet. The only things that are different are the docstrings and this comment.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Copy link
Member
@pdasigi pdasigi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@matt-gardner matt-gardner merged commit d8b13e0 into allenai:master Oct 3, 2018
@matt-gardner matt-gardner deleted the simplify_grammar_statelet branch October 3, 2018 02:27
pku-wuwei added a commit to pku-wuwei/allennlp that referenced this pull request Oct 3, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0