chore: Update eslint and prettier configurations
This commit is contained in:
parent
c63c9b5c8a
commit
5b1aaee605
24 changed files with 826 additions and 38 deletions
|
|
@ -66,7 +66,7 @@ const basicAcademicSearchResponsePrompt = `
|
|||
const strParser = new StringOutputParser();
|
||||
|
||||
const handleStream = async (
|
||||
stream: AsyncGenerator<StreamEvent, any, unknown>,
|
||||
stream: AsyncGenerator<StreamEvent, unknown, unknown>,
|
||||
emitter: eventEmitter,
|
||||
) => {
|
||||
for await (const event of stream) {
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ const basicRedditSearchResponsePrompt = `
|
|||
const strParser = new StringOutputParser();
|
||||
|
||||
const handleStream = async (
|
||||
stream: AsyncGenerator<StreamEvent, any, unknown>,
|
||||
stream: AsyncGenerator<StreamEvent, unknown, unknown>,
|
||||
emitter: eventEmitter,
|
||||
) => {
|
||||
for await (const event of stream) {
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ const basicWebSearchResponsePrompt = `
|
|||
const strParser = new StringOutputParser();
|
||||
|
||||
const handleStream = async (
|
||||
stream: AsyncGenerator<StreamEvent, any, unknown>,
|
||||
stream: AsyncGenerator<StreamEvent, unknown, unknown>,
|
||||
emitter: eventEmitter,
|
||||
) => {
|
||||
for await (const event of stream) {
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@ const basicWolframAlphaSearchResponsePrompt = `
|
|||
const strParser = new StringOutputParser();
|
||||
|
||||
const handleStream = async (
|
||||
stream: AsyncGenerator<StreamEvent, any, unknown>,
|
||||
stream: AsyncGenerator<StreamEvent, unknown, unknown>,
|
||||
emitter: eventEmitter,
|
||||
) => {
|
||||
for await (const event of stream) {
|
||||
|
|
@ -153,7 +153,7 @@ const createBasicWolframAlphaSearchAnsweringChain = (llm: BaseChatModel) => {
|
|||
chat_history: formatChatHistoryAsString(input.chat_history),
|
||||
}),
|
||||
basicWolframAlphaSearchRetrieverChain
|
||||
.pipe(({ query, docs }) => {
|
||||
.pipe(({ docs }) => {
|
||||
return docs;
|
||||
})
|
||||
.withConfig({
|
||||
|
|
@ -210,7 +210,8 @@ const handleWolframAlphaSearch = (
|
|||
message: string,
|
||||
history: BaseMessage[],
|
||||
llm: BaseChatModel,
|
||||
embeddings: Embeddings,
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
_embeddings: Embeddings,
|
||||
) => {
|
||||
const emitter = basicWolframAlphaSearch(message, history, llm);
|
||||
return emitter;
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ Since you are a writing assistant, you would not perform web searches. If you th
|
|||
const strParser = new StringOutputParser();
|
||||
|
||||
const handleStream = async (
|
||||
stream: AsyncGenerator<StreamEvent, any, unknown>,
|
||||
stream: AsyncGenerator<StreamEvent, unknown, unknown>,
|
||||
emitter: eventEmitter,
|
||||
) => {
|
||||
for await (const event of stream) {
|
||||
|
|
@ -59,7 +59,8 @@ const handleWritingAssistant = (
|
|||
query: string,
|
||||
history: BaseMessage[],
|
||||
llm: BaseChatModel,
|
||||
embeddings: Embeddings,
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
||||
_embeddings: Embeddings,
|
||||
) => {
|
||||
const emitter = new eventEmitter();
|
||||
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ const basicYoutubeSearchResponsePrompt = `
|
|||
const strParser = new StringOutputParser();
|
||||
|
||||
const handleStream = async (
|
||||
stream: AsyncGenerator<StreamEvent, any, unknown>,
|
||||
stream: AsyncGenerator<StreamEvent, unknown, unknown>,
|
||||
emitter: eventEmitter,
|
||||
) => {
|
||||
for await (const event of stream) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue