summaryrefslogtreecommitdiff
path: root/src/actions/lang.ts
diff options
context:
space:
mode:
authorpolwex <polwex@sortug.com>2025-05-15 21:29:24 +0700
committerpolwex <polwex@sortug.com>2025-05-15 21:29:24 +0700
commit4f2bd597beaa778476b84c10b571db1b13524301 (patch)
treedaffaae0250d0b88b3a03d0de3821c680aeb337e /src/actions/lang.ts
parentfd86dc15734f3b7126d88f0130897c597100e30a (diff)
m
Diffstat (limited to 'src/actions/lang.ts')
-rw-r--r--src/actions/lang.ts15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/actions/lang.ts b/src/actions/lang.ts
index 5242c7a..fc798da 100644
--- a/src/actions/lang.ts
+++ b/src/actions/lang.ts
@@ -1,15 +1,16 @@
"use server";
import { AsyncRes } from "@/lib/types";
import { NLP } from "sortug-ai";
+import ServerWord from "@/zoom/ServerWord";
// import db from "../lib/db";
-// export async function textAction(
-// text: string,
-// lang: string,
-// ): AsyncRes<NLP.Spacy.SpacyRes> {
-// const res = await NLP.Spacy.run(text, lang);
-// return res;
-// }
+export async function wordAction(
+ text: string,
+ lang: string,
+): Promise<React.ReactNode> {
+ console.log("");
+ return ServerWord({ word: text, lang });
+}
// export async function ocrAction(file: File): AsyncRes<string[]> {
// const res = await NLP.ocr(file);