honeyhive 0.3.0 → 0.3.6
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 +76 -14
- package/dist/internal/utils/requestbody.js +28 -18
- package/dist/internal/utils/utils.js +2 -4
- package/dist/sdk/index.d.ts +1 -0
- package/dist/sdk/index.js +1 -0
- package/dist/sdk/models/operations/deletedatasetsname.d.ts +1 -1
- package/dist/sdk/models/operations/deletedatasetsname.js +1 -1
- package/dist/sdk/models/operations/deletemetrics.d.ts +1 -1
- package/dist/sdk/models/operations/deletemetrics.js +1 -1
- package/dist/sdk/models/operations/deletepromptsid.d.ts +1 -1
- package/dist/sdk/models/operations/deletepromptsid.js +1 -1
- package/dist/sdk/models/operations/deletetasks.d.ts +1 -1
- package/dist/sdk/models/operations/deletetasks.js +1 -1
- package/dist/sdk/models/operations/getdatasets.d.ts +5 -5
- package/dist/sdk/models/operations/getdatasets.js +5 -5
- package/dist/sdk/models/operations/getfinetunedmodels.d.ts +5 -5
- package/dist/sdk/models/operations/getfinetunedmodels.js +5 -5
- package/dist/sdk/models/operations/getfinetunedmodelsid.d.ts +1 -1
- package/dist/sdk/models/operations/getfinetunedmodelsid.js +1 -1
- package/dist/sdk/models/operations/getgenerations.d.ts +5 -5
- package/dist/sdk/models/operations/getgenerations.js +5 -5
- package/dist/sdk/models/operations/getmetrics.d.ts +5 -5
- package/dist/sdk/models/operations/getmetrics.js +5 -5
- package/dist/sdk/models/operations/getprompts.d.ts +5 -5
- package/dist/sdk/models/operations/getprompts.js +5 -5
- package/dist/sdk/models/operations/getsession.d.ts +6 -11
- package/dist/sdk/models/operations/getsession.js +7 -18
- package/dist/sdk/models/operations/getsessionsessionid.d.ts +1 -1
- package/dist/sdk/models/operations/getsessionsessionid.js +1 -1
- package/dist/sdk/models/operations/getsessionsessionidexport.d.ts +1 -1
- package/dist/sdk/models/operations/getsessionsessionidexport.js +1 -1
- package/dist/sdk/models/operations/gettasks.d.ts +2 -2
- package/dist/sdk/models/operations/gettasks.js +2 -2
- package/dist/sdk/models/operations/index.d.ts +1 -1
- package/dist/sdk/models/operations/index.js +1 -1
- package/dist/sdk/models/operations/postdatasets.d.ts +1 -1
- package/dist/sdk/models/operations/postdatasets.js +1 -1
- package/dist/sdk/models/operations/postevaluations.d.ts +1 -1
- package/dist/sdk/models/operations/postevaluations.js +1 -1
- package/dist/sdk/models/operations/postfeedback.d.ts +1 -1
- package/dist/sdk/models/operations/postfeedback.js +1 -1
- package/dist/sdk/models/operations/postgenerations.d.ts +1 -1
- package/dist/sdk/models/operations/postgenerations.js +1 -1
- package/dist/sdk/models/operations/postgenerationslog.d.ts +1 -1
- package/dist/sdk/models/operations/postgenerationslog.js +1 -1
- package/dist/sdk/models/operations/postmetrics.d.ts +1 -1
- package/dist/sdk/models/operations/postmetrics.js +1 -1
- package/dist/sdk/models/operations/postprompts.d.ts +1 -1
- package/dist/sdk/models/operations/postprompts.js +1 -1
- package/dist/sdk/models/operations/postsessionsessionidend.d.ts +1 -1
- package/dist/sdk/models/operations/postsessionsessionidend.js +1 -1
- package/dist/sdk/models/operations/postsessionsessionidevent.d.ts +1 -1
- package/dist/sdk/models/operations/postsessionsessionidevent.js +1 -1
- package/dist/sdk/models/operations/postsessionsessionidfeedback.d.ts +1 -1
- package/dist/sdk/models/operations/postsessionsessionidfeedback.js +1 -1
- package/dist/sdk/models/operations/postsessionsessionidtraces.d.ts +25 -0
- package/dist/sdk/models/operations/postsessionsessionidtraces.js +95 -0
- package/dist/sdk/models/operations/postsessionstart.d.ts +1 -1
- package/dist/sdk/models/operations/postsessionstart.js +1 -1
- package/dist/sdk/models/operations/posttasks.d.ts +1 -1
- package/dist/sdk/models/operations/posttasks.js +1 -1
- package/dist/sdk/models/operations/putpromptsid.d.ts +1 -1
- package/dist/sdk/models/operations/putpromptsid.js +1 -1
- package/dist/sdk/models/operations/puttasks.d.ts +1 -1
- package/dist/sdk/models/operations/puttasks.js +1 -1
- package/dist/sdk/models/shared/datasetresponse.d.ts +1 -3
- package/dist/sdk/models/shared/datasetresponse.js +2 -11
- package/dist/sdk/models/shared/evaluationloggingquery.d.ts +7 -21
- package/dist/sdk/models/shared/evaluationloggingquery.js +8 -71
- package/dist/sdk/models/shared/feedbackquery.d.ts +1 -6
- package/dist/sdk/models/shared/feedbackquery.js +2 -14
- package/dist/sdk/models/shared/feedbackresponse.d.ts +1 -6
- package/dist/sdk/models/shared/feedbackresponse.js +2 -14
- package/dist/sdk/models/shared/generatequery.d.ts +3 -18
- package/dist/sdk/models/shared/generatequery.js +4 -40
- package/dist/sdk/models/shared/generationloggingquery.d.ts +7 -32
- package/dist/sdk/models/shared/generationloggingquery.js +13 -73
- package/dist/sdk/models/shared/metricresponse.d.ts +1 -6
- package/dist/sdk/models/shared/metricresponse.js +2 -14
- package/dist/sdk/models/shared/promptcreationquery.d.ts +1 -3
- package/dist/sdk/models/shared/promptcreationquery.js +2 -11
- package/dist/sdk/models/shared/promptresponse.d.ts +1 -3
- package/dist/sdk/models/shared/promptresponse.js +2 -11
- package/dist/sdk/models/shared/promptupdatequery.d.ts +1 -3
- package/dist/sdk/models/shared/promptupdatequery.js +2 -11
- package/dist/sdk/models/shared/sessioneventquery.d.ts +33 -31
- package/dist/sdk/models/shared/sessioneventquery.js +40 -67
- package/dist/sdk/models/shared/sessionfeedback.d.ts +1 -6
- package/dist/sdk/models/shared/sessionfeedback.js +2 -14
- package/dist/sdk/models/shared/sessionstartquery.d.ts +1 -6
- package/dist/sdk/models/shared/sessionstartquery.js +2 -14
- package/dist/sdk/models/shared/uploaddataset.d.ts +1 -3
- package/dist/sdk/models/shared/uploaddataset.js +2 -11
- package/dist/sdk/sdk.d.ts +3 -3
- package/dist/sdk/sdk.js +24 -24
- package/dist/sdk/tracer.d.ts +140 -0
- package/dist/sdk/tracer.js +233 -0
- package/docs/models/operations/getdatasetsresponse.md +2 -2
- package/docs/models/operations/getfinetunedmodelsresponse.md +2 -2
- package/docs/models/operations/getgenerationsresponse.md +2 -2
- package/docs/models/operations/getmetricsresponse.md +2 -2
- package/docs/models/operations/getpromptsresponse.md +2 -2
- package/docs/models/operations/getsessionrequest.md +5 -5
- package/docs/models/operations/getsessionresponse.md +2 -2
- package/docs/models/operations/gettasksresponse.md +1 -1
- package/docs/models/operations/{postsessionssessionidtracesrequest.md → postsessionsessionidtracesrequest.md} +1 -1
- package/docs/models/operations/{postsessionssessionidtracesresponse.md → postsessionsessionidtracesresponse.md} +1 -1
- package/docs/models/shared/datasetresponse.md +1 -1
- package/docs/models/shared/evaluationloggingquery.md +16 -16
- package/docs/models/shared/feedbackquery.md +6 -6
- package/docs/models/shared/feedbackresponse.md +1 -1
- package/docs/models/shared/generatequery.md +14 -14
- package/docs/models/shared/generationloggingquery.md +16 -16
- package/docs/models/shared/{generatequerymetadata.md → metadata.md} +1 -1
- package/docs/models/shared/metricresponse.md +1 -1
- package/docs/models/shared/promptcreationquery.md +11 -11
- package/docs/models/shared/promptresponse.md +1 -1
- package/docs/models/shared/promptupdatequery.md +9 -9
- package/docs/models/shared/sessioneventquery.md +20 -14
- package/docs/models/shared/sessionfeedback.md +4 -4
- package/docs/models/shared/sessionstartquery.md +7 -7
- package/docs/models/shared/sessiontrace.md +3 -3
- package/docs/models/shared/taskcreationquery.md +4 -4
- package/docs/models/shared/taskresponse.md +4 -4
- package/docs/models/shared/taskupdatequery.md +9 -9
- package/docs/models/shared/uploaddataset.md +8 -8
- package/docs/sdks/honeyhive/README.md +313 -132
- package/package.json +7 -5
- package/docs/models/operations/getsessionquery.md +0 -9
- package/docs/models/shared/datasetresponsefile.md +0 -7
- package/docs/models/shared/evaluationloggingquerycomments.md +0 -7
- package/docs/models/shared/evaluationloggingquerydataset.md +0 -7
- package/docs/models/shared/evaluationloggingquerygenerations.md +0 -7
- package/docs/models/shared/evaluationloggingquerymetrics.md +0 -7
- package/docs/models/shared/evaluationloggingqueryprompts.md +0 -7
- package/docs/models/shared/evaluationloggingqueryresults.md +0 -7
- package/docs/models/shared/evaluationloggingquerysummary.md +0 -7
- package/docs/models/shared/feedbackqueryfeedbackjson.md +0 -9
- package/docs/models/shared/feedbackresponsefeedback.md +0 -9
- package/docs/models/shared/generatequeryinput.md +0 -9
- package/docs/models/shared/generatequeryuserproperties.md +0 -9
- package/docs/models/shared/generationloggingqueryfeedback.md +0 -9
- package/docs/models/shared/generationloggingqueryhyperparameters.md +0 -9
- package/docs/models/shared/generationloggingqueryinputs.md +0 -9
- package/docs/models/shared/generationloggingquerymetadata.md +0 -9
- package/docs/models/shared/generationloggingqueryusage.md +0 -9
- package/docs/models/shared/generationloggingqueryuserproperties.md +0 -9
- package/docs/models/shared/metricresponsethreshold.md +0 -9
- package/docs/models/shared/promptcreationqueryfewshotexamples.md +0 -7
- package/docs/models/shared/promptresponsefewshotexamples.md +0 -7
- package/docs/models/shared/promptupdatequeryfewshotexamples.md +0 -7
- package/docs/models/shared/sessioneventquerychildren.md +0 -7
- package/docs/models/shared/sessioneventqueryconfig.md +0 -9
- package/docs/models/shared/sessioneventqueryerror.md +0 -9
- package/docs/models/shared/sessioneventqueryinputs.md +0 -9
- package/docs/models/shared/sessioneventquerymetadata.md +0 -9
- package/docs/models/shared/sessionfeedbackfeedback.md +0 -9
- package/docs/models/shared/sessionstartqueryuserproperties.md +0 -9
- package/docs/models/shared/uploaddatasetfile.md +0 -7
package/dist/sdk/sdk.js
CHANGED
|
@@ -94,9 +94,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
94
94
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
95
95
|
exports.HoneyHive = exports.SDKConfiguration = exports.ServerList = void 0;
|
|
96
96
|
var utils = __importStar(require("../internal/utils"));
|
|
97
|
-
var errors = __importStar(require("
|
|
98
|
-
var operations = __importStar(require("
|
|
99
|
-
var shared = __importStar(require("
|
|
97
|
+
var errors = __importStar(require("../sdk/models/errors"));
|
|
98
|
+
var operations = __importStar(require("../sdk/models/operations"));
|
|
99
|
+
var shared = __importStar(require("../sdk/models/shared"));
|
|
100
100
|
var axios_1 = __importDefault(require("axios"));
|
|
101
101
|
/**
|
|
102
102
|
* Contains the list of servers available to the SDK
|
|
@@ -106,9 +106,9 @@ var SDKConfiguration = /** @class */ (function () {
|
|
|
106
106
|
function SDKConfiguration(init) {
|
|
107
107
|
this.language = "typescript";
|
|
108
108
|
this.openapiDocVersion = "1.0.1";
|
|
109
|
-
this.sdkVersion = "0.
|
|
110
|
-
this.genVersion = "2.
|
|
111
|
-
this.userAgent = "speakeasy-sdk/typescript 0.
|
|
109
|
+
this.sdkVersion = "0.5.0";
|
|
110
|
+
this.genVersion = "2.183.0";
|
|
111
|
+
this.userAgent = "speakeasy-sdk/typescript 0.5.0 2.183.0 1.0.1 honeyhive";
|
|
112
112
|
Object.assign(this, init);
|
|
113
113
|
}
|
|
114
114
|
return SDKConfiguration;
|
|
@@ -423,9 +423,9 @@ var HoneyHive = /** @class */ (function () {
|
|
|
423
423
|
switch (true) {
|
|
424
424
|
case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 200:
|
|
425
425
|
if (utils.matchContentType(contentType, "application/json")) {
|
|
426
|
-
res.
|
|
426
|
+
res.classes = [];
|
|
427
427
|
resFieldDepth = utils.getResFieldDepth(res);
|
|
428
|
-
res.
|
|
428
|
+
res.classes = utils.objectToClass(JSON.parse(decodedRes), shared.DatasetResponse, resFieldDepth);
|
|
429
429
|
}
|
|
430
430
|
else {
|
|
431
431
|
throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
|
|
@@ -487,9 +487,9 @@ var HoneyHive = /** @class */ (function () {
|
|
|
487
487
|
switch (true) {
|
|
488
488
|
case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 200:
|
|
489
489
|
if (utils.matchContentType(contentType, "application/json")) {
|
|
490
|
-
res.
|
|
490
|
+
res.classes = [];
|
|
491
491
|
resFieldDepth = utils.getResFieldDepth(res);
|
|
492
|
-
res.
|
|
492
|
+
res.classes = utils.objectToClass(JSON.parse(decodedRes), shared.FineTunedModelResponse, resFieldDepth);
|
|
493
493
|
}
|
|
494
494
|
else {
|
|
495
495
|
throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
|
|
@@ -612,9 +612,9 @@ var HoneyHive = /** @class */ (function () {
|
|
|
612
612
|
switch (true) {
|
|
613
613
|
case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 200:
|
|
614
614
|
if (utils.matchContentType(contentType, "application/json")) {
|
|
615
|
-
res.
|
|
615
|
+
res.classes = [];
|
|
616
616
|
resFieldDepth = utils.getResFieldDepth(res);
|
|
617
|
-
res.
|
|
617
|
+
res.classes = utils.objectToClass(JSON.parse(decodedRes), shared.Generation, resFieldDepth);
|
|
618
618
|
}
|
|
619
619
|
else {
|
|
620
620
|
throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
|
|
@@ -676,9 +676,9 @@ var HoneyHive = /** @class */ (function () {
|
|
|
676
676
|
switch (true) {
|
|
677
677
|
case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 200:
|
|
678
678
|
if (utils.matchContentType(contentType, "application/json")) {
|
|
679
|
-
res.
|
|
679
|
+
res.classes = [];
|
|
680
680
|
resFieldDepth = utils.getResFieldDepth(res);
|
|
681
|
-
res.
|
|
681
|
+
res.classes = utils.objectToClass(JSON.parse(decodedRes), shared.MetricResponse, resFieldDepth);
|
|
682
682
|
}
|
|
683
683
|
else {
|
|
684
684
|
throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
|
|
@@ -740,9 +740,9 @@ var HoneyHive = /** @class */ (function () {
|
|
|
740
740
|
switch (true) {
|
|
741
741
|
case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 200:
|
|
742
742
|
if (utils.matchContentType(contentType, "application/json")) {
|
|
743
|
-
res.
|
|
743
|
+
res.classes = [];
|
|
744
744
|
resFieldDepth = utils.getResFieldDepth(res);
|
|
745
|
-
res.
|
|
745
|
+
res.classes = utils.objectToClass(JSON.parse(decodedRes), shared.PromptResponse, resFieldDepth);
|
|
746
746
|
}
|
|
747
747
|
else {
|
|
748
748
|
throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
|
|
@@ -804,9 +804,9 @@ var HoneyHive = /** @class */ (function () {
|
|
|
804
804
|
switch (true) {
|
|
805
805
|
case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 200:
|
|
806
806
|
if (utils.matchContentType(contentType, "application/json")) {
|
|
807
|
-
res.
|
|
807
|
+
res.classes = [];
|
|
808
808
|
resFieldDepth = utils.getResFieldDepth(res);
|
|
809
|
-
res.
|
|
809
|
+
res.classes = utils.objectToClass(JSON.parse(decodedRes), shared.SessionEventQuery, resFieldDepth);
|
|
810
810
|
}
|
|
811
811
|
else {
|
|
812
812
|
throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
|
|
@@ -992,9 +992,9 @@ var HoneyHive = /** @class */ (function () {
|
|
|
992
992
|
switch (true) {
|
|
993
993
|
case (httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == 200:
|
|
994
994
|
if (utils.matchContentType(contentType, "application/json")) {
|
|
995
|
-
res.
|
|
995
|
+
res.classes = [];
|
|
996
996
|
resFieldDepth = utils.getResFieldDepth(res);
|
|
997
|
-
res.
|
|
997
|
+
res.classes = utils.objectToClass(JSON.parse(decodedRes), shared.TaskResponse, resFieldDepth);
|
|
998
998
|
}
|
|
999
999
|
else {
|
|
1000
1000
|
throw new errors.SDKError("unknown content-type received: " + contentType, httpRes.status, decodedRes, httpRes);
|
|
@@ -1803,7 +1803,7 @@ var HoneyHive = /** @class */ (function () {
|
|
|
1803
1803
|
/**
|
|
1804
1804
|
* Log a trace
|
|
1805
1805
|
*/
|
|
1806
|
-
HoneyHive.prototype.
|
|
1806
|
+
HoneyHive.prototype.postSessionSessionIdTraces = function (req, config) {
|
|
1807
1807
|
var _a, _b;
|
|
1808
1808
|
return __awaiter(this, void 0, void 0, function () {
|
|
1809
1809
|
var baseURL, url, _c, reqBodyHeaders, reqBody, client, globalSecurity, properties, headers, httpRes, contentType, res, decodedRes;
|
|
@@ -1812,10 +1812,10 @@ var HoneyHive = /** @class */ (function () {
|
|
|
1812
1812
|
switch (_e.label) {
|
|
1813
1813
|
case 0:
|
|
1814
1814
|
if (!(req instanceof utils.SpeakeasyBase)) {
|
|
1815
|
-
req = new operations.
|
|
1815
|
+
req = new operations.PostSessionSessionIdTracesRequest(req);
|
|
1816
1816
|
}
|
|
1817
1817
|
baseURL = utils.templateUrl(this.sdkConfiguration.serverURL, this.sdkConfiguration.serverDefaults);
|
|
1818
|
-
url = utils.generateURL(baseURL, "/
|
|
1818
|
+
url = utils.generateURL(baseURL, "/session/{session_id}/traces", req);
|
|
1819
1819
|
_c = __read([{}, null], 2), reqBodyHeaders = _c[0], reqBody = _c[1];
|
|
1820
1820
|
try {
|
|
1821
1821
|
_d = __read(utils.serializeRequestBody(req, "sessionTrace", "json"), 2), reqBodyHeaders = _d[0], reqBody = _d[1];
|
|
@@ -1849,7 +1849,7 @@ var HoneyHive = /** @class */ (function () {
|
|
|
1849
1849
|
if ((httpRes === null || httpRes === void 0 ? void 0 : httpRes.status) == null) {
|
|
1850
1850
|
throw new Error("status code not found in response: ".concat(httpRes));
|
|
1851
1851
|
}
|
|
1852
|
-
res = new operations.
|
|
1852
|
+
res = new operations.PostSessionSessionIdTracesResponse({
|
|
1853
1853
|
statusCode: httpRes.status,
|
|
1854
1854
|
contentType: contentType,
|
|
1855
1855
|
rawResponse: httpRes,
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
export type EventType = "chain" | "generic" | "tool" | "model";
|
|
2
|
+
export interface Config {
|
|
3
|
+
type: string;
|
|
4
|
+
name?: string;
|
|
5
|
+
description?: string;
|
|
6
|
+
}
|
|
7
|
+
export interface ModelConfig extends Config {
|
|
8
|
+
provider: string;
|
|
9
|
+
endpoint?: string;
|
|
10
|
+
model: string;
|
|
11
|
+
prompt_template?: string;
|
|
12
|
+
chat_template?: ChatMessage[];
|
|
13
|
+
temperature?: number;
|
|
14
|
+
max_tokens?: number;
|
|
15
|
+
top_p?: number;
|
|
16
|
+
stop?: string | string[];
|
|
17
|
+
presence_penalty?: number;
|
|
18
|
+
frequency_penalty?: number;
|
|
19
|
+
other?: {
|
|
20
|
+
[key: string]: any;
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
export interface ToolConfig extends Config {
|
|
24
|
+
source?: string;
|
|
25
|
+
other?: {
|
|
26
|
+
[key: string]: any;
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
export interface AgentOther {
|
|
30
|
+
max_iterations: number;
|
|
31
|
+
stop?: string | string[];
|
|
32
|
+
output_parser?: string;
|
|
33
|
+
}
|
|
34
|
+
export interface AgentConfig extends Config {
|
|
35
|
+
agent_class: string;
|
|
36
|
+
tools: ToolConfig[];
|
|
37
|
+
model_config: ModelConfig;
|
|
38
|
+
other: AgentOther;
|
|
39
|
+
}
|
|
40
|
+
export declare enum ChatRole {
|
|
41
|
+
User = "user",
|
|
42
|
+
Assistant = "assistant",
|
|
43
|
+
System = "system"
|
|
44
|
+
}
|
|
45
|
+
export interface ChatMessage {
|
|
46
|
+
role: ChatRole;
|
|
47
|
+
content: string;
|
|
48
|
+
name?: string;
|
|
49
|
+
}
|
|
50
|
+
export interface ParentLog {
|
|
51
|
+
project?: string;
|
|
52
|
+
eventId?: string;
|
|
53
|
+
sessionId?: string;
|
|
54
|
+
eventType?: EventType;
|
|
55
|
+
eventName?: string;
|
|
56
|
+
config?: Config | ModelConfig | ToolConfig | AgentConfig;
|
|
57
|
+
inputs?: {
|
|
58
|
+
[key: string]: any;
|
|
59
|
+
};
|
|
60
|
+
outputs?: {
|
|
61
|
+
[key: string]: any;
|
|
62
|
+
};
|
|
63
|
+
children?: ChildLog[];
|
|
64
|
+
userProperties?: {
|
|
65
|
+
[key: string]: any;
|
|
66
|
+
};
|
|
67
|
+
metadata?: {
|
|
68
|
+
[key: string]: any;
|
|
69
|
+
};
|
|
70
|
+
source?: string;
|
|
71
|
+
startTime?: number;
|
|
72
|
+
endTime?: number;
|
|
73
|
+
duration?: number;
|
|
74
|
+
error?: string;
|
|
75
|
+
metrics?: {
|
|
76
|
+
[key: string]: number;
|
|
77
|
+
};
|
|
78
|
+
feedback?: {
|
|
79
|
+
[key: string]: any;
|
|
80
|
+
};
|
|
81
|
+
}
|
|
82
|
+
export interface ChildLog {
|
|
83
|
+
project?: string;
|
|
84
|
+
event_id: string;
|
|
85
|
+
session_id?: string;
|
|
86
|
+
parent_id?: string;
|
|
87
|
+
event_type: EventType;
|
|
88
|
+
event_name: string;
|
|
89
|
+
config: Config | ModelConfig | ToolConfig | AgentConfig;
|
|
90
|
+
inputs: {
|
|
91
|
+
[key: string]: any;
|
|
92
|
+
};
|
|
93
|
+
outputs?: {
|
|
94
|
+
[key: string]: any;
|
|
95
|
+
};
|
|
96
|
+
children?: ChildLog[];
|
|
97
|
+
user_properties?: {
|
|
98
|
+
[key: string]: any;
|
|
99
|
+
};
|
|
100
|
+
metadata?: {
|
|
101
|
+
[key: string]: any;
|
|
102
|
+
};
|
|
103
|
+
source?: string;
|
|
104
|
+
start_time?: number;
|
|
105
|
+
end_time?: number;
|
|
106
|
+
duration?: number;
|
|
107
|
+
error?: string;
|
|
108
|
+
metrics?: {
|
|
109
|
+
[key: string]: number;
|
|
110
|
+
};
|
|
111
|
+
feedback?: {
|
|
112
|
+
[key: string]: any;
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
export declare class SessionTracer {
|
|
116
|
+
private api_key;
|
|
117
|
+
private project;
|
|
118
|
+
private session_name;
|
|
119
|
+
private user_properties;
|
|
120
|
+
private source;
|
|
121
|
+
private eventStack;
|
|
122
|
+
private sdk;
|
|
123
|
+
private session_id;
|
|
124
|
+
private parentEvent;
|
|
125
|
+
constructor(api_key: string, project: string, session_name: string, user_properties?: {
|
|
126
|
+
[key: string]: any;
|
|
127
|
+
}, source?: string);
|
|
128
|
+
startSession(inputs?: {
|
|
129
|
+
[key: string]: any;
|
|
130
|
+
}): Promise<void>;
|
|
131
|
+
startEvent(event_type: EventType, event_name: string, config: Config | ModelConfig | ToolConfig | AgentConfig, inputs: {
|
|
132
|
+
[key: string]: any;
|
|
133
|
+
}): void;
|
|
134
|
+
endEvent(outputs?: {
|
|
135
|
+
[key: string]: any;
|
|
136
|
+
}, error?: string): void;
|
|
137
|
+
endSession(outputs?: {
|
|
138
|
+
[key: string]: any;
|
|
139
|
+
}, error?: string): Promise<void>;
|
|
140
|
+
}
|
|
@@ -0,0 +1,233 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
12
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
13
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
14
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
15
|
+
function step(op) {
|
|
16
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
17
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
18
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
19
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
20
|
+
switch (op[0]) {
|
|
21
|
+
case 0: case 1: t = op; break;
|
|
22
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
23
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
24
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
25
|
+
default:
|
|
26
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
27
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
28
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
29
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
30
|
+
if (t[2]) _.ops.pop();
|
|
31
|
+
_.trys.pop(); continue;
|
|
32
|
+
}
|
|
33
|
+
op = body.call(thisArg, _);
|
|
34
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
35
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
var __read = (this && this.__read) || function (o, n) {
|
|
39
|
+
var m = typeof Symbol === "function" && o[Symbol.iterator];
|
|
40
|
+
if (!m) return o;
|
|
41
|
+
var i = m.call(o), r, ar = [], e;
|
|
42
|
+
try {
|
|
43
|
+
while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);
|
|
44
|
+
}
|
|
45
|
+
catch (error) { e = { error: error }; }
|
|
46
|
+
finally {
|
|
47
|
+
try {
|
|
48
|
+
if (r && !r.done && (m = i["return"])) m.call(i);
|
|
49
|
+
}
|
|
50
|
+
finally { if (e) throw e.error; }
|
|
51
|
+
}
|
|
52
|
+
return ar;
|
|
53
|
+
};
|
|
54
|
+
var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
55
|
+
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
56
|
+
if (ar || !(i in from)) {
|
|
57
|
+
if (!ar) ar = Array.prototype.slice.call(from, 0, i);
|
|
58
|
+
ar[i] = from[i];
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
return to.concat(ar || Array.prototype.slice.call(from));
|
|
62
|
+
};
|
|
63
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
64
|
+
exports.SessionTracer = exports.ChatRole = void 0;
|
|
65
|
+
var uuid_1 = require("uuid");
|
|
66
|
+
var sdk_1 = require("./sdk");
|
|
67
|
+
var ChatRole;
|
|
68
|
+
(function (ChatRole) {
|
|
69
|
+
ChatRole["User"] = "user";
|
|
70
|
+
ChatRole["Assistant"] = "assistant";
|
|
71
|
+
ChatRole["System"] = "system";
|
|
72
|
+
})(ChatRole = exports.ChatRole || (exports.ChatRole = {}));
|
|
73
|
+
var SessionTracer = /** @class */ (function () {
|
|
74
|
+
function SessionTracer(api_key, project, session_name, user_properties, source) {
|
|
75
|
+
if (user_properties === void 0) { user_properties = {}; }
|
|
76
|
+
if (source === void 0) { source = 'HoneyHive Typescript SDK'; }
|
|
77
|
+
this.api_key = api_key;
|
|
78
|
+
this.project = project;
|
|
79
|
+
this.session_name = session_name;
|
|
80
|
+
this.user_properties = user_properties;
|
|
81
|
+
this.source = source;
|
|
82
|
+
this.eventStack = [];
|
|
83
|
+
this.sdk = new sdk_1.HoneyHive({
|
|
84
|
+
bearerAuth: api_key,
|
|
85
|
+
});
|
|
86
|
+
this.session_id = "";
|
|
87
|
+
this.parentEvent = {};
|
|
88
|
+
}
|
|
89
|
+
SessionTracer.prototype.startSession = function (inputs) {
|
|
90
|
+
var _a;
|
|
91
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
92
|
+
var event_id, res, session_id, _b;
|
|
93
|
+
return __generator(this, function (_c) {
|
|
94
|
+
switch (_c.label) {
|
|
95
|
+
case 0:
|
|
96
|
+
_c.trys.push([0, 2, , 3]);
|
|
97
|
+
event_id = (0, uuid_1.v4)();
|
|
98
|
+
this.parentEvent = {
|
|
99
|
+
project: this.project,
|
|
100
|
+
eventId: event_id,
|
|
101
|
+
eventType: "chain",
|
|
102
|
+
eventName: this.session_name,
|
|
103
|
+
config: { type: "chain" },
|
|
104
|
+
inputs: inputs || {},
|
|
105
|
+
startTime: Date.now(),
|
|
106
|
+
userProperties: this.user_properties,
|
|
107
|
+
metadata: {},
|
|
108
|
+
source: this.source,
|
|
109
|
+
children: [],
|
|
110
|
+
metrics: {},
|
|
111
|
+
feedback: {},
|
|
112
|
+
};
|
|
113
|
+
return [4 /*yield*/, this.sdk.postSessionStart({
|
|
114
|
+
userProperties: this.user_properties,
|
|
115
|
+
sessionId: event_id,
|
|
116
|
+
sessionName: this.session_name,
|
|
117
|
+
source: this.source,
|
|
118
|
+
project: this.project,
|
|
119
|
+
})];
|
|
120
|
+
case 1:
|
|
121
|
+
res = _c.sent();
|
|
122
|
+
session_id = (_a = res.sessionStartResponse) === null || _a === void 0 ? void 0 : _a.sessionId;
|
|
123
|
+
if (session_id) {
|
|
124
|
+
this.session_id = session_id;
|
|
125
|
+
}
|
|
126
|
+
else {
|
|
127
|
+
throw new Error("Session start failed!");
|
|
128
|
+
}
|
|
129
|
+
return [3 /*break*/, 3];
|
|
130
|
+
case 2:
|
|
131
|
+
_b = _c.sent();
|
|
132
|
+
return [3 /*break*/, 3];
|
|
133
|
+
case 3: return [2 /*return*/];
|
|
134
|
+
}
|
|
135
|
+
});
|
|
136
|
+
});
|
|
137
|
+
};
|
|
138
|
+
SessionTracer.prototype.startEvent = function (event_type, event_name, config, inputs) {
|
|
139
|
+
try {
|
|
140
|
+
var newEvent = {
|
|
141
|
+
event_id: (0, uuid_1.v4)(),
|
|
142
|
+
parent_id: this.eventStack.length > 0 ? this.eventStack[this.eventStack.length - 1].event_id : this.parentEvent.eventId,
|
|
143
|
+
event_type: event_type,
|
|
144
|
+
event_name: event_name,
|
|
145
|
+
config: config,
|
|
146
|
+
inputs: inputs,
|
|
147
|
+
start_time: Date.now(),
|
|
148
|
+
user_properties: this.user_properties,
|
|
149
|
+
metadata: {},
|
|
150
|
+
source: this.source,
|
|
151
|
+
children: [],
|
|
152
|
+
error: "",
|
|
153
|
+
metrics: {},
|
|
154
|
+
feedback: {},
|
|
155
|
+
};
|
|
156
|
+
this.eventStack.push(newEvent);
|
|
157
|
+
}
|
|
158
|
+
catch (_a) {
|
|
159
|
+
// continue regardless of error
|
|
160
|
+
}
|
|
161
|
+
};
|
|
162
|
+
SessionTracer.prototype.endEvent = function (outputs, error) {
|
|
163
|
+
try {
|
|
164
|
+
if (this.eventStack.length < 1) {
|
|
165
|
+
throw new Error("No event to end. Stack length must be at least 1.");
|
|
166
|
+
}
|
|
167
|
+
var currentEvent = this.eventStack.pop();
|
|
168
|
+
if (currentEvent) {
|
|
169
|
+
currentEvent.end_time = Date.now();
|
|
170
|
+
currentEvent.duration = currentEvent.end_time - (currentEvent.start_time || currentEvent.end_time);
|
|
171
|
+
currentEvent.outputs = outputs;
|
|
172
|
+
if (error) {
|
|
173
|
+
currentEvent.error = error;
|
|
174
|
+
}
|
|
175
|
+
if (this.eventStack.length > 0) {
|
|
176
|
+
this.eventStack[this.eventStack.length - 1].children = __spreadArray(__spreadArray([], __read((this.eventStack[this.eventStack.length - 1].children || [])), false), [currentEvent], false);
|
|
177
|
+
}
|
|
178
|
+
else {
|
|
179
|
+
this.parentEvent.children = __spreadArray(__spreadArray([], __read((this.parentEvent.children || [])), false), [currentEvent], false);
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
catch (_a) {
|
|
184
|
+
// continue regardless of error
|
|
185
|
+
}
|
|
186
|
+
};
|
|
187
|
+
SessionTracer.prototype.endSession = function (outputs, error) {
|
|
188
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
189
|
+
var session_trace, res, _a;
|
|
190
|
+
return __generator(this, function (_b) {
|
|
191
|
+
switch (_b.label) {
|
|
192
|
+
case 0:
|
|
193
|
+
_b.trys.push([0, 3, , 4]);
|
|
194
|
+
while (this.eventStack.length > 0) {
|
|
195
|
+
this.endEvent();
|
|
196
|
+
}
|
|
197
|
+
session_trace = this.parentEvent;
|
|
198
|
+
if (session_trace) {
|
|
199
|
+
session_trace.sessionId = (0, uuid_1.v4)();
|
|
200
|
+
}
|
|
201
|
+
session_trace.endTime = Date.now();
|
|
202
|
+
session_trace.duration = session_trace.endTime - (session_trace.startTime || session_trace.endTime);
|
|
203
|
+
session_trace.outputs = outputs;
|
|
204
|
+
if (error) {
|
|
205
|
+
session_trace.error = error;
|
|
206
|
+
}
|
|
207
|
+
if (!session_trace) return [3 /*break*/, 2];
|
|
208
|
+
return [4 /*yield*/, this.sdk.postSessionSessionIdTraces({
|
|
209
|
+
sessionTrace: { logs: [session_trace] },
|
|
210
|
+
sessionId: this.session_id,
|
|
211
|
+
})];
|
|
212
|
+
case 1:
|
|
213
|
+
res = _b.sent();
|
|
214
|
+
if (res.statusCode == 200) {
|
|
215
|
+
// handle response
|
|
216
|
+
console.log('Session trace sent successfully.');
|
|
217
|
+
}
|
|
218
|
+
else {
|
|
219
|
+
console.error('Failed to send session trace:', res);
|
|
220
|
+
}
|
|
221
|
+
_b.label = 2;
|
|
222
|
+
case 2: return [3 /*break*/, 4];
|
|
223
|
+
case 3:
|
|
224
|
+
_a = _b.sent();
|
|
225
|
+
return [3 /*break*/, 4];
|
|
226
|
+
case 4: return [2 /*return*/];
|
|
227
|
+
}
|
|
228
|
+
});
|
|
229
|
+
});
|
|
230
|
+
};
|
|
231
|
+
return SessionTracer;
|
|
232
|
+
}());
|
|
233
|
+
exports.SessionTracer = SessionTracer;
|
|
@@ -6,6 +6,6 @@
|
|
|
6
6
|
| Field | Type | Required | Description |
|
|
7
7
|
| ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ |
|
|
8
8
|
| `contentType` | *string* | :heavy_check_mark: | HTTP response content type for this operation |
|
|
9
|
-
| `datasetResponses` | [shared.DatasetResponse](../../models/shared/datasetresponse.md)[] | :heavy_minus_sign: | OK |
|
|
10
9
|
| `statusCode` | *number* | :heavy_check_mark: | HTTP response status code for this operation |
|
|
11
|
-
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
10
|
+
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
11
|
+
| `classes` | [shared.DatasetResponse](../../models/shared/datasetresponse.md)[] | :heavy_minus_sign: | OK |
|
|
@@ -6,6 +6,6 @@
|
|
|
6
6
|
| Field | Type | Required | Description |
|
|
7
7
|
| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- |
|
|
8
8
|
| `contentType` | *string* | :heavy_check_mark: | HTTP response content type for this operation |
|
|
9
|
-
| `fineTunedModelResponses` | [shared.FineTunedModelResponse](../../models/shared/finetunedmodelresponse.md)[] | :heavy_minus_sign: | OK |
|
|
10
9
|
| `statusCode` | *number* | :heavy_check_mark: | HTTP response status code for this operation |
|
|
11
|
-
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
10
|
+
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
11
|
+
| `classes` | [shared.FineTunedModelResponse](../../models/shared/finetunedmodelresponse.md)[] | :heavy_minus_sign: | OK |
|
|
@@ -6,6 +6,6 @@
|
|
|
6
6
|
| Field | Type | Required | Description |
|
|
7
7
|
| -------------------------------------------------------- | -------------------------------------------------------- | -------------------------------------------------------- | -------------------------------------------------------- |
|
|
8
8
|
| `contentType` | *string* | :heavy_check_mark: | HTTP response content type for this operation |
|
|
9
|
-
| `generations` | [shared.Generation](../../models/shared/generation.md)[] | :heavy_minus_sign: | OK |
|
|
10
9
|
| `statusCode` | *number* | :heavy_check_mark: | HTTP response status code for this operation |
|
|
11
|
-
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
10
|
+
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
11
|
+
| `classes` | [shared.Generation](../../models/shared/generation.md)[] | :heavy_minus_sign: | OK |
|
|
@@ -6,6 +6,6 @@
|
|
|
6
6
|
| Field | Type | Required | Description |
|
|
7
7
|
| ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- |
|
|
8
8
|
| `contentType` | *string* | :heavy_check_mark: | HTTP response content type for this operation |
|
|
9
|
-
| `metricResponses` | [shared.MetricResponse](../../models/shared/metricresponse.md)[] | :heavy_minus_sign: | OK |
|
|
10
9
|
| `statusCode` | *number* | :heavy_check_mark: | HTTP response status code for this operation |
|
|
11
|
-
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
10
|
+
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
11
|
+
| `classes` | [shared.MetricResponse](../../models/shared/metricresponse.md)[] | :heavy_minus_sign: | OK |
|
|
@@ -6,6 +6,6 @@
|
|
|
6
6
|
| Field | Type | Required | Description |
|
|
7
7
|
| ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- |
|
|
8
8
|
| `contentType` | *string* | :heavy_check_mark: | HTTP response content type for this operation |
|
|
9
|
-
| `promptResponses` | [shared.PromptResponse](../../models/shared/promptresponse.md)[] | :heavy_minus_sign: | OK |
|
|
10
9
|
| `statusCode` | *number* | :heavy_check_mark: | HTTP response status code for this operation |
|
|
11
|
-
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
10
|
+
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
11
|
+
| `classes` | [shared.PromptResponse](../../models/shared/promptresponse.md)[] | :heavy_minus_sign: | OK |
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
|
|
4
4
|
## Fields
|
|
5
5
|
|
|
6
|
-
| Field
|
|
7
|
-
|
|
|
8
|
-
| `limit`
|
|
9
|
-
| `project`
|
|
10
|
-
| `query`
|
|
6
|
+
| Field | Type | Required | Description |
|
|
7
|
+
| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- | ---------------------------------------- |
|
|
8
|
+
| `limit` | *number* | :heavy_minus_sign: | The maximum number of sessions to return |
|
|
9
|
+
| `project` | *string* | :heavy_minus_sign: | The project to query sessions for |
|
|
10
|
+
| `query` | Record<string, *any*> | :heavy_minus_sign: | The query for finding sessions |
|
|
@@ -6,6 +6,6 @@
|
|
|
6
6
|
| Field | Type | Required | Description |
|
|
7
7
|
| ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- |
|
|
8
8
|
| `contentType` | *string* | :heavy_check_mark: | HTTP response content type for this operation |
|
|
9
|
-
| `sessionEventQueries` | [shared.SessionEventQuery](../../models/shared/sessioneventquery.md)[] | :heavy_minus_sign: | OK |
|
|
10
9
|
| `statusCode` | *number* | :heavy_check_mark: | HTTP response status code for this operation |
|
|
11
|
-
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
10
|
+
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
11
|
+
| `classes` | [shared.SessionEventQuery](../../models/shared/sessioneventquery.md)[] | :heavy_minus_sign: | OK |
|
|
@@ -8,4 +8,4 @@
|
|
|
8
8
|
| `contentType` | *string* | :heavy_check_mark: | HTTP response content type for this operation |
|
|
9
9
|
| `statusCode` | *number* | :heavy_check_mark: | HTTP response status code for this operation |
|
|
10
10
|
| `rawResponse` | [AxiosResponse](https://axios-http.com/docs/res_schema) | :heavy_minus_sign: | Raw HTTP response; suitable for custom response parsing |
|
|
11
|
-
| `
|
|
11
|
+
| `classes` | [shared.TaskResponse](../../models/shared/taskresponse.md)[] | :heavy_minus_sign: | OK |
|
|
@@ -10,7 +10,7 @@ The response object for a dataset
|
|
|
10
10
|
| `bytes` | *number* | :heavy_minus_sign: | The size of the dataset in bytes |
|
|
11
11
|
| `createdAt` | [Date](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date) | :heavy_minus_sign: | The timestamp of when the dataset was created |
|
|
12
12
|
| `description` | *string* | :heavy_minus_sign: | The description of the dataset |
|
|
13
|
-
| `file` | [
|
|
13
|
+
| `file` | Record<string, *any*>[] | :heavy_minus_sign: | The file in the dataset |
|
|
14
14
|
| `id` | *string* | :heavy_minus_sign: | The id of this dataset |
|
|
15
15
|
| `name` | *string* | :heavy_minus_sign: | The name of the dataset file |
|
|
16
16
|
| `prompt` | *string* | :heavy_minus_sign: | The prompt related to the dataset |
|