@workit-dev/codex 2.18.1 → 2.19.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/launch-mcp.js
CHANGED
|
@@ -15511,6 +15511,7 @@ var workspaceConfigSchema = object({
|
|
|
15511
15511
|
trailers: boolean2().optional().describe("Whether commits get the `Workit-Session:` trailer (default true). With false, authorship lives in the ledger only."),
|
|
15512
15512
|
deleteBranch: boolean2().optional().describe("Whether `workit pr merge` deletes the head branch after a merge (default true); `--keep-branch` opts out for one merge."),
|
|
15513
15513
|
cleanup: unknown().optional().describe("What happens when work finishes: `auto` (default) removes the delivered branch's clean Workit worktree and local branch, switches a clean checkout on it back to the trunk, and stops the processes registered inside them; `keep` removes and stops nothing. A value Workit does not know reads as `keep`."),
|
|
15514
|
+
feedback: unknown().optional().describe('`workit feedback` for this workspace: `off` hides its contract line and makes the verb refuse; `{ "account": "<login>" }` names the GitHub login it posts with; workspaces inside this one inherit it.'),
|
|
15514
15515
|
liveSessionGuard: boolean2().optional().describe("Whether the live-session guard denies edits in a checkout another live agent session owns (default true)."),
|
|
15515
15516
|
fanout: object({
|
|
15516
15517
|
tierModels: unknown().optional().describe("The model per slice TIER (mundane, standard, hard), as one name or per host.")
|
|
@@ -15553,7 +15554,10 @@ var workspaceConfigSchema = object({
|
|
|
15553
15554
|
});
|
|
15554
15555
|
var workspacesFileSchema = object({
|
|
15555
15556
|
workspaces: array(workspaceConfigSchema).optional().describe("Workspace entries, each mapping a path glob to its forge, policies and grants."),
|
|
15556
|
-
models: object({ roles: modelRoles }).passthrough().optional().describe("The global default model and effort per role and host (roles), the lead's own advisory model (lead), how a role model applies (enforce: advise, the default, or strict) and, under strict, whether a model the lead names on a spawn wins (allowLeadOverride, default false).")
|
|
15557
|
+
models: object({ roles: modelRoles }).passthrough().optional().describe("The global default model and effort per role and host (roles), the lead's own advisory model (lead), how a role model applies (enforce: advise, the default, or strict) and, under strict, whether a model the lead names on a spawn wins (allowLeadOverride, default false)."),
|
|
15558
|
+
feedback: object({
|
|
15559
|
+
account: nonBlank.optional().describe("The GitHub login `workit feedback --post` uses when no workspace names one; never the workspace's work account by default.")
|
|
15560
|
+
}).passthrough().optional().describe("`workit feedback` defaults for every workspace.")
|
|
15557
15561
|
}).passthrough().superRefine((file, context) => {
|
|
15558
15562
|
const names = new Set;
|
|
15559
15563
|
for (const [index, workspace] of (file.workspaces ?? []).entries()) {
|
|
@@ -23901,6 +23905,7 @@ effect before a retry.
|
|
|
23901
23905
|
Mid-task: never silently drop or resume an objective (workit-continue).
|
|
23902
23906
|
Notes, drafts, logs, resume files: \`workit dir notes|handoffs\` (outside the
|
|
23903
23907
|
repo), never the repo tree.
|
|
23908
|
+
FEEDBACK_LINE
|
|
23904
23909
|
|
|
23905
23910
|
Skills: load the skill, never act from memory.
|
|
23906
23911
|
- brainstorm, plan, spec, grill, should we: workit-shape
|
|
@@ -30567,7 +30572,8 @@ var WORKIT_USER_ONLY = [
|
|
|
30567
30572
|
["install"],
|
|
30568
30573
|
["workspace", "seal"]
|
|
30569
30574
|
];
|
|
30570
|
-
var
|
|
30575
|
+
var WORKIT_ASKED_VERBS = ["feedback"];
|
|
30576
|
+
var USER_ONLY_WORD = new RegExp(`\\b(?:${[...new Set([...WORKIT_USER_ONLY.map((words) => words[0]), ...WORKIT_ASKED_VERBS])].join("|")})\\b`);
|
|
30571
30577
|
var ALLOWED = new Set(WORKIT_ALLOWED_VERBS);
|
|
30572
30578
|
// packages/workit-core/src/core/heavy-rules.ts
|
|
30573
30579
|
var EFFECTS = new Set(["allow", "ask", "deny"]);
|
|
@@ -7358,6 +7358,7 @@ var workspaceConfigSchema = object({
|
|
|
7358
7358
|
trailers: boolean2().optional().describe("Whether commits get the `Workit-Session:` trailer (default true). With false, authorship lives in the ledger only."),
|
|
7359
7359
|
deleteBranch: boolean2().optional().describe("Whether `workit pr merge` deletes the head branch after a merge (default true); `--keep-branch` opts out for one merge."),
|
|
7360
7360
|
cleanup: unknown().optional().describe("What happens when work finishes: `auto` (default) removes the delivered branch's clean Workit worktree and local branch, switches a clean checkout on it back to the trunk, and stops the processes registered inside them; `keep` removes and stops nothing. A value Workit does not know reads as `keep`."),
|
|
7361
|
+
feedback: unknown().optional().describe('`workit feedback` for this workspace: `off` hides its contract line and makes the verb refuse; `{ "account": "<login>" }` names the GitHub login it posts with; workspaces inside this one inherit it.'),
|
|
7361
7362
|
liveSessionGuard: boolean2().optional().describe("Whether the live-session guard denies edits in a checkout another live agent session owns (default true)."),
|
|
7362
7363
|
fanout: object({
|
|
7363
7364
|
tierModels: unknown().optional().describe("The model per slice TIER (mundane, standard, hard), as one name or per host.")
|
|
@@ -7400,7 +7401,10 @@ var workspaceConfigSchema = object({
|
|
|
7400
7401
|
});
|
|
7401
7402
|
var workspacesFileSchema = object({
|
|
7402
7403
|
workspaces: array(workspaceConfigSchema).optional().describe("Workspace entries, each mapping a path glob to its forge, policies and grants."),
|
|
7403
|
-
models: object({ roles: modelRoles }).passthrough().optional().describe("The global default model and effort per role and host (roles), the lead's own advisory model (lead), how a role model applies (enforce: advise, the default, or strict) and, under strict, whether a model the lead names on a spawn wins (allowLeadOverride, default false).")
|
|
7404
|
+
models: object({ roles: modelRoles }).passthrough().optional().describe("The global default model and effort per role and host (roles), the lead's own advisory model (lead), how a role model applies (enforce: advise, the default, or strict) and, under strict, whether a model the lead names on a spawn wins (allowLeadOverride, default false)."),
|
|
7405
|
+
feedback: object({
|
|
7406
|
+
account: nonBlank.optional().describe("The GitHub login `workit feedback --post` uses when no workspace names one; never the workspace's work account by default.")
|
|
7407
|
+
}).passthrough().optional().describe("`workit feedback` defaults for every workspace.")
|
|
7404
7408
|
}).passthrough().superRefine((file, context) => {
|
|
7405
7409
|
const names = new Set;
|
|
7406
7410
|
for (const [index, workspace] of (file.workspaces ?? []).entries()) {
|
|
@@ -7845,6 +7849,12 @@ var workspaceTrailers = (cwd, dir) => {
|
|
|
7845
7849
|
};
|
|
7846
7850
|
};
|
|
7847
7851
|
var workspaceLiveSessionGuard = (cwd, dir) => inheritedSetting(cwd, dir, (entry) => typeof entry.liveSessionGuard === "boolean")?.source?.liveSessionGuard !== false;
|
|
7852
|
+
var feedbackSetting = (cwd, dir) => {
|
|
7853
|
+
const found = inheritedSetting(cwd, dir, (entry) => entry.feedback !== undefined);
|
|
7854
|
+
const value = found?.source?.feedback;
|
|
7855
|
+
return { found, value, off: value === "off" };
|
|
7856
|
+
};
|
|
7857
|
+
var workspaceFeedbackOff = (cwd, dir) => feedbackSetting(cwd, dir).off;
|
|
7848
7858
|
var changelogPathOf = (value) => {
|
|
7849
7859
|
if (typeof value !== "string")
|
|
7850
7860
|
return null;
|
|
@@ -9182,6 +9192,7 @@ function selectMethods(policy, capabilities) {
|
|
|
9182
9192
|
return [{ id, reason: reasons.join("; "), assurance: capability.assurance }];
|
|
9183
9193
|
});
|
|
9184
9194
|
}
|
|
9195
|
+
var FEEDBACK_LINE = "Workit friction: offer `workit feedback` once per problem; keep working.";
|
|
9185
9196
|
var BOOTSTRAP = `
|
|
9186
9197
|
Workit is optional coordination and proof tooling: you decide what and
|
|
9187
9198
|
whether, the CLI does how and records what it observed.
|
|
@@ -9236,6 +9247,7 @@ effect before a retry.
|
|
|
9236
9247
|
Mid-task: never silently drop or resume an objective (workit-continue).
|
|
9237
9248
|
Notes, drafts, logs, resume files: \`workit dir notes|handoffs\` (outside the
|
|
9238
9249
|
repo), never the repo tree.
|
|
9250
|
+
FEEDBACK_LINE
|
|
9239
9251
|
|
|
9240
9252
|
Skills: load the skill, never act from memory.
|
|
9241
9253
|
- brainstorm, plan, spec, grill, should we: workit-shape
|
|
@@ -9253,9 +9265,13 @@ Skills: load the skill, never act from memory.
|
|
|
9253
9265
|
- architecture, deepen modules (user-invoked; offer it): workit-architecture
|
|
9254
9266
|
`.trim();
|
|
9255
9267
|
var invariantBootstrap = (session = null) => {
|
|
9268
|
+
const feedbackOff = session !== null && workspaceFeedbackOff(session.cwd);
|
|
9269
|
+
const bootstrap = BOOTSTRAP.replace(`FEEDBACK_LINE
|
|
9270
|
+
`, () => feedbackOff ? "" : `${FEEDBACK_LINE}
|
|
9271
|
+
`);
|
|
9256
9272
|
const table = session && hostFamily(session.host) === "claude_code" ? claudeSpawnTable(session.cwd) : null;
|
|
9257
|
-
return table ? `${
|
|
9258
|
-
${table}` :
|
|
9273
|
+
return table ? `${bootstrap}
|
|
9274
|
+
${table}` : bootstrap;
|
|
9259
9275
|
};
|
|
9260
9276
|
|
|
9261
9277
|
// packages/workit-core/src/store/paths.ts
|
|
@@ -18674,7 +18690,8 @@ var WORKIT_USER_ONLY = [
|
|
|
18674
18690
|
["install"],
|
|
18675
18691
|
["workspace", "seal"]
|
|
18676
18692
|
];
|
|
18677
|
-
var
|
|
18693
|
+
var WORKIT_ASKED_VERBS = ["feedback"];
|
|
18694
|
+
var USER_ONLY_WORD = new RegExp(`\\b(?:${[...new Set([...WORKIT_USER_ONLY.map((words) => words[0]), ...WORKIT_ASKED_VERBS])].join("|")})\\b`);
|
|
18678
18695
|
var mayRunUserOnly = (text) => {
|
|
18679
18696
|
const joined = text.replace(/\\\r?\n/g, "");
|
|
18680
18697
|
const bare = joined.replace(/['"\\]/g, "");
|
|
@@ -18743,6 +18760,37 @@ var userOnlyWorkitCall = (command, dialect = "posix") => {
|
|
|
18743
18760
|
}
|
|
18744
18761
|
return null;
|
|
18745
18762
|
};
|
|
18763
|
+
var askedWorkitCall = (command, dialect = "posix") => {
|
|
18764
|
+
if (!mayRunUserOnly(command))
|
|
18765
|
+
return null;
|
|
18766
|
+
for (const segment of segmentsOf(command, dialect)) {
|
|
18767
|
+
if (segment.unanalyzable)
|
|
18768
|
+
continue;
|
|
18769
|
+
const start = segment.words.findIndex(isWorkitWord);
|
|
18770
|
+
if (start < 0)
|
|
18771
|
+
continue;
|
|
18772
|
+
const words = segment.words.slice(start + 1);
|
|
18773
|
+
let at = 0;
|
|
18774
|
+
for (;; ) {
|
|
18775
|
+
const word = words[at];
|
|
18776
|
+
if (word === "--json")
|
|
18777
|
+
at += 1;
|
|
18778
|
+
else if (word === "--cwd" || word === "--session")
|
|
18779
|
+
at += 2;
|
|
18780
|
+
else if (word?.startsWith("--cwd="))
|
|
18781
|
+
at += 1;
|
|
18782
|
+
else
|
|
18783
|
+
break;
|
|
18784
|
+
}
|
|
18785
|
+
const verb = WORKIT_ASKED_VERBS.find((name) => words[at] === name);
|
|
18786
|
+
if (verb && !helpOnly(words.slice(at), [verb]))
|
|
18787
|
+
return {
|
|
18788
|
+
verb,
|
|
18789
|
+
plain: at === 0 && start === 0 && segment.words[0] === "workit"
|
|
18790
|
+
};
|
|
18791
|
+
}
|
|
18792
|
+
return null;
|
|
18793
|
+
};
|
|
18746
18794
|
// packages/workit-core/src/core/heavy-rules.ts
|
|
18747
18795
|
import fs17 from "node:fs";
|
|
18748
18796
|
import os6 from "node:os";
|
|
@@ -24965,6 +25013,18 @@ function decide(input, deps) {
|
|
|
24965
25013
|
unblock: null
|
|
24966
25014
|
};
|
|
24967
25015
|
}
|
|
25016
|
+
const asked = askedWorkitCall(event.command, event.dialect);
|
|
25017
|
+
if (asked && input.host === "claude_code")
|
|
25018
|
+
return {
|
|
25019
|
+
kind: "ask",
|
|
25020
|
+
reason: `\`workit ${asked.verb}\` reports to the Workit tracker: the user decides this call.`
|
|
25021
|
+
};
|
|
25022
|
+
if (asked && !asked.plain && canDeny && ["codex_cli", "codex_desktop"].includes(input.host))
|
|
25023
|
+
return {
|
|
25024
|
+
kind: "deny",
|
|
25025
|
+
reason: `Run \`workit ${asked.verb} …\` with nothing before the verb (no env, wrapper or global option), so Codex asks the user.`,
|
|
25026
|
+
unblock: null
|
|
25027
|
+
};
|
|
24968
25028
|
const role = canDeny ? agentRole(input, descriptor) : null;
|
|
24969
25029
|
if (role) {
|
|
24970
25030
|
const confined = (role === "implementer" ? confineImplementerShell : confineJudgeShell)(input, event.command, event.dialect);
|
package/dist/workit-hook.js
CHANGED
|
@@ -46,7 +46,7 @@ var namesYtrack = (text) => {
|
|
|
46
46
|
const bare = text.replace(/['"\\]/g, "");
|
|
47
47
|
return YTRACK_WORD.test(bare) || YTRACK_WORD.test(bare.replace(/`/g, ""));
|
|
48
48
|
};
|
|
49
|
-
var USER_ONLY_WORD = /\b(?:release|grant|ledger|approve|setup|uninstall|install|workspace)\b/;
|
|
49
|
+
var USER_ONLY_WORD = /\b(?:release|grant|ledger|approve|setup|uninstall|install|workspace|feedback)\b/;
|
|
50
50
|
var mayRunUserOnly = (text) => {
|
|
51
51
|
const joined = text.replace(/\\\r?\n/g, "");
|
|
52
52
|
const bare = joined.replace(/['"\\]/g, "");
|
|
@@ -101,7 +101,7 @@ if (quiet) {
|
|
|
101
101
|
`);
|
|
102
102
|
} else {
|
|
103
103
|
try {
|
|
104
|
-
const { runCodexHook } = await import("./workit-hook-
|
|
104
|
+
const { runCodexHook } = await import("./workit-hook-anp8ma2m.js");
|
|
105
105
|
await runCodexHook([payload]);
|
|
106
106
|
} catch (error) {
|
|
107
107
|
const { answerRuntimeFailure } = await import("./workit-hook-9k8dtngs.js");
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@workit-dev/codex",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.19.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Workit Codex CLI/desktop plugin — shared MCP transport, hooks, method skills, and verifier/reviewer/implementer agents",
|
|
6
6
|
"keywords": [
|
|
@@ -41,8 +41,8 @@
|
|
|
41
41
|
"build": "bun scripts/build.ts"
|
|
42
42
|
},
|
|
43
43
|
"devDependencies": {
|
|
44
|
-
"@workit-dev/core": "^2.
|
|
45
|
-
"@workit-dev/mcp": "^2.
|
|
44
|
+
"@workit-dev/core": "^2.19.0",
|
|
45
|
+
"@workit-dev/mcp": "^2.19.0"
|
|
46
46
|
},
|
|
47
47
|
"engines": {
|
|
48
48
|
"node": ">=24"
|
|
@@ -42,7 +42,7 @@ proposes and stops. Nothing changes until the user approves.
|
|
|
42
42
|
agent behaviour, becomes an issue or PR on BrainerVirus/workit, not a host
|
|
43
43
|
memory (one host reads it). Never fork a local copy. Use a minimal synthetic
|
|
44
44
|
repro: no private repo name, path, code, ledger text, PR, thread or transcript.
|
|
45
|
-
Paste the
|
|
45
|
+
Paste the whole `workit feedback "<title>" --body-file -` draft; `--post` once approved.
|
|
46
46
|
6. **Bloat guards.** AGENTS.md stays within 8 KB: each addition names what it
|
|
47
47
|
removes. Create `CODING_STANDARDS.md` or `GLOSSARY.md` only in the same
|
|
48
48
|
edit as its first real entry, never as a scaffold. Edit steering text by
|