{"action":"created","comment":{"url":"https://api.github.com/repos/vqtran/EchoQuery/pulls/comments/60763852","id":60763852,"diff_hunk":"@@ -178,6 +189,61 @@\n         \"below or equal\",\n         \"is below or equal\"\n     }));\n+    refineAddExpr.addAll(Arrays.asList(new String[]{\n+        \"and\",\n+        \"and if\",\n+        \"and when\",\n+        \"and where\",\n+        \"and also\",\n+        \"and also where\",\n+        \"also\",\n+        \"also if\",\n+        \"also when\",\n+        \"also where\",\n+        \"add\",\n+        \"add where\",\n+        \"also add\",\n+        \"also add where\"\n+    }));\n+    refineReplaceExpr.addAll(Arrays.asList(new String[]{\n+        \"what if\",\n+        \"what if we\",\n+        \"what if where\",\n+        \"how about\",\n+        \"how about where\",\n+        \"how about if\",\n+        \"instead\",\n+        \"instead how about\",\n+        \"instead where\",\n+        \"instead how about where\",\n+        \"actually\",\n+        \"actually how about where\"\n+    }));\n+    refineDropExpr.addAll(Arrays.asList(new String[]{\n+        \"drop\",\n+        \"drop where\",\n+        \"drop the\",\n+        \"drop the part\",\n+        \"drop the part where\",\n+        \"drop the clause\",\n+        \"drop the clause where\",\n+        \"forget\",\n+        \"forget the\",\n+        \"forget about\",\n+        \"forget where\",\n+        \"forget about where\",\n+        \"forget the part\",\n+        \"forget the part where\",\n+        \"forget the clause\",\n+        \"forget the clause where\",\n+        \"remove\",\n+        \"remove the\",\n+        \"remove where\",\n+        \"remove the part\",\n+        \"remove the part where\",\n+        \"remove the clause\",\n+        \"remove the clause where\"\n+    }));","path":"src/main/java/echoquery/utils/SlotUtil.java","position":97,"original_position":97,"commit_id":"eb24dfba8821febd34156507e5cbc5b2d9568404","original_commit_id":"eb24dfba8821febd34156507e5cbc5b2d9568404","user":{"login":"vqtran","id":3363601,"avatar_url":"https://avatars.githubusercontent.com/u/3363601?v=3","gravatar_id":"","url":"https://api.github.com/users/vqtran","html_url":"https://github.com/vqtran","followers_url":"https://api.github.com/users/vqtran/followers","following_url":"https://api.github.com/users/vqtran/following{/other_user}","gists_url":"https://api.github.com/users/vqtran/gists{/gist_id}","starred_url":"https://api.github.com/users/vqtran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vqtran/subscriptions","organizations_url":"https://api.github.com/users/vqtran/orgs","repos_url":"https://api.github.com/users/vqtran/repos","events_url":"https://api.github.com/users/vqtran/events{/privacy}","received_events_url":"https://api.github.com/users/vqtran/received_events","type":"User","site_admin":false},"body":"Yeah or made a special json version of custom slots that we can read from Java, and compile into what Amazon needs. pipe dreams.","created_at":"2016-04-22T16:09:34Z","updated_at":"2016-04-22T16:09:34Z","html_url":"https://github.com/vqtran/EchoQuery/pull/48#discussion_r60763852","pull_request_url":"https://api.github.com/repos/vqtran/EchoQuery/pulls/48","_links":{"self":{"href":"https://api.github.com/repos/vqtran/EchoQuery/pulls/comments/60763852"},"html":{"href":"https://github.com/vqtran/EchoQuery/pull/48#discussion_r60763852"},"pull_request":{"href":"https://api.github.com/repos/vqtran/EchoQuery/pulls/48"}}},"pull_request":{"url":"https://api.github.com/repos/vqtran/EchoQuery/pulls/48","id":66271805,"html_url":"https://github.com/vqtran/EchoQuery/pull/48","diff_url":"https://github.com/vqtran/EchoQuery/pull/48.diff","patch_url":"https://github.com/vqtran/EchoQuery/pull/48.patch","issue_url":"https://api.github.com/repos/vqtran/EchoQuery/issues/48","number":48,"state":"open","locked":false,"title":"Sophisticated RefineIntent with Add/Replace/Drop implemented.","user":{"login":"vqtran","id":3363601,"avatar_url":"https://avatars.githubusercontent.com/u/3363601?v=3","gravatar_id":"","url":"https://api.github.com/users/vqtran","html_url":"https://github.com/vqtran","followers_url":"https://api.github.com/users/vqtran/followers","following_url":"https://api.github.com/users/vqtran/following{/other_user}","gists_url":"https://api.github.com/users/vqtran/gists{/gist_id}","starred_url":"https://api.github.com/users/vqtran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vqtran/subscriptions","organizations_url":"https://api.github.com/users/vqtran/orgs","repos_url":"https://api.github.com/users/vqtran/repos","events_url":"https://api.github.com/users/vqtran/events{/privacy}","received_events_url":"https://api.github.com/users/vqtran/received_events","type":"User","site_admin":false},"body":"Ready to be reviewed & merged! Refine intent with add/replace/drop implemented.\r\n\r\n1. Add works as you would expect, you can add up to three clauses at a time.\r\n2. Replace logic is more complicated. If all the columns in replace exist in the query already, then just replace what they're comparing. If there are any columns not in the query already, remove all clauses already in the query in favor of the new ones.\r\n3. Drop works as expected, \"remove where gender is male\".\r\n\r\nI addressed the problem with ambiguous tables in the refinement in a naive way - no schema inference, there was a lot of challenges if we wanted to do that. Instead I say two columns are the same if 1. they are an exact match (table and column names match) or if 2. the column in the refinement doesn't have a specified table and its column name matches.","created_at":"2016-04-13T06:32:48Z","updated_at":"2016-04-22T16:09:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":"784de936bd29aa8f14e46c1ed3774822bd27fd66","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/vqtran/EchoQuery/pulls/48/commits","review_comments_url":"https://api.github.com/repos/vqtran/EchoQuery/pulls/48/comments","review_comment_url":"https://api.github.com/repos/vqtran/EchoQuery/pulls/comments{/number}","comments_url":"https://api.github.com/repos/vqtran/EchoQuery/issues/48/comments","statuses_url":"https://api.github.com/repos/vqtran/EchoQuery/statuses/eb24dfba8821febd34156507e5cbc5b2d9568404","head":{"label":"vqtran:RefineIntent","ref":"RefineIntent","sha":"eb24dfba8821febd34156507e5cbc5b2d9568404","user":{"login":"vqtran","id":3363601,"avatar_url":"https://avatars.githubusercontent.com/u/3363601?v=3","gravatar_id":"","url":"https://api.github.com/users/vqtran","html_url":"https://github.com/vqtran","followers_url":"https://api.github.com/users/vqtran/followers","following_url":"https://api.github.com/users/vqtran/following{/other_user}","gists_url":"https://api.github.com/users/vqtran/gists{/gist_id}","starred_url":"https://api.github.com/users/vqtran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vqtran/subscriptions","organizations_url":"https://api.github.com/users/vqtran/orgs","repos_url":"https://api.github.com/users/vqtran/repos","events_url":"https://api.github.com/users/vqtran/events{/privacy}","received_events_url":"https://api.github.com/users/vqtran/received_events","type":"User","site_admin":false},"repo":{"id":44494789,"name":"EchoQuery","full_name":"vqtran/EchoQuery","owner":{"login":"vqtran","id":3363601,"avatar_url":"https://avatars.githubusercontent.com/u/3363601?v=3","gravatar_id":"","url":"https://api.github.com/users/vqtran","html_url":"https://github.com/vqtran","followers_url":"https://api.github.com/users/vqtran/followers","following_url":"https://api.github.com/users/vqtran/following{/other_user}","gists_url":"https://api.github.com/users/vqtran/gists{/gist_id}","starred_url":"https://api.github.com/users/vqtran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vqtran/subscriptions","organizations_url":"https://api.github.com/users/vqtran/orgs","repos_url":"https://api.github.com/users/vqtran/repos","events_url":"https://api.github.com/users/vqtran/events{/privacy}","received_events_url":"https://api.github.com/users/vqtran/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/vqtran/EchoQuery","description":"Spoken dialogue querying for SQL databases.","fork":false,"url":"https://api.github.com/repos/vqtran/EchoQuery","forks_url":"https://api.github.com/repos/vqtran/EchoQuery/forks","keys_url":"https://api.github.com/repos/vqtran/EchoQuery/keys{/key_id}","collaborators_url":"https://api.github.com/repos/vqtran/EchoQuery/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/vqtran/EchoQuery/teams","hooks_url":"https://api.github.com/repos/vqtran/EchoQuery/hooks","issue_events_url":"https://api.github.com/repos/vqtran/EchoQuery/issues/events{/number}","events_url":"https://api.github.com/repos/vqtran/EchoQuery/events","assignees_url":"https://api.github.com/repos/vqtran/EchoQuery/assignees{/user}","branches_url":"https://api.github.com/repos/vqtran/EchoQuery/branches{/branch}","tags_url":"https://api.github.com/repos/vqtran/EchoQuery/tags","blobs_url":"https://api.github.com/repos/vqtran/EchoQuery/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/vqtran/EchoQuery/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/vqtran/EchoQuery/git/refs{/sha}","trees_url":"https://api.github.com/repos/vqtran/EchoQuery/git/trees{/sha}","statuses_url":"https://api.github.com/repos/vqtran/EchoQuery/statuses/{sha}","languages_url":"https://api.github.com/repos/vqtran/EchoQuery/languages","stargazers_url":"https://api.github.com/repos/vqtran/EchoQuery/stargazers","contributors_url":"https://api.github.com/repos/vqtran/EchoQuery/contributors","subscribers_url":"https://api.github.com/repos/vqtran/EchoQuery/subscribers","subscription_url":"https://api.github.com/repos/vqtran/EchoQuery/subscription","commits_url":"https://api.github.com/repos/vqtran/EchoQuery/commits{/sha}","git_commits_url":"https://api.github.com/repos/vqtran/EchoQuery/git/commits{/sha}","comments_url":"https://api.github.com/repos/vqtran/EchoQuery/comments{/number}","issue_comment_url":"https://api.github.com/repos/vqtran/EchoQuery/issues/comments{/number}","contents_url":"https://api.github.com/repos/vqtran/EchoQuery/contents/{+path}","compare_url":"https://api.github.com/repos/vqtran/EchoQuery/compare/{base}...{head}","merges_url":"https://api.github.com/repos/vqtran/EchoQuery/merges","archive_url":"https://api.github.com/repos/vqtran/EchoQuery/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/vqtran/EchoQuery/downloads","issues_url":"https://api.github.com/repos/vqtran/EchoQuery/issues{/number}","pulls_url":"https://api.github.com/repos/vqtran/EchoQuery/pulls{/number}","milestones_url":"https://api.github.com/repos/vqtran/EchoQuery/milestones{/number}","notifications_url":"https://api.github.com/repos/vqtran/EchoQuery/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/vqtran/EchoQuery/labels{/name}","releases_url":"https://api.github.com/repos/vqtran/EchoQuery/releases{/id}","deployments_url":"https://api.github.com/repos/vqtran/EchoQuery/deployments","created_at":"2015-10-18T20:17:15Z","updated_at":"2016-02-21T05:16:28Z","pushed_at":"2016-04-22T03:40:18Z","git_url":"git://github.com/vqtran/EchoQuery.git","ssh_url":"git@github.com:vqtran/EchoQuery.git","clone_url":"https://github.com/vqtran/EchoQuery.git","svn_url":"https://github.com/vqtran/EchoQuery","homepage":"","size":1902,"stargazers_count":1,"watchers_count":1,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":5,"forks":0,"open_issues":5,"watchers":1,"default_branch":"master"}},"base":{"label":"vqtran:master","ref":"master","sha":"3680b1704f0319e225294a2d7810ffd20c86a116","user":{"login":"vqtran","id":3363601,"avatar_url":"https://avatars.githubusercontent.com/u/3363601?v=3","gravatar_id":"","url":"https://api.github.com/users/vqtran","html_url":"https://github.com/vqtran","followers_url":"https://api.github.com/users/vqtran/followers","following_url":"https://api.github.com/users/vqtran/following{/other_user}","gists_url":"https://api.github.com/users/vqtran/gists{/gist_id}","starred_url":"https://api.github.com/users/vqtran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vqtran/subscriptions","organizations_url":"https://api.github.com/users/vqtran/orgs","repos_url":"https://api.github.com/users/vqtran/repos","events_url":"https://api.github.com/users/vqtran/events{/privacy}","received_events_url":"https://api.github.com/users/vqtran/received_events","type":"User","site_admin":false},"repo":{"id":44494789,"name":"EchoQuery","full_name":"vqtran/EchoQuery","owner":{"login":"vqtran","id":3363601,"avatar_url":"https://avatars.githubusercontent.com/u/3363601?v=3","gravatar_id":"","url":"https://api.github.com/users/vqtran","html_url":"https://github.com/vqtran","followers_url":"https://api.github.com/users/vqtran/followers","following_url":"https://api.github.com/users/vqtran/following{/other_user}","gists_url":"https://api.github.com/users/vqtran/gists{/gist_id}","starred_url":"https://api.github.com/users/vqtran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vqtran/subscriptions","organizations_url":"https://api.github.com/users/vqtran/orgs","repos_url":"https://api.github.com/users/vqtran/repos","events_url":"https://api.github.com/users/vqtran/events{/privacy}","received_events_url":"https://api.github.com/users/vqtran/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/vqtran/EchoQuery","description":"Spoken dialogue querying for SQL databases.","fork":false,"url":"https://api.github.com/repos/vqtran/EchoQuery","forks_url":"https://api.github.com/repos/vqtran/EchoQuery/forks","keys_url":"https://api.github.com/repos/vqtran/EchoQuery/keys{/key_id}","collaborators_url":"https://api.github.com/repos/vqtran/EchoQuery/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/vqtran/EchoQuery/teams","hooks_url":"https://api.github.com/repos/vqtran/EchoQuery/hooks","issue_events_url":"https://api.github.com/repos/vqtran/EchoQuery/issues/events{/number}","events_url":"https://api.github.com/repos/vqtran/EchoQuery/events","assignees_url":"https://api.github.com/repos/vqtran/EchoQuery/assignees{/user}","branches_url":"https://api.github.com/repos/vqtran/EchoQuery/branches{/branch}","tags_url":"https://api.github.com/repos/vqtran/EchoQuery/tags","blobs_url":"https://api.github.com/repos/vqtran/EchoQuery/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/vqtran/EchoQuery/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/vqtran/EchoQuery/git/refs{/sha}","trees_url":"https://api.github.com/repos/vqtran/EchoQuery/git/trees{/sha}","statuses_url":"https://api.github.com/repos/vqtran/EchoQuery/statuses/{sha}","languages_url":"https://api.github.com/repos/vqtran/EchoQuery/languages","stargazers_url":"https://api.github.com/repos/vqtran/EchoQuery/stargazers","contributors_url":"https://api.github.com/repos/vqtran/EchoQuery/contributors","subscribers_url":"https://api.github.com/repos/vqtran/EchoQuery/subscribers","subscription_url":"https://api.github.com/repos/vqtran/EchoQuery/subscription","commits_url":"https://api.github.com/repos/vqtran/EchoQuery/commits{/sha}","git_commits_url":"https://api.github.com/repos/vqtran/EchoQuery/git/commits{/sha}","comments_url":"https://api.github.com/repos/vqtran/EchoQuery/comments{/number}","issue_comment_url":"https://api.github.com/repos/vqtran/EchoQuery/issues/comments{/number}","contents_url":"https://api.github.com/repos/vqtran/EchoQuery/contents/{+path}","compare_url":"https://api.github.com/repos/vqtran/EchoQuery/compare/{base}...{head}","merges_url":"https://api.github.com/repos/vqtran/EchoQuery/merges","archive_url":"https://api.github.com/repos/vqtran/EchoQuery/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/vqtran/EchoQuery/downloads","issues_url":"https://api.github.com/repos/vqtran/EchoQuery/issues{/number}","pulls_url":"https://api.github.com/repos/vqtran/EchoQuery/pulls{/number}","milestones_url":"https://api.github.com/repos/vqtran/EchoQuery/milestones{/number}","notifications_url":"https://api.github.com/repos/vqtran/EchoQuery/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/vqtran/EchoQuery/labels{/name}","releases_url":"https://api.github.com/repos/vqtran/EchoQuery/releases{/id}","deployments_url":"https://api.github.com/repos/vqtran/EchoQuery/deployments","created_at":"2015-10-18T20:17:15Z","updated_at":"2016-02-21T05:16:28Z","pushed_at":"2016-04-22T03:40:18Z","git_url":"git://github.com/vqtran/EchoQuery.git","ssh_url":"git@github.com:vqtran/EchoQuery.git","clone_url":"https://github.com/vqtran/EchoQuery.git","svn_url":"https://github.com/vqtran/EchoQuery","homepage":"","size":1902,"stargazers_count":1,"watchers_count":1,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":5,"forks":0,"open_issues":5,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/vqtran/EchoQuery/pulls/48"},"html":{"href":"https://github.com/vqtran/EchoQuery/pull/48"},"issue":{"href":"https://api.github.com/repos/vqtran/EchoQuery/issues/48"},"comments":{"href":"https://api.github.com/repos/vqtran/EchoQuery/issues/48/comments"},"review_comments":{"href":"https://api.github.com/repos/vqtran/EchoQuery/pulls/48/comments"},"review_comment":{"href":"https://api.github.com/repos/vqtran/EchoQuery/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/vqtran/EchoQuery/pulls/48/commits"},"statuses":{"href":"https://api.github.com/repos/vqtran/EchoQuery/statuses/eb24dfba8821febd34156507e5cbc5b2d9568404"}}}}