@livx.cc/agentx 0.99.82 → 0.99.83

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/cli.js CHANGED
@@ -17663,7 +17663,7 @@ async function repl(args, ai, cfg, cwd) {
17663
17663
  let dx;
17664
17664
  let voiceIO;
17665
17665
  let voiceDiag;
17666
- const decider = duplex && process.env.TYPESAFE_AI_KEY ? new DecideClient({ apiKey: process.env.TYPESAFE_AI_KEY }) : void 0;
17666
+ const decider = duplex ? leakDecider() : void 0;
17667
17667
  const instinct = decider && process.env.VOICE_INSTINCT === "1" ? new Instinct({
17668
17668
  decider,
17669
17669
  context: () => ({ agentSaid: dx?.recentExcerpt(1).replace(/^\w+: /, ""), recent: dx?.recentExcerpt(4) }),
@@ -19925,6 +19925,7 @@ function duplexError(e, reflexModel) {
19925
19925
  const code = e?.statusCode;
19926
19926
  return code && !msg.includes(String(code)) ? `${msg} (${code})` : msg;
19927
19927
  }
19928
+ var leakDecider = () => process.env.TYPESAFE_AI_KEY ? new DecideClient({ apiKey: process.env.TYPESAFE_AI_KEY }) : void 0;
19928
19929
  async function duplexServe(args, ai, cfg, cwd) {
19929
19930
  const out = (o) => process.stdout.write(JSON.stringify(o) + "\n");
19930
19931
  const mounted = await mountMcp(cfg, new McpOAuth({ storePath: join15(cwd, ".agent", "mcp-auth.json") }));
@@ -19952,6 +19953,8 @@ async function duplexServe(args, ai, cfg, cwd) {
19952
19953
  `));
19953
19954
  const dx = new DuplexAgent({
19954
19955
  ai,
19956
+ decider: leakDecider(),
19957
+ // without it only the strict leak shapes are cut — "We need to provide…" was spoken (bare-browser #509)
19955
19958
  fs: agent.options.fs,
19956
19959
  memoryDir: agent.options.memoryDir,
19957
19960
  memoryUserDir: agent.options.memoryUserDir,