hume 0.3.0 → 0.3.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/Client.js +5 -5
- package/api/types/FaceModelConfig.d.ts +4 -17
- package/api/types/ModelConfig.d.ts +0 -5
- package/api/types/ModelsInput.d.ts +1 -9
- package/api/types/TextPosition.d.ts +0 -1
- package/dist/Client.js +5 -5
- package/dist/api/types/FaceModelConfig.d.ts +4 -17
- package/dist/api/types/ModelConfig.d.ts +0 -5
- package/dist/api/types/ModelsInput.d.ts +1 -9
- package/dist/api/types/TextPosition.d.ts +0 -1
- package/package.json +1 -1
package/Client.js
CHANGED
|
@@ -94,7 +94,7 @@ class HumeClient {
|
|
|
94
94
|
"X-Hume-Api-Key": yield core.Supplier.get(this._options.apiKey),
|
|
95
95
|
"X-Fern-Language": "JavaScript",
|
|
96
96
|
"X-Fern-SDK-Name": "hume",
|
|
97
|
-
"X-Fern-SDK-Version": "0.3.
|
|
97
|
+
"X-Fern-SDK-Version": "0.3.1",
|
|
98
98
|
},
|
|
99
99
|
contentType: "application/json",
|
|
100
100
|
queryParameters: _queryParams,
|
|
@@ -143,7 +143,7 @@ class HumeClient {
|
|
|
143
143
|
"X-Hume-Api-Key": yield core.Supplier.get(this._options.apiKey),
|
|
144
144
|
"X-Fern-Language": "JavaScript",
|
|
145
145
|
"X-Fern-SDK-Name": "hume",
|
|
146
|
-
"X-Fern-SDK-Version": "0.3.
|
|
146
|
+
"X-Fern-SDK-Version": "0.3.1",
|
|
147
147
|
},
|
|
148
148
|
contentType: "application/json",
|
|
149
149
|
body: yield serializers.BaseRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -195,7 +195,7 @@ class HumeClient {
|
|
|
195
195
|
"X-Hume-Api-Key": yield core.Supplier.get(this._options.apiKey),
|
|
196
196
|
"X-Fern-Language": "JavaScript",
|
|
197
197
|
"X-Fern-SDK-Name": "hume",
|
|
198
|
-
"X-Fern-SDK-Version": "0.3.
|
|
198
|
+
"X-Fern-SDK-Version": "0.3.1",
|
|
199
199
|
},
|
|
200
200
|
contentType: "application/json",
|
|
201
201
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -243,7 +243,7 @@ class HumeClient {
|
|
|
243
243
|
"X-Hume-Api-Key": yield core.Supplier.get(this._options.apiKey),
|
|
244
244
|
"X-Fern-Language": "JavaScript",
|
|
245
245
|
"X-Fern-SDK-Name": "hume",
|
|
246
|
-
"X-Fern-SDK-Version": "0.3.
|
|
246
|
+
"X-Fern-SDK-Version": "0.3.1",
|
|
247
247
|
},
|
|
248
248
|
contentType: "application/json",
|
|
249
249
|
responseType: "streaming",
|
|
@@ -287,7 +287,7 @@ class HumeClient {
|
|
|
287
287
|
"X-Hume-Api-Key": yield core.Supplier.get(this._options.apiKey),
|
|
288
288
|
"X-Fern-Language": "JavaScript",
|
|
289
289
|
"X-Fern-SDK-Name": "hume",
|
|
290
|
-
"X-Fern-SDK-Version": "0.3.
|
|
290
|
+
"X-Fern-SDK-Version": "0.3.1",
|
|
291
291
|
},
|
|
292
292
|
contentType: "application/json",
|
|
293
293
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -5,31 +5,18 @@
|
|
|
5
5
|
* Configuration for the facial expression emotion model.
|
|
6
6
|
*
|
|
7
7
|
* Note: Using the `reset_stream` parameter does not have any effect on face identification. A single face identifier cache is maintained over a full session whether `reset_stream` is used or not.
|
|
8
|
-
*
|
|
9
8
|
*/
|
|
10
9
|
export interface FaceModelConfig {
|
|
11
10
|
/** Configuration for FACS predictions. If missing or null, no FACS predictions will be generated. */
|
|
12
11
|
facs?: Record<string, unknown>;
|
|
13
12
|
/** Configuration for Descriptions predictions. If missing or null, no Descriptions predictions will be generated. */
|
|
14
13
|
descriptions?: Record<string, unknown>;
|
|
15
|
-
/**
|
|
16
|
-
* Whether to return identifiers for faces across frames. If true, unique identifiers will be assigned to face bounding boxes to differentiate different faces. If false, all faces will be tagged with an "unknown" ID.
|
|
17
|
-
*
|
|
18
|
-
*/
|
|
14
|
+
/** Whether to return identifiers for faces across frames. If true, unique identifiers will be assigned to face bounding boxes to differentiate different faces. If false, all faces will be tagged with an "unknown" ID. */
|
|
19
15
|
identifyFaces?: boolean;
|
|
20
|
-
/**
|
|
21
|
-
* Number of frames per second to process. Other frames will be omitted from the response.
|
|
22
|
-
*
|
|
23
|
-
*/
|
|
16
|
+
/** Number of frames per second to process. Other frames will be omitted from the response. */
|
|
24
17
|
fpsPred?: number;
|
|
25
|
-
/**
|
|
26
|
-
* Face detection probability threshold. Faces detected with a probability less than this threshold will be omitted from the response.
|
|
27
|
-
*
|
|
28
|
-
*/
|
|
18
|
+
/** Face detection probability threshold. Faces detected with a probability less than this threshold will be omitted from the response. */
|
|
29
19
|
probThreshold?: number;
|
|
30
|
-
/**
|
|
31
|
-
* Minimum bounding box side length in pixels to treat as a face. Faces detected with a bounding box side length in pixels less than this threshold will be omitted from the response.
|
|
32
|
-
*
|
|
33
|
-
*/
|
|
20
|
+
/** Minimum bounding box side length in pixels to treat as a face. Faces detected with a bounding box side length in pixels less than this threshold will be omitted from the response. */
|
|
34
21
|
minFaceSize?: number;
|
|
35
22
|
}
|
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
import * as Hume from "..";
|
|
5
5
|
/**
|
|
6
6
|
* Configuration used to specify which models should be used and with what settings.
|
|
7
|
-
*
|
|
8
7
|
*/
|
|
9
8
|
export interface ModelConfig {
|
|
10
9
|
/**
|
|
@@ -13,14 +12,12 @@ export interface ModelConfig {
|
|
|
13
12
|
* Note: Model configuration is not currently available in streaming.
|
|
14
13
|
*
|
|
15
14
|
* Please use the default configuration by passing an empty object `{}`.
|
|
16
|
-
*
|
|
17
15
|
*/
|
|
18
16
|
burst?: Record<string, unknown>;
|
|
19
17
|
/**
|
|
20
18
|
* Configuration for the facial expression emotion model.
|
|
21
19
|
*
|
|
22
20
|
* Note: Using the `reset_stream` parameter does not have any effect on face identification. A single face identifier cache is maintained over a full session whether `reset_stream` is used or not.
|
|
23
|
-
*
|
|
24
21
|
*/
|
|
25
22
|
face?: Hume.FaceModelConfig;
|
|
26
23
|
/**
|
|
@@ -29,7 +26,6 @@ export interface ModelConfig {
|
|
|
29
26
|
* Note: Model configuration is not currently available in streaming.
|
|
30
27
|
*
|
|
31
28
|
* Please use the default configuration by passing an empty object `{}`.
|
|
32
|
-
*
|
|
33
29
|
*/
|
|
34
30
|
facemesh?: Record<string, unknown>;
|
|
35
31
|
/** Configuration for the language emotion model. */
|
|
@@ -40,7 +36,6 @@ export interface ModelConfig {
|
|
|
40
36
|
* Note: Model configuration is not currently available in streaming.
|
|
41
37
|
*
|
|
42
38
|
* Please use the default configuration by passing an empty object `{}`.
|
|
43
|
-
*
|
|
44
39
|
*/
|
|
45
40
|
prosody?: Record<string, unknown>;
|
|
46
41
|
}
|
|
@@ -4,10 +4,7 @@
|
|
|
4
4
|
import * as Hume from "..";
|
|
5
5
|
export interface ModelsInput {
|
|
6
6
|
data?: string;
|
|
7
|
-
/**
|
|
8
|
-
* Configuration used to specify which models should be used and with what settings.
|
|
9
|
-
*
|
|
10
|
-
*/
|
|
7
|
+
/** Configuration used to specify which models should be used and with what settings. */
|
|
11
8
|
models?: Hume.ModelConfig;
|
|
12
9
|
/**
|
|
13
10
|
* Length in milliseconds of streaming sliding window.
|
|
@@ -19,7 +16,6 @@ export interface ModelsInput {
|
|
|
19
16
|
* A window of 600ms would append the full 500ms of the second payload to the last 100ms of the first payload.
|
|
20
17
|
*
|
|
21
18
|
* Note: This feature is currently only supported for audio data and audio models. For other file types and models this parameter will be ignored.
|
|
22
|
-
*
|
|
23
19
|
*/
|
|
24
20
|
streamWindowMs?: number;
|
|
25
21
|
/**
|
|
@@ -28,13 +24,11 @@ export interface ModelsInput {
|
|
|
28
24
|
* If this parameter is set to `true` then past context will be deleted before processing the current payload.
|
|
29
25
|
*
|
|
30
26
|
* Use reset_stream when one audio file is done being processed and you do not want context to leak across files.
|
|
31
|
-
*
|
|
32
27
|
*/
|
|
33
28
|
resetStream?: boolean;
|
|
34
29
|
/**
|
|
35
30
|
* Set to `true` to enable the data parameter to be parsed as raw text rather than base64 encoded bytes.
|
|
36
31
|
* This parameter is useful if you want to send text to be processed by the language model, but it cannot be used with other file types like audio, image, or video.
|
|
37
|
-
*
|
|
38
32
|
*/
|
|
39
33
|
rawText?: boolean;
|
|
40
34
|
/**
|
|
@@ -43,14 +37,12 @@ export interface ModelsInput {
|
|
|
43
37
|
* This parameter can be set in the same payload as data or it can be set without data and models configuration to get the job details between payloads.
|
|
44
38
|
*
|
|
45
39
|
* This parameter is useful to get the unique job ID.
|
|
46
|
-
*
|
|
47
40
|
*/
|
|
48
41
|
jobDetails?: boolean;
|
|
49
42
|
/**
|
|
50
43
|
* Pass an arbitrary string as the payload ID and get it back at the top level of the socket response.
|
|
51
44
|
*
|
|
52
45
|
* This can be useful if you have multiple requests running asynchronously and want to disambiguate responses as they are received.
|
|
53
|
-
*
|
|
54
46
|
*/
|
|
55
47
|
payloadId?: string;
|
|
56
48
|
}
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
*/
|
|
4
4
|
/**
|
|
5
5
|
* Position of a segment of text within a larger document, measured in characters. Uses zero-based indexing. The beginning index is inclusive and the end index is exclusive.
|
|
6
|
-
*
|
|
7
6
|
*/
|
|
8
7
|
export interface TextPosition {
|
|
9
8
|
/** The index of the first character in the text segment, inclusive. */
|
package/dist/Client.js
CHANGED
|
@@ -94,7 +94,7 @@ class HumeClient {
|
|
|
94
94
|
"X-Hume-Api-Key": yield core.Supplier.get(this._options.apiKey),
|
|
95
95
|
"X-Fern-Language": "JavaScript",
|
|
96
96
|
"X-Fern-SDK-Name": "hume",
|
|
97
|
-
"X-Fern-SDK-Version": "0.3.
|
|
97
|
+
"X-Fern-SDK-Version": "0.3.1",
|
|
98
98
|
},
|
|
99
99
|
contentType: "application/json",
|
|
100
100
|
queryParameters: _queryParams,
|
|
@@ -143,7 +143,7 @@ class HumeClient {
|
|
|
143
143
|
"X-Hume-Api-Key": yield core.Supplier.get(this._options.apiKey),
|
|
144
144
|
"X-Fern-Language": "JavaScript",
|
|
145
145
|
"X-Fern-SDK-Name": "hume",
|
|
146
|
-
"X-Fern-SDK-Version": "0.3.
|
|
146
|
+
"X-Fern-SDK-Version": "0.3.1",
|
|
147
147
|
},
|
|
148
148
|
contentType: "application/json",
|
|
149
149
|
body: yield serializers.BaseRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
|
|
@@ -195,7 +195,7 @@ class HumeClient {
|
|
|
195
195
|
"X-Hume-Api-Key": yield core.Supplier.get(this._options.apiKey),
|
|
196
196
|
"X-Fern-Language": "JavaScript",
|
|
197
197
|
"X-Fern-SDK-Name": "hume",
|
|
198
|
-
"X-Fern-SDK-Version": "0.3.
|
|
198
|
+
"X-Fern-SDK-Version": "0.3.1",
|
|
199
199
|
},
|
|
200
200
|
contentType: "application/json",
|
|
201
201
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -243,7 +243,7 @@ class HumeClient {
|
|
|
243
243
|
"X-Hume-Api-Key": yield core.Supplier.get(this._options.apiKey),
|
|
244
244
|
"X-Fern-Language": "JavaScript",
|
|
245
245
|
"X-Fern-SDK-Name": "hume",
|
|
246
|
-
"X-Fern-SDK-Version": "0.3.
|
|
246
|
+
"X-Fern-SDK-Version": "0.3.1",
|
|
247
247
|
},
|
|
248
248
|
contentType: "application/json",
|
|
249
249
|
responseType: "streaming",
|
|
@@ -287,7 +287,7 @@ class HumeClient {
|
|
|
287
287
|
"X-Hume-Api-Key": yield core.Supplier.get(this._options.apiKey),
|
|
288
288
|
"X-Fern-Language": "JavaScript",
|
|
289
289
|
"X-Fern-SDK-Name": "hume",
|
|
290
|
-
"X-Fern-SDK-Version": "0.3.
|
|
290
|
+
"X-Fern-SDK-Version": "0.3.1",
|
|
291
291
|
},
|
|
292
292
|
contentType: "application/json",
|
|
293
293
|
timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
|
|
@@ -5,31 +5,18 @@
|
|
|
5
5
|
* Configuration for the facial expression emotion model.
|
|
6
6
|
*
|
|
7
7
|
* Note: Using the `reset_stream` parameter does not have any effect on face identification. A single face identifier cache is maintained over a full session whether `reset_stream` is used or not.
|
|
8
|
-
*
|
|
9
8
|
*/
|
|
10
9
|
export interface FaceModelConfig {
|
|
11
10
|
/** Configuration for FACS predictions. If missing or null, no FACS predictions will be generated. */
|
|
12
11
|
facs?: Record<string, unknown>;
|
|
13
12
|
/** Configuration for Descriptions predictions. If missing or null, no Descriptions predictions will be generated. */
|
|
14
13
|
descriptions?: Record<string, unknown>;
|
|
15
|
-
/**
|
|
16
|
-
* Whether to return identifiers for faces across frames. If true, unique identifiers will be assigned to face bounding boxes to differentiate different faces. If false, all faces will be tagged with an "unknown" ID.
|
|
17
|
-
*
|
|
18
|
-
*/
|
|
14
|
+
/** Whether to return identifiers for faces across frames. If true, unique identifiers will be assigned to face bounding boxes to differentiate different faces. If false, all faces will be tagged with an "unknown" ID. */
|
|
19
15
|
identifyFaces?: boolean;
|
|
20
|
-
/**
|
|
21
|
-
* Number of frames per second to process. Other frames will be omitted from the response.
|
|
22
|
-
*
|
|
23
|
-
*/
|
|
16
|
+
/** Number of frames per second to process. Other frames will be omitted from the response. */
|
|
24
17
|
fpsPred?: number;
|
|
25
|
-
/**
|
|
26
|
-
* Face detection probability threshold. Faces detected with a probability less than this threshold will be omitted from the response.
|
|
27
|
-
*
|
|
28
|
-
*/
|
|
18
|
+
/** Face detection probability threshold. Faces detected with a probability less than this threshold will be omitted from the response. */
|
|
29
19
|
probThreshold?: number;
|
|
30
|
-
/**
|
|
31
|
-
* Minimum bounding box side length in pixels to treat as a face. Faces detected with a bounding box side length in pixels less than this threshold will be omitted from the response.
|
|
32
|
-
*
|
|
33
|
-
*/
|
|
20
|
+
/** Minimum bounding box side length in pixels to treat as a face. Faces detected with a bounding box side length in pixels less than this threshold will be omitted from the response. */
|
|
34
21
|
minFaceSize?: number;
|
|
35
22
|
}
|
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
import * as Hume from "..";
|
|
5
5
|
/**
|
|
6
6
|
* Configuration used to specify which models should be used and with what settings.
|
|
7
|
-
*
|
|
8
7
|
*/
|
|
9
8
|
export interface ModelConfig {
|
|
10
9
|
/**
|
|
@@ -13,14 +12,12 @@ export interface ModelConfig {
|
|
|
13
12
|
* Note: Model configuration is not currently available in streaming.
|
|
14
13
|
*
|
|
15
14
|
* Please use the default configuration by passing an empty object `{}`.
|
|
16
|
-
*
|
|
17
15
|
*/
|
|
18
16
|
burst?: Record<string, unknown>;
|
|
19
17
|
/**
|
|
20
18
|
* Configuration for the facial expression emotion model.
|
|
21
19
|
*
|
|
22
20
|
* Note: Using the `reset_stream` parameter does not have any effect on face identification. A single face identifier cache is maintained over a full session whether `reset_stream` is used or not.
|
|
23
|
-
*
|
|
24
21
|
*/
|
|
25
22
|
face?: Hume.FaceModelConfig;
|
|
26
23
|
/**
|
|
@@ -29,7 +26,6 @@ export interface ModelConfig {
|
|
|
29
26
|
* Note: Model configuration is not currently available in streaming.
|
|
30
27
|
*
|
|
31
28
|
* Please use the default configuration by passing an empty object `{}`.
|
|
32
|
-
*
|
|
33
29
|
*/
|
|
34
30
|
facemesh?: Record<string, unknown>;
|
|
35
31
|
/** Configuration for the language emotion model. */
|
|
@@ -40,7 +36,6 @@ export interface ModelConfig {
|
|
|
40
36
|
* Note: Model configuration is not currently available in streaming.
|
|
41
37
|
*
|
|
42
38
|
* Please use the default configuration by passing an empty object `{}`.
|
|
43
|
-
*
|
|
44
39
|
*/
|
|
45
40
|
prosody?: Record<string, unknown>;
|
|
46
41
|
}
|
|
@@ -4,10 +4,7 @@
|
|
|
4
4
|
import * as Hume from "..";
|
|
5
5
|
export interface ModelsInput {
|
|
6
6
|
data?: string;
|
|
7
|
-
/**
|
|
8
|
-
* Configuration used to specify which models should be used and with what settings.
|
|
9
|
-
*
|
|
10
|
-
*/
|
|
7
|
+
/** Configuration used to specify which models should be used and with what settings. */
|
|
11
8
|
models?: Hume.ModelConfig;
|
|
12
9
|
/**
|
|
13
10
|
* Length in milliseconds of streaming sliding window.
|
|
@@ -19,7 +16,6 @@ export interface ModelsInput {
|
|
|
19
16
|
* A window of 600ms would append the full 500ms of the second payload to the last 100ms of the first payload.
|
|
20
17
|
*
|
|
21
18
|
* Note: This feature is currently only supported for audio data and audio models. For other file types and models this parameter will be ignored.
|
|
22
|
-
*
|
|
23
19
|
*/
|
|
24
20
|
streamWindowMs?: number;
|
|
25
21
|
/**
|
|
@@ -28,13 +24,11 @@ export interface ModelsInput {
|
|
|
28
24
|
* If this parameter is set to `true` then past context will be deleted before processing the current payload.
|
|
29
25
|
*
|
|
30
26
|
* Use reset_stream when one audio file is done being processed and you do not want context to leak across files.
|
|
31
|
-
*
|
|
32
27
|
*/
|
|
33
28
|
resetStream?: boolean;
|
|
34
29
|
/**
|
|
35
30
|
* Set to `true` to enable the data parameter to be parsed as raw text rather than base64 encoded bytes.
|
|
36
31
|
* This parameter is useful if you want to send text to be processed by the language model, but it cannot be used with other file types like audio, image, or video.
|
|
37
|
-
*
|
|
38
32
|
*/
|
|
39
33
|
rawText?: boolean;
|
|
40
34
|
/**
|
|
@@ -43,14 +37,12 @@ export interface ModelsInput {
|
|
|
43
37
|
* This parameter can be set in the same payload as data or it can be set without data and models configuration to get the job details between payloads.
|
|
44
38
|
*
|
|
45
39
|
* This parameter is useful to get the unique job ID.
|
|
46
|
-
*
|
|
47
40
|
*/
|
|
48
41
|
jobDetails?: boolean;
|
|
49
42
|
/**
|
|
50
43
|
* Pass an arbitrary string as the payload ID and get it back at the top level of the socket response.
|
|
51
44
|
*
|
|
52
45
|
* This can be useful if you have multiple requests running asynchronously and want to disambiguate responses as they are received.
|
|
53
|
-
*
|
|
54
46
|
*/
|
|
55
47
|
payloadId?: string;
|
|
56
48
|
}
|
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
*/
|
|
4
4
|
/**
|
|
5
5
|
* Position of a segment of text within a larger document, measured in characters. Uses zero-based indexing. The beginning index is inclusive and the end index is exclusive.
|
|
6
|
-
*
|
|
7
6
|
*/
|
|
8
7
|
export interface TextPosition {
|
|
9
8
|
/** The index of the first character in the text segment, inclusive. */
|