mirror of
https://github.com/labring/FastGPT.git
synced 2025-08-01 03:48:24 +00:00
perf: btn color (#423)
This commit is contained in:
@@ -38,6 +38,7 @@ export async function generateQA(): Promise<any> {
|
||||
datasetCollectionId: 1,
|
||||
q: 1,
|
||||
model: 1,
|
||||
prompt: 1,
|
||||
billId: 1
|
||||
});
|
||||
|
||||
|
@@ -35,7 +35,6 @@ export type ChatResponse = {
|
||||
[TaskResponseKeyEnum.answerText]: string;
|
||||
[TaskResponseKeyEnum.responseData]: ChatHistoryItemResType;
|
||||
[TaskResponseKeyEnum.history]: ChatItemType[];
|
||||
finish: boolean;
|
||||
};
|
||||
|
||||
/* request openai chat */
|
||||
@@ -193,8 +192,7 @@ export const dispatchChatCompletion = async (props: ChatProps): Promise<ChatResp
|
||||
quoteList: filterQuoteQA,
|
||||
historyPreview: getHistoryPreview(completeMessages)
|
||||
},
|
||||
[TaskResponseKeyEnum.history]: completeMessages,
|
||||
finish: true
|
||||
[TaskResponseKeyEnum.history]: completeMessages
|
||||
};
|
||||
};
|
||||
|
||||
|
@@ -6,7 +6,6 @@ export type AnswerProps = ModuleDispatchProps<{
|
||||
text: string;
|
||||
}>;
|
||||
export type AnswerResponse = {
|
||||
finish: boolean;
|
||||
[TaskResponseKeyEnum.answerText]: string;
|
||||
};
|
||||
|
||||
@@ -31,7 +30,6 @@ export const dispatchAnswer = (props: Record<string, any>): AnswerResponse => {
|
||||
}
|
||||
|
||||
return {
|
||||
finish: true,
|
||||
[TaskResponseKeyEnum.answerText]: formatText
|
||||
};
|
||||
};
|
||||
|
@@ -8,7 +8,6 @@ export type HttpRequestProps = ModuleDispatchProps<{
|
||||
[key: string]: any;
|
||||
}>;
|
||||
export type HttpResponse = {
|
||||
[HttpPropsEnum.finish]: boolean;
|
||||
[HttpPropsEnum.failed]?: boolean;
|
||||
[TaskResponseKeyEnum.responseData]: ChatHistoryItemResType;
|
||||
[key: string]: any;
|
||||
@@ -33,7 +32,6 @@ export const dispatchHttpRequest = async (props: Record<string, any>): Promise<H
|
||||
});
|
||||
|
||||
return {
|
||||
[HttpPropsEnum.finish]: true,
|
||||
[TaskResponseKeyEnum.responseData]: {
|
||||
moduleType: FlowModuleTypeEnum.httpRequest,
|
||||
moduleName,
|
||||
@@ -45,7 +43,6 @@ export const dispatchHttpRequest = async (props: Record<string, any>): Promise<H
|
||||
};
|
||||
} catch (error) {
|
||||
return {
|
||||
[HttpPropsEnum.finish]: true,
|
||||
[HttpPropsEnum.failed]: true,
|
||||
[TaskResponseKeyEnum.responseData]: {
|
||||
moduleType: FlowModuleTypeEnum.httpRequest,
|
||||
|
@@ -13,7 +13,6 @@ type Props = ModuleDispatchProps<{
|
||||
app: SelectAppItemType;
|
||||
}>;
|
||||
type Response = {
|
||||
finish: boolean;
|
||||
[TaskResponseKeyEnum.responseData]: ChatHistoryItemResType[];
|
||||
[TaskResponseKeyEnum.answerText]: string;
|
||||
[TaskResponseKeyEnum.history]: ChatItemType[];
|
||||
@@ -77,7 +76,6 @@ export const dispatchAppRequest = async (props: Record<string, any>): Promise<Re
|
||||
]);
|
||||
|
||||
return {
|
||||
finish: true,
|
||||
responseData,
|
||||
[TaskResponseKeyEnum.answerText]: answerText,
|
||||
[TaskResponseKeyEnum.history]: completeMessages
|
||||
|
Reference in New Issue
Block a user