only_ever_generator 0.5.7 → 0.5.8

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.
@@ -20,14 +20,14 @@ class GenerateCards {
20
20
  var _a, _b, _c, _d, _e;
21
21
  let response = yield ((_a = this.openAiService) === null || _a === void 0 ? void 0 : _a.sendRequest(prompt, parsedContent));
22
22
  // console.log("response to card generation ", response);
23
- response["request_type"] = {
24
- type: "depth",
25
- n: isGapFill ? 1 : 2,
26
- bloom_level: 1,
27
- };
23
+ // response["request_type"] = ;
28
24
  response.metadata = {
29
25
  req_time: (_b = response.generated_at) !== null && _b !== void 0 ? _b : new Date(),
30
- req_type: response.request_type,
26
+ req_type: {
27
+ type: "depth",
28
+ n: isGapFill ? 1 : 2,
29
+ bloom_level: 1,
30
+ },
31
31
  req_tokens: (_c = response.usage_data) === null || _c === void 0 ? void 0 : _c.prompt_tokens,
32
32
  res_tokens: (_d = response.usage_data) === null || _d === void 0 ? void 0 : _d.completion_tokens,
33
33
  prompt_tokens_details: (_e = response.usage_data) === null || _e === void 0 ? void 0 : _e.prompt_tokens_details,
@@ -31,7 +31,10 @@ class GenerateTypology {
31
31
  };
32
32
  response.metadata = {
33
33
  req_time: (_b = response.generated_at) !== null && _b !== void 0 ? _b : new Date(),
34
- req_type: response.request_type,
34
+ req_type: {
35
+ type: "breadth",
36
+ n: 1,
37
+ },
35
38
  req_tokens: (_c = response.usage_data) === null || _c === void 0 ? void 0 : _c.prompt_tokens,
36
39
  res_tokens: (_d = response.usage_data) === null || _d === void 0 ? void 0 : _d.completion_tokens,
37
40
  prompt_tokens_details: (_e = response.usage_data) === null || _e === void 0 ? void 0 : _e.prompt_tokens_details,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "only_ever_generator",
3
- "version": "0.5.7",
3
+ "version": "0.5.8",
4
4
  "main": "dist/index.js",
5
5
  "scripts": {
6
6
  "start": "npm run build && nodemon dist/index.js",
@@ -108,8 +108,8 @@ export class OnlyEverGenerator {
108
108
  this.typologyResponse.concepts = gapFill.remainingConcepts;
109
109
  response = await this.generateCard(
110
110
  this.promptForCardGen +
111
- "Generate cards only suitable for the given remaining concepts and facts" +
112
- JSON.stringify(gapFill),
111
+ "Generate cards only suitable for the given remaining concepts and facts" +
112
+ JSON.stringify(gapFill),
113
113
 
114
114
  "",
115
115
  true
@@ -159,9 +159,9 @@ export class OnlyEverGenerator {
159
159
 
160
160
  response = await this.generateCard(
161
161
  this.promptForCardGen +
162
- "Generate cards only suitable for the given remaining concepts and facts" +
163
- JSON.stringify(factsMaps) +
164
- "Exclude generating cards with content in the following",
162
+ "Generate cards only suitable for the given remaining concepts and facts" +
163
+ JSON.stringify(factsMaps) +
164
+ "Exclude generating cards with content in the following",
165
165
  JSON.stringify(aiCards),
166
166
  true
167
167
  );
@@ -16,14 +16,14 @@ export class GenerateCards {
16
16
  ) {
17
17
  let response = await this.openAiService?.sendRequest(prompt, parsedContent);
18
18
  // console.log("response to card generation ", response);
19
- response["request_type"] = {
20
- type: "depth",
21
- n: isGapFill ? 1 : 2,
22
- bloom_level: 1,
23
- };
19
+ // response["request_type"] = ;
24
20
  response.metadata = {
25
21
  req_time: response.generated_at ?? new Date(),
26
- req_type: response.request_type,
22
+ req_type: {
23
+ type: "depth",
24
+ n: isGapFill ? 1 : 2,
25
+ bloom_level: 1,
26
+ },
27
27
  req_tokens: response.usage_data?.prompt_tokens,
28
28
  res_tokens: response.usage_data?.completion_tokens,
29
29
  prompt_tokens_details: response.usage_data?.prompt_tokens_details,
@@ -32,7 +32,10 @@ export class GenerateTypology {
32
32
  };
33
33
  response.metadata = {
34
34
  req_time: response.generated_at ?? new Date(),
35
- req_type: response.request_type,
35
+ req_type: {
36
+ type: "breadth",
37
+ n: 1,
38
+ },
36
39
  req_tokens: response.usage_data?.prompt_tokens,
37
40
  res_tokens: response.usage_data?.completion_tokens,
38
41
  prompt_tokens_details: response.usage_data?.prompt_tokens_details,