@jkwd/inbase 0.1.9 → 0.1.11
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/LICENSE +21 -0
- package/README.md +23 -7
- package/apps/explorer/package.json +1 -0
- package/apps/explorer/scripts/branch-changes.d.ts +24 -0
- package/apps/explorer/scripts/branch-changes.mjs +237 -0
- package/apps/explorer/scripts/js-source.mjs +12 -15
- package/apps/explorer/scripts/patch-lib.d.ts +6 -0
- package/apps/explorer/scripts/patch-lib.mjs +6 -0
- package/apps/explorer/scripts/scan-target.mjs +46 -13
- package/apps/explorer/scripts/session-store.d.ts +64 -1
- package/apps/explorer/scripts/session-store.mjs +369 -88
- package/apps/explorer/scripts/tree-diff.mjs +121 -0
- package/apps/explorer/src/App.tsx +215 -86
- package/apps/explorer/src/agentIntent.ts +78 -0
- package/apps/explorer/src/branchChanges.ts +54 -0
- package/apps/explorer/src/index.css +152 -10
- package/apps/explorer/src/scene/FileBlock.tsx +55 -5
- package/apps/explorer/src/types.ts +46 -0
- package/apps/explorer/src/ui/HUD.tsx +670 -158
- package/apps/explorer/src/userContext.ts +11 -0
- package/apps/explorer/vite.config.ts +65 -5
- package/bin/inbase.mjs +23 -4
- package/bin/project.mjs +62 -4
- package/bin/session.mjs +215 -125
- package/package.json +20 -2
- package/skill/commands/inbase.md +17 -0
- package/skill/commands/skipinbase.md +9 -0
- package/skill/inbase/SKILL.md +142 -89
|
@@ -20,6 +20,7 @@ export type DiffEntry = {
|
|
|
20
20
|
export type DiffManifest = {
|
|
21
21
|
version: number
|
|
22
22
|
sessionId: string
|
|
23
|
+
name: string
|
|
23
24
|
feature: string
|
|
24
25
|
steps: Array<{ index: number; title: string }>
|
|
25
26
|
status: 'active' | 'finished' | 'rejected'
|
|
@@ -33,9 +34,11 @@ export type DiffManifest = {
|
|
|
33
34
|
| 'replanning'
|
|
34
35
|
| 'finished'
|
|
35
36
|
| 'stopped'
|
|
37
|
+
awaitingAttach?: boolean
|
|
36
38
|
currentStep: number
|
|
37
39
|
activeDiffId: string | null
|
|
38
40
|
pendingInstruction: string | null
|
|
41
|
+
initialInstruction?: string | null
|
|
39
42
|
workStartedAt: string | null
|
|
40
43
|
stepByStep: boolean
|
|
41
44
|
createdAt: string
|
|
@@ -46,7 +49,27 @@ export type DiffManifest = {
|
|
|
46
49
|
export function assertSessionId(value: unknown): string
|
|
47
50
|
export function readActiveSession(dataDir: string): string | null
|
|
48
51
|
export function writeActiveSession(dataDir: string, sessionId: string | null): void
|
|
52
|
+
export function focusSession(dataDir: string, sessionId: string): string
|
|
53
|
+
export function sessionPaths(
|
|
54
|
+
dataDir: string,
|
|
55
|
+
sessionId: string,
|
|
56
|
+
): {
|
|
57
|
+
root: string
|
|
58
|
+
diffs: string
|
|
59
|
+
manifest: string
|
|
60
|
+
blueprint: string
|
|
61
|
+
baseline: string
|
|
62
|
+
baselineFiles: string
|
|
63
|
+
preStep: string
|
|
64
|
+
stopped: string
|
|
65
|
+
}
|
|
49
66
|
export function touchSessionConnection(dataDir: string, sessionId: string): void
|
|
67
|
+
export function recordSessionAck(
|
|
68
|
+
dataDir: string,
|
|
69
|
+
sessionId: string,
|
|
70
|
+
kind: string,
|
|
71
|
+
detail?: string,
|
|
72
|
+
): { kind: string; detail: string; at: string } | null
|
|
50
73
|
export function isSessionConnected(
|
|
51
74
|
dataDir: string,
|
|
52
75
|
sessionId: string,
|
|
@@ -62,6 +85,10 @@ export function discardInactiveDiffSessions(
|
|
|
62
85
|
targetRoot?: string | null,
|
|
63
86
|
waiterIds?: Iterable<string>,
|
|
64
87
|
): string[]
|
|
88
|
+
export function recoverOpenDiffSessions(
|
|
89
|
+
dataDir: string,
|
|
90
|
+
targetRoot?: string | null,
|
|
91
|
+
): string[]
|
|
65
92
|
export function clearDiffSessions(
|
|
66
93
|
dataDir: string,
|
|
67
94
|
targetRoot?: string | null,
|
|
@@ -81,9 +108,28 @@ export function startSession(
|
|
|
81
108
|
dataDir: string,
|
|
82
109
|
input: {
|
|
83
110
|
sessionId: string
|
|
111
|
+
name?: string
|
|
84
112
|
feature?: string
|
|
85
113
|
},
|
|
86
114
|
): DiffManifest
|
|
115
|
+
export function setupSession(
|
|
116
|
+
dataDir: string,
|
|
117
|
+
input?: {
|
|
118
|
+
sessionId?: string
|
|
119
|
+
name?: string
|
|
120
|
+
feature?: string
|
|
121
|
+
},
|
|
122
|
+
): DiffManifest
|
|
123
|
+
export function attachSession(
|
|
124
|
+
dataDir: string,
|
|
125
|
+
sessionId?: string | null,
|
|
126
|
+
): DiffManifest
|
|
127
|
+
export function setInitialInstruction(
|
|
128
|
+
dataDir: string,
|
|
129
|
+
sessionId: string,
|
|
130
|
+
instruction: string | null | undefined,
|
|
131
|
+
): DiffManifest
|
|
132
|
+
export function readAttachedSession(dataDir: string): string | null
|
|
87
133
|
export type SessionBlueprint = {
|
|
88
134
|
enabled: boolean
|
|
89
135
|
sent: boolean
|
|
@@ -127,12 +173,18 @@ export function sendBlueprint(
|
|
|
127
173
|
addedImports?: unknown[]
|
|
128
174
|
},
|
|
129
175
|
): DiffManifest
|
|
176
|
+
export function maybeStartVisualizerHandshake(
|
|
177
|
+
dataDir: string,
|
|
178
|
+
sessionId: string,
|
|
179
|
+
): DiffManifest
|
|
130
180
|
export function reportPlan(
|
|
131
181
|
dataDir: string,
|
|
132
182
|
input: {
|
|
133
183
|
sessionId: string
|
|
184
|
+
name?: string
|
|
134
185
|
feature: string
|
|
135
186
|
stepTitles: string[]
|
|
187
|
+
targetRoot?: string | null
|
|
136
188
|
},
|
|
137
189
|
): DiffManifest
|
|
138
190
|
export function isStepByStep(manifest: DiffManifest | null | undefined): boolean
|
|
@@ -181,6 +233,16 @@ export function materializeDiff(
|
|
|
181
233
|
sessionId: string,
|
|
182
234
|
diffId?: string | null,
|
|
183
235
|
): DiffManifest
|
|
236
|
+
export function snapshotPreStep(
|
|
237
|
+
dataDir: string,
|
|
238
|
+
sessionId: string,
|
|
239
|
+
targetRoot: string,
|
|
240
|
+
): string
|
|
241
|
+
export function readLiveDiff(
|
|
242
|
+
dataDir: string,
|
|
243
|
+
sessionId: string,
|
|
244
|
+
targetRoot: string,
|
|
245
|
+
): string
|
|
184
246
|
export function inspectTargetFile(
|
|
185
247
|
dataDir: string,
|
|
186
248
|
targetRoot: string,
|
|
@@ -195,7 +257,7 @@ export function appendDiff(
|
|
|
195
257
|
targetRoot: string,
|
|
196
258
|
input: {
|
|
197
259
|
sessionId: string
|
|
198
|
-
patchText
|
|
260
|
+
patchText?: string
|
|
199
261
|
},
|
|
200
262
|
): { manifest: DiffManifest; entry: DiffEntry }
|
|
201
263
|
export function continueDiff(
|
|
@@ -209,6 +271,7 @@ export function requestReplan(
|
|
|
209
271
|
sessionId: string,
|
|
210
272
|
diffId: string,
|
|
211
273
|
instruction: string,
|
|
274
|
+
targetRoot?: string | null,
|
|
212
275
|
): DiffManifest
|
|
213
276
|
export function stopSession(
|
|
214
277
|
dataDir: string,
|