{"action":"created","comment":{"url":"https://api.github.com/repos/biopython/biopython/pulls/comments/24588569","id":24588569,"diff_hunk":"@@ -33,23 +33,250 @@\n # each key is tag_name + tag_number\n # if a tag entry needs to be added, just add its key and its key\n # for the annotations dictionary as the value\n+# dictionary for tags that require preprocessing before use in creating\n+# seqrecords\n _EXTRACT = {\n     'TUBE1': 'sample_well',\n     'DySN1': 'dye',\n     'GTyp1': 'polymer',\n     'MODL1': 'machine_model',\n }\n-# dictionary for tags that require preprocessing before use in creating\n-# seqrecords\n-_SPCTAGS = [\n-    'PBAS2',    # base-called sequence\n-    'PCON2',    # quality values of base-called sequence\n-    'SMPL1',    # sample id inputted before sequencing run\n-    'RUND1',    # run start date\n-    'RUND2',    # run finish date\n-    'RUNT1',    # run start time\n-    'RUNT2',    # run finish time\n-]\n+\n+\n+# Complete data structure representing 98% of the API. The general section\n+# represents the part of the API that's common to ALL instruments, whereas the\n+# instrument specific sections are labelled as they are in the ABIF spec\n+#\n+# The 2%:\n+#  - on some fields, there are repeated fields (e.g DYEN1-100), and those are not supported\n+#  - OvrI1-N containing color data of some sort\n+#\n+# Keys don't seem to clash from machine to machine, so when we parse, we look\n+# for ANY key, and store that in the raw ABIF data structure attached to the\n+# annotations, with the assumption that anyone parsing the data can look up the\n+# spec themself\n+#\n+# Key definitions are retained in case end users want \"nice\" labels pre-made\n+# for them for all of the available fields.\n+_INSTRUMENT_SPECIFIC_TAGS = {\n+    'general': {\n+        'APFN2': 'Sequencing Analysis parameters file name',\n+        'APXV1': 'Analysis Protocol XML schema version',\n+        'APrN1': 'Analysis Protocol settings name',\n+        'APrV1': 'Analysis Protocol settings version',\n+        'APrX1': 'Analysis Protocol XML string',\n+        'CMNT1': 'Sample Comment',\n+        'CTID1': 'Container Identifier, a.k.a. plate barcode',\n+        'CTNM1': 'Container name, usually identical to CTID, but not necessarily so',\n+        'CTTL1': 'Comment Title',\n+        'CpEP1': 'Capillary type electrophoresis. 1 for a capillary based machine. 0 for a slab gel based machine.',\n+        'DATA1': 'Channel 1 raw data',\n+        'DATA1': 'Channel 1 raw data',","path":"Bio/SeqIO/AbiIO.py","position":null,"original_position":53,"commit_id":"e5ae712b66930093866df16516cecc31f5e40d15","original_commit_id":"9dc556c3a19d34eb77eab2e4f1ae2f1bc77cf464","user":{"login":"erasche","id":458683,"avatar_url":"https://avatars.githubusercontent.com/u/458683?v=3","gravatar_id":"","url":"https://api.github.com/users/erasche","html_url":"https://github.com/erasche","followers_url":"https://api.github.com/users/erasche/followers","following_url":"https://api.github.com/users/erasche/following{/other_user}","gists_url":"https://api.github.com/users/erasche/gists{/gist_id}","starred_url":"https://api.github.com/users/erasche/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/erasche/subscriptions","organizations_url":"https://api.github.com/users/erasche/orgs","repos_url":"https://api.github.com/users/erasche/repos","events_url":"https://api.github.com/users/erasche/events{/privacy}","received_events_url":"https://api.github.com/users/erasche/received_events","type":"User","site_admin":false},"body":"Ah, great, happy to help!","created_at":"2015-02-12T15:29:15Z","updated_at":"2015-02-12T15:29:15Z","html_url":"https://github.com/biopython/biopython/pull/473#discussion_r24588569","pull_request_url":"https://api.github.com/repos/biopython/biopython/pulls/473","_links":{"self":{"href":"https://api.github.com/repos/biopython/biopython/pulls/comments/24588569"},"html":{"href":"https://github.com/biopython/biopython/pull/473#discussion_r24588569"},"pull_request":{"href":"https://api.github.com/repos/biopython/biopython/pulls/473"}}},"pull_request":{"url":"https://api.github.com/repos/biopython/biopython/pulls/473","id":29130065,"html_url":"https://github.com/biopython/biopython/pull/473","diff_url":"https://github.com/biopython/biopython/pull/473.diff","patch_url":"https://github.com/biopython/biopython/pull/473.patch","issue_url":"https://api.github.com/repos/biopython/biopython/issues/473","number":473,"state":"open","locked":false,"title":"Implement rest of ABIF spec","user":{"login":"erasche","id":458683,"avatar_url":"https://avatars.githubusercontent.com/u/458683?v=3","gravatar_id":"","url":"https://api.github.com/users/erasche","html_url":"https://github.com/erasche","followers_url":"https://api.github.com/users/erasche/followers","following_url":"https://api.github.com/users/erasche/following{/other_user}","gists_url":"https://api.github.com/users/erasche/gists{/gist_id}","starred_url":"https://api.github.com/users/erasche/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/erasche/subscriptions","organizations_url":"https://api.github.com/users/erasche/orgs","repos_url":"https://api.github.com/users/erasche/repos","events_url":"https://api.github.com/users/erasche/events{/privacy}","received_events_url":"https://api.github.com/users/erasche/received_events","type":"User","site_admin":false},"body":"This PR implements the rest of the ABIF spec, nearly every key listed in their documentation.\r\n\r\nMy users were clamouring for channel data from each individual channel for viz. purposes, and I figured \"well, while I'm there...\" and went ahead and added in the rest of the keys.\r\n\r\n- all keys from all instrument models are searched for in the ABIF data structure\r\n- labels are made available for anyone wishing to e.g. import the data structure and annotate tracks for their datasets.","created_at":"2015-02-11T21:28:07Z","updated_at":"2015-02-12T15:29:15Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2b23f1403c10f5e26504b9e7c78bbabd82460683","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/biopython/biopython/pulls/473/commits","review_comments_url":"https://api.github.com/repos/biopython/biopython/pulls/473/comments","review_comment_url":"https://api.github.com/repos/biopython/biopython/pulls/comments/{number}","comments_url":"https://api.github.com/repos/biopython/biopython/issues/473/comments","statuses_url":"https://api.github.com/repos/biopython/biopython/statuses/e5ae712b66930093866df16516cecc31f5e40d15","head":{"label":"erasche:abi","ref":"abi","sha":"e5ae712b66930093866df16516cecc31f5e40d15","user":{"login":"erasche","id":458683,"avatar_url":"https://avatars.githubusercontent.com/u/458683?v=3","gravatar_id":"","url":"https://api.github.com/users/erasche","html_url":"https://github.com/erasche","followers_url":"https://api.github.com/users/erasche/followers","following_url":"https://api.github.com/users/erasche/following{/other_user}","gists_url":"https://api.github.com/users/erasche/gists{/gist_id}","starred_url":"https://api.github.com/users/erasche/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/erasche/subscriptions","organizations_url":"https://api.github.com/users/erasche/orgs","repos_url":"https://api.github.com/users/erasche/repos","events_url":"https://api.github.com/users/erasche/events{/privacy}","received_events_url":"https://api.github.com/users/erasche/received_events","type":"User","site_admin":false},"repo":{"id":30665105,"name":"biopython","full_name":"erasche/biopython","owner":{"login":"erasche","id":458683,"avatar_url":"https://avatars.githubusercontent.com/u/458683?v=3","gravatar_id":"","url":"https://api.github.com/users/erasche","html_url":"https://github.com/erasche","followers_url":"https://api.github.com/users/erasche/followers","following_url":"https://api.github.com/users/erasche/following{/other_user}","gists_url":"https://api.github.com/users/erasche/gists{/gist_id}","starred_url":"https://api.github.com/users/erasche/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/erasche/subscriptions","organizations_url":"https://api.github.com/users/erasche/orgs","repos_url":"https://api.github.com/users/erasche/repos","events_url":"https://api.github.com/users/erasche/events{/privacy}","received_events_url":"https://api.github.com/users/erasche/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/erasche/biopython","description":"Official git repository for Biopython (converted from CVS)","fork":true,"url":"https://api.github.com/repos/erasche/biopython","forks_url":"https://api.github.com/repos/erasche/biopython/forks","keys_url":"https://api.github.com/repos/erasche/biopython/keys{/key_id}","collaborators_url":"https://api.github.com/repos/erasche/biopython/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/erasche/biopython/teams","hooks_url":"https://api.github.com/repos/erasche/biopython/hooks","issue_events_url":"https://api.github.com/repos/erasche/biopython/issues/events{/number}","events_url":"https://api.github.com/repos/erasche/biopython/events","assignees_url":"https://api.github.com/repos/erasche/biopython/assignees{/user}","branches_url":"https://api.github.com/repos/erasche/biopython/branches{/branch}","tags_url":"https://api.github.com/repos/erasche/biopython/tags","blobs_url":"https://api.github.com/repos/erasche/biopython/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/erasche/biopython/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/erasche/biopython/git/refs{/sha}","trees_url":"https://api.github.com/repos/erasche/biopython/git/trees{/sha}","statuses_url":"https://api.github.com/repos/erasche/biopython/statuses/{sha}","languages_url":"https://api.github.com/repos/erasche/biopython/languages","stargazers_url":"https://api.github.com/repos/erasche/biopython/stargazers","contributors_url":"https://api.github.com/repos/erasche/biopython/contributors","subscribers_url":"https://api.github.com/repos/erasche/biopython/subscribers","subscription_url":"https://api.github.com/repos/erasche/biopython/subscription","commits_url":"https://api.github.com/repos/erasche/biopython/commits{/sha}","git_commits_url":"https://api.github.com/repos/erasche/biopython/git/commits{/sha}","comments_url":"https://api.github.com/repos/erasche/biopython/comments{/number}","issue_comment_url":"https://api.github.com/repos/erasche/biopython/issues/comments/{number}","contents_url":"https://api.github.com/repos/erasche/biopython/contents/{+path}","compare_url":"https://api.github.com/repos/erasche/biopython/compare/{base}...{head}","merges_url":"https://api.github.com/repos/erasche/biopython/merges","archive_url":"https://api.github.com/repos/erasche/biopython/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/erasche/biopython/downloads","issues_url":"https://api.github.com/repos/erasche/biopython/issues{/number}","pulls_url":"https://api.github.com/repos/erasche/biopython/pulls{/number}","milestones_url":"https://api.github.com/repos/erasche/biopython/milestones{/number}","notifications_url":"https://api.github.com/repos/erasche/biopython/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/erasche/biopython/labels{/name}","releases_url":"https://api.github.com/repos/erasche/biopython/releases{/id}","created_at":"2015-02-11T19:20:19Z","updated_at":"2015-02-11T19:20:31Z","pushed_at":"2015-02-12T15:03:55Z","git_url":"git://github.com/erasche/biopython.git","ssh_url":"git@github.com:erasche/biopython.git","clone_url":"https://github.com/erasche/biopython.git","svn_url":"https://github.com/erasche/biopython","homepage":"http://biopython.org/","size":49698,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"biopython:master","ref":"master","sha":"fba3c8a926a07b8b6b821759db8c71d93c51be86","user":{"login":"biopython","id":54555,"avatar_url":"https://avatars.githubusercontent.com/u/54555?v=3","gravatar_id":"","url":"https://api.github.com/users/biopython","html_url":"https://github.com/biopython","followers_url":"https://api.github.com/users/biopython/followers","following_url":"https://api.github.com/users/biopython/following{/other_user}","gists_url":"https://api.github.com/users/biopython/gists{/gist_id}","starred_url":"https://api.github.com/users/biopython/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/biopython/subscriptions","organizations_url":"https://api.github.com/users/biopython/orgs","repos_url":"https://api.github.com/users/biopython/repos","events_url":"https://api.github.com/users/biopython/events{/privacy}","received_events_url":"https://api.github.com/users/biopython/received_events","type":"Organization","site_admin":false},"repo":{"id":151541,"name":"biopython","full_name":"biopython/biopython","owner":{"login":"biopython","id":54555,"avatar_url":"https://avatars.githubusercontent.com/u/54555?v=3","gravatar_id":"","url":"https://api.github.com/users/biopython","html_url":"https://github.com/biopython","followers_url":"https://api.github.com/users/biopython/followers","following_url":"https://api.github.com/users/biopython/following{/other_user}","gists_url":"https://api.github.com/users/biopython/gists{/gist_id}","starred_url":"https://api.github.com/users/biopython/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/biopython/subscriptions","organizations_url":"https://api.github.com/users/biopython/orgs","repos_url":"https://api.github.com/users/biopython/repos","events_url":"https://api.github.com/users/biopython/events{/privacy}","received_events_url":"https://api.github.com/users/biopython/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/biopython/biopython","description":"Official git repository for Biopython (converted from CVS)","fork":false,"url":"https://api.github.com/repos/biopython/biopython","forks_url":"https://api.github.com/repos/biopython/biopython/forks","keys_url":"https://api.github.com/repos/biopython/biopython/keys{/key_id}","collaborators_url":"https://api.github.com/repos/biopython/biopython/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/biopython/biopython/teams","hooks_url":"https://api.github.com/repos/biopython/biopython/hooks","issue_events_url":"https://api.github.com/repos/biopython/biopython/issues/events{/number}","events_url":"https://api.github.com/repos/biopython/biopython/events","assignees_url":"https://api.github.com/repos/biopython/biopython/assignees{/user}","branches_url":"https://api.github.com/repos/biopython/biopython/branches{/branch}","tags_url":"https://api.github.com/repos/biopython/biopython/tags","blobs_url":"https://api.github.com/repos/biopython/biopython/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/biopython/biopython/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/biopython/biopython/git/refs{/sha}","trees_url":"https://api.github.com/repos/biopython/biopython/git/trees{/sha}","statuses_url":"https://api.github.com/repos/biopython/biopython/statuses/{sha}","languages_url":"https://api.github.com/repos/biopython/biopython/languages","stargazers_url":"https://api.github.com/repos/biopython/biopython/stargazers","contributors_url":"https://api.github.com/repos/biopython/biopython/contributors","subscribers_url":"https://api.github.com/repos/biopython/biopython/subscribers","subscription_url":"https://api.github.com/repos/biopython/biopython/subscription","commits_url":"https://api.github.com/repos/biopython/biopython/commits{/sha}","git_commits_url":"https://api.github.com/repos/biopython/biopython/git/commits{/sha}","comments_url":"https://api.github.com/repos/biopython/biopython/comments{/number}","issue_comment_url":"https://api.github.com/repos/biopython/biopython/issues/comments/{number}","contents_url":"https://api.github.com/repos/biopython/biopython/contents/{+path}","compare_url":"https://api.github.com/repos/biopython/biopython/compare/{base}...{head}","merges_url":"https://api.github.com/repos/biopython/biopython/merges","archive_url":"https://api.github.com/repos/biopython/biopython/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/biopython/biopython/downloads","issues_url":"https://api.github.com/repos/biopython/biopython/issues{/number}","pulls_url":"https://api.github.com/repos/biopython/biopython/pulls{/number}","milestones_url":"https://api.github.com/repos/biopython/biopython/milestones{/number}","notifications_url":"https://api.github.com/repos/biopython/biopython/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/biopython/biopython/labels{/name}","releases_url":"https://api.github.com/repos/biopython/biopython/releases{/id}","created_at":"2009-03-15T21:09:53Z","updated_at":"2015-02-12T11:23:00Z","pushed_at":"2015-02-12T11:23:00Z","git_url":"git://github.com/biopython/biopython.git","ssh_url":"git@github.com:biopython/biopython.git","clone_url":"https://github.com/biopython/biopython.git","svn_url":"https://github.com/biopython/biopython","homepage":"http://biopython.org/","size":49698,"stargazers_count":562,"watchers_count":562,"language":"Python","has_issues":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":341,"mirror_url":null,"open_issues_count":71,"forks":341,"open_issues":71,"watchers":562,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/biopython/biopython/pulls/473"},"html":{"href":"https://github.com/biopython/biopython/pull/473"},"issue":{"href":"https://api.github.com/repos/biopython/biopython/issues/473"},"comments":{"href":"https://api.github.com/repos/biopython/biopython/issues/473/comments"},"review_comments":{"href":"https://api.github.com/repos/biopython/biopython/pulls/473/comments"},"review_comment":{"href":"https://api.github.com/repos/biopython/biopython/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/biopython/biopython/pulls/473/commits"},"statuses":{"href":"https://api.github.com/repos/biopython/biopython/statuses/e5ae712b66930093866df16516cecc31f5e40d15"}}}}