@knid/agentx 0.1.2 → 0.1.3
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/index.js +2 -19
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -314,19 +314,6 @@ function buildPromptWithPipe(prompt, pipedContent) {
|
|
|
314
314
|
${prompt}`;
|
|
315
315
|
}
|
|
316
316
|
|
|
317
|
-
// src/runtime/output-formatter.ts
|
|
318
|
-
function formatOutput(data, format) {
|
|
319
|
-
if (format === "json") {
|
|
320
|
-
try {
|
|
321
|
-
const parsed = JSON.parse(data);
|
|
322
|
-
return JSON.stringify(parsed, null, 2);
|
|
323
|
-
} catch {
|
|
324
|
-
return JSON.stringify({ output: data });
|
|
325
|
-
}
|
|
326
|
-
}
|
|
327
|
-
return data;
|
|
328
|
-
}
|
|
329
|
-
|
|
330
317
|
// src/telemetry/reporter.ts
|
|
331
318
|
function sendTelemetry(event) {
|
|
332
319
|
try {
|
|
@@ -502,18 +489,14 @@ async function runAgent(agentName, options) {
|
|
|
502
489
|
});
|
|
503
490
|
return "";
|
|
504
491
|
}
|
|
505
|
-
|
|
506
|
-
const output = formatOutput(result.stdout, options.outputFormat ?? "text");
|
|
507
|
-
if (!options.quiet) {
|
|
508
|
-
process.stdout.write(output);
|
|
509
|
-
}
|
|
492
|
+
await execa(claudePath, claudeArgs, { stdio: "inherit" });
|
|
510
493
|
sendTelemetry({
|
|
511
494
|
agent: agentFullName,
|
|
512
495
|
version: manifest.version,
|
|
513
496
|
success: true,
|
|
514
497
|
duration_ms: Date.now() - startTime
|
|
515
498
|
});
|
|
516
|
-
return
|
|
499
|
+
return "";
|
|
517
500
|
} catch (error) {
|
|
518
501
|
sendTelemetry({
|
|
519
502
|
agent: agentFullName,
|