diff --git a/main.js b/main.js index fbcd1ba..cc1aa45 100644 --- a/main.js +++ b/main.js @@ -4419,9 +4419,11 @@ Additional instructions for the task (ignore anything unrelated to the origi stream }, { timeout: 6e4 }); if (!stream) { + response = response; response = (_d = (_c = (_b = (_a2 = response == null ? void 0 : response.choices[0]) == null ? void 0 : _a2.message) == null ? void 0 : _b.content) == null ? void 0 : _c.trim()) != null ? _d : null; yield response || ""; } else { + response = response; for await (const chunk of response) { yield ((_f = (_e = chunk.choices[0]) == null ? void 0 : _e.delta) == null ? void 0 : _f.content) || ""; } @@ -4600,4 +4602,3 @@ var FlashcardsSettingsTab = class extends import_obsidian.PluginSettingTab { ); } }; -//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsic3JjL21haW4udHMiLCAic3JjL21vZGVscy50cyIsICJub2RlX21vZHVsZXMvb3BlbmFpL3NyYy92ZXJzaW9uLnRzIiwgIm5vZGVfbW9kdWxlcy9vcGVuYWkvc3JjL19zaGltcy9yZWdpc3RyeS50cyIsICJub2RlX21vZHVsZXMvb3BlbmFpL3NyYy9fc2hpbXMvTXVsdGlwYXJ0Qm9keS50cyIsICJub2RlX21vZHVsZXMvb3BlbmFpL3NyYy9fc2hpbXMvd2ViLXJ1bnRpbWUudHMiLCAibm9kZV9tb2R1bGVzL29wZW5haS9fc2hpbXMvaW5kZXgubWpzIiwgIm5vZGVfbW9kdWxlcy9vcGVuYWkvc3JjL2Vycm9yLnRzIiwgIm5vZGVfbW9kdWxlcy9vcGVuYWkvc3JjL3N0cmVhbWluZy50cyIsICJub2RlX21vZHVsZXMvb3BlbmFpL3NyYy91cGxvYWRzLnRzIiwgIm5vZGVfbW9kdWxlcy9vcGVuYWkvc3JjL2NvcmUudHMiLCAibm9kZV9tb2R1bGVzL29wZW5haS9zcmMvcGFnaW5hdGlvbi50cyIsICJub2RlX21vZHVsZXMvb3BlbmFpL3NyYy9yZXNvdXJjZS50cyIsICJub2RlX21vZHVsZ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HN0cmVhbS4nKTtcbiAgICAgIH1cbiAgICAgIGNvbnN1bWVkID0gdHJ1ZTtcbiAgICAgIGxldCBkb25lID0gZmFsc2U7XG4gICAgICB0cnkge1xuICAgICAgICBmb3IgYXdhaXQgKGNvbnN0IHNzZSBvZiBfaXRlclNTRU1lc3NhZ2VzKHJlc3BvbnNlLCBjb250cm9sbGVyKSkge1xuICAgICAgICAgIGlmIChkb25lKSBjb250aW51ZTtcblxuICAgICAgICAgIGlmIChzc2UuZGF0YS5zdGFydHNXaXRoKCdbRE9ORV0nKSkge1xuICAgICAgICAgICAgZG9uZSA9IHRydWU7XG4gICAgICAgICAgICBjb250aW51ZTtcbiAgICAgICAgICB9XG5cbiAgICAgICAgICBpZiAoc3NlLmV2ZW50ID09PSBudWxsKSB7XG4gICAgICAgICAgICBsZXQgZGF0YTtcblxuICAgICAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgICAgZGF0YSA9IEpTT04ucGFyc2Uoc3NlLmRhdGEpO1xuICAgICAgICAgICAgfSBjYXRjaCAoZSkge1xuICAgICAgICAgICAgICBjb25zb2xlLmVycm9yKGBDb3VsZCBub3QgcGFyc2UgbWVzc2FnZSBpbnRvIEpTT046YCwgc3NlLmRhdGEpO1xuICAgICAgICAgICAgICBjb25zb2xlLmVycm9yKGBGcm9tIGNodW5rOmAsIHNzZS5yYXcpO1xuICAgICAgICAgICAgICB0aHJvdyBlO1xuICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICBpZiAoZGF0YSAmJiBkYXRhLmVycm9yKSB7XG4gICAgICAgICAgICAgIHRocm93IG5ldyBBUElFcnJvcih1bmRlZmluZWQsIGRhdGEuZXJyb3IsIHVuZGVmaW5lZCwgdW5kZWZpbmVkKTtcbiAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgeWllbGQgZGF0YTtcbiAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgbGV0IGRhdGE7XG4gICAgICAgICAgICB0cnkge1xuICAgICAgICAgICAgICBk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LCBpbmRleCwgbWVzc2FnZToge30sIGxvZ3Byb2JzLCAuLi5vdGhlciB9O1xuICAgICAgfVxuXG4gICAgICBpZiAobG9ncHJvYnMpIHtcbiAgICAgICAgaWYgKCFjaG9pY2UubG9ncHJvYnMpIHtcbiAgICAgICAgICBjaG9pY2UubG9ncHJvYnMgPSBPYmplY3QuYXNzaWduKHt9LCBsb2dwcm9icyk7XG4gICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgY29uc3QgeyBjb250ZW50LCAuLi5yZXN0IH0gPSBsb2dwcm9icztcbiAgICAgICAgICBPYmplY3QuYXNzaWduKGNob2ljZS5sb2dwcm9icywgcmVzdCk7XG4gICAgICAgICAgaWYgKGNvbnRlbnQpIHtcbiAgICAgICAgICAgIGNob2ljZS5sb2dwcm9icy5jb250ZW50ID8/PSBbXTtcbiAgICAgICAgICAgIGNob2ljZS5sb2dwcm9icy5jb250ZW50LnB1c2goLi4uY29udGVudCk7XG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICB9XG5cbiAgICAgIGlmIChmaW5pc2hfcmVhc29uKSBjaG9pY2UuZmluaXNoX3JlYXNvbiA9IGZpbmlzaF9yZWFzb247XG4gICAgICBPYmplY3QuYXNzaWduKGNob2ljZSwgb3RoZXIpO1xuXG4gICAgICBpZiAoIWRlbHRhKSBjb250aW51ZTsgLy8gU2hvdWxkbid0IGhhcHBlbjsganVzdCBpbiBjYXNlLlxuICAgICAgY29uc3QgeyBjb250ZW50LCBmdW5jdGlvbl9jYWxsLCByb2xlLCB0b29sX2NhbGxzLCAuLi5yZXN0IH0gPSBkZWx0YTtcbiAgICAgIE9iamVjdC5hc3NpZ24oY2hvaWNlLm1lc3NhZ2UsIHJlc3QpO1xuXG4gICAgICBpZiAoY29udGVudCkgY2hvaWNlLm1lc3NhZ2UuY29udGVudCA9IChjaG9pY2UubWVzc2FnZS5jb250ZW50IHx8ICcnKSArIGNvbnRlbnQ7XG4gICAgICBpZiAocm9sZSkgY2hvaWNlLm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md1bWVudHM6IGFyZ3MsIG5hbWUgfSwgcm9sZSB9LFxuICAgICAgICAgICAgZmluaXNoX3JlYXNvbixcbiAgICAgICAgICAgIGluZGV4LFxuICAgICAgICAgICAgbG9ncHJvYnMsXG4gICAgICAgICAgfTtcbiAgICAgICAgfVxuICAgICAgICBpZiAodG9vbF9jYWxscykge1xuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICAuLi5jaG9pY2VSZXN0LFxuICAgICAgICAgICAgaW5kZXgsXG4gICAgICAgICAgICBmaW5pc2hfcmVhc29uLFxuICAgICAgICAgICAgbG9ncHJvYnMsXG4gICAgICAgICAgICBtZXNzYWdlOiB7XG4gICAgICAgICAgICAgIC4uLm1lc3NhZ2VSZXN0LFxuICAgICAgICAgICAgICByb2xlLFxuICAgICAgICAgICAgICBjb250ZW50LFxuICAgICAgICAgICAgICB0b29sX2NhbGxzOiB0b29sX2NhbGxzLm1hcCgodG9vbF9jYWxsLCBpKSA9PiB7XG4gICAgICAgICAgICAgICAgY29uc3QgeyBmdW5jdGlvbjogZm4sIHR5cGUsIGlkLCAuLi50b29sUmVzdCB9ID0gdG9vbF9jYWxsO1xuICAgICAgICAgICAgICAgIGNvbnN0IHsgYXJndW1lbnRzOiBhcmdzLCBuYW1lLCAuLi5mblJlc3QgfSA9IGZuIHx8IHt9O1xuICAgICAgICAgICAgICAgIGlmIChpZCA9PSBudWxsKVxuICAgICAgICAgICAgICAgICAgdGhyb3cgbmV3IE9wZW5BSUVycm9yKGBtaXNzaW5nIGNob2ljZXNbJHtpbmRleH1dLnRvb2xfY2FsbHNbJHtpfV0uaWRcXG4ke3N0cihzbmFwc2hvdCl9YCk7XG4gICAgICAgICAgICAgICAgaWYgKHR5cGUgPT0gbnVsbClcbiAgICAgICAgICAgICAgICAgIHRocm93IG5ldyBPcGVuQUlFcnJvcihgbWlzc2luZyBjaG9pY2VzWyR7aW5kZXh9XS50b29sX2NhbGxzWyR7aX1dLnR5cGVcXG4ke3N0cihzbmFwc2hvdCl9YCk7XG4gICAgICAgICAgICAgICAgaWYgKG5hbWUgPT0gbnVsbClcbiAgICAgICAgICAgICAgICAgIHRocm93IG5ldyBPcGVuQUlFcnJvcihcbiAgICAgICAgICAgICAgICAgICAgYG1pc3NpbmcgY2hvaWNlc1ske2luZGV4fV0udG9vbF9jYWxsc1ske2l9XS5mdW5jdGlvbi5uYW1lXFxuJHtzdHIoc25hcHNob3QpfWAsXG4gICAgICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgICAgIGlmIChhcmdzID09IG51bGwpXG4gICAgICAgICAgICAgICAgICB0aHJvdyBuZXcgT3BlbkFJRXJyb3IoXG4gICAgICAgICAgICAgICAgICAgIGBtaXNzaW5nIGNob2ljZXNbJHtpbmRleH1dLnRvb2xfY2FsbHNbJHtpfV0uZnVuY3Rpb24uYXJndW1lbnRzXFxuJHtzdHIoc25hcHNob3QpfWAsXG4gICAgICAgICAgICAgICAgICApO1xuXG4gICAgICAgICAgICAgICAgcmV0dXJuIHsgLi4udG9vbFJlc3QsIGlkLCB0eXBlLCBmdW5jdGlvbjogeyAuLi5mblJlc3QsIG5hbWUsIGFyZ3VtZW50czogYXJncyB9IH07XG4gICAgICAgICAgICAgIH0pLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICB9O1xuICAgICAgICB9XG4gICAgICAgIHJldHVybiB7XG4gICAgICAgICAgLi4uY2hvaWNlUmVzdCxcbiAgICAgICAgICBtZXNzYWdlOiB7IC4uLm1lc3NhZ2VSZXN0LCBjb250ZW50LCByb2xlIH0sXG4gICAgICAgICAgZmluaXNoX3JlYXNvbixcbiAgICAgICAgICBpbmRleCxcbiAgICAgICAgICBsb2dwcm9icyxcbiAgICAgICAgfTtcbiAgICAgIH0sXG4gICAgKSxcbiAgICBjcmVhdGVkLFxuICAgIG1vZGVsLFxuICAgIG9iamVjdDogJ2NoYXQuY29tcGxldGlvbicsXG4gICAgLi4uKHN5c3RlbV9maW5nZXJwcmludCA/IHsgc3lzdGVtX2Z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bWl0KCdtZXNzYWdlRGVsdGEnLCBldmVudC5kYXRhLmRlbHRhLCBhY2N1bXVsYXRlZE1lc3NhZ2UpO1xuXG4gICAgICAgIGlmIChldmVudC5kYXRhLmRlbHRhLmNvbnRlbnQpIHtcbiAgICAgICAgICBmb3IgKGNvbnN0IGNvbnRlbnQgb2YgZXZlbnQuZGF0YS5kZWx0YS5jb250ZW50KSB7XG4gICAgICAgICAgICAvL0lmIGl0IGlzIHRleHQgZGVsdGEsIGVtaXQgYSB0ZXh0IGRlbHRhIGV2ZW50XG4gICAgICAgICAgICBpZiAoY29udGVudC50eXBlID09ICd0ZXh0JyAmJiBjb250ZW50LnRleHQpIHtcbiAgICAgICAgICAgICAgbGV0IHRleHREZWx0YSA9IGNvbnRlbnQudGV4dDtcbiAgICAgICAgICAgICAgbGV0IHNuYXBzaG90ID0gYWNjdW11bGF0ZWRNZXNzYWdlLmNvbnRlbnRbY29udGVudC5pbmRleF07XG4gICAgICAgICAgICAgIGlmIChzbmFwc2hvdCAmJiBzbmFwc2hvdC50eXBlID09ICd0ZXh0Jykge1xuICAgICAgICAgICAgICAgIHRoaXMuX2VtaXQoJ3RleHREZWx0YScsIHRleHREZWx0YSwgc25hcHNob3QudGV4dCk7XG4gICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgdGhyb3cgRXJyb3IoJ1RoZSBzbmFwc2hvdCBhc3NvY2lhdGVkIHdpdGggdGhpcyB0ZXh0IGRlbHRhIGlzIG5vdCB0ZXh0IG9yIG1pc3NpbmcnKTtcbiAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICBpZiAoY29udGVudC5pbmRleCAhPSB0aGlzLiNjdXJyZW50Q29udGVudEluZGV4KSB7XG4gICAgICAgICAgICAgIC8vU2VlIGlmIHdlIGhhdmUgaW4gcHJvZ3Jlc3MgY29udGVudFxuICAgICAgICAgICAgICBpZiAodGhpcy4jY3VycmVudENvbnRlbnQpIHtcbiAgICAgICAgICAgICAgICBzd2l0Y2ggKHRoaXMuI2N1cnJlbnRDb250ZW50LnR5cGUpIHtcbiAgICAgICAgICAgICAgICAgIGNhc2UgJ3RleHQnOlxuICAgICAgICAgICAgICAgICAgICB0aGlzLl9lbWl0KCd0ZXh0RG9uZScsIHRoaXMuI2N1cnJlbnRDb250ZW50LnRleHQsIHRoaXMuI21lc3NhZ2VTbmFwc2hvdCk7XG4gICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgICAgY2FzZSAnaW1hZ2VfZmlsZSc6XG4gICAgICAgICAgICAgICAgICAgIHRoaXMuX2VtaXQoJ2ltYWdlRmlsZURvbmUnLCB0aGlzLiNjdXJyZW50Q29udGVudC5pbWFnZV9maWxlLCB0aGlzLiNtZXNzYWdlU25hcHNob3QpO1xuICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICB0aGlzLiNjdXJyZW50Q29udGVudEluZGV4ID0gY29udGVudC5pbmRleDtcbiAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgdGhpcy4jY3VycmVudENvbnRlbnQgPSBhY2N1bXVsYXRlZE1lc3NhZ2UuY29udGVudFtjb250ZW50LmluZGV4XTtcbiAgICAgICAgICB9XG4gICAgICAgIH1cblxuICAgICAgICBicmVhaztcblxuICAgICAgY2FzZSAndGhyZWFkLm1lc3NhZ2UuY29tcGxldGVkJzpcbiAgICAgIGNhc2UgJ3RocmVhZC5tZXNzYWdlLmluY29tcGxldGUnOlxuICAgICAgICAvL1dlIGVtaXQgdGhlIGxhdGVzdCBjb250ZW50IHdlIHdlcmUgd29ya2luZyBvbiBvbiBjb21wbGV0aW9uIChpbmNsdWRpbmcgaW5jb21wbGV0ZSlcbiAgICAgICAgaWYgKHRoaXMuI2N1cnJlbnRDb250ZW50SW5kZXggIT09IHVuZGVmaW5lZCkge1xuICAgICAgICAgIGNvbnN0IGN1cnJl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ZW50RWxlbWVudC5pbmRleF07XG4gICAgICAgICAgICAgIHNuYXBzaG90LmNvbnRlbnRbY29udGVudEVsZW1lbnQuaW5kZXhdID0gdGhpcy4jYWNjdW11bGF0ZUNvbnRlbnQoXG4gICAgICAgICAgICAgICAgY29udGVudEVsZW1lbnQsXG4gICAgICAgICAgICAgICAgY3VycmVudENvbnRlbnQsXG4gICAgICAgICAgICAgICk7XG4gICAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgICBzbmFwc2hvdC5jb250ZW50W2NvbnRlbnRFbGVtZW50LmluZGV4XSA9IGNvbnRlbnRFbGVtZW50IGFzIE1lc3NhZ2VDb250ZW50O1xuICAgICAgICAgICAgICAvLyBUaGlzIGlzIGEgbmV3IGVsZW1lbnRcbiAgICAgICAgICAgICAgbmV3Q29udGVudC5wdXNoKGNvbnRlbnRFbGVtZW50KTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICB9XG4gICAgICAgIH1cblxuICAgICAgICByZXR1cm4gW3NuYXBzaG90LCBuZXdDb250ZW50XTtcblxuICAgICAgY2FzZSAndGhyZWFkLm1lc3NhZ2UuaW5fcHJvZ3Jlc3MnOlxuICAgICAgY2FzZSAndGhyZWFkLm1lc3NhZ2UuY29tcGxldGVkJzpcbiAgICAgIGNhc2UgJ3RocmVhZC5tZXNzYWdlLmluY29tcGxldGUnOlxuICAgICAgICAvL05vIGNoYW5nZXMgb24gb3RoZXIgdGhyZWFkIGV2ZW50c1xuICAgICAgICBpZiAoc25hcHNob3QpIHtcbiAgICAgICAgICByZXR1cm4gW3NuYXBzaG90LCBuZXdDb250ZW50XTtcbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICB0aHJvdyBFcnJvcignUmVjZWl2ZWQgdGhyZWFkIG1lc3NhZ2UgZXZlbnQgd2l0aCBubyBleGlzdGluZyBzbmFwc2hvdCcpO1xuICAgICAgICB9XG4gICAgfVxuICAgIHRocm93IEVycm9yKCdUcmllZCB0byBhY2N1bXVsYXRlI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AncXVldWVkJzpcbiAgICAgICAgY2FzZSAnaW5fcHJvZ3Jlc3MnOlxuICAgICAgICBjYXNlICdjYW5jZWxsaW5nJzpcbiAgICAgICAgICBsZXQgc2xlZXBJbnRlcnZhbCA9IDUwMDA7XG5cbiAgICAgICAgICBpZiAob3B0aW9ucz8ucG9sbEludGVydmFsTXMpIHtcbiAgICAgICAgICAgIHNsZWVwSW50ZXJ2YWwgPSBvcHRpb25zLnBvbGxJbnRlcnZhbE1zO1xuICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICBjb25zdCBoZWFkZXJJbnRlcnZhbCA9IHJlc3BvbnNlLmhlYWRlcnMuZ2V0KCdvcGVuYWktcG9sbC1hZnRlci1tcycpO1xuICAgICAgICAgICAgaWYgKGhlYWRlckludGVydmFsKSB7XG4gICAgICAgICAgICAgIGNvbnN0IGhlYWRlckludGVydmFsTXMgPSBwYXJzZUludChoZWFkZXJJbnRlcnZhbCk7XG4gICAgICAgICAgICAgIGlmICghaXNOYU4oaGVhZGVySW50ZXJ2YWxNcykpIHtcbiAgICAgICAgICAgICAgICBzbGVlcEludGVydmFsID0gaGVhZGVySW50ZXJ2YWxNcztcbiAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfVxuICAgICAgICAgIH1cbiAgICAgICAgICBhd2FpdCBzbGVlcChzbGVlcEludGVydmFsKTtcbiAgICAgICAgICBicmVhaztcbiAgICAgICAgLy9XZSByZXR1cm4gdGhlIHJ1biBpbiBhbnkgdGVybWluYWwgc3RhdGUuXG4gICAgICAgIGNhc2UgJ3JlcXVpcmVzX2FjdGlvbic6XG4gICAgICAgIGNhc2UgJ2luY29tcGxldGUnOlxuICAgICAgICBjYXNlICdjYW5jZWxsZWQnOlxuICAgICAgICBjYXNlICdjb21wbGV0ZWQnOlxuICAgICAgICBjYXNlICdmYWlsZWQnOlxuICAgICAgICBjYXNlICdleHBpcmVkJzpcbiAgICAgICAgICByZXR1cm4gcnVuO1xuICAgICAgfVxuICAgIH1cb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iwgIkZpbmVUdW5pbmciLCAiSW1hZ2VzIiwgIk1vZGVscyIsICJNb2RlcmF0aW9ucyIsICJfYSIsICJDb21wbGV0aW9ucyIsICJGaWxlcyIsICJPcGVuQUlFcnJvciIsICJBUElFcnJvciIsICJBUElDb25uZWN0aW9uRXJyb3IiLCAiQVBJQ29ubmVjdGlvblRpbWVvdXRFcnJvciIsICJBUElVc2VyQWJvcnRFcnJvciIsICJOb3RGb3VuZEVycm9yIiwgIkNvbmZsaWN0RXJyb3IiLCAiUmF0ZUxpbWl0RXJyb3IiLCAiQmFkUmVxdWVzdEVycm9yIiwgIkF1dGhlbnRpY2F0aW9uRXJyb3IiLCAiSW50ZXJuYWxTZXJ2ZXJFcnJvciIsICJQZXJtaXNzaW9uRGVuaWVkRXJyb3IiLCAiVW5wcm9jZXNzYWJsZUVudGl0eUVycm9yIiwgIk9wZW5BSSIsICJDb21wbGV0aW9ucyIsICJGaWxlcyIsICJPcGVuQUlFcnJvciIsICJfYSIsICJPcGVuQUlFcnJvciIsICJvbiJdCn0K diff --git a/manifest.json b/manifest.json index 8daba99..71b8914 100644 --- a/manifest.json +++ b/manifest.json @@ -1,7 +1,7 @@ { "id": "flashcards-llm", "name": "Flashcards LLM", - "version": "0.0.8", + "version": "0.0.9", "minAppVersion": "0.15.0", "description": "Use Large Language Models (such as ChatGPT) to automatically generate flashcards from obsidian notes", "author": "Marco Pampaloni", diff --git a/src/flashcards.ts b/src/flashcards.ts index 70177df..d6a6328 100644 --- a/src/flashcards.ts +++ b/src/flashcards.ts @@ -1,5 +1,7 @@ import { availableChatModels, availableCompletionModels } from "./models"; import { OpenAI } from 'openai'; +import { Readable } from "stream"; + // TODO: @@ -35,6 +37,7 @@ function multilineCardsPrompt(sep: string, flashcardsCount: number): string { return `You will be provided with a note. At the end of the note are some flashcards. Identify which are the most important concepts within the note and generate exactly ${flashcardsCount} new original flashcard in the format \"question${sep}answer\", where is a newline. The question cannot start with special symbols or numbers. Do not add trailing spaces. Separate invidivual flashcards with a single empty line. An example is \"What is chemical formula of water\\n${sep}\\nH2O\". Do not use any prefix text, start generating right away. The flashcards can be as complex as needed, but have to be rich of information and challenging. Do not repeat or rephrase flashcards. Typeset equations and math formulas correctly (that is using the \$ symbol without trailing spaces)`; } + export async function* generateFlashcards( text: string, apiKey: string, @@ -80,10 +83,12 @@ export async function* generateFlashcards( }, { timeout: 60000 }); if (!stream) { + response = response as OpenAI.ChatCompletion response = response?.choices[0]?.message?.content?.trim() ?? null; yield response || ''; } else { + response = response as AsyncIterable for await (const chunk of response) { yield chunk.choices[0]?.delta?.content || ''; }