{"action":"created","comment":{"url":"https://api.github.com/repos/ga4gh/schemas/pulls/comments/67718314","id":67718314,"diff_hunk":"@@ -0,0 +1,97 @@\n+syntax = \"proto3\";\n+\n+package ga4gh;\n+\n+import \"ga4gh/bio_metadata.proto\";\n+\n+\n+service BioMetadataService {\n+  // Gets a list of Individuals accessible through the API.\n+  // `POST /individuals/search` must accept a JSON version of\n+  // `SearchIndividualsRequest` as the post body and will return a JSON version\n+  // of `SearchIndividualsResponse`.\n+  rpc SearchIndividuals(SearchIndividualsRequest)\n+      returns (SearchIndividualsResponse);\n+  \n+  // `POST /biosamples/search` must accept a JSON version of\n+  // `SearchBioSamplesRequest` as the post body and will return a JSON version\n+  // of `SearchBioSamplesResponse`.\n+  rpc SearchBioSamples(SearchBioSamplesRequest)\n+      returns (SearchBioSamplesResponse);\n+\n+  // Gets an `Individual` by ID.\n+  // `GET /individuals/{id}` will return a JSON version of `Individual`.\n+  rpc GetIndividual(SearchIndividualsRequest)\n+      returns (Individual);\n+\n+  // Gets a `BioSample` by ID.\n+  // `GET /biosamples/{id}` will return a JSON version of `BioSample`.\n+  rpc GetBioSample(SearchIndividualsRequest)\n+      returns (BioSample);\n+}\n+// *********************  /individuals ********************************\n+// This request maps to the body of `POST /individuals/search` as JSON.\n+message SearchIndividualsRequest {\n+  // The dataset to search within.\n+  string dataset_id = 1;","path":"src/main/proto/ga4gh/bio_metadata_service.proto","position":36,"original_position":36,"commit_id":"15cb3e1a11f5327b49c9c40e9740bdac268225f0","original_commit_id":"15cb3e1a11f5327b49c9c40e9740bdac268225f0","user":{"login":"jeromekelleher","id":2664569,"avatar_url":"https://avatars.githubusercontent.com/u/2664569?v=3","gravatar_id":"","url":"https://api.github.com/users/jeromekelleher","html_url":"https://github.com/jeromekelleher","followers_url":"https://api.github.com/users/jeromekelleher/followers","following_url":"https://api.github.com/users/jeromekelleher/following{/other_user}","gists_url":"https://api.github.com/users/jeromekelleher/gists{/gist_id}","starred_url":"https://api.github.com/users/jeromekelleher/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeromekelleher/subscriptions","organizations_url":"https://api.github.com/users/jeromekelleher/orgs","repos_url":"https://api.github.com/users/jeromekelleher/repos","events_url":"https://api.github.com/users/jeromekelleher/events{/privacy}","received_events_url":"https://api.github.com/users/jeromekelleher/received_events","type":"User","site_admin":false},"body":"Why are we searching within a dataset here? There is no ``dataset_id`` attribute for Individuals or BioSamples, so it's not clear what this means. Should Individuals and BioSamples be considered to be \"in\" a dataset? I don't think so. I think these high-level metadata items should be repository level and useable within any dataset.","created_at":"2016-06-20T16:14:34Z","updated_at":"2016-06-20T16:14:34Z","html_url":"https://github.com/ga4gh/schemas/pull/636#discussion_r67718314","pull_request_url":"https://api.github.com/repos/ga4gh/schemas/pulls/636","_links":{"self":{"href":"https://api.github.com/repos/ga4gh/schemas/pulls/comments/67718314"},"html":{"href":"https://github.com/ga4gh/schemas/pull/636#discussion_r67718314"},"pull_request":{"href":"https://api.github.com/repos/ga4gh/schemas/pulls/636"}}},"pull_request":{"url":"https://api.github.com/repos/ga4gh/schemas/pulls/636","id":74114935,"html_url":"https://github.com/ga4gh/schemas/pull/636","diff_url":"https://github.com/ga4gh/schemas/pull/636.diff","patch_url":"https://github.com/ga4gh/schemas/pull/636.patch","issue_url":"https://api.github.com/repos/ga4gh/schemas/issues/636","number":636,"state":"open","locked":false,"title":"BioMetadata Protocol","user":{"login":"david4096","id":3795586,"avatar_url":"https://avatars.githubusercontent.com/u/3795586?v=3","gravatar_id":"","url":"https://api.github.com/users/david4096","html_url":"https://github.com/david4096","followers_url":"https://api.github.com/users/david4096/followers","following_url":"https://api.github.com/users/david4096/following{/other_user}","gists_url":"https://api.github.com/users/david4096/gists{/gist_id}","starred_url":"https://api.github.com/users/david4096/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/david4096/subscriptions","organizations_url":"https://api.github.com/users/david4096/orgs","repos_url":"https://api.github.com/users/david4096/repos","events_url":"https://api.github.com/users/david4096/events{/privacy}","received_events_url":"https://api.github.com/users/david4096/received_events","type":"User","site_admin":false},"body":"The GA4GH API currently lacks a unified way for describing samples across data types. This means that it is difficult to reconcile whether a variant call or read group is from the same sample. This PR adds the ability to filter by samples to these types.\r\n\r\nThe BioMetadata protocol allows read groups and call sets to be related to `BioSample`s. This is done by adding `bioSampleId` fields to both of those records. A `bioSampleId` field is then an optional field in both in SearchReadGroupSetsRequest and SearchCallSetsRequest. In addition to being able to filter callsets and readgroups, search and get endpoints for biosamples and individuals endpoints have been added.\r\n\r\nIndividuals can be searched by name, and biosamples can be filtered by individualId and name.\r\n\r\nGiven some read find which individual it derives from:\r\n1) Read the bioSampleId from a ReadGroup record.\r\n2) Get the BioSample record by performing a get at http://ga4gh/biosamples/<bioSampleId>.\r\n3) Read the individualId from the BioSample record.\r\n4) Get the Individual record by performing a get at http://ga4gh/individuals/<bioSampleId>.\r\n\r\nGiven some individual find reads:\r\n1) From the Individual record get the individualId.\r\n2) Create a SearchBioSamplesRequest with the provided individualId.\r\n3) Perform a SearchReadGroupSetsRequest with each returned bioSampleId.\r\n4) Only read groups matching the bioSampleId will be returned. Perform a SearchReadsRequest for each read group in the SearchReadGroupSetsResponse.\r\n\r\nTo clarify the metadata roles, some reusable elements have been moved to `AssayMetadata` (`Experiment` and `Analysis`). Other assisting documentation is included in this PR to assist proper usage of Ontology Terms. Thanks to everyone for all the effort put into this @mbaudis @diekhans @jeromekelleher @bwalsh @saupchurch @sarahhunt @dzerbino  ","created_at":"2016-06-16T16:51:13Z","updated_at":"2016-06-20T16:14:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ef20cee9999a8c4ae9362c1a72f57285045a9dcf","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ga4gh/schemas/pulls/636/commits","review_comments_url":"https://api.github.com/repos/ga4gh/schemas/pulls/636/comments","review_comment_url":"https://api.github.com/repos/ga4gh/schemas/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ga4gh/schemas/issues/636/comments","statuses_url":"https://api.github.com/repos/ga4gh/schemas/statuses/15cb3e1a11f5327b49c9c40e9740bdac268225f0","head":{"label":"ga4gh:biodataproto","ref":"biodataproto","sha":"15cb3e1a11f5327b49c9c40e9740bdac268225f0","user":{"login":"ga4gh","id":6921777,"avatar_url":"https://avatars.githubusercontent.com/u/6921777?v=3","gravatar_id":"","url":"https://api.github.com/users/ga4gh","html_url":"https://github.com/ga4gh","followers_url":"https://api.github.com/users/ga4gh/followers","following_url":"https://api.github.com/users/ga4gh/following{/other_user}","gists_url":"https://api.github.com/users/ga4gh/gists{/gist_id}","starred_url":"https://api.github.com/users/ga4gh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ga4gh/subscriptions","organizations_url":"https://api.github.com/users/ga4gh/orgs","repos_url":"https://api.github.com/users/ga4gh/repos","events_url":"https://api.github.com/users/ga4gh/events{/privacy}","received_events_url":"https://api.github.com/users/ga4gh/received_events","type":"Organization","site_admin":false},"repo":{"id":17925227,"name":"schemas","full_name":"ga4gh/schemas","owner":{"login":"ga4gh","id":6921777,"avatar_url":"https://avatars.githubusercontent.com/u/6921777?v=3","gravatar_id":"","url":"https://api.github.com/users/ga4gh","html_url":"https://github.com/ga4gh","followers_url":"https://api.github.com/users/ga4gh/followers","following_url":"https://api.github.com/users/ga4gh/following{/other_user}","gists_url":"https://api.github.com/users/ga4gh/gists{/gist_id}","starred_url":"https://api.github.com/users/ga4gh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ga4gh/subscriptions","organizations_url":"https://api.github.com/users/ga4gh/orgs","repos_url":"https://api.github.com/users/ga4gh/repos","events_url":"https://api.github.com/users/ga4gh/events{/privacy}","received_events_url":"https://api.github.com/users/ga4gh/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ga4gh/schemas","description":"Work on data models and APIs for Genomic data.","fork":false,"url":"https://api.github.com/repos/ga4gh/schemas","forks_url":"https://api.github.com/repos/ga4gh/schemas/forks","keys_url":"https://api.github.com/repos/ga4gh/schemas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ga4gh/schemas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ga4gh/schemas/teams","hooks_url":"https://api.github.com/repos/ga4gh/schemas/hooks","issue_events_url":"https://api.github.com/repos/ga4gh/schemas/issues/events{/number}","events_url":"https://api.github.com/repos/ga4gh/schemas/events","assignees_url":"https://api.github.com/repos/ga4gh/schemas/assignees{/user}","branches_url":"https://api.github.com/repos/ga4gh/schemas/branches{/branch}","tags_url":"https://api.github.com/repos/ga4gh/schemas/tags","blobs_url":"https://api.github.com/repos/ga4gh/schemas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ga4gh/schemas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ga4gh/schemas/git/refs{/sha}","trees_url":"https://api.github.com/repos/ga4gh/schemas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ga4gh/schemas/statuses/{sha}","languages_url":"https://api.github.com/repos/ga4gh/schemas/languages","stargazers_url":"https://api.github.com/repos/ga4gh/schemas/stargazers","contributors_url":"https://api.github.com/repos/ga4gh/schemas/contributors","subscribers_url":"https://api.github.com/repos/ga4gh/schemas/subscribers","subscription_url":"https://api.github.com/repos/ga4gh/schemas/subscription","commits_url":"https://api.github.com/repos/ga4gh/schemas/commits{/sha}","git_commits_url":"https://api.github.com/repos/ga4gh/schemas/git/commits{/sha}","comments_url":"https://api.github.com/repos/ga4gh/schemas/comments{/number}","issue_comment_url":"https://api.github.com/repos/ga4gh/schemas/issues/comments{/number}","contents_url":"https://api.github.com/repos/ga4gh/schemas/contents/{+path}","compare_url":"https://api.github.com/repos/ga4gh/schemas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ga4gh/schemas/merges","archive_url":"https://api.github.com/repos/ga4gh/schemas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ga4gh/schemas/downloads","issues_url":"https://api.github.com/repos/ga4gh/schemas/issues{/number}","pulls_url":"https://api.github.com/repos/ga4gh/schemas/pulls{/number}","milestones_url":"https://api.github.com/repos/ga4gh/schemas/milestones{/number}","notifications_url":"https://api.github.com/repos/ga4gh/schemas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ga4gh/schemas/labels{/name}","releases_url":"https://api.github.com/repos/ga4gh/schemas/releases{/id}","deployments_url":"https://api.github.com/repos/ga4gh/schemas/deployments","created_at":"2014-03-20T00:13:40Z","updated_at":"2016-06-09T21:44:10Z","pushed_at":"2016-06-17T09:23:31Z","git_url":"git://github.com/ga4gh/schemas.git","ssh_url":"git@github.com:ga4gh/schemas.git","clone_url":"https://github.com/ga4gh/schemas.git","svn_url":"https://github.com/ga4gh/schemas","homepage":"http://ga4gh.org/#/api","size":15228,"stargazers_count":184,"watchers_count":184,"language":"Protocol Buffer","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":100,"mirror_url":null,"open_issues_count":162,"forks":100,"open_issues":162,"watchers":184,"default_branch":"master"}},"base":{"label":"ga4gh:master","ref":"master","sha":"d2fd0ae21bdd9cf6bf40931e9e5027a90e1c0123","user":{"login":"ga4gh","id":6921777,"avatar_url":"https://avatars.githubusercontent.com/u/6921777?v=3","gravatar_id":"","url":"https://api.github.com/users/ga4gh","html_url":"https://github.com/ga4gh","followers_url":"https://api.github.com/users/ga4gh/followers","following_url":"https://api.github.com/users/ga4gh/following{/other_user}","gists_url":"https://api.github.com/users/ga4gh/gists{/gist_id}","starred_url":"https://api.github.com/users/ga4gh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ga4gh/subscriptions","organizations_url":"https://api.github.com/users/ga4gh/orgs","repos_url":"https://api.github.com/users/ga4gh/repos","events_url":"https://api.github.com/users/ga4gh/events{/privacy}","received_events_url":"https://api.github.com/users/ga4gh/received_events","type":"Organization","site_admin":false},"repo":{"id":17925227,"name":"schemas","full_name":"ga4gh/schemas","owner":{"login":"ga4gh","id":6921777,"avatar_url":"https://avatars.githubusercontent.com/u/6921777?v=3","gravatar_id":"","url":"https://api.github.com/users/ga4gh","html_url":"https://github.com/ga4gh","followers_url":"https://api.github.com/users/ga4gh/followers","following_url":"https://api.github.com/users/ga4gh/following{/other_user}","gists_url":"https://api.github.com/users/ga4gh/gists{/gist_id}","starred_url":"https://api.github.com/users/ga4gh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ga4gh/subscriptions","organizations_url":"https://api.github.com/users/ga4gh/orgs","repos_url":"https://api.github.com/users/ga4gh/repos","events_url":"https://api.github.com/users/ga4gh/events{/privacy}","received_events_url":"https://api.github.com/users/ga4gh/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ga4gh/schemas","description":"Work on data models and APIs for Genomic data.","fork":false,"url":"https://api.github.com/repos/ga4gh/schemas","forks_url":"https://api.github.com/repos/ga4gh/schemas/forks","keys_url":"https://api.github.com/repos/ga4gh/schemas/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ga4gh/schemas/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ga4gh/schemas/teams","hooks_url":"https://api.github.com/repos/ga4gh/schemas/hooks","issue_events_url":"https://api.github.com/repos/ga4gh/schemas/issues/events{/number}","events_url":"https://api.github.com/repos/ga4gh/schemas/events","assignees_url":"https://api.github.com/repos/ga4gh/schemas/assignees{/user}","branches_url":"https://api.github.com/repos/ga4gh/schemas/branches{/branch}","tags_url":"https://api.github.com/repos/ga4gh/schemas/tags","blobs_url":"https://api.github.com/repos/ga4gh/schemas/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ga4gh/schemas/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ga4gh/schemas/git/refs{/sha}","trees_url":"https://api.github.com/repos/ga4gh/schemas/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ga4gh/schemas/statuses/{sha}","languages_url":"https://api.github.com/repos/ga4gh/schemas/languages","stargazers_url":"https://api.github.com/repos/ga4gh/schemas/stargazers","contributors_url":"https://api.github.com/repos/ga4gh/schemas/contributors","subscribers_url":"https://api.github.com/repos/ga4gh/schemas/subscribers","subscription_url":"https://api.github.com/repos/ga4gh/schemas/subscription","commits_url":"https://api.github.com/repos/ga4gh/schemas/commits{/sha}","git_commits_url":"https://api.github.com/repos/ga4gh/schemas/git/commits{/sha}","comments_url":"https://api.github.com/repos/ga4gh/schemas/comments{/number}","issue_comment_url":"https://api.github.com/repos/ga4gh/schemas/issues/comments{/number}","contents_url":"https://api.github.com/repos/ga4gh/schemas/contents/{+path}","compare_url":"https://api.github.com/repos/ga4gh/schemas/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ga4gh/schemas/merges","archive_url":"https://api.github.com/repos/ga4gh/schemas/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ga4gh/schemas/downloads","issues_url":"https://api.github.com/repos/ga4gh/schemas/issues{/number}","pulls_url":"https://api.github.com/repos/ga4gh/schemas/pulls{/number}","milestones_url":"https://api.github.com/repos/ga4gh/schemas/milestones{/number}","notifications_url":"https://api.github.com/repos/ga4gh/schemas/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ga4gh/schemas/labels{/name}","releases_url":"https://api.github.com/repos/ga4gh/schemas/releases{/id}","deployments_url":"https://api.github.com/repos/ga4gh/schemas/deployments","created_at":"2014-03-20T00:13:40Z","updated_at":"2016-06-09T21:44:10Z","pushed_at":"2016-06-17T09:23:31Z","git_url":"git://github.com/ga4gh/schemas.git","ssh_url":"git@github.com:ga4gh/schemas.git","clone_url":"https://github.com/ga4gh/schemas.git","svn_url":"https://github.com/ga4gh/schemas","homepage":"http://ga4gh.org/#/api","size":15228,"stargazers_count":184,"watchers_count":184,"language":"Protocol Buffer","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":100,"mirror_url":null,"open_issues_count":162,"forks":100,"open_issues":162,"watchers":184,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ga4gh/schemas/pulls/636"},"html":{"href":"https://github.com/ga4gh/schemas/pull/636"},"issue":{"href":"https://api.github.com/repos/ga4gh/schemas/issues/636"},"comments":{"href":"https://api.github.com/repos/ga4gh/schemas/issues/636/comments"},"review_comments":{"href":"https://api.github.com/repos/ga4gh/schemas/pulls/636/comments"},"review_comment":{"href":"https://api.github.com/repos/ga4gh/schemas/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ga4gh/schemas/pulls/636/commits"},"statuses":{"href":"https://api.github.com/repos/ga4gh/schemas/statuses/15cb3e1a11f5327b49c9c40e9740bdac268225f0"}}}}
{"actor":{"display_login":"jeromekelleher"}}