feat(平台): 补齐服务端持久化和AI拆解契约
This commit is contained in:
14
apps/server/src/modules/ai/ai.controller.ts
Normal file
14
apps/server/src/modules/ai/ai.controller.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
import { Body, Controller, Post } from '@nestjs/common';
|
||||
import { AiService } from './ai.service';
|
||||
import { DecomposeDto } from './dto/decompose.dto';
|
||||
import type { AgentDecomposeResponse, AgentDecomposeError } from '@ftb/shared';
|
||||
|
||||
@Controller('ai')
|
||||
export class AiController {
|
||||
constructor(private readonly aiService: AiService) {}
|
||||
|
||||
@Post('decompose')
|
||||
async decompose(@Body() dto: DecomposeDto): Promise<AgentDecomposeResponse | AgentDecomposeError> {
|
||||
return this.aiService.decompose(dto);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user