auto-mode 0.11.0 → 0.12.0

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
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env node
2
- import { D as string, E as strictObject, T as number, _ as loadRepositoryContext, b as DEFAULT_SCOPE_SOURCES, c as splitShellCommand, d as resolveSessionScopePath, f as loadSessionScope, g as toRepositorySlug, h as findCheckout, l as splitCommandWords, m as loadCheckoutRemotes, n as parseActionRequest, p as EMPTY_SESSION_SCOPE, r as classifyAction, s as loadPolicy, t as renderVerdict, u as resolveStateDir, x as loadConfig, y as DEFAULT_DENIAL_BUDGET } from "./render-verdict-BiGjYb1x.js";
2
+ import { D as string, E as strictObject, T as number, _ as splitCommandWords, a as resolveSessionScopePath, b as DEFAULT_SCOPE_SOURCES, c as loadCheckoutRemotes, g as splitShellCommand, h as toRepositorySlug, i as resolveStateDir, l as findCheckout, m as loadPolicy, n as parseActionRequest, o as loadSessionScope, p as loadRepositoryContext, r as classifyAction, s as EMPTY_SESSION_SCOPE, t as renderVerdict, x as loadConfig, y as DEFAULT_DENIAL_BUDGET } from "./render-verdict-FhSKxlO9.js";
3
3
  import { appendFile, mkdir, open, readFile, rename, rm, stat, writeFile } from "node:fs/promises";
4
- import { homedir } from "node:os";
5
4
  import { dirname, isAbsolute, join, normalize } from "node:path";
5
+ import { homedir } from "node:os";
6
6
  import { spawn } from "node:child_process";
7
7
  import { createHash, randomUUID } from "node:crypto";
8
8
  import { text } from "node:stream/consumers";
@@ -0,0 +1,20 @@
1
+ //#region src/bypass/get-edit-fields.ts
2
+ const EDIT_FIELDS = {
3
+ Edit: {
4
+ path: "file_path",
5
+ content: "new_string"
6
+ },
7
+ Write: {
8
+ path: "file_path",
9
+ content: "content"
10
+ },
11
+ NotebookEdit: {
12
+ path: "notebook_path",
13
+ content: "new_source"
14
+ }
15
+ };
16
+ function getEditFields(toolName) {
17
+ return EDIT_FIELDS[toolName] ?? null;
18
+ }
19
+ //#endregion
20
+ export { getEditFields as t };
package/dist/index.d.ts CHANGED
@@ -115,7 +115,7 @@ interface DecisionDiagnostics {
115
115
  }
116
116
  //#endregion
117
117
  //#region src/classify-action.d.ts
118
- type DecidingStage = 'local' | 'containment' | 'jev' | 'messages' | 'retry';
118
+ type DecidingStage = 'local' | 'containment' | 'bypass' | 'jev' | 'messages' | 'retry';
119
119
  interface ActionOutcome {
120
120
  readonly verdict: Verdict | null;
121
121
  readonly decidingStage: DecidingStage;
package/dist/index.js CHANGED
@@ -1,2 +1,2 @@
1
- import { C as resolveConfigPath, S as resolveApiKey, a as classifyWithModel, i as classifyLocally, n as parseActionRequest, o as parseModelVerdict, r as classifyAction, s as loadPolicy, t as renderVerdict, v as DEFAULT_CONFIG, w as PRESETS, x as loadConfig } from "./render-verdict-BiGjYb1x.js";
1
+ import { C as resolveConfigPath, S as resolveApiKey, d as classifyWithModel, f as parseModelVerdict, m as loadPolicy, n as parseActionRequest, r as classifyAction, t as renderVerdict, u as classifyLocally, v as DEFAULT_CONFIG, w as PRESETS, x as loadConfig } from "./render-verdict-FhSKxlO9.js";
2
2
  export { DEFAULT_CONFIG, PRESETS, classifyAction, classifyLocally, classifyWithModel, loadConfig, loadPolicy, parseActionRequest, parseModelVerdict, renderVerdict, resolveApiKey, resolveConfigPath };