@clazic/kordoc 2.2.5 → 2.2.6
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/dist/{chunk-LMJTT3ZJ.js → chunk-BU42ZFTN.js} +2 -2
- package/dist/{chunk-3PTQ3RGF.js → chunk-KHUTUB7G.js} +3 -3
- package/dist/cli.js +5 -5
- package/dist/index.cjs +15 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +15 -5
- package/dist/index.js.map +1 -1
- package/dist/mcp.js +2 -2
- package/dist/{resolve-BVSC3NC2.js → resolve-77C5OWLO.js} +15 -5
- package/dist/resolve-77C5OWLO.js.map +1 -0
- package/dist/{utils-ZZOKWPQK.js → utils-PGXOUDRW.js} +2 -2
- package/dist/{watch-NUH25Y6O.js → watch-VDBYOMEJ.js} +3 -3
- package/package.json +1 -1
- package/dist/resolve-BVSC3NC2.js.map +0 -1
- /package/dist/{chunk-LMJTT3ZJ.js.map → chunk-BU42ZFTN.js.map} +0 -0
- /package/dist/{chunk-3PTQ3RGF.js.map → chunk-KHUTUB7G.js.map} +0 -0
- /package/dist/{utils-ZZOKWPQK.js.map → utils-PGXOUDRW.js.map} +0 -0
- /package/dist/{watch-NUH25Y6O.js.map → watch-VDBYOMEJ.js.map} +0 -0
package/dist/index.js
CHANGED
|
@@ -2067,6 +2067,8 @@ function callCodexCli(imagePath) {
|
|
|
2067
2067
|
const outPath = join(tmpdir(), `kordoc-codex-out-${Date.now()}.txt`);
|
|
2068
2068
|
try {
|
|
2069
2069
|
const args = ["exec", OCR_PROMPT, "--image", imagePath, "--output-last-message", outPath];
|
|
2070
|
+
const model = process.env.KORDOC_CODEX_MODEL;
|
|
2071
|
+
if (model) args.push("--model", model);
|
|
2070
2072
|
const result = spawnSync("codex", args, {
|
|
2071
2073
|
encoding: "utf-8",
|
|
2072
2074
|
timeout: 18e4,
|
|
@@ -2098,10 +2100,18 @@ function buildCliArgs(mode, imagePath) {
|
|
|
2098
2100
|
|
|
2099
2101
|
\uC774\uBBF8\uC9C0: @${imagePath}`;
|
|
2100
2102
|
switch (mode) {
|
|
2101
|
-
case "gemini":
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
-
|
|
2103
|
+
case "gemini": {
|
|
2104
|
+
const args = ["--prompt", promptWithImage, "--yolo"];
|
|
2105
|
+
const model = process.env.KORDOC_GEMINI_MODEL;
|
|
2106
|
+
if (model) args.push("--model", model);
|
|
2107
|
+
return args;
|
|
2108
|
+
}
|
|
2109
|
+
case "claude": {
|
|
2110
|
+
const args = ["--print", promptWithImage];
|
|
2111
|
+
const model = process.env.KORDOC_CLAUDE_MODEL;
|
|
2112
|
+
if (model) args.push("--model", model);
|
|
2113
|
+
return args;
|
|
2114
|
+
}
|
|
2105
2115
|
default:
|
|
2106
2116
|
throw new Error(`\uC9C0\uC6D0\uD558\uC9C0 \uC54A\uB294 CLI: ${mode}`);
|
|
2107
2117
|
}
|
|
@@ -2436,7 +2446,7 @@ import JSZip2 from "jszip";
|
|
|
2436
2446
|
import { DOMParser } from "@xmldom/xmldom";
|
|
2437
2447
|
|
|
2438
2448
|
// src/utils.ts
|
|
2439
|
-
var VERSION = true ? "2.2.
|
|
2449
|
+
var VERSION = true ? "2.2.6" : "0.0.0-dev";
|
|
2440
2450
|
function toArrayBuffer(buf) {
|
|
2441
2451
|
if (buf.byteOffset === 0 && buf.byteLength === buf.buffer.byteLength) {
|
|
2442
2452
|
return buf.buffer;
|