immunum 1.0.0 → 1.1.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/README.md +4 -2
- package/immunum.d.ts +33 -21
- package/immunum.js +10 -8
- package/immunum_bg.wasm +0 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+

|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Immunum is a high-performance antibody and TCR sequence numbering tool for Rust, Python, Polars and JS/TS.
|
|
4
|
+
|
|
5
|
+
Try it in your browser: [interactive demo](https://immunum.enpicom.com/demo/).
|
|
4
6
|
|
|
5
7
|
[](https://crates.io/crates/immunum)
|
|
6
8
|
[](https://pypi.org/project/immunum/)
|
package/immunum.d.ts
CHANGED
|
@@ -1,34 +1,45 @@
|
|
|
1
1
|
/* tslint:disable */
|
|
2
2
|
/* eslint-disable */
|
|
3
3
|
|
|
4
|
-
/**
|
|
5
|
-
|
|
4
|
+
/**
|
|
5
|
+
* Ordered position → residue map, iterated in IMGT-correct order.
|
|
6
|
+
* Keys are position strings (e.g. `"112A"`) and values are single-character residues.
|
|
7
|
+
*/
|
|
8
|
+
export type Numbering = Map<string, string>;
|
|
6
9
|
|
|
7
|
-
/** Result returned by {@link Annotator.number}. */
|
|
10
|
+
/** Result returned by {@link Annotator.number}. On failure, chain/scheme/confidence/numbering/query_start/query_end are null and error contains the reason. */
|
|
8
11
|
export interface NumberingResult {
|
|
9
|
-
/** Detected chain type: `"H"`, `"K"`, `"L"`, `"A"`, `"B"`, `"G"`, or `"D"`. */
|
|
10
|
-
chain: string;
|
|
11
|
-
/** Numbering scheme used: `"imgt"` or `"kabat"`. */
|
|
12
|
-
scheme: string;
|
|
13
|
-
/** Alignment confidence score between 0 and 1. */
|
|
14
|
-
confidence: number;
|
|
15
|
-
/** Position-to-residue mapping for the aligned region. */
|
|
16
|
-
numbering: Numbering;
|
|
12
|
+
/** Detected chain type: `"H"`, `"K"`, `"L"`, `"A"`, `"B"`, `"G"`, or `"D"`. Null on failure. */
|
|
13
|
+
chain: string | null;
|
|
14
|
+
/** Numbering scheme used: `"imgt"` or `"kabat"`. Null on failure. */
|
|
15
|
+
scheme: string | null;
|
|
16
|
+
/** Alignment confidence score between 0 and 1. Null on failure. */
|
|
17
|
+
confidence: number | null;
|
|
18
|
+
/** Position-to-residue mapping for the aligned region. Null on failure. */
|
|
19
|
+
numbering: Numbering | null;
|
|
20
|
+
/** 0-indexed start of the aligned region in the input sequence (inclusive). Null on failure. */
|
|
21
|
+
query_start: number | null;
|
|
22
|
+
/** 0-indexed end of the aligned region in the input sequence (inclusive). Null on failure. */
|
|
23
|
+
query_end: number | null;
|
|
24
|
+
/** Error message if numbering failed, null on success. */
|
|
25
|
+
error: string | null;
|
|
17
26
|
}
|
|
18
27
|
|
|
19
|
-
/** FR/CDR segments returned by {@link Annotator.segment}. */
|
|
28
|
+
/** FR/CDR segments returned by {@link Annotator.segment}. On failure, all region fields are absent and error contains the reason. */
|
|
20
29
|
export interface SegmentationResult {
|
|
21
|
-
fr1
|
|
22
|
-
cdr1
|
|
23
|
-
fr2
|
|
24
|
-
cdr2
|
|
25
|
-
fr3
|
|
26
|
-
cdr3
|
|
27
|
-
fr4
|
|
30
|
+
fr1?: string;
|
|
31
|
+
cdr1?: string;
|
|
32
|
+
fr2?: string;
|
|
33
|
+
cdr2?: string;
|
|
34
|
+
fr3?: string;
|
|
35
|
+
cdr3?: string;
|
|
36
|
+
fr4?: string;
|
|
28
37
|
/** Residues before FR1 (non-canonical N-terminal extension). */
|
|
29
|
-
prefix
|
|
38
|
+
prefix?: string;
|
|
30
39
|
/** Residues after FR4 (non-canonical C-terminal extension). */
|
|
31
|
-
postfix
|
|
40
|
+
postfix?: string;
|
|
41
|
+
/** Error message if segmentation failed, null on success. */
|
|
42
|
+
error: string | null;
|
|
32
43
|
}
|
|
33
44
|
|
|
34
45
|
/**
|
|
@@ -62,4 +73,5 @@ export class Annotator {
|
|
|
62
73
|
constructor(chains: string[], scheme: string, min_confidence?: number | null);
|
|
63
74
|
number(sequence: string): NumberingResult;
|
|
64
75
|
segment(sequence: string): SegmentationResult;
|
|
76
|
+
|
|
65
77
|
}
|
package/immunum.js
CHANGED
|
@@ -40,10 +40,7 @@ class Annotator {
|
|
|
40
40
|
const ptr0 = passStringToWasm0(sequence, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
41
41
|
const len0 = WASM_VECTOR_LEN;
|
|
42
42
|
const ret = wasm.annotator_number(this.__wbg_ptr, ptr0, len0);
|
|
43
|
-
|
|
44
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
45
|
-
}
|
|
46
|
-
return takeFromExternrefTable0(ret[0]);
|
|
43
|
+
return ret;
|
|
47
44
|
}
|
|
48
45
|
/**
|
|
49
46
|
* @param {string} sequence
|
|
@@ -53,10 +50,7 @@ class Annotator {
|
|
|
53
50
|
const ptr0 = passStringToWasm0(sequence, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
54
51
|
const len0 = WASM_VECTOR_LEN;
|
|
55
52
|
const ret = wasm.annotator_segment(this.__wbg_ptr, ptr0, len0);
|
|
56
|
-
|
|
57
|
-
throw takeFromExternrefTable0(ret[1]);
|
|
58
|
-
}
|
|
59
|
-
return takeFromExternrefTable0(ret[0]);
|
|
53
|
+
return ret;
|
|
60
54
|
}
|
|
61
55
|
}
|
|
62
56
|
if (Symbol.dispose) Annotator.prototype[Symbol.dispose] = Annotator.prototype.free;
|
|
@@ -83,6 +77,10 @@ function __wbg_get_imports() {
|
|
|
83
77
|
__wbg___wbindgen_throw_6ddd609b62940d55: function(arg0, arg1) {
|
|
84
78
|
throw new Error(getStringFromWasm0(arg0, arg1));
|
|
85
79
|
},
|
|
80
|
+
__wbg_new_49d5571bd3f0c4d4: function() {
|
|
81
|
+
const ret = new Map();
|
|
82
|
+
return ret;
|
|
83
|
+
},
|
|
86
84
|
__wbg_new_ab79df5bd7c26067: function() {
|
|
87
85
|
const ret = new Object();
|
|
88
86
|
return ret;
|
|
@@ -91,6 +89,10 @@ function __wbg_get_imports() {
|
|
|
91
89
|
const ret = Reflect.set(arg0, arg1, arg2);
|
|
92
90
|
return ret;
|
|
93
91
|
}, arguments); },
|
|
92
|
+
__wbg_set_bf7251625df30a02: function(arg0, arg1, arg2) {
|
|
93
|
+
const ret = arg0.set(arg1, arg2);
|
|
94
|
+
return ret;
|
|
95
|
+
},
|
|
94
96
|
__wbindgen_cast_0000000000000001: function(arg0) {
|
|
95
97
|
// Cast intrinsic for `F64 -> Externref`.
|
|
96
98
|
const ret = arg0;
|
package/immunum_bg.wasm
CHANGED
|
Binary file
|