koishi-plugin-aka-ai-generator 0.3.3 → 0.3.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.js +8 -0
- package/package.json +1 -1
package/lib/index.js
CHANGED
|
@@ -1365,6 +1365,14 @@ function apply(ctx, config) {
|
|
|
1365
1365
|
if (extraText) {
|
|
1366
1366
|
finalPrompt += " " + extraText;
|
|
1367
1367
|
}
|
|
1368
|
+
finalPrompt = finalPrompt.trim();
|
|
1369
|
+
if (!finalPrompt) {
|
|
1370
|
+
const promptInput = await getPromptInput(session, "请发送画面描述");
|
|
1371
|
+
if (!promptInput) {
|
|
1372
|
+
return "未检测到描述,请重新发送";
|
|
1373
|
+
}
|
|
1374
|
+
finalPrompt = promptInput.trim();
|
|
1375
|
+
}
|
|
1368
1376
|
const providerType = requestContext?.provider || config.provider;
|
|
1369
1377
|
const providerModelId = requestContext?.modelId || (providerType === "yunwu" ? config.yunwuModelId : config.gptgodModelId);
|
|
1370
1378
|
logger.info("开始图像处理", {
|