{"action":"created","comment":{"url":"https://api.github.com/repos/peoplepattern/lib-text/pulls/comments/46970060","id":46970060,"diff_hunk":"@@ -144,24 +170,57 @@ trait LangBundle {\n     termNgrams.toSet\n   }\n \n+  /**\n+   * Extract the set of term-only bigrams from the text\n+   *\n+   * For example from the text \"this is the winning team\" only the bigram\n+   * \"winning team\" would be extracted\n+   *\n+   * @param text the text to extract n-grams from\n+   */\n   def termBigrams(text: String) = termNgrams(text, 2, 2)\n \n+  /**\n+   * Extract the set of term-only bigrams from the token sequence\n+   *\n+   * For example from the text \"this is the winning team\" only the bigram\n+   * \"winning team\" would be extracted\n+   *\n+   * @param tokens the token sequence to extract n-grams from\n+   */\n   def termBigrams(tokens: Seq[String]) = termNgrams(tokens, 2, 2)\n \n+  /**\n+   * Extract the set of term-only bigrams from the text\n+   *\n+   * For example from the text \"this is red sox nation\" only the trigram\n+   * \"red sox nation\" would be extracted\n+   *\n+   * @param text the text to extract n-grams from\n+   */\n   def termTrigrams(text: String) = termNgrams(text, 3, 3)\n \n+  /**\n+   * Extract the set of term-only bigrams from the text\n+   *\n+   * For example from the text \"this is red sox nation\" only the trigram\n+   * \"red sox nation\" would be extracted\n+   *\n+   * @param tokens the token sequence to extract n-grams from\n+   */\n   def termTrigrams(tokens: Seq[String]) = termNgrams(tokens, 3, 3)\n }\n \n+/** Helpers and language-specifi [[LangBundle]]s **/\n object LangBundle {\n \n   import scala.io.Source\n \n-  def srcFromResource(path: String) = {\n+  private def srcFromResource(path: String) = {\n     Source.fromInputStream(getClass.getResourceAsStream(path))","path":"src/main/scala/com/peoplepattern/text/LangBundle.scala","position":128,"original_position":128,"commit_id":"a54844fec383cf177af3f6c86fd3f36e02f04deb","original_commit_id":"a54844fec383cf177af3f6c86fd3f36e02f04deb","user":{"login":"jfrazee","id":47344,"avatar_url":"https://avatars.githubusercontent.com/u/47344?v=3","gravatar_id":"","url":"https://api.github.com/users/jfrazee","html_url":"https://github.com/jfrazee","followers_url":"https://api.github.com/users/jfrazee/followers","following_url":"https://api.github.com/users/jfrazee/following{/other_user}","gists_url":"https://api.github.com/users/jfrazee/gists{/gist_id}","starred_url":"https://api.github.com/users/jfrazee/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jfrazee/subscriptions","organizations_url":"https://api.github.com/users/jfrazee/orgs","repos_url":"https://api.github.com/users/jfrazee/repos","events_url":"https://api.github.com/users/jfrazee/events{/privacy}","received_events_url":"https://api.github.com/users/jfrazee/received_events","type":"User","site_admin":false},"body":"Not thread safe?","created_at":"2015-12-08T15:49:54Z","updated_at":"2015-12-08T15:49:54Z","html_url":"https://github.com/peoplepattern/lib-text/pull/9#discussion_r46970060","pull_request_url":"https://api.github.com/repos/peoplepattern/lib-text/pulls/9","_links":{"self":{"href":"https://api.github.com/repos/peoplepattern/lib-text/pulls/comments/46970060"},"html":{"href":"https://github.com/peoplepattern/lib-text/pull/9#discussion_r46970060"},"pull_request":{"href":"https://api.github.com/repos/peoplepattern/lib-text/pulls/9"}}},"pull_request":{"url":"https://api.github.com/repos/peoplepattern/lib-text/pulls/9","id":52900607,"html_url":"https://github.com/peoplepattern/lib-text/pull/9","diff_url":"https://github.com/peoplepattern/lib-text/pull/9.diff","patch_url":"https://github.com/peoplepattern/lib-text/pull/9.patch","issue_url":"https://api.github.com/repos/peoplepattern/lib-text/issues/9","number":9,"state":"open","locked":false,"title":"StringUtils, more tests and Scaladoc","user":{"login":"eponvert","id":575305,"avatar_url":"https://avatars.githubusercontent.com/u/575305?v=3","gravatar_id":"","url":"https://api.github.com/users/eponvert","html_url":"https://github.com/eponvert","followers_url":"https://api.github.com/users/eponvert/followers","following_url":"https://api.github.com/users/eponvert/following{/other_user}","gists_url":"https://api.github.com/users/eponvert/gists{/gist_id}","starred_url":"https://api.github.com/users/eponvert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eponvert/subscriptions","organizations_url":"https://api.github.com/users/eponvert/orgs","repos_url":"https://api.github.com/users/eponvert/repos","events_url":"https://api.github.com/users/eponvert/events{/privacy}","received_events_url":"https://api.github.com/users/eponvert/received_events","type":"User","site_admin":false},"body":"Including a StringUtils package of convenience methods for strings","created_at":"2015-12-07T21:05:16Z","updated_at":"2015-12-08T15:49:54Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7d82b0ccf57113c290a4b464f9303295673d0091","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/peoplepattern/lib-text/pulls/9/commits","review_comments_url":"https://api.github.com/repos/peoplepattern/lib-text/pulls/9/comments","review_comment_url":"https://api.github.com/repos/peoplepattern/lib-text/pulls/comments{/number}","comments_url":"https://api.github.com/repos/peoplepattern/lib-text/issues/9/comments","statuses_url":"https://api.github.com/repos/peoplepattern/lib-text/statuses/a54844fec383cf177af3f6c86fd3f36e02f04deb","head":{"label":"peoplepattern:strings-util","ref":"strings-util","sha":"a54844fec383cf177af3f6c86fd3f36e02f04deb","user":{"login":"peoplepattern","id":4258223,"avatar_url":"https://avatars.githubusercontent.com/u/4258223?v=3","gravatar_id":"","url":"https://api.github.com/users/peoplepattern","html_url":"https://github.com/peoplepattern","followers_url":"https://api.github.com/users/peoplepattern/followers","following_url":"https://api.github.com/users/peoplepattern/following{/other_user}","gists_url":"https://api.github.com/users/peoplepattern/gists{/gist_id}","starred_url":"https://api.github.com/users/peoplepattern/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/peoplepattern/subscriptions","organizations_url":"https://api.github.com/users/peoplepattern/orgs","repos_url":"https://api.github.com/users/peoplepattern/repos","events_url":"https://api.github.com/users/peoplepattern/events{/privacy}","received_events_url":"https://api.github.com/users/peoplepattern/received_events","type":"Organization","site_admin":false},"repo":{"id":47280696,"name":"lib-text","full_name":"peoplepattern/lib-text","owner":{"login":"peoplepattern","id":4258223,"avatar_url":"https://avatars.githubusercontent.com/u/4258223?v=3","gravatar_id":"","url":"https://api.github.com/users/peoplepattern","html_url":"https://github.com/peoplepattern","followers_url":"https://api.github.com/users/peoplepattern/followers","following_url":"https://api.github.com/users/peoplepattern/following{/other_user}","gists_url":"https://api.github.com/users/peoplepattern/gists{/gist_id}","starred_url":"https://api.github.com/users/peoplepattern/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/peoplepattern/subscriptions","organizations_url":"https://api.github.com/users/peoplepattern/orgs","repos_url":"https://api.github.com/users/peoplepattern/repos","events_url":"https://api.github.com/users/peoplepattern/events{/privacy}","received_events_url":"https://api.github.com/users/peoplepattern/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/peoplepattern/lib-text","description":"A little text processing library for Scala.","fork":false,"url":"https://api.github.com/repos/peoplepattern/lib-text","forks_url":"https://api.github.com/repos/peoplepattern/lib-text/forks","keys_url":"https://api.github.com/repos/peoplepattern/lib-text/keys{/key_id}","collaborators_url":"https://api.github.com/repos/peoplepattern/lib-text/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/peoplepattern/lib-text/teams","hooks_url":"https://api.github.com/repos/peoplepattern/lib-text/hooks","issue_events_url":"https://api.github.com/repos/peoplepattern/lib-text/issues/events{/number}","events_url":"https://api.github.com/repos/peoplepattern/lib-text/events","assignees_url":"https://api.github.com/repos/peoplepattern/lib-text/assignees{/user}","branches_url":"https://api.github.com/repos/peoplepattern/lib-text/branches{/branch}","tags_url":"https://api.github.com/repos/peoplepattern/lib-text/tags","blobs_url":"https://api.github.com/repos/peoplepattern/lib-text/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/peoplepattern/lib-text/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/peoplepattern/lib-text/git/refs{/sha}","trees_url":"https://api.github.com/repos/peoplepattern/lib-text/git/trees{/sha}","statuses_url":"https://api.github.com/repos/peoplepattern/lib-text/statuses/{sha}","languages_url":"https://api.github.com/repos/peoplepattern/lib-text/languages","stargazers_url":"https://api.github.com/repos/peoplepattern/lib-text/stargazers","contributors_url":"https://api.github.com/repos/peoplepattern/lib-text/contributors","subscribers_url":"https://api.github.com/repos/peoplepattern/lib-text/subscribers","subscription_url":"https://api.github.com/repos/peoplepattern/lib-text/subscription","commits_url":"https://api.github.com/repos/peoplepattern/lib-text/commits{/sha}","git_commits_url":"https://api.github.com/repos/peoplepattern/lib-text/git/commits{/sha}","comments_url":"https://api.github.com/repos/peoplepattern/lib-text/comments{/number}","issue_comment_url":"https://api.github.com/repos/peoplepattern/lib-text/issues/comments{/number}","contents_url":"https://api.github.com/repos/peoplepattern/lib-text/contents/{+path}","compare_url":"https://api.github.com/repos/peoplepattern/lib-text/compare/{base}...{head}","merges_url":"https://api.github.com/repos/peoplepattern/lib-text/merges","archive_url":"https://api.github.com/repos/peoplepattern/lib-text/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/peoplepattern/lib-text/downloads","issues_url":"https://api.github.com/repos/peoplepattern/lib-text/issues{/number}","pulls_url":"https://api.github.com/repos/peoplepattern/lib-text/pulls{/number}","milestones_url":"https://api.github.com/repos/peoplepattern/lib-text/milestones{/number}","notifications_url":"https://api.github.com/repos/peoplepattern/lib-text/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/peoplepattern/lib-text/labels{/name}","releases_url":"https://api.github.com/repos/peoplepattern/lib-text/releases{/id}","created_at":"2015-12-02T18:39:29Z","updated_at":"2015-12-04T21:52:15Z","pushed_at":"2015-12-07T21:20:01Z","git_url":"git://github.com/peoplepattern/lib-text.git","ssh_url":"git@github.com:peoplepattern/lib-text.git","clone_url":"https://github.com/peoplepattern/lib-text.git","svn_url":"https://github.com/peoplepattern/lib-text","homepage":"https://peoplepattern.github.io/lib-text","size":426,"stargazers_count":7,"watchers_count":7,"language":"HTML","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":1,"mirror_url":null,"open_issues_count":5,"forks":1,"open_issues":5,"watchers":7,"default_branch":"master"}},"base":{"label":"peoplepattern:master","ref":"master","sha":"a1c47a8839a3dc562ff3adfe5727e6e880f63254","user":{"login":"peoplepattern","id":4258223,"avatar_url":"https://avatars.githubusercontent.com/u/4258223?v=3","gravatar_id":"","url":"https://api.github.com/users/peoplepattern","html_url":"https://github.com/peoplepattern","followers_url":"https://api.github.com/users/peoplepattern/followers","following_url":"https://api.github.com/users/peoplepattern/following{/other_user}","gists_url":"https://api.github.com/users/peoplepattern/gists{/gist_id}","starred_url":"https://api.github.com/users/peoplepattern/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/peoplepattern/subscriptions","organizations_url":"https://api.github.com/users/peoplepattern/orgs","repos_url":"https://api.github.com/users/peoplepattern/repos","events_url":"https://api.github.com/users/peoplepattern/events{/privacy}","received_events_url":"https://api.github.com/users/peoplepattern/received_events","type":"Organization","site_admin":false},"repo":{"id":47280696,"name":"lib-text","full_name":"peoplepattern/lib-text","owner":{"login":"peoplepattern","id":4258223,"avatar_url":"https://avatars.githubusercontent.com/u/4258223?v=3","gravatar_id":"","url":"https://api.github.com/users/peoplepattern","html_url":"https://github.com/peoplepattern","followers_url":"https://api.github.com/users/peoplepattern/followers","following_url":"https://api.github.com/users/peoplepattern/following{/other_user}","gists_url":"https://api.github.com/users/peoplepattern/gists{/gist_id}","starred_url":"https://api.github.com/users/peoplepattern/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/peoplepattern/subscriptions","organizations_url":"https://api.github.com/users/peoplepattern/orgs","repos_url":"https://api.github.com/users/peoplepattern/repos","events_url":"https://api.github.com/users/peoplepattern/events{/privacy}","received_events_url":"https://api.github.com/users/peoplepattern/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/peoplepattern/lib-text","description":"A little text processing library for Scala.","fork":false,"url":"https://api.github.com/repos/peoplepattern/lib-text","forks_url":"https://api.github.com/repos/peoplepattern/lib-text/forks","keys_url":"https://api.github.com/repos/peoplepattern/lib-text/keys{/key_id}","collaborators_url":"https://api.github.com/repos/peoplepattern/lib-text/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/peoplepattern/lib-text/teams","hooks_url":"https://api.github.com/repos/peoplepattern/lib-text/hooks","issue_events_url":"https://api.github.com/repos/peoplepattern/lib-text/issues/events{/number}","events_url":"https://api.github.com/repos/peoplepattern/lib-text/events","assignees_url":"https://api.github.com/repos/peoplepattern/lib-text/assignees{/user}","branches_url":"https://api.github.com/repos/peoplepattern/lib-text/branches{/branch}","tags_url":"https://api.github.com/repos/peoplepattern/lib-text/tags","blobs_url":"https://api.github.com/repos/peoplepattern/lib-text/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/peoplepattern/lib-text/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/peoplepattern/lib-text/git/refs{/sha}","trees_url":"https://api.github.com/repos/peoplepattern/lib-text/git/trees{/sha}","statuses_url":"https://api.github.com/repos/peoplepattern/lib-text/statuses/{sha}","languages_url":"https://api.github.com/repos/peoplepattern/lib-text/languages","stargazers_url":"https://api.github.com/repos/peoplepattern/lib-text/stargazers","contributors_url":"https://api.github.com/repos/peoplepattern/lib-text/contributors","subscribers_url":"https://api.github.com/repos/peoplepattern/lib-text/subscribers","subscription_url":"https://api.github.com/repos/peoplepattern/lib-text/subscription","commits_url":"https://api.github.com/repos/peoplepattern/lib-text/commits{/sha}","git_commits_url":"https://api.github.com/repos/peoplepattern/lib-text/git/commits{/sha}","comments_url":"https://api.github.com/repos/peoplepattern/lib-text/comments{/number}","issue_comment_url":"https://api.github.com/repos/peoplepattern/lib-text/issues/comments{/number}","contents_url":"https://api.github.com/repos/peoplepattern/lib-text/contents/{+path}","compare_url":"https://api.github.com/repos/peoplepattern/lib-text/compare/{base}...{head}","merges_url":"https://api.github.com/repos/peoplepattern/lib-text/merges","archive_url":"https://api.github.com/repos/peoplepattern/lib-text/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/peoplepattern/lib-text/downloads","issues_url":"https://api.github.com/repos/peoplepattern/lib-text/issues{/number}","pulls_url":"https://api.github.com/repos/peoplepattern/lib-text/pulls{/number}","milestones_url":"https://api.github.com/repos/peoplepattern/lib-text/milestones{/number}","notifications_url":"https://api.github.com/repos/peoplepattern/lib-text/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/peoplepattern/lib-text/labels{/name}","releases_url":"https://api.github.com/repos/peoplepattern/lib-text/releases{/id}","created_at":"2015-12-02T18:39:29Z","updated_at":"2015-12-04T21:52:15Z","pushed_at":"2015-12-07T21:20:01Z","git_url":"git://github.com/peoplepattern/lib-text.git","ssh_url":"git@github.com:peoplepattern/lib-text.git","clone_url":"https://github.com/peoplepattern/lib-text.git","svn_url":"https://github.com/peoplepattern/lib-text","homepage":"https://peoplepattern.github.io/lib-text","size":426,"stargazers_count":7,"watchers_count":7,"language":"HTML","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":1,"mirror_url":null,"open_issues_count":5,"forks":1,"open_issues":5,"watchers":7,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/peoplepattern/lib-text/pulls/9"},"html":{"href":"https://github.com/peoplepattern/lib-text/pull/9"},"issue":{"href":"https://api.github.com/repos/peoplepattern/lib-text/issues/9"},"comments":{"href":"https://api.github.com/repos/peoplepattern/lib-text/issues/9/comments"},"review_comments":{"href":"https://api.github.com/repos/peoplepattern/lib-text/pulls/9/comments"},"review_comment":{"href":"https://api.github.com/repos/peoplepattern/lib-text/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/peoplepattern/lib-text/pulls/9/commits"},"statuses":{"href":"https://api.github.com/repos/peoplepattern/lib-text/statuses/a54844fec383cf177af3f6c86fd3f36e02f04deb"}}}}