espace-codage / server /src /core /tools.ts
Abmacode12's picture
Architecture “Rosalinda” (100% propriétaire)
6ce9b06 verified
raw
history blame contribute delete
549 Bytes
```typescript
import { plugins } from "../plugins/index.js";
export async function runTools(input: { projectId: string; userText: string }) {
const t = input.userText.toLowerCase();
if (t.includes("crée un projet") || t.includes("creer un projet")) {
return plugins.projectCreate.run({ projectId: input.projectId, text: input.userText });
}
if (t.includes("résume le fichier") || t.includes("resume le fichier")) {
return plugins.fileSummarize.run({ projectId: input.projectId, text: input.userText });
}
return null;
}
```