@integrity-labs/agt-cli 0.28.333 → 0.28.334

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/bin/agt.js CHANGED
@@ -38,7 +38,7 @@ import {
38
38
  success,
39
39
  table,
40
40
  warn
41
- } from "../chunk-RQOJLHYA.js";
41
+ } from "../chunk-ZBLSH3CX.js";
42
42
  import {
43
43
  AnchorSessionClient,
44
44
  CHANNEL_REGISTRY,
@@ -4827,7 +4827,7 @@ import { execFileSync, execSync } from "child_process";
4827
4827
  import { existsSync as existsSync10, realpathSync as realpathSync2 } from "fs";
4828
4828
  import chalk18 from "chalk";
4829
4829
  import ora16 from "ora";
4830
- var cliVersion = true ? "0.28.333" : "dev";
4830
+ var cliVersion = true ? "0.28.334" : "dev";
4831
4831
  async function fetchLatestVersion() {
4832
4832
  const host2 = getHost();
4833
4833
  if (!host2) return null;
@@ -5931,7 +5931,7 @@ function handleError(err) {
5931
5931
  }
5932
5932
 
5933
5933
  // src/bin/agt.ts
5934
- var cliVersion2 = true ? "0.28.333" : "dev";
5934
+ var cliVersion2 = true ? "0.28.334" : "dev";
5935
5935
  var program = new Command();
5936
5936
  program.name("agt").description("Augmented CLI \u2014 agent provisioning and management").version(cliVersion2).option("--json", "Emit machine-readable JSON output (suppress spinners and colors)").option("--skip-update-check", "Skip the automatic update check on startup");
5937
5937
  program.hook("preAction", async (thisCommand, actionCommand) => {
@@ -971,7 +971,16 @@ function formatEmailDomainConfigLines(config) {
971
971
  } else if (mode === "internal_only") {
972
972
  lines.push(` - only your organization's own email domain is permitted`);
973
973
  }
974
- lines.push(` *Advisory: honor this restriction \u2014 it is guidance in your instructions, not a hard block at send time.*`);
974
+ const stage = typeof config.stage === "string" ? config.stage : void 0;
975
+ const enforceLive = config.enforce_live === true;
976
+ if (stage) {
977
+ lines.push(` - stage: ${stage}`);
978
+ if (!(stage === "enforce" && enforceLive)) {
979
+ lines.push(` *Currently observe-only: the API records domain decisions to guardrail_audit_log but does not block sends at this stage. Honor the restriction as authoritative guidance; the runtime flip is operator-side.*`);
980
+ }
981
+ } else {
982
+ lines.push(` *Advisory: honor this restriction \u2014 it is guidance in your instructions, not a hard block at send time.*`);
983
+ }
975
984
  return lines;
976
985
  }
977
986
  var CALENDAR_CONFIDENTIALITY_DEF = "calendar.confidentiality";
@@ -1018,10 +1027,31 @@ function effectiveCalendarEnforcement(g) {
1018
1027
  return "warn";
1019
1028
  return g.enforcement;
1020
1029
  }
1030
+ function effectiveEmailEnforcement(g) {
1031
+ if (g.definitionId !== EMAIL_DOMAIN_RESTRICT_DEF)
1032
+ return g.enforcement;
1033
+ if (g.enforcement === "disabled")
1034
+ return g.enforcement;
1035
+ const stage = typeof g.config?.["stage"] === "string" ? g.config["stage"] : void 0;
1036
+ if (stage === void 0)
1037
+ return g.enforcement;
1038
+ const enforceLive = g.config?.["enforce_live"] === true;
1039
+ if (stage === "enforce" && enforceLive)
1040
+ return g.enforcement;
1041
+ if (stage === "warn")
1042
+ return g.enforcement === "enforce" ? "warn" : g.enforcement;
1043
+ return "log";
1044
+ }
1021
1045
  function buildGuardrailsSection(guardrails) {
1022
1046
  if (!guardrails || guardrails.length === 0)
1023
1047
  return "";
1024
- const active = guardrails.map((g) => ({ ...g, enforcement: effectiveCalendarEnforcement(g) })).filter((g) => g.enforcement !== "disabled" || !!(g.overrideApplied && g.overrideReason?.trim()));
1048
+ const active = guardrails.map((g) => {
1049
+ const enforcement = effectiveEmailEnforcement({
1050
+ ...g,
1051
+ enforcement: effectiveCalendarEnforcement(g)
1052
+ });
1053
+ return { ...g, enforcement };
1054
+ }).filter((g) => g.enforcement !== "disabled" || !!(g.overrideApplied && g.overrideReason?.trim()));
1025
1055
  if (active.length === 0)
1026
1056
  return "";
1027
1057
  const isOverridden = (g) => !!(g.overrideApplied && g.overrideReason?.trim());
@@ -6956,7 +6986,7 @@ function requireHost() {
6956
6986
  }
6957
6987
 
6958
6988
  // src/lib/api-client.ts
6959
- var agtCliVersion = true ? "0.28.333" : "dev";
6989
+ var agtCliVersion = true ? "0.28.334" : "dev";
6960
6990
  var lastConfigHash = null;
6961
6991
  function setConfigHash(hash) {
6962
6992
  lastConfigHash = hash && hash.length > 0 ? hash : null;
@@ -9353,4 +9383,4 @@ export {
9353
9383
  managerInstallSystemUnitCommand,
9354
9384
  managerUninstallSystemUnitCommand
9355
9385
  };
9356
- //# sourceMappingURL=chunk-RQOJLHYA.js.map
9386
+ //# sourceMappingURL=chunk-ZBLSH3CX.js.map