@gajae-code/coding-agent 0.1.3 → 0.2.1
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/CHANGELOG.md +25 -0
- package/dist/types/cli/skills-cli.d.ts +9 -0
- package/dist/types/commands/gjc-runtime-bridge.d.ts +24 -0
- package/dist/types/commands/skills.d.ts +26 -0
- package/dist/types/config/model-registry.d.ts +31 -2
- package/dist/types/config/models-config-schema.d.ts +39 -0
- package/dist/types/gjc-runtime/launch-tmux.d.ts +23 -0
- package/dist/types/gjc-runtime/team-runtime.d.ts +35 -1
- package/dist/types/gjc-runtime/ultragoal-runtime.d.ts +15 -10
- package/dist/types/hooks/skill-state.d.ts +4 -1
- package/dist/types/modes/components/model-selector.d.ts +21 -1
- package/dist/types/skill-state/active-state.d.ts +19 -0
- package/dist/types/skill-state/workflow-hud.d.ts +62 -0
- package/dist/types/slash-commands/builtin-registry.d.ts +1 -0
- package/package.json +7 -7
- package/src/cli/args.ts +14 -0
- package/src/cli/skills-cli.ts +88 -0
- package/src/cli.ts +1 -0
- package/src/commands/deep-interview.ts +21 -2
- package/src/commands/gjc-runtime-bridge.ts +161 -15
- package/src/commands/ralplan.ts +21 -2
- package/src/commands/skills.ts +48 -0
- package/src/commands/team.ts +54 -3
- package/src/commands/ultragoal.ts +21 -1
- package/src/commit/agentic/index.ts +1 -0
- package/src/commit/pipeline.ts +1 -0
- package/src/config/model-registry.ts +259 -8
- package/src/config/models-config-schema.ts +18 -0
- package/src/defaults/gjc/skills/deep-interview/SKILL.md +6 -6
- package/src/defaults/gjc/skills/ralplan/SKILL.md +5 -9
- package/src/defaults/gjc/skills/team/SKILL.md +4 -4
- package/src/defaults/gjc/skills/ultragoal/SKILL.md +8 -8
- package/src/gjc-runtime/launch-tmux.ts +73 -2
- package/src/gjc-runtime/team-runtime.ts +285 -34
- package/src/gjc-runtime/ultragoal-guard.ts +43 -1
- package/src/gjc-runtime/ultragoal-runtime.ts +307 -187
- package/src/hooks/skill-state.ts +4 -1
- package/src/internal-urls/docs-index.generated.ts +1 -1
- package/src/main.ts +10 -1
- package/src/modes/components/model-selector.ts +109 -28
- package/src/modes/components/skill-hud/render.ts +35 -8
- package/src/modes/controllers/selector-controller.ts +42 -2
- package/src/prompts/system/system-prompt.md +5 -4
- package/src/sdk.ts +1 -0
- package/src/session/agent-session.ts +6 -0
- package/src/setup/provider-onboarding.ts +2 -0
- package/src/skill-state/active-state.ts +104 -4
- package/src/skill-state/workflow-hud.ts +160 -0
- package/src/slash-commands/acp-builtins.ts +11 -2
- package/src/slash-commands/builtin-registry.ts +16 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,31 @@
|
|
|
2
2
|
|
|
3
3
|
## [Unreleased]
|
|
4
4
|
|
|
5
|
+
## [0.2.1] - 2026-05-30
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
|
|
9
|
+
- Added a `gjc skills` inspection command so installed binaries can list and read embedded workflow skills from any project without relying on source-tree `.gjc` files.
|
|
10
|
+
- Fixed first-run API provider onboarding so `models.yml` parent directories are created before writing, and malformed `/provicer` startup invocations now report the intended `/provider add` spelling instead of falling through to model bootstrap.
|
|
11
|
+
|
|
12
|
+
## [0.2.0] - 2026-05-28
|
|
13
|
+
|
|
14
|
+
### Added
|
|
15
|
+
|
|
16
|
+
- Added scoped GJC tmux profile handling for `gjc --tmux` and `gjc team` sessions without mutating global tmux configuration.
|
|
17
|
+
- Added GJC team integration hardening for worker turn-end integration requests, auto-rebase/auto-merge conflict surfacing, protected checkpoint classification, and leader/worker-visible integration summaries.
|
|
18
|
+
- Added Node 20 release baseline validation to the release/check surface.
|
|
19
|
+
|
|
20
|
+
### Changed
|
|
21
|
+
|
|
22
|
+
- Clarified the public workflow contract so `deep-interview` and `ralplan` are invoked through `/skill:<name>`, while `gjc ultragoal` and `gjc team` remain native runtime commands.
|
|
23
|
+
- Updated the README hero image and Discord community invite.
|
|
24
|
+
|
|
25
|
+
### Fixed
|
|
26
|
+
|
|
27
|
+
- Restored Ultragoal completion receipt export/generation validation and completion gates.
|
|
28
|
+
- Fixed workflow bridge guidance and tests so private compatibility bridge commands are not advertised as public skill-loading paths.
|
|
29
|
+
|
|
5
30
|
## [0.1.3] - 2026-05-28
|
|
6
31
|
|
|
7
32
|
### Changed
|
|
@@ -1,6 +1,30 @@
|
|
|
1
|
+
import { type WorkflowHudSummary } from "../skill-state/active-state";
|
|
2
|
+
export declare const WORKFLOW_HUD_PROTOCOL = "workflow-hud-summary-v1";
|
|
1
3
|
export interface GjcRuntimeBridgeResult {
|
|
2
4
|
status: number;
|
|
3
5
|
error?: string;
|
|
4
6
|
}
|
|
7
|
+
export interface WorkflowHudBridgePayload {
|
|
8
|
+
version: 1;
|
|
9
|
+
skill: string;
|
|
10
|
+
phase?: string;
|
|
11
|
+
active?: boolean;
|
|
12
|
+
session_id?: string;
|
|
13
|
+
thread_id?: string;
|
|
14
|
+
turn_id?: string;
|
|
15
|
+
hud: WorkflowHudSummary;
|
|
16
|
+
}
|
|
17
|
+
export interface GjcRuntimeHudBridgeResult extends GjcRuntimeBridgeResult {
|
|
18
|
+
hudPayload?: WorkflowHudBridgePayload;
|
|
19
|
+
}
|
|
20
|
+
export interface GjcRuntimeHudBridgeOptions {
|
|
21
|
+
cwd?: string;
|
|
22
|
+
env?: NodeJS.ProcessEnv;
|
|
23
|
+
sidecarSkill: string;
|
|
24
|
+
onHudPayload?: (payload: WorkflowHudBridgePayload) => Promise<void> | void;
|
|
25
|
+
pollIntervalMs?: number;
|
|
26
|
+
}
|
|
27
|
+
export declare function normalizeWorkflowHudBridgePayload(raw: unknown, expectedSkill: string): WorkflowHudBridgePayload | null;
|
|
5
28
|
export declare function runGjcRuntimeBridge(endpoint: string, args: string[], env?: NodeJS.ProcessEnv): GjcRuntimeBridgeResult;
|
|
29
|
+
export declare function runGjcRuntimeBridgeWithHudSidecar(endpoint: string, args: string[], options: GjcRuntimeHudBridgeOptions): Promise<GjcRuntimeHudBridgeResult>;
|
|
6
30
|
export declare function runBridgedRuntimeEndpoint(endpoint: string, args: string[]): Promise<void>;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Inspect bundled workflow skills.
|
|
3
|
+
*/
|
|
4
|
+
import { Command } from "@gajae-code/utils/cli";
|
|
5
|
+
import { type SkillsAction } from "../cli/skills-cli";
|
|
6
|
+
export default class Skills extends Command {
|
|
7
|
+
static description: string;
|
|
8
|
+
static args: {
|
|
9
|
+
action: import("@gajae-code/utils/cli").ArgDescriptor & {
|
|
10
|
+
description: string;
|
|
11
|
+
required: false;
|
|
12
|
+
options: SkillsAction[];
|
|
13
|
+
};
|
|
14
|
+
name: import("@gajae-code/utils/cli").ArgDescriptor & {
|
|
15
|
+
description: string;
|
|
16
|
+
required: false;
|
|
17
|
+
};
|
|
18
|
+
};
|
|
19
|
+
static flags: {
|
|
20
|
+
json: import("@gajae-code/utils/cli").FlagDescriptor<"boolean"> & {
|
|
21
|
+
description: string;
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
static examples: string[];
|
|
25
|
+
run(): Promise<void>;
|
|
26
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type Api, type AssistantMessageEventStream, type Context, type Model, type ModelRefreshStrategy, type SimpleStreamOptions, type ThinkingConfig } from "@gajae-code/ai";
|
|
1
|
+
import { type Api, type AssistantMessageEventStream, type Context, type Model, type ModelRefreshStrategy, type ModelRequestTransform, type SimpleStreamOptions, type ThinkingConfig } from "@gajae-code/ai";
|
|
2
2
|
import type { OAuthCredentials, OAuthLoginCallbacks } from "@gajae-code/ai/utils/oauth/types";
|
|
3
3
|
import { type ThemeColor } from "../modes/theme/theme";
|
|
4
4
|
import type { AuthStorage } from "../session/auth-storage";
|
|
@@ -88,6 +88,12 @@ export declare const ModelsConfigFile: ConfigFile<{
|
|
|
88
88
|
discovery?: {
|
|
89
89
|
type: "llama.cpp" | "lm-studio" | "ollama" | "openai-models-list";
|
|
90
90
|
} | undefined;
|
|
91
|
+
requestTransform?: {
|
|
92
|
+
profile?: "openai-proxy" | undefined;
|
|
93
|
+
stripHeaders?: string[] | undefined;
|
|
94
|
+
setHeaders?: Record<string, string | null> | undefined;
|
|
95
|
+
extraBody?: Record<string, unknown> | undefined;
|
|
96
|
+
} | undefined;
|
|
91
97
|
models?: {
|
|
92
98
|
id: string;
|
|
93
99
|
name?: string | undefined;
|
|
@@ -151,6 +157,13 @@ export declare const ModelsConfigFile: ConfigFile<{
|
|
|
151
157
|
toolStrictMode?: "all_strict" | "none" | undefined;
|
|
152
158
|
} | undefined;
|
|
153
159
|
contextPromotionTarget?: string | undefined;
|
|
160
|
+
wireModelId?: string | undefined;
|
|
161
|
+
requestTransform?: {
|
|
162
|
+
profile?: "openai-proxy" | undefined;
|
|
163
|
+
stripHeaders?: string[] | undefined;
|
|
164
|
+
setHeaders?: Record<string, string | null> | undefined;
|
|
165
|
+
extraBody?: Record<string, unknown> | undefined;
|
|
166
|
+
} | undefined;
|
|
154
167
|
}[] | undefined;
|
|
155
168
|
modelOverrides?: Record<string, {
|
|
156
169
|
name?: string | undefined;
|
|
@@ -212,10 +225,21 @@ export declare const ModelsConfigFile: ConfigFile<{
|
|
|
212
225
|
toolStrictMode?: "all_strict" | "none" | undefined;
|
|
213
226
|
} | undefined;
|
|
214
227
|
contextPromotionTarget?: string | undefined;
|
|
228
|
+
wireModelId?: string | undefined;
|
|
229
|
+
requestTransform?: {
|
|
230
|
+
profile?: "openai-proxy" | undefined;
|
|
231
|
+
stripHeaders?: string[] | undefined;
|
|
232
|
+
setHeaders?: Record<string, string | null> | undefined;
|
|
233
|
+
extraBody?: Record<string, unknown> | undefined;
|
|
234
|
+
} | undefined;
|
|
215
235
|
}> | undefined;
|
|
216
236
|
disableStrictTools?: boolean | undefined;
|
|
217
237
|
transport?: "pi-native" | undefined;
|
|
218
238
|
}> | undefined;
|
|
239
|
+
modelBindings?: {
|
|
240
|
+
modelRoles?: Record<string, string> | undefined;
|
|
241
|
+
agentModelOverrides?: Record<string, string> | undefined;
|
|
242
|
+
} | undefined;
|
|
219
243
|
equivalence?: {
|
|
220
244
|
overrides?: Record<string, string> | undefined;
|
|
221
245
|
exclude?: string[] | undefined;
|
|
@@ -229,6 +253,7 @@ interface ProviderOverride {
|
|
|
229
253
|
authHeader?: boolean;
|
|
230
254
|
compat?: Model<Api>["compat"];
|
|
231
255
|
transport?: Model<Api>["transport"];
|
|
256
|
+
requestTransform?: ModelRequestTransform;
|
|
232
257
|
}
|
|
233
258
|
/**
|
|
234
259
|
* Merge a freshly discovered model with the matching bundled/configured entry
|
|
@@ -246,7 +271,7 @@ interface ProviderOverride {
|
|
|
246
271
|
* See `xiaomi-tp-discovery-merge.test.ts` and the `refresh()` baseUrl-override
|
|
247
272
|
* regression in `model-registry.test.ts`.
|
|
248
273
|
*/
|
|
249
|
-
export declare function mergeDiscoveredModel<TApi extends Api>(model: Model<TApi>, existing: Model<Api> | undefined, providerOverride?: Pick<ProviderOverride, "baseUrl" | "headers" | "transport">): Model<TApi>;
|
|
274
|
+
export declare function mergeDiscoveredModel<TApi extends Api>(model: Model<TApi>, existing: Model<Api> | undefined, providerOverride?: Pick<ProviderOverride, "baseUrl" | "headers" | "transport" | "requestTransform">): Model<TApi>;
|
|
250
275
|
export type ProviderDiscoveryStatus = "idle" | "ok" | "empty" | "cached" | "unavailable" | "unauthenticated";
|
|
251
276
|
export interface ProviderDiscoveryState {
|
|
252
277
|
provider: string;
|
|
@@ -281,6 +306,7 @@ export declare class ModelRegistry {
|
|
|
281
306
|
* Get any error from loading models.json (undefined if no error).
|
|
282
307
|
*/
|
|
283
308
|
getError(): ConfigError | undefined;
|
|
309
|
+
applyConfiguredModelBindings(targetSettings: Settings): void;
|
|
284
310
|
/**
|
|
285
311
|
* Get all models (built-in + custom).
|
|
286
312
|
* If models.json had errors, returns only built-in models.
|
|
@@ -364,6 +390,7 @@ export interface ProviderConfigInput {
|
|
|
364
390
|
streamSimple?: (model: Model<Api>, context: Context, options?: SimpleStreamOptions) => AssistantMessageEventStream;
|
|
365
391
|
headers?: Record<string, string>;
|
|
366
392
|
compat?: Model<Api>["compat"];
|
|
393
|
+
requestTransform?: ModelRequestTransform;
|
|
367
394
|
authHeader?: boolean;
|
|
368
395
|
/** Streaming transport override — see {@link Model.transport}. */
|
|
369
396
|
transport?: Model<Api>["transport"];
|
|
@@ -392,6 +419,8 @@ export interface ProviderConfigInput {
|
|
|
392
419
|
maxTokens: number;
|
|
393
420
|
headers?: Record<string, string>;
|
|
394
421
|
compat?: Model<Api>["compat"];
|
|
422
|
+
requestTransform?: ModelRequestTransform;
|
|
423
|
+
wireModelId?: string;
|
|
395
424
|
contextPromotionTarget?: string;
|
|
396
425
|
premiumMultiplier?: number;
|
|
397
426
|
}>;
|
|
@@ -162,6 +162,15 @@ export declare const ModelOverrideSchema: z.ZodObject<{
|
|
|
162
162
|
}>>;
|
|
163
163
|
}, z.core.$strip>>;
|
|
164
164
|
contextPromotionTarget: z.ZodOptional<z.ZodString>;
|
|
165
|
+
wireModelId: z.ZodOptional<z.ZodString>;
|
|
166
|
+
requestTransform: z.ZodOptional<z.ZodObject<{
|
|
167
|
+
profile: z.ZodOptional<z.ZodEnum<{
|
|
168
|
+
"openai-proxy": "openai-proxy";
|
|
169
|
+
}>>;
|
|
170
|
+
stripHeaders: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
171
|
+
setHeaders: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodString>>>;
|
|
172
|
+
extraBody: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
173
|
+
}, z.core.$strip>>;
|
|
165
174
|
}, z.core.$strip>;
|
|
166
175
|
export type ModelOverride = z.infer<typeof ModelOverrideSchema>;
|
|
167
176
|
export declare const ProviderDiscoverySchema: z.ZodObject<{
|
|
@@ -262,6 +271,14 @@ export declare const ModelsConfigSchema: z.ZodObject<{
|
|
|
262
271
|
"openai-models-list": "openai-models-list";
|
|
263
272
|
}>;
|
|
264
273
|
}, z.core.$strip>>;
|
|
274
|
+
requestTransform: z.ZodOptional<z.ZodObject<{
|
|
275
|
+
profile: z.ZodOptional<z.ZodEnum<{
|
|
276
|
+
"openai-proxy": "openai-proxy";
|
|
277
|
+
}>>;
|
|
278
|
+
stripHeaders: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
279
|
+
setHeaders: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodString>>>;
|
|
280
|
+
extraBody: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
281
|
+
}, z.core.$strip>>;
|
|
265
282
|
models: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
266
283
|
id: z.ZodString;
|
|
267
284
|
name: z.ZodOptional<z.ZodString>;
|
|
@@ -382,6 +399,15 @@ export declare const ModelsConfigSchema: z.ZodObject<{
|
|
|
382
399
|
}>>;
|
|
383
400
|
}, z.core.$strip>>;
|
|
384
401
|
contextPromotionTarget: z.ZodOptional<z.ZodString>;
|
|
402
|
+
wireModelId: z.ZodOptional<z.ZodString>;
|
|
403
|
+
requestTransform: z.ZodOptional<z.ZodObject<{
|
|
404
|
+
profile: z.ZodOptional<z.ZodEnum<{
|
|
405
|
+
"openai-proxy": "openai-proxy";
|
|
406
|
+
}>>;
|
|
407
|
+
stripHeaders: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
408
|
+
setHeaders: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodString>>>;
|
|
409
|
+
extraBody: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
410
|
+
}, z.core.$strip>>;
|
|
385
411
|
}, z.core.$strip>>>;
|
|
386
412
|
modelOverrides: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
387
413
|
name: z.ZodOptional<z.ZodString>;
|
|
@@ -492,10 +518,23 @@ export declare const ModelsConfigSchema: z.ZodObject<{
|
|
|
492
518
|
}>>;
|
|
493
519
|
}, z.core.$strip>>;
|
|
494
520
|
contextPromotionTarget: z.ZodOptional<z.ZodString>;
|
|
521
|
+
wireModelId: z.ZodOptional<z.ZodString>;
|
|
522
|
+
requestTransform: z.ZodOptional<z.ZodObject<{
|
|
523
|
+
profile: z.ZodOptional<z.ZodEnum<{
|
|
524
|
+
"openai-proxy": "openai-proxy";
|
|
525
|
+
}>>;
|
|
526
|
+
stripHeaders: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
527
|
+
setHeaders: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNullable<z.ZodString>>>;
|
|
528
|
+
extraBody: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
529
|
+
}, z.core.$strip>>;
|
|
495
530
|
}, z.core.$strip>>>;
|
|
496
531
|
disableStrictTools: z.ZodOptional<z.ZodBoolean>;
|
|
497
532
|
transport: z.ZodOptional<z.ZodLiteral<"pi-native">>;
|
|
498
533
|
}, z.core.$strip>>>;
|
|
534
|
+
modelBindings: z.ZodOptional<z.ZodObject<{
|
|
535
|
+
modelRoles: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
536
|
+
agentModelOverrides: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
537
|
+
}, z.core.$strip>>;
|
|
499
538
|
equivalence: z.ZodOptional<z.ZodObject<{
|
|
500
539
|
overrides: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
501
540
|
exclude: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
@@ -3,6 +3,8 @@ export declare const GJC_DEFAULT_TMUX_SESSION = "gajae_code";
|
|
|
3
3
|
export declare const GJC_TMUX_LAUNCHED_ENV = "GJC_TMUX_LAUNCHED";
|
|
4
4
|
export declare const GJC_LAUNCH_POLICY_ENV = "GJC_LAUNCH_POLICY";
|
|
5
5
|
export declare const GJC_TMUX_COMMAND_ENV = "GJC_TMUX_COMMAND";
|
|
6
|
+
export declare const GJC_TMUX_PROFILE_ENV = "GJC_TMUX_PROFILE";
|
|
7
|
+
export declare const GJC_TMUX_MOUSE_ENV = "GJC_MOUSE";
|
|
6
8
|
interface TtyState {
|
|
7
9
|
stdin: boolean;
|
|
8
10
|
stdout: boolean;
|
|
@@ -40,6 +42,27 @@ export interface TmuxLaunchPlan {
|
|
|
40
42
|
newSessionArgs: string[];
|
|
41
43
|
attachSessionArgs: string[];
|
|
42
44
|
}
|
|
45
|
+
export interface GjcTmuxProfileCommand {
|
|
46
|
+
description: string;
|
|
47
|
+
args: string[];
|
|
48
|
+
}
|
|
49
|
+
export interface GjcTmuxProfileResult {
|
|
50
|
+
skipped: boolean;
|
|
51
|
+
commands: GjcTmuxProfileCommand[];
|
|
52
|
+
failures: Array<{
|
|
53
|
+
command: GjcTmuxProfileCommand;
|
|
54
|
+
stderr?: string;
|
|
55
|
+
}>;
|
|
56
|
+
}
|
|
57
|
+
export interface GjcTmuxProfileContext {
|
|
58
|
+
tmuxCommand: string;
|
|
59
|
+
target: string;
|
|
60
|
+
cwd?: string;
|
|
61
|
+
env?: NodeJS.ProcessEnv;
|
|
62
|
+
spawnSync?: TmuxSpawnSync;
|
|
63
|
+
}
|
|
64
|
+
export declare function buildGjcTmuxProfileCommands(target: string, env?: NodeJS.ProcessEnv): GjcTmuxProfileCommand[];
|
|
65
|
+
export declare function applyGjcTmuxProfile(context: GjcTmuxProfileContext): GjcTmuxProfileResult;
|
|
43
66
|
export declare function buildDefaultTmuxLaunchPlan(context: TmuxLaunchContext): TmuxLaunchPlan | undefined;
|
|
44
67
|
export declare function launchDefaultTmuxIfNeeded(context: TmuxLaunchContext): boolean;
|
|
45
68
|
export {};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { WorkflowHudSummary } from "../skill-state/active-state";
|
|
1
2
|
export type GjcTeamPhase = "starting" | "running" | "complete" | "failed" | "cancelled";
|
|
2
3
|
export type GjcTeamTaskStatus = "pending" | "blocked" | "in_progress" | "completed" | "failed";
|
|
3
4
|
export type GjcWorkerStatusState = "idle" | "working" | "blocked" | "done" | "failed" | "draining" | "unknown";
|
|
@@ -143,7 +144,7 @@ export interface GjcTeamMailboxMessage {
|
|
|
143
144
|
export declare function resolveGjcTeamWorkerCli(env?: NodeJS.ProcessEnv): GjcTeamWorkerCli;
|
|
144
145
|
export declare function resolveGjcTeamWorkerCliPlan(workerCount: number, env?: NodeJS.ProcessEnv): GjcTeamWorkerCli[];
|
|
145
146
|
export declare function translateGjcWorkerLaunchArgsForCli(workerCli: GjcTeamWorkerCli, args: string[]): string[];
|
|
146
|
-
interface GjcTeamEvent {
|
|
147
|
+
export interface GjcTeamEvent {
|
|
147
148
|
event_id: string;
|
|
148
149
|
ts: string;
|
|
149
150
|
type: string;
|
|
@@ -164,12 +165,45 @@ interface WorkerHeartbeatFile {
|
|
|
164
165
|
turn_count: number;
|
|
165
166
|
alive: boolean;
|
|
166
167
|
}
|
|
168
|
+
export interface GjcWorkerIntegrationAttemptRequestResult {
|
|
169
|
+
requested: boolean;
|
|
170
|
+
reason: "requested" | "not_worker" | "missing_worktree" | "no_changes" | "deduped" | "git_error";
|
|
171
|
+
worker?: string;
|
|
172
|
+
team_name?: string;
|
|
173
|
+
fingerprint?: string;
|
|
174
|
+
head?: string | null;
|
|
175
|
+
status?: GjcWorkerCheckpointClassification["kind"];
|
|
176
|
+
}
|
|
167
177
|
export declare const GJC_TEAM_API_OPERATIONS: readonly ["send-message", "broadcast", "mailbox-list", "mailbox-mark-delivered", "mailbox-mark-notified", "create-task", "read-task", "list-tasks", "update-task", "claim-task", "transition-task-status", "transition-task", "release-task-claim", "read-config", "read-manifest", "read-worker-status", "read-worker-heartbeat", "update-worker-heartbeat", "write-worker-inbox", "write-worker-identity", "append-event", "read-events", "await-event", "write-shutdown-request", "read-shutdown-ack", "read-monitor-snapshot", "write-monitor-snapshot", "read-task-approval", "write-task-approval"];
|
|
168
178
|
export declare function resolveGjcTeamStateRoot(cwd?: string, env?: NodeJS.ProcessEnv): string;
|
|
169
179
|
export declare function resolveGjcTmuxCommand(env?: NodeJS.ProcessEnv): string;
|
|
170
180
|
export declare function resolveGjcWorkerCommand(cwd?: string, env?: NodeJS.ProcessEnv): string;
|
|
181
|
+
export type GjcWorkerCheckpointClassification = {
|
|
182
|
+
kind: "clean";
|
|
183
|
+
files: string[];
|
|
184
|
+
} | {
|
|
185
|
+
kind: "eligible";
|
|
186
|
+
files: string[];
|
|
187
|
+
} | {
|
|
188
|
+
kind: "protected_only";
|
|
189
|
+
files: string[];
|
|
190
|
+
} | {
|
|
191
|
+
kind: "conflicted";
|
|
192
|
+
files: string[];
|
|
193
|
+
} | {
|
|
194
|
+
kind: "git_error";
|
|
195
|
+
files: string[];
|
|
196
|
+
detail: string;
|
|
197
|
+
};
|
|
198
|
+
export declare function classifyGjcTeamCheckpointFiles(files: string[]): {
|
|
199
|
+
eligible: string[];
|
|
200
|
+
protected: string[];
|
|
201
|
+
};
|
|
202
|
+
export declare function classifyWorkerCheckpointStatus(cwd: string): GjcWorkerCheckpointClassification;
|
|
171
203
|
export declare function startGjcTeam(options: GjcTeamStartOptions): Promise<GjcTeamSnapshot>;
|
|
172
204
|
export declare function readGjcTeamSnapshot(teamName: string, cwd?: string, env?: NodeJS.ProcessEnv): Promise<GjcTeamSnapshot>;
|
|
205
|
+
export declare function requestGjcWorkerIntegrationAttempt(cwd?: string, env?: NodeJS.ProcessEnv): Promise<GjcWorkerIntegrationAttemptRequestResult>;
|
|
206
|
+
export declare function buildTeamHudSummary(snapshot: GjcTeamSnapshot, latestEvent?: GjcTeamEvent, latestMessage?: GjcTeamMailboxMessage): Promise<WorkflowHudSummary>;
|
|
173
207
|
export declare function monitorGjcTeam(teamName: string, cwd?: string, env?: NodeJS.ProcessEnv): Promise<GjcTeamSnapshot>;
|
|
174
208
|
export declare function listGjcTeams(cwd?: string, env?: NodeJS.ProcessEnv): Promise<GjcTeamSnapshot[]>;
|
|
175
209
|
export declare function shutdownGjcTeam(teamName: string, cwd?: string, env?: NodeJS.ProcessEnv): Promise<GjcTeamSnapshot>;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { WorkflowHudSummary } from "../skill-state/active-state";
|
|
1
2
|
export type UltragoalGjcGoalMode = "aggregate" | "per-story";
|
|
2
3
|
export type UltragoalGoalStatus = "pending" | "active" | "complete" | "failed" | "blocked" | "review_blocked" | "superseded";
|
|
3
4
|
export interface UltragoalGoal {
|
|
@@ -34,6 +35,7 @@ export interface UltragoalCompletionVerification {
|
|
|
34
35
|
gjcGoalMode: UltragoalGjcGoalMode;
|
|
35
36
|
gjcObjective: string;
|
|
36
37
|
qualityGateHash: string;
|
|
38
|
+
gjcGoalSnapshotHash: string;
|
|
37
39
|
planGeneration: string;
|
|
38
40
|
basis: {
|
|
39
41
|
planHashBeforeCheckpoint: string;
|
|
@@ -77,8 +79,21 @@ interface JsonObject {
|
|
|
77
79
|
export declare function hashStructuredValue(value: unknown): string;
|
|
78
80
|
export declare function getUltragoalPaths(cwd: string): UltragoalPaths;
|
|
79
81
|
export declare function readUltragoalLedger(cwd: string): Promise<UltragoalLedgerEvent[]>;
|
|
82
|
+
export declare function computeUltragoalPlanGeneration(input: {
|
|
83
|
+
plan: UltragoalPlan;
|
|
84
|
+
ledger: readonly UltragoalLedgerEvent[];
|
|
85
|
+
goal: UltragoalGoal;
|
|
86
|
+
receiptKind: UltragoalReceiptKind;
|
|
87
|
+
beforeStatus: UltragoalGoalStatus;
|
|
88
|
+
excludeEventId?: string;
|
|
89
|
+
targetGoalUpdatedAt?: string;
|
|
90
|
+
}): {
|
|
91
|
+
planGeneration: string;
|
|
92
|
+
basis: UltragoalCompletionVerification["basis"];
|
|
93
|
+
};
|
|
80
94
|
export declare function readUltragoalPlan(cwd: string): Promise<UltragoalPlan | null>;
|
|
81
95
|
export declare function getUltragoalStatus(cwd: string): Promise<UltragoalStatusSummary>;
|
|
96
|
+
export declare function buildUltragoalHudSummary(summary: UltragoalStatusSummary, latestLedger?: UltragoalLedgerEvent): WorkflowHudSummary;
|
|
82
97
|
export declare function createUltragoalPlan(input: {
|
|
83
98
|
cwd: string;
|
|
84
99
|
brief: string;
|
|
@@ -92,16 +107,6 @@ export declare function startNextUltragoalGoal(input: {
|
|
|
92
107
|
goal?: UltragoalGoal;
|
|
93
108
|
allComplete: boolean;
|
|
94
109
|
}>;
|
|
95
|
-
export declare function computeUltragoalPlanGeneration(input: {
|
|
96
|
-
plan: UltragoalPlan;
|
|
97
|
-
ledger: readonly UltragoalLedgerEvent[];
|
|
98
|
-
goal: UltragoalGoal;
|
|
99
|
-
receiptKind: UltragoalReceiptKind;
|
|
100
|
-
beforeStatus: UltragoalGoalStatus;
|
|
101
|
-
excludeEventId?: string;
|
|
102
|
-
}): UltragoalCompletionVerification["basis"] & {
|
|
103
|
-
planGeneration: string;
|
|
104
|
-
};
|
|
105
110
|
export declare function checkpointUltragoalGoal(input: {
|
|
106
111
|
cwd: string;
|
|
107
112
|
goalId: string;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { SkillDiscoverySettings } from "../config/skill-settings-defaults";
|
|
2
|
+
import type { SkillActiveEntry as CanonicalSkillActiveEntry, WorkflowHudSummary } from "../skill-state/active-state";
|
|
2
3
|
import { type GjcWorkflowSkill } from "./skill-keywords";
|
|
3
4
|
export declare const GJC_STATE_DIR = ".gjc/state";
|
|
4
5
|
export declare const SKILL_ACTIVE_STATE_FILE = "skill-active-state.json";
|
|
@@ -13,7 +14,7 @@ export interface SkillKeywordMatch {
|
|
|
13
14
|
skill: GjcWorkflowSkill;
|
|
14
15
|
priority: number;
|
|
15
16
|
}
|
|
16
|
-
export interface SkillActiveEntry {
|
|
17
|
+
export interface SkillActiveEntry extends Omit<CanonicalSkillActiveEntry, "skill"> {
|
|
17
18
|
skill: GjcWorkflowSkill;
|
|
18
19
|
phase?: string;
|
|
19
20
|
active?: boolean;
|
|
@@ -22,6 +23,8 @@ export interface SkillActiveEntry {
|
|
|
22
23
|
session_id?: string;
|
|
23
24
|
thread_id?: string;
|
|
24
25
|
turn_id?: string;
|
|
26
|
+
hud?: WorkflowHudSummary;
|
|
27
|
+
stale?: boolean;
|
|
25
28
|
}
|
|
26
29
|
export interface SkillActiveState {
|
|
27
30
|
version: number;
|
|
@@ -5,6 +5,26 @@ import type { GjcModelAssignmentTargetId, ModelRegistry } from "../../config/mod
|
|
|
5
5
|
import { type ScopedModelSelection } from "../../config/model-resolver";
|
|
6
6
|
import type { Settings } from "../../config/settings";
|
|
7
7
|
type ScopedModelItem = ScopedModelSelection;
|
|
8
|
+
export interface ModelAssignmentPreset {
|
|
9
|
+
id: "openai-codex";
|
|
10
|
+
label: string;
|
|
11
|
+
description: string;
|
|
12
|
+
assignments: Partial<Record<GjcModelAssignmentTargetId, ThinkingLevel>>;
|
|
13
|
+
}
|
|
14
|
+
export type ModelSelectorSelection = {
|
|
15
|
+
kind: "assignment";
|
|
16
|
+
model: Model;
|
|
17
|
+
role: GjcModelAssignmentTargetId | null;
|
|
18
|
+
thinkingLevel?: ThinkingLevel;
|
|
19
|
+
selector?: string;
|
|
20
|
+
} | {
|
|
21
|
+
kind: "preset";
|
|
22
|
+
model: Model;
|
|
23
|
+
selector: string;
|
|
24
|
+
preset: ModelAssignmentPreset;
|
|
25
|
+
assignments: Record<GjcModelAssignmentTargetId, ThinkingLevel>;
|
|
26
|
+
};
|
|
27
|
+
type RoleSelectCallback = (selection: ModelSelectorSelection) => void;
|
|
8
28
|
/**
|
|
9
29
|
* Component that renders a canonical model selector with provider tabs.
|
|
10
30
|
* - Tab/Arrow Left/Right: Switch between provider tabs
|
|
@@ -14,7 +34,7 @@ type ScopedModelItem = ScopedModelSelection;
|
|
|
14
34
|
*/
|
|
15
35
|
export declare class ModelSelectorComponent extends Container {
|
|
16
36
|
#private;
|
|
17
|
-
constructor(tui: TUI, _currentModel: Model | undefined, settings: Settings, modelRegistry: ModelRegistry, scopedModels: ReadonlyArray<ScopedModelItem>, onSelect:
|
|
37
|
+
constructor(tui: TUI, _currentModel: Model | undefined, settings: Settings, modelRegistry: ModelRegistry, scopedModels: ReadonlyArray<ScopedModelItem>, onSelect: RoleSelectCallback, onCancel: () => void, options?: {
|
|
18
38
|
temporaryOnly?: boolean;
|
|
19
39
|
initialSearchInput?: string;
|
|
20
40
|
});
|
|
@@ -2,6 +2,21 @@ export declare const SKILL_ACTIVE_STATE_FILE = "skill-active-state.json";
|
|
|
2
2
|
export declare const SKILL_ACTIVE_STALE_MS: number;
|
|
3
3
|
export declare const CANONICAL_GJC_WORKFLOW_SKILLS: readonly ["deep-interview", "ralplan", "ultragoal", "team"];
|
|
4
4
|
export type CanonicalGjcWorkflowSkill = (typeof CANONICAL_GJC_WORKFLOW_SKILLS)[number];
|
|
5
|
+
export type WorkflowHudSeverity = "info" | "warning" | "blocked" | "error" | "success";
|
|
6
|
+
export interface WorkflowHudChip {
|
|
7
|
+
label: string;
|
|
8
|
+
value?: string;
|
|
9
|
+
priority?: number;
|
|
10
|
+
severity?: WorkflowHudSeverity;
|
|
11
|
+
}
|
|
12
|
+
export interface WorkflowHudSummary {
|
|
13
|
+
version: 1;
|
|
14
|
+
summary?: string;
|
|
15
|
+
chips?: WorkflowHudChip[];
|
|
16
|
+
details?: WorkflowHudChip[];
|
|
17
|
+
severity?: WorkflowHudSeverity;
|
|
18
|
+
updated_at?: string;
|
|
19
|
+
}
|
|
5
20
|
export interface SkillActiveEntry {
|
|
6
21
|
skill: string;
|
|
7
22
|
phase?: string;
|
|
@@ -11,6 +26,8 @@ export interface SkillActiveEntry {
|
|
|
11
26
|
session_id?: string;
|
|
12
27
|
thread_id?: string;
|
|
13
28
|
turn_id?: string;
|
|
29
|
+
hud?: WorkflowHudSummary;
|
|
30
|
+
stale?: boolean;
|
|
14
31
|
}
|
|
15
32
|
export interface SkillActiveState {
|
|
16
33
|
version?: number;
|
|
@@ -41,7 +58,9 @@ export interface SyncSkillActiveStateOptions {
|
|
|
41
58
|
turnId?: string;
|
|
42
59
|
nowIso?: string;
|
|
43
60
|
source?: string;
|
|
61
|
+
hud?: WorkflowHudSummary;
|
|
44
62
|
}
|
|
63
|
+
export declare function normalizeWorkflowHudSummary(raw: unknown): WorkflowHudSummary | undefined;
|
|
45
64
|
export declare function isCanonicalGjcWorkflowSkill(skill: string): skill is CanonicalGjcWorkflowSkill;
|
|
46
65
|
export declare function listActiveSkills(raw: unknown): SkillActiveEntry[];
|
|
47
66
|
export declare function normalizeSkillActiveState(raw: unknown): SkillActiveState | null;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import type { WorkflowHudSummary } from "./active-state";
|
|
2
|
+
interface DeepInterviewHudState {
|
|
3
|
+
phase?: string;
|
|
4
|
+
ambiguity?: number;
|
|
5
|
+
threshold?: number;
|
|
6
|
+
roundCount?: number;
|
|
7
|
+
targetComponent?: string;
|
|
8
|
+
weakestDimension?: string;
|
|
9
|
+
specStatus?: string;
|
|
10
|
+
updatedAt?: string;
|
|
11
|
+
}
|
|
12
|
+
interface RalplanHudState {
|
|
13
|
+
stage?: string;
|
|
14
|
+
waiting?: string;
|
|
15
|
+
iteration?: number;
|
|
16
|
+
verdict?: string;
|
|
17
|
+
latestSummary?: string;
|
|
18
|
+
pendingApproval?: boolean;
|
|
19
|
+
updatedAt?: string;
|
|
20
|
+
}
|
|
21
|
+
interface UltragoalLikeGoal {
|
|
22
|
+
id: string;
|
|
23
|
+
title: string;
|
|
24
|
+
status: string;
|
|
25
|
+
}
|
|
26
|
+
interface UltragoalHudState {
|
|
27
|
+
status: string;
|
|
28
|
+
currentGoal?: UltragoalLikeGoal;
|
|
29
|
+
counts: Record<string, number>;
|
|
30
|
+
goals: UltragoalLikeGoal[];
|
|
31
|
+
latestLedgerEvent?: {
|
|
32
|
+
event?: string;
|
|
33
|
+
goalId?: string;
|
|
34
|
+
timestamp?: string;
|
|
35
|
+
};
|
|
36
|
+
updatedAt?: string;
|
|
37
|
+
}
|
|
38
|
+
interface TeamHudWorker {
|
|
39
|
+
id: string;
|
|
40
|
+
status?: string;
|
|
41
|
+
}
|
|
42
|
+
interface TeamHudState {
|
|
43
|
+
phase: string;
|
|
44
|
+
task_total: number;
|
|
45
|
+
task_counts: Record<string, number>;
|
|
46
|
+
workers: TeamHudWorker[];
|
|
47
|
+
updated_at?: string;
|
|
48
|
+
latestEvent?: {
|
|
49
|
+
type?: string;
|
|
50
|
+
worker?: string;
|
|
51
|
+
message?: string;
|
|
52
|
+
};
|
|
53
|
+
latestMessage?: {
|
|
54
|
+
from_worker?: string;
|
|
55
|
+
body?: string;
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
export declare function buildDeepInterviewHudSummary(state: DeepInterviewHudState): WorkflowHudSummary;
|
|
59
|
+
export declare function buildRalplanHudSummary(state: RalplanHudState): WorkflowHudSummary;
|
|
60
|
+
export declare function buildUltragoalHudSummary(state: UltragoalHudState): WorkflowHudSummary;
|
|
61
|
+
export declare function buildTeamHudSummary(state: TeamHudState): WorkflowHudSummary;
|
|
62
|
+
export {};
|
|
@@ -2,6 +2,7 @@ import type { BuiltinSlashCommand, ParsedSlashCommand, SlashCommandResult, Slash
|
|
|
2
2
|
export type { BuiltinSlashCommand, SubcommandDef } from "./types";
|
|
3
3
|
/** TUI-specific runtime accepted by `executeBuiltinSlashCommand`. */
|
|
4
4
|
export type BuiltinSlashCommandRuntime = TuiSlashCommandRuntime;
|
|
5
|
+
export declare function formatUnknownBuiltinSlashCommandDiagnostic(commandName: string): string | undefined;
|
|
5
6
|
/** Builtin command metadata used for slash-command autocomplete and help text. */
|
|
6
7
|
export declare const BUILTIN_SLASH_COMMAND_DEFS: ReadonlyArray<BuiltinSlashCommand>;
|
|
7
8
|
/**
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"type": "module",
|
|
3
3
|
"name": "@gajae-code/coding-agent",
|
|
4
|
-
"version": "0.1
|
|
4
|
+
"version": "0.2.1",
|
|
5
5
|
"description": "Gajae Code CLI with read, bash, edit, write tools and session management",
|
|
6
6
|
"homepage": "https://gaebal-gajae.dev",
|
|
7
7
|
"author": "Yeachan-Heo",
|
|
@@ -48,12 +48,12 @@
|
|
|
48
48
|
"@agentclientprotocol/sdk": "0.21.0",
|
|
49
49
|
"@babel/parser": "^7.29.3",
|
|
50
50
|
"@mozilla/readability": "^0.6.0",
|
|
51
|
-
"@gajae-code/stats": "0.1
|
|
52
|
-
"@gajae-code/agent-core": "0.1
|
|
53
|
-
"@gajae-code/ai": "0.1
|
|
54
|
-
"@gajae-code/natives": "0.1
|
|
55
|
-
"@gajae-code/tui": "0.1
|
|
56
|
-
"@gajae-code/utils": "0.1
|
|
51
|
+
"@gajae-code/stats": "0.2.1",
|
|
52
|
+
"@gajae-code/agent-core": "0.2.1",
|
|
53
|
+
"@gajae-code/ai": "0.2.1",
|
|
54
|
+
"@gajae-code/natives": "0.2.1",
|
|
55
|
+
"@gajae-code/tui": "0.2.1",
|
|
56
|
+
"@gajae-code/utils": "0.2.1",
|
|
57
57
|
"@puppeteer/browsers": "^2.13.0",
|
|
58
58
|
"@types/turndown": "5.0.6",
|
|
59
59
|
"@xterm/headless": "^6.0.0",
|
package/src/cli/args.ts
CHANGED
|
@@ -55,6 +55,15 @@ export interface Args {
|
|
|
55
55
|
unknownFlags: Map<string, boolean | string>;
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
+
function isStartupSlashCommandArg(arg: string | undefined): boolean {
|
|
59
|
+
return (
|
|
60
|
+
arg === "/provider" ||
|
|
61
|
+
arg?.startsWith("/provider:") === true ||
|
|
62
|
+
arg === "/provicer" ||
|
|
63
|
+
arg?.startsWith("/provicer:") === true
|
|
64
|
+
);
|
|
65
|
+
}
|
|
66
|
+
|
|
58
67
|
export function parseArgs(args: string[]): Args {
|
|
59
68
|
const result: Args = {
|
|
60
69
|
messages: [],
|
|
@@ -65,6 +74,11 @@ export function parseArgs(args: string[]): Args {
|
|
|
65
74
|
for (let i = 0; i < args.length; i++) {
|
|
66
75
|
let arg = args[i];
|
|
67
76
|
|
|
77
|
+
if (isStartupSlashCommandArg(arg)) {
|
|
78
|
+
result.messages.push(args.slice(i).join(" "));
|
|
79
|
+
break;
|
|
80
|
+
}
|
|
81
|
+
|
|
68
82
|
// Support --flag=value syntax (e.g. --tools=ask,read)
|
|
69
83
|
if (arg.startsWith("--") && arg.includes("=")) {
|
|
70
84
|
const eqIdx = arg.indexOf("=");
|