@sjcrh/proteinpaint-types 2.145.2 → 2.146.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/aiProjectSelectedWSImages.js +1 -1
- package/dist/{chunk-PPPSDO6G.js → chunk-2BHWLFKE.js} +21 -25
- package/dist/{chunk-NO2EZKW4.js → chunk-75OHIZMS.js} +21 -25
- package/dist/chunk-DBSRGRXR.js +2126 -0
- package/dist/index.js +24 -16
- package/dist/samplewsimages.js +1 -1
- package/dist/termdb.chat.js +11 -0
- package/package.json +1 -1
- package/src/dataset.ts +8 -2
- package/src/index.ts +3 -2
- package/src/routes/aiProjectSelectedWSImages.ts +16 -0
- package/src/routes/samplewsimages.ts +6 -20
- package/src/routes/termdb.chat.ts +58 -0
package/dist/index.js
CHANGED
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
import {
|
|
2
|
+
tilePayload,
|
|
3
|
+
validTileRequest,
|
|
4
|
+
validTileResponse
|
|
5
|
+
} from "./chunk-HQV2A7JV.js";
|
|
1
6
|
import {
|
|
2
7
|
validWSImagesRequest,
|
|
3
8
|
validWSImagesResponse,
|
|
@@ -8,6 +13,11 @@ import {
|
|
|
8
13
|
validWSISamplesResponse,
|
|
9
14
|
wsiSamplesPayload
|
|
10
15
|
} from "./chunk-2744ACBX.js";
|
|
16
|
+
import {
|
|
17
|
+
termdbSingleCellDataPayload,
|
|
18
|
+
validTermdbSingleCellDataRequest,
|
|
19
|
+
validTermdbSingleCellDataResponse
|
|
20
|
+
} from "./chunk-4ZMQ5CTL.js";
|
|
11
21
|
import {
|
|
12
22
|
termdbSingleCellSamplesPayload,
|
|
13
23
|
validTermdbSingleCellSamplesRequest,
|
|
@@ -44,10 +54,10 @@ import {
|
|
|
44
54
|
violinPayload
|
|
45
55
|
} from "./chunk-MMFL6N5M.js";
|
|
46
56
|
import {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
} from "./chunk-
|
|
57
|
+
numericCategoriesPayload,
|
|
58
|
+
validNumericCategoriesRequest,
|
|
59
|
+
validNumericCategoriesResponse
|
|
60
|
+
} from "./chunk-4MLQS6N7.js";
|
|
51
61
|
import {
|
|
52
62
|
percentilePayload,
|
|
53
63
|
validPercentileRequest,
|
|
@@ -83,11 +93,6 @@ import {
|
|
|
83
93
|
validTermdbSingleCellDEgenesRequest,
|
|
84
94
|
validTermdbSingleCellDEgenesResponse
|
|
85
95
|
} from "./chunk-EYKGJDKU.js";
|
|
86
|
-
import {
|
|
87
|
-
termdbSingleCellDataPayload,
|
|
88
|
-
validTermdbSingleCellDataRequest,
|
|
89
|
-
validTermdbSingleCellDataResponse
|
|
90
|
-
} from "./chunk-4ZMQ5CTL.js";
|
|
91
96
|
import {
|
|
92
97
|
boxplotPayload,
|
|
93
98
|
validBoxPlotRequest,
|
|
@@ -98,6 +103,11 @@ import {
|
|
|
98
103
|
validCategoriesRequest,
|
|
99
104
|
validCategoriesResponse
|
|
100
105
|
} from "./chunk-5KADNZH2.js";
|
|
106
|
+
import {
|
|
107
|
+
ChatPayload,
|
|
108
|
+
validChatRequest,
|
|
109
|
+
validChatResponse
|
|
110
|
+
} from "./chunk-DBSRGRXR.js";
|
|
101
111
|
import {
|
|
102
112
|
termdbClusterPayload,
|
|
103
113
|
validTermdbClusterRequest,
|
|
@@ -123,11 +133,6 @@ import {
|
|
|
123
133
|
validFilterTermValuesRequest,
|
|
124
134
|
validFilterTermValuesResponse
|
|
125
135
|
} from "./chunk-CQXBQY2H.js";
|
|
126
|
-
import {
|
|
127
|
-
numericCategoriesPayload,
|
|
128
|
-
validNumericCategoriesRequest,
|
|
129
|
-
validNumericCategoriesResponse
|
|
130
|
-
} from "./chunk-4MLQS6N7.js";
|
|
131
136
|
import {
|
|
132
137
|
isoformlstPayload,
|
|
133
138
|
validIsoformLstRequest,
|
|
@@ -147,7 +152,7 @@ import {
|
|
|
147
152
|
sampleWSImagesPayload,
|
|
148
153
|
validSampleWSImagesRequest,
|
|
149
154
|
validSampleWSImagesResponse
|
|
150
|
-
} from "./chunk-
|
|
155
|
+
} from "./chunk-2BHWLFKE.js";
|
|
151
156
|
import {
|
|
152
157
|
saveWSIAnnotationPayload,
|
|
153
158
|
validSaveWSIAnnotationRequest,
|
|
@@ -255,7 +260,7 @@ import {
|
|
|
255
260
|
aiProjectSelectedWSImagesResponsePayload,
|
|
256
261
|
validAiProjectSelectedWSImagesRequest,
|
|
257
262
|
validAiProjectSelectedWSImagesResponse
|
|
258
|
-
} from "./chunk-
|
|
263
|
+
} from "./chunk-75OHIZMS.js";
|
|
259
264
|
import {
|
|
260
265
|
brainImagingPayload,
|
|
261
266
|
validBrainImagingRequest,
|
|
@@ -285,6 +290,7 @@ import {
|
|
|
285
290
|
} from "./chunk-4VEXL32Q.js";
|
|
286
291
|
import "./chunk-YNHC5SXO.js";
|
|
287
292
|
export {
|
|
293
|
+
ChatPayload,
|
|
288
294
|
CorrelationVolcanoPayload,
|
|
289
295
|
FilterTermValuesPayload,
|
|
290
296
|
GRIN2Payload,
|
|
@@ -353,6 +359,8 @@ export {
|
|
|
353
359
|
validBurdenResponse,
|
|
354
360
|
validCategoriesRequest,
|
|
355
361
|
validCategoriesResponse,
|
|
362
|
+
validChatRequest,
|
|
363
|
+
validChatResponse,
|
|
356
364
|
validClearWSImagesSessionsRequest,
|
|
357
365
|
validClearWSImagesSessionsResponse,
|
|
358
366
|
validCorrelationVolcanoRequest,
|
package/dist/samplewsimages.js
CHANGED
package/package.json
CHANGED
package/src/dataset.ts
CHANGED
|
@@ -1011,8 +1011,14 @@ type Mds3Queries = {
|
|
|
1011
1011
|
DZImages?: DZImages
|
|
1012
1012
|
WSImages?: WSImages
|
|
1013
1013
|
images?: Images
|
|
1014
|
+
chat?: any
|
|
1014
1015
|
}
|
|
1015
1016
|
|
|
1017
|
+
/** chat app support
|
|
1018
|
+
type Chat = {
|
|
1019
|
+
}
|
|
1020
|
+
*/
|
|
1021
|
+
|
|
1016
1022
|
/** non-zoom small images
|
|
1017
1023
|
iamge file to sample mapping is stored in images table
|
|
1018
1024
|
*/
|
|
@@ -1066,8 +1072,6 @@ export type WSImages = {
|
|
|
1066
1072
|
/** ds supplied */
|
|
1067
1073
|
getWSIAnnotations?: (projectId: string, wsiImage: string) => Promise<string[]>
|
|
1068
1074
|
/** ds supplied */
|
|
1069
|
-
makeGeoJson?: (sampleId: string, wsiImage: string) => void
|
|
1070
|
-
/** ds supplied */
|
|
1071
1075
|
getWSIPredictionOverlay?: (wsiImage: string) => Promise<string | undefined>
|
|
1072
1076
|
/** ds supplied */
|
|
1073
1077
|
getWSIUncertaintyOverlay?: (wsiImage: string) => Promise<string | undefined>
|
|
@@ -1299,6 +1303,8 @@ type Matrix = {
|
|
|
1299
1303
|
legendGrpFilter?: any
|
|
1300
1304
|
/** filter to hide categories or mclass, e.g. hide male, hide MISSENSE */
|
|
1301
1305
|
legendValueFilter?: any
|
|
1306
|
+
/** local filter to limit samples in matrix/hiercluster, merged with this.state.termfilter.filter when querying server */
|
|
1307
|
+
localFilter?: any
|
|
1302
1308
|
/** matrix criteria for a CNV alteration */
|
|
1303
1309
|
cnvCutoffs?: any
|
|
1304
1310
|
}
|
package/src/index.ts
CHANGED
|
@@ -22,7 +22,6 @@ export * from './routes/gdc.maf.ts'
|
|
|
22
22
|
export * from './routes/gdc.mafBuild.ts'
|
|
23
23
|
export * from './routes/gdc.grin2.ts'
|
|
24
24
|
export * from './routes/grin2.ts'
|
|
25
|
-
export * from './routes/termdb.topMutatedGenes.ts'
|
|
26
25
|
export * from './routes/genelookup.ts'
|
|
27
26
|
export * from './routes/genesetEnrichment.ts'
|
|
28
27
|
export * from './routes/genesetOverrepresentation.ts'
|
|
@@ -30,6 +29,7 @@ export * from './routes/healthcheck.ts'
|
|
|
30
29
|
export * from './routes/hicdata.ts'
|
|
31
30
|
export * from './routes/hicgenome.ts'
|
|
32
31
|
export * from './routes/hicstat.ts'
|
|
32
|
+
export * from './routes/img.ts'
|
|
33
33
|
export * from './routes/isoformlst.ts'
|
|
34
34
|
export * from './routes/ntseq.ts'
|
|
35
35
|
export * from './routes/pdomain.ts'
|
|
@@ -38,6 +38,7 @@ export * from './routes/saveWSIAnnotation.ts'
|
|
|
38
38
|
export * from './routes/snp.ts'
|
|
39
39
|
export * from './routes/termdb.boxplot.ts'
|
|
40
40
|
export * from './routes/termdb.categories.ts'
|
|
41
|
+
export * from './routes/termdb.chat.ts'
|
|
41
42
|
export * from './routes/termdb.cluster.ts'
|
|
42
43
|
export * from './routes/termdb.cohort.summary.ts'
|
|
43
44
|
export * from './routes/termdb.cohorts.ts'
|
|
@@ -48,13 +49,13 @@ export * from './routes/termdb.percentile.ts'
|
|
|
48
49
|
export * from './routes/termdb.rootterm.ts'
|
|
49
50
|
export * from './routes/termdb.termchildren.ts'
|
|
50
51
|
export * from './routes/termdb.sampleImages.ts'
|
|
51
|
-
export * from './routes/img.ts'
|
|
52
52
|
export * from './routes/termdb.singlecellData.ts'
|
|
53
53
|
export * from './routes/termdb.singlecellDEgenes.ts'
|
|
54
54
|
export * from './routes/termdb.singlecellSamples.ts'
|
|
55
55
|
export * from './routes/termdb.singleSampleMutation.ts'
|
|
56
56
|
export * from './routes/termdb.termsbyids.ts'
|
|
57
57
|
export * from './routes/termdb.termchildren.ts'
|
|
58
|
+
export * from './routes/termdb.topMutatedGenes.ts'
|
|
58
59
|
export * from './routes/termdb.topTermsByType.ts'
|
|
59
60
|
export * from './routes/termdb.topVariablyExpressedGenes.ts'
|
|
60
61
|
export * from './routes/termdb.violin.ts'
|
|
@@ -13,6 +13,22 @@ export type AiProjectSelectedWSImagesResponse = {
|
|
|
13
13
|
wsimages: WSImage[]
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
+
// TODO move to another class
|
|
17
|
+
export interface TileSelection {
|
|
18
|
+
zoomCoordinates: [number, number]
|
|
19
|
+
class?: string
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export interface Annotation extends TileSelection {
|
|
23
|
+
class: string
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export interface Prediction extends TileSelection {
|
|
27
|
+
type: string
|
|
28
|
+
class: string
|
|
29
|
+
uncertainty: number
|
|
30
|
+
}
|
|
31
|
+
|
|
16
32
|
export const aiProjectSelectedWSImagesResponsePayload: RoutePayload = {
|
|
17
33
|
request: {
|
|
18
34
|
typeId: 'AiProjectSelectedWSImagesRequest'
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { RoutePayload } from './routeApi.ts'
|
|
2
2
|
import type { WSIClass } from '../dataset.ts'
|
|
3
|
+
import type { Annotation, Prediction } from './aiProjectSelectedWSImages.ts'
|
|
3
4
|
|
|
4
5
|
export type SampleWSImagesRequest = {
|
|
5
6
|
genome: string
|
|
@@ -12,13 +13,11 @@ export type SampleWSImagesResponse = {
|
|
|
12
13
|
sampleWSImages: WSImage[]
|
|
13
14
|
}
|
|
14
15
|
|
|
15
|
-
export
|
|
16
|
+
export class WSImage {
|
|
16
17
|
id?: number
|
|
17
18
|
filename: string
|
|
18
|
-
// TODO remove when it's verified
|
|
19
|
-
annotationsAndPredictionsOverlay?: string
|
|
20
|
-
predictionLayers?: Array<string>
|
|
21
19
|
metadata?: string
|
|
20
|
+
predictionLayers?: Array<string>
|
|
22
21
|
annotations?: Array<Annotation>
|
|
23
22
|
predictions?: Array<Prediction>
|
|
24
23
|
classes?: Array<WSIClass>
|
|
@@ -28,23 +27,10 @@ export type WSImage = {
|
|
|
28
27
|
activePatchColor?: string
|
|
29
28
|
/** Tile size in pixels needed for AI scripts */
|
|
30
29
|
tileSize?: number
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
export type Annotation = {
|
|
34
|
-
zoomCoordinates: [number, number]
|
|
35
|
-
class: string
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
export type Prediction = {
|
|
39
|
-
zoomCoordinates: [number, number]
|
|
40
|
-
type: string
|
|
41
|
-
class: string
|
|
42
|
-
uncertainty: number
|
|
43
|
-
}
|
|
44
30
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
31
|
+
constructor(filename: string) {
|
|
32
|
+
this.filename = filename
|
|
33
|
+
}
|
|
48
34
|
}
|
|
49
35
|
|
|
50
36
|
export const sampleWSImagesPayload: RoutePayload = {
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import type { Filter } from '../filter.ts'
|
|
2
|
+
import type { RoutePayload } from './routeApi.js'
|
|
3
|
+
|
|
4
|
+
/** */
|
|
5
|
+
export type ChatRequest = {
|
|
6
|
+
genome: string
|
|
7
|
+
dslabel: string
|
|
8
|
+
filter?: Filter
|
|
9
|
+
filter0?: any // gdc
|
|
10
|
+
/** user prompt */
|
|
11
|
+
prompt: string
|
|
12
|
+
__protected__: any
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export type numeric_filter = {
|
|
16
|
+
lower: number
|
|
17
|
+
upper: number
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export type categorical_filter = {
|
|
21
|
+
name: string
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export type filter_variable = {
|
|
25
|
+
name: string
|
|
26
|
+
variable_type: 'float' | 'categories'
|
|
27
|
+
cutoff: numeric_filter | categorical_filter
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export type summary = {
|
|
31
|
+
group_categories: string
|
|
32
|
+
overlay?: string
|
|
33
|
+
divide_by?: string
|
|
34
|
+
filter?: filter_variable
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export type plot = {
|
|
38
|
+
/** Different chart types currently supported by the AI chatbot, will add types for the other charts when they will be implemented */
|
|
39
|
+
chartType: summary | 'survival' | 'hierarchial' | 'snv_indel' | 'cnv' | 'variant_calling' | 'none' | 'dge'
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export type ChatResponse = {
|
|
43
|
+
type: 'html' | 'plot'
|
|
44
|
+
/** when type=html, this value is set meaning server returns a chat response */
|
|
45
|
+
html?: string
|
|
46
|
+
/** when type=plot. value is json */
|
|
47
|
+
plot?: any
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export const ChatPayload: RoutePayload = {
|
|
51
|
+
request: {
|
|
52
|
+
typeId: 'ChatRequest'
|
|
53
|
+
},
|
|
54
|
+
response: {
|
|
55
|
+
typeId: 'ChatResponse'
|
|
56
|
+
}
|
|
57
|
+
//examples: []
|
|
58
|
+
}
|