Skip to content

Commit cadcd74

Browse files
authored
Model changes to GenomeCoordinates, RepositoryId and ManuallyTyped (#71)
* model changed for #70 * re-order tests * closes #69 * closes #65; closes #66 * rename location to coordinates * adjust test to the use of coordinates instead of location * migrate examples * add manually typed sequence as class * remove field repository_name and revert examples * handle collections and other repos * migrate examples * test and migrate templates
1 parent 6849729 commit cadcd74

File tree

69 files changed

+9441
-3992
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

69 files changed

+9441
-3992
lines changed

migrate_templates.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
rm -f src/data/templates/*/templates/*backup.json
2+
python -m opencloning_linkml.migrations.migrate --target-version 0.4.9 src/data/templates/*/templates/*.json
3+
rm -f src/data/templates/*/templates/*backup.json
-306 Bytes
Binary file not shown.

project/graphql/opencloning_linkml.graphql

Lines changed: 24 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -33,19 +33,6 @@ enum GatewayReactionType
3333
BP
3434
}
3535

36-
enum RepositoryName
37-
{
38-
addgene
39-
genbank
40-
benchling
41-
snapgene
42-
euroscarf
43-
igem
44-
wekwikgene
45-
seva
46-
open_dna_collections
47-
}
48-
4936
enum SequenceFileFormat
5037
{
5138
fasta
@@ -62,7 +49,6 @@ type AddgeneIdSource
6249
databaseId: Integer
6350
input: [SourceInput]
6451
repositoryId: String!
65-
repositoryName: RepositoryName!
6652
sequenceFileUrl: String
6753
addgeneSequenceType: AddgeneSequenceType
6854
}
@@ -118,7 +104,6 @@ type BenchlingUrlSource
118104
outputName: String
119105
databaseId: Integer
120106
input: [SourceInput]
121-
repositoryName: RepositoryName!
122107
repositoryId: String!
123108
}
124109

@@ -200,7 +185,6 @@ type EuroscarfSource
200185
outputName: String
201186
databaseId: Integer
202187
input: [SourceInput]
203-
repositoryName: RepositoryName!
204188
repositoryId: String!
205189
}
206190

@@ -223,13 +207,12 @@ type GenomeCoordinatesSource
223207
outputName: String
224208
databaseId: Integer
225209
input: [SourceInput]
210+
coordinates: SimpleSequenceLocation
211+
repositoryId: String!
226212
assemblyAccession: String
227-
sequenceAccession: String!
228213
locusTag: String
229214
geneId: Integer
230-
start: Integer!
231-
end: Integer!
232-
strand: Integer!
215+
location: String!
233216
}
234217

235218
type GibsonAssemblySource
@@ -259,7 +242,6 @@ type IGEMSource
259242
outputName: String
260243
databaseId: Integer
261244
input: [SourceInput]
262-
repositoryName: RepositoryName!
263245
sequenceFileUrl: String!
264246
repositoryId: String!
265247
}
@@ -294,24 +276,41 @@ type LigationSource
294276
circular: Boolean
295277
}
296278

279+
type ManuallyTypedSequence
280+
{
281+
id: Integer!
282+
type: String
283+
overhangCrick3prime: Integer
284+
overhangWatson3prime: Integer
285+
sequence: String!
286+
circular: Boolean
287+
}
288+
297289
type ManuallyTypedSource
298290
{
299291
id: Integer!
300292
type: String
301293
outputName: String
302294
databaseId: Integer
303295
input: [SourceInput]
304-
overhangCrick3prime: Integer
305-
overhangWatson3prime: Integer
306-
userInput: String!
307-
circular: Boolean
308296
}
309297

310298
type NamedThing
311299
{
312300
id: Integer!
313301
}
314302

303+
type NCBISequenceSource
304+
{
305+
id: Integer!
306+
type: String
307+
outputName: String
308+
databaseId: Integer
309+
input: [SourceInput]
310+
coordinates: SimpleSequenceLocation
311+
repositoryId: String!
312+
}
313+
315314
type OligoHybridizationSource
316315
{
317316
id: Integer!
@@ -329,7 +328,6 @@ type OpenDNACollectionsSource
329328
outputName: String
330329
databaseId: Integer
331330
input: [SourceInput]
332-
repositoryName: RepositoryName!
333331
sequenceFileUrl: String
334332
repositoryId: String!
335333
}
@@ -400,7 +398,6 @@ type RepositoryIdSource
400398
databaseId: Integer
401399
input: [SourceInput]
402400
repositoryId: String!
403-
repositoryName: RepositoryName!
404401
}
405402

406403
type RestrictionAndLigationSource
@@ -480,7 +477,6 @@ type SEVASource
480477
outputName: String
481478
databaseId: Integer
482479
input: [SourceInput]
483-
repositoryName: RepositoryName!
484480
sequenceFileUrl: String
485481
repositoryId: String!
486482
}
@@ -492,7 +488,6 @@ type SnapGenePlasmidSource
492488
outputName: String
493489
databaseId: Integer
494490
input: [SourceInput]
495-
repositoryName: RepositoryName!
496491
repositoryId: String!
497492
}
498493

@@ -550,7 +545,6 @@ type WekWikGeneIdSource
550545
outputName: String
551546
databaseId: Integer
552547
input: [SourceInput]
553-
repositoryName: RepositoryName!
554548
sequenceFileUrl: String
555549
repositoryId: String!
556550
}

project/jsonld/opencloning_linkml.context.jsonld

Lines changed: 20 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"comments": {
33
"description": "Auto generated by LinkML jsonld context generator",
4-
"generation_date": "2025-11-27T13:31:19",
4+
"generation_date": "2025-12-06T00:30:23",
55
"source": "opencloning_linkml.yaml"
66
},
77
"@context": {
@@ -163,35 +163,27 @@
163163
"assembly_accession": {
164164
"@id": "assembly_accession"
165165
},
166-
"end": {
167-
"@type": "xsd:integer",
168-
"@id": "end"
169-
},
170166
"gene_id": {
171167
"@type": "xsd:integer",
172168
"@id": "gene_id"
173169
},
174170
"locus_tag": {
175171
"@id": "locus_tag"
176172
},
177-
"sequence_accession": {
178-
"@id": "sequence_accession"
179-
},
180-
"start": {
181-
"@type": "xsd:integer",
182-
"@id": "start"
183-
},
184-
"strand": {
185-
"@type": "xsd:integer",
186-
"@id": "strand"
187-
},
188173
"id": "@id",
189-
"user_input": {
190-
"@id": "user_input"
174+
"location": {
175+
"@id": "location"
176+
},
177+
"sequence": {
178+
"@type": "@id",
179+
"@id": "sequence"
191180
},
192181
"name": {
193182
"@id": "schema:name"
194183
},
184+
"coordinates": {
185+
"@id": "coordinates"
186+
},
195187
"output_name": {
196188
"@id": "output_name"
197189
},
@@ -240,31 +232,23 @@
240232
"@type": "xsd:float",
241233
"@id": "percent_match_length"
242234
},
243-
"sequence": {
244-
"@type": "@id",
245-
"@id": "sequence"
246-
},
247235
"sseqid": {
248236
"@id": "sseqid"
249237
},
250238
"start_location": {
251239
"@type": "xsd:integer",
252240
"@id": "start_location"
253241
},
242+
"strand": {
243+
"@type": "xsd:integer",
244+
"@id": "strand"
245+
},
254246
"Type": {
255247
"@id": "Type"
256248
},
257249
"repository_id": {
258250
"@id": "repository_id"
259251
},
260-
"repository_name": {
261-
"@context": {
262-
"text": "skos:notation",
263-
"description": "skos:prefLabel",
264-
"meaning": "@id"
265-
},
266-
"@id": "repository_name"
267-
},
268252
"restriction_enzyme": {
269253
"@id": "restriction_enzyme"
270254
},
@@ -315,9 +299,6 @@
315299
"@type": "xsd:boolean",
316300
"@id": "circularize"
317301
},
318-
"coordinates": {
319-
"@id": "coordinates"
320-
},
321302
"index_in_file": {
322303
"@type": "xsd:integer",
323304
"@id": "index_in_file"
@@ -391,12 +372,18 @@
391372
"LigationSource": {
392373
"@id": "LigationSource"
393374
},
375+
"ManuallyTypedSequence": {
376+
"@id": "ManuallyTypedSequence"
377+
},
394378
"ManuallyTypedSource": {
395379
"@id": "ManuallyTypedSource"
396380
},
397381
"NamedThing": {
398382
"@id": "schema:Thing"
399383
},
384+
"NCBISequenceSource": {
385+
"@id": "NCBISequenceSource"
386+
},
400387
"OligoHybridizationSource": {
401388
"@id": "OligoHybridizationSource"
402389
},

0 commit comments

Comments
 (0)