Skip to content

Commit

Permalink
fix: fix type problem
Browse files Browse the repository at this point in the history
  • Loading branch information
Fleurxxx committed Oct 20, 2024
1 parent 638a146 commit c0b8f00
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions app/service/app-center/aiChat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@
import { Service } from 'egg';
import Transformer from '@opentiny/tiny-engine-transform';
import { E_FOUNDATION_MODEL } from '../../lib/enum';
import { gzip } from 'compressing';
import FileStream = gzip.FileStream;

export type AiMessage = {
role: string; // 角色
Expand Down Expand Up @@ -177,14 +175,14 @@ export default class AiChat extends Service {
* @return
*/

async getFileContentFromAi(fileStream: FileStream, chatConfig: ConfigModel) {
async getFileContentFromAi(fileStream: any, chatConfig: ConfigModel) {
const answer = await this.requestFileContentFromAi(fileStream, chatConfig);
return this.ctx.helper.getResponseData({
originalResponse: answer
});
}

async requestFileContentFromAi(file: FileStream, chatConfig: ConfigModel) {
async requestFileContentFromAi(file: any, chatConfig: ConfigModel) {
const { ctx } = this;
let res: any = null;
try {
Expand Down

0 comments on commit c0b8f00

Please sign in to comment.