Conversation
📝 WalkthroughWalkthroughThis pull request introduces an in-memory agent workspace management system. It defines TypeScript types and interfaces for workspace data structures, implements an AgentWorkspaceManager class with CRUD and lifecycle operations, integrates the manager into the dependency injection container, and exposes public IPC-based APIs for renderer process communication. Includes comprehensive test coverage for all manager functionality. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Tip Try Coding Plans. Let us write the prompt for your AI agent so you can ship faster (with fewer bugs). Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🧹 Nitpick comments (2)
packages/main/src/plugin/agent-workspace/agent-workspace-manager.spec.ts (1)
110-177: Add one malformed-input test forcreate()to lock runtime validation behavior.Given IPC inputs are runtime values, include a negative test (casted invalid payload) to prevent regressions once validation is added.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@packages/main/src/plugin/agent-workspace/agent-workspace-manager.spec.ts` around lines 110 - 177, Add a negative unit test in the existing "create" describe block that calls manager.create with a clearly malformed payload (e.g., { name: 123, agent: null } cast through unknown/any) and assert the call throws (or rejects) to lock current runtime validation behavior; reference manager.create in the test (name it like 'rejects malformed input') and use the same test harness expectations pattern (expect(() => manager.create(badPayload)).toThrow()) so the CI will catch future regressions when runtime validation changes.packages/main/src/plugin/agent-workspace/agent-workspace-manager.ts (1)
182-213: Makeinit()idempotent to avoid duplicate IPC handler registration.A second
init()call can register handlers again. Add a lightweight init guard to keep lifecycle safe.♻️ Proposed lifecycle guard
init(): void { + if (this.#initialized) { + return; + } + this.#initialized = true; + for (const ws of this.loadWorkspaces()) { this.#workspaces.set(ws.id, ws); } @@ `@preDestroy`() dispose(): void { + this.#initialized = false; this.#workspaces.clear(); }Also applies to: 215-218
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@packages/main/src/plugin/agent-workspace/agent-workspace-manager.ts` around lines 182 - 213, The init() method currently registers IPC handlers every call which can lead to duplicates; add a lightweight idempotency guard (e.g., a private boolean like this.#inited) checked at the start of init() that returns immediately if already true, and set the flag to true after handlers are registered; apply the same guard pattern to the analogous initialization block around the other IPC registrations referenced (lines 215-218) so each handler is only registered once (reference symbols: init(), ipcHandle, and the new private flag name such as `#inited`).
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@packages/main/src/plugin/agent-workspace/agent-workspace-manager.ts`:
- Around line 109-126: The create() method currently trusts the runtime IPC
payload shaped as AgentWorkspaceCreateOptions; add explicit runtime validation
at the start of AgentWorkspaceManager.create() to guard against malformed inputs
(validate required fields like options.name and options.agent are present and of
correct type, whitelist fileAccess values, ensure model is valid or replace via
getDefaultModel(options.agent), validate workingDirectory is a non-empty string,
ensure skills and mcpServers are arrays and customPaths if present is an
object/array), and throw a clear error (or return a rejected result) when
validation fails before constructing the AgentWorkspaceInfo; use existing
helpers getDefaultModel() and getContextWindowSize(model) to normalize/derive
model and contextUsage after validation.
In `@packages/preload/src/index.ts`:
- Around line 409-435: The generated preload type declarations are missing the
six Agent Workspace APIs exposed via contextBridge in index.ts; update the
preload type generation so packages/preload/exposedInMainWorld.d.ts includes
type signatures for listAgentWorkspaces, getAgentWorkspace,
createAgentWorkspace, startAgentWorkspace, stopAgentWorkspace, and
deleteAgentWorkspace (matching AgentWorkspaceInfo and
AgentWorkspaceCreateOptions types). Modify the type-generation entry (the code
that emits exposedInMainWorld.d.ts) to pick up the new exports from
packages/preload/src/index.ts and then run/verify the build task (pnpm run
build:preload:types) to ensure the file is created and contains the exact method
signatures exposedInMainWorld expects.
---
Nitpick comments:
In `@packages/main/src/plugin/agent-workspace/agent-workspace-manager.spec.ts`:
- Around line 110-177: Add a negative unit test in the existing "create"
describe block that calls manager.create with a clearly malformed payload (e.g.,
{ name: 123, agent: null } cast through unknown/any) and assert the call throws
(or rejects) to lock current runtime validation behavior; reference
manager.create in the test (name it like 'rejects malformed input') and use the
same test harness expectations pattern (expect(() =>
manager.create(badPayload)).toThrow()) so the CI will catch future regressions
when runtime validation changes.
In `@packages/main/src/plugin/agent-workspace/agent-workspace-manager.ts`:
- Around line 182-213: The init() method currently registers IPC handlers every
call which can lead to duplicates; add a lightweight idempotency guard (e.g., a
private boolean like this.#inited) checked at the start of init() that returns
immediately if already true, and set the flag to true after handlers are
registered; apply the same guard pattern to the analogous initialization block
around the other IPC registrations referenced (lines 215-218) so each handler is
only registered once (reference symbols: init(), ipcHandle, and the new private
flag name such as `#inited`).
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: dce63b9b-a0df-432f-afd0-177b7429a85d
📒 Files selected for processing (5)
packages/api/src/agent-workspace-info.tspackages/main/src/plugin/agent-workspace/agent-workspace-manager.spec.tspackages/main/src/plugin/agent-workspace/agent-workspace-manager.tspackages/main/src/plugin/index.tspackages/preload/src/index.ts
| create(options: AgentWorkspaceCreateOptions): AgentWorkspaceInfo { | ||
| const model = options.model ?? this.getDefaultModel(options.agent); | ||
| const workspace: AgentWorkspaceInfo = { | ||
| id: randomUUID(), | ||
| name: options.name, | ||
| description: options.description ?? '', | ||
| agent: options.agent, | ||
| model, | ||
| status: 'stopped', | ||
| workingDirectory: options.workingDirectory ?? '.', | ||
| contextUsage: { used: 0, total: this.getContextWindowSize(model) }, | ||
| resources: { | ||
| skills: options.skills ?? [], | ||
| mcpServers: options.mcpServers ?? [], | ||
| }, | ||
| fileAccess: options.fileAccess ?? 'workspace', | ||
| customPaths: options.customPaths, | ||
| stats: { messages: 0, toolCalls: 0, filesModified: 0, linesChanged: 0 }, |
There was a problem hiding this comment.
Validate create() IPC payloads at runtime before building workspace state.
AgentWorkspaceCreateOptions is compile-time only; malformed runtime payloads can still pass through IPC and create inconsistent objects (for example invalid agent / fileAccess combinations). Add explicit runtime guards in create().
🔒 Proposed defensive validation patch
export class AgentWorkspaceManager implements Disposable {
`#workspaces`: Map<string, AgentWorkspaceInfo> = new Map();
+ `#initialized` = false;
+
+ private readonly allowedAgents = new Set(['claude', 'cursor', 'goose']);
+ private readonly allowedFileAccess = new Set(['workspace', 'home', 'custom', 'full']);
@@
create(options: AgentWorkspaceCreateOptions): AgentWorkspaceInfo {
+ if (!this.allowedAgents.has(options.agent)) {
+ throw new Error(`Unsupported agent type: ${String(options.agent)}`);
+ }
+
+ const fileAccess = options.fileAccess ?? 'workspace';
+ if (!this.allowedFileAccess.has(fileAccess)) {
+ throw new Error(`Unsupported file access level: ${String(fileAccess)}`);
+ }
+ if (fileAccess === 'custom' && (!options.customPaths || options.customPaths.length === 0)) {
+ throw new Error('customPaths is required when fileAccess is "custom"');
+ }
+
const model = options.model ?? this.getDefaultModel(options.agent);
const workspace: AgentWorkspaceInfo = {
@@
- fileAccess: options.fileAccess ?? 'workspace',
- customPaths: options.customPaths,
+ fileAccess,
+ customPaths: fileAccess === 'custom' ? options.customPaths : undefined,
stats: { messages: 0, toolCalls: 0, filesModified: 0, linesChanged: 0 },
createdAt: new Date().toISOString(),
};Also applies to: 162-170
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@packages/main/src/plugin/agent-workspace/agent-workspace-manager.ts` around
lines 109 - 126, The create() method currently trusts the runtime IPC payload
shaped as AgentWorkspaceCreateOptions; add explicit runtime validation at the
start of AgentWorkspaceManager.create() to guard against malformed inputs
(validate required fields like options.name and options.agent are present and of
correct type, whitelist fileAccess values, ensure model is valid or replace via
getDefaultModel(options.agent), validate workingDirectory is a non-empty string,
ensure skills and mcpServers are arrays and customPaths if present is an
object/array), and throw a clear error (or return a rejected result) when
validation fails before constructing the AgentWorkspaceInfo; use existing
helpers getDefaultModel() and getContextWindowSize(model) to normalize/derive
model and contextUsage after validation.
| // Agent Workspaces | ||
| contextBridge.exposeInMainWorld('listAgentWorkspaces', async (): Promise<AgentWorkspaceInfo[]> => { | ||
| return ipcInvoke('agent-workspace:list'); | ||
| }); | ||
|
|
||
| contextBridge.exposeInMainWorld('getAgentWorkspace', async (id: string): Promise<AgentWorkspaceInfo> => { | ||
| return ipcInvoke('agent-workspace:get', id); | ||
| }); | ||
|
|
||
| contextBridge.exposeInMainWorld( | ||
| 'createAgentWorkspace', | ||
| async (options: AgentWorkspaceCreateOptions): Promise<AgentWorkspaceInfo> => { | ||
| return ipcInvoke('agent-workspace:create', options); | ||
| }, | ||
| ); | ||
|
|
||
| contextBridge.exposeInMainWorld('startAgentWorkspace', async (id: string): Promise<AgentWorkspaceInfo> => { | ||
| return ipcInvoke('agent-workspace:start', id); | ||
| }); | ||
|
|
||
| contextBridge.exposeInMainWorld('stopAgentWorkspace', async (id: string): Promise<AgentWorkspaceInfo> => { | ||
| return ipcInvoke('agent-workspace:stop', id); | ||
| }); | ||
|
|
||
| contextBridge.exposeInMainWorld('deleteAgentWorkspace', async (id: string): Promise<void> => { | ||
| return ipcInvoke('agent-workspace:delete', id); | ||
| }); |
There was a problem hiding this comment.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "Searching generated preload declaration files..."
fd 'exposedInMainWorld\.d\.ts$|preload.*\.d\.ts$' packages
echo
echo "Checking for new Agent Workspace API signatures..."
fd 'exposedInMainWorld\.d\.ts$|preload.*\.d\.ts$' packages | while read -r f; do
echo "== $f =="
rg -n "listAgentWorkspaces|getAgentWorkspace|createAgentWorkspace|startAgentWorkspace|stopAgentWorkspace|deleteAgentWorkspace" "$f" || true
doneRepository: kortex-hub/kortex
Length of output: 161
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Checking packages/preload directory structure ==="
ls -la packages/preload/ 2>/dev/null | head -20
echo
echo "=== Looking for ALL .d.ts files in packages ==="
fd '\.d\.ts$' packages | head -20
echo
echo "=== Searching for 'exposedInMainWorld' anywhere in codebase ==="
rg -l "exposedInMainWorld" packages --type ts --type tsx 2>/dev/null | head -10
echo
echo "=== Checking for type definitions in packages/preload/src ==="
ls -la packages/preload/src/ 2>/dev/nullRepository: kortex-hub/kortex
Length of output: 704
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Viewing packages/preload/src/index.ts ==="
wc -l packages/preload/src/index.ts
head -50 packages/preload/src/index.ts
echo
echo "=== Checking if there's a preload.d.ts or type definition anywhere ==="
rg "exposeInMainWorld" packages --type ts -A 2 | head -40
echo
echo "=== Looking at packages/renderer for preload type imports ==="
fd . packages/renderer/src -name "*.ts" -o -name "*.tsx" | xargs rg -l "preload|exposedInMainWorld" 2>/dev/null | head -5
echo
echo "=== Checking vite config for preload ==="
cat packages/preload/vite.config.jsRepository: kortex-hub/kortex
Length of output: 4798
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Finding `@kortex-app/api` package ==="
find . -name "@kortex-app" -o -name "api" | grep -E "packages|src" | head -20
echo
echo "=== Checking packages directory structure ==="
ls -la packages/
echo
echo "=== Searching for where window types are extended for preload ==="
rg "window\." packages --type ts -B 2 -A 2 | grep -E "listAgentWorkspaces|getAgentWorkspace|createAgentWorkspace|startAgentWorkspace|stopAgentWorkspace|deleteAgentWorkspace" -B 2 -A 2 || echo "No matches found"
echo
echo "=== Looking for type definitions in api package ==="
find packages -type d -name "*api*"Repository: kortex-hub/kortex
Length of output: 1248
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Checking packages/api structure ==="
find packages/api -type f | head -40
echo
echo "=== Searching for agent-workspace type definitions ==="
rg "AgentWorkspace" packages/api --type ts
echo
echo "=== Checking packages/api/src/index.ts or main export ==="
ls -la packages/api/src/
echo
echo "=== Looking for any window type augmentation ==="
rg "window\[|Window {|interface.*Window|declare global" packages/api --type ts -B 1 -A 3 | head -30Repository: kortex-hub/kortex
Length of output: 7400
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Checking packages/api/src/index.ts ==="
ls -la packages/api/src/index.ts 2>/dev/null || echo "No index.ts found"
echo
echo "=== Searching for window or preload interface in renderer ==="
rg "interface.*Preload\|declare.*window\|window:" packages/renderer --type ts -B 2 -A 5 | head -50
echo
echo "=== Looking for containerDesktopAPI or API type exports ==="
rg "export.*type\|export.*interface" packages/api/src/index.ts || echo "Checking if index.ts exists..."
echo
echo "=== Checking renderer/src for window augmentation ==="
find packages/renderer/src -name "*.ts" -o -name "*.tsx" | xargs rg "declare global\|window\." --max-count=5 2>/dev/null | head -40
echo
echo "=== Viewing agent-workspace-info.ts ==="
cat packages/api/src/agent-workspace-info.tsRepository: kortex-hub/kortex
Length of output: 184
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Checking packages/api root files ==="
ls -la packages/api/
echo
echo "=== Viewing agent-workspace-info.ts ==="
cat packages/api/src/agent-workspace-info.ts
echo
echo "=== Searching for containerDesktopAPI type definition ==="
rg "containerDesktopAPI\|type.*API\|interface.*API" packages --type ts | grep -v node_modules | head -20
echo
echo "=== Looking in packages/extension-api for type definitions ==="
cat packages/extension-api/src/extension-api.d.ts | head -100Repository: kortex-hub/kortex
Length of output: 2260
🏁 Script executed:
#!/bin/bash
set -euo pipefixpipe
echo "=== Viewing preload vite.config.js ==="
cat packages/preload/vite.config.js
echo
echo "=== Checking for any .d.ts generation in build config ==="
find packages -name "vite.config.js" -o -name "tsconfig.json" | xargs grep -l "dts\|declaration\|types" 2>/dev/null
echo
echo "=== Viewing packages/api vite.config.js ==="
cat packages/api/vite.config.js
echo
echo "=== Searching for window type augmentation in entire renderer package ==="
find packages/renderer/src -type f \( -name "*.ts" -o -name "*.tsx" \) | xargs grep -l "window" | head -5
echo
echo "=== Checking for types in renderer shim or env files ==="
cat packages/renderer/src/vite-env.d.ts 2>/dev/null || echo "No vite-env.d.ts"Repository: kortex-hub/kortex
Length of output: 117
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Viewing preload vite.config.js ==="
cat packages/preload/vite.config.js
echo
echo "=== Viewing packages/api vite.config.js ==="
cat packages/api/vite.config.js
echo
echo "=== Searching for window type augmentation in renderer ==="
find packages/renderer/src -type f \( -name "*.ts" -o -name "*.tsx" \) -exec grep -l "window" {} \; | head -5
echo
echo "=== Checking for types in renderer shim or env files ==="
cat packages/renderer/src/vite-env.d.ts 2>/dev/null || echo "No vite-env.d.ts"
echo
echo "=== Searching for preload API types anywhere in renderer ==="
rg "listAgentWorkspaces\|getAgentWorkspace\|createAgentWorkspace" packages/renderer --type tsRepository: kortex-hub/kortex
Length of output: 16484
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Searching for how renderer uses window properties ==="
rg "window\." packages/renderer/src --type ts --max-count=10
echo
echo "=== Looking for renderer main entry point ==="
find packages/renderer/src -name "main.ts" -o -name "App.svelte" -o -name "index.ts" | head -3
echo
echo "=== Checking if there are any .d.ts type declaration files in renderer ==="
find packages/renderer -name "*.d.ts"
echo
echo "=== Searching for preload imports in renderer ==="
rg "from.*preload\|import.*preload" packages/renderer --type ts
echo
echo "=== Checking tsconfig.json in renderer ==="
cat packages/renderer/tsconfig.json | grep -A 10 "types\|includes" || echo "No type config found"Repository: kortex-hub/kortex
Length of output: 50374
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Looking for global type declarations ==="
find packages -name "global.d.ts" -o -name "ambient.d.ts" -o -name "window.d.ts"
echo
echo "=== Searching for window interface extensions specifically ==="
rg "interface.*Window\|declare.*Window" packages --type ts -B 1 -A 5 | head -50
echo
echo "=== Checking preload package.json for types/exports ==="
cat packages/preload/package.json 2>/dev/null || echo "No package.json"
echo
echo "=== Looking in dist directories for generated types ==="
find packages -path "*/dist/*.d.ts" | head -10Repository: kortex-hub/kortex
Length of output: 169
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Checking preload package.json ==="
cat packages/preload/package.json
echo
echo "=== Looking for containerDesktopAPI type definition file ==="
rg "containerDesktopAPI\|declare.*type" packages/preload/src --type ts -B 2 -A 10 | head -80
echo
echo "=== Searching for ANY type declarations in the preload file around workspace methods ==="
sed -n '400,450p' packages/preload/src/index.tsRepository: kortex-hub/kortex
Length of output: 177
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Checking root package.json workspaces ==="
cat package.json | head -50
echo
echo "=== Looking at lines around 409-435 in preload index.ts ==="
sed -n '405,440p' packages/preload/src/index.ts
echo
echo "=== Searching for type declarations or interfaces that expose preload methods ==="
rg "listAgentWorkspaces\|getAgentWorkspace\|createAgentWorkspace\|startAgentWorkspace\|stopAgentWorkspace\|deleteAgentWorkspace" packages --type ts -B 2 -A 2
echo
echo "=== Looking for how containerDesktopAPI types are created ==="
rg "type.*containerDesktopAPI\|interface.*containerDesktopAPI" packages --type tsRepository: kortex-hub/kortex
Length of output: 5541
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Checking if exposedInMainWorld.d.ts exists ==="
ls -la packages/preload/exposedInMainWorld.d.ts 2>/dev/null || echo "File does not exist"
echo
echo "=== Checking what dts-cb tool is ==="
rg "dts-cb" . --type json | head -10
echo
echo "=== Looking at preload tsconfig.json ==="
cat packages/preload/tsconfig.json
echo
echo "=== Checking if there's any type generation in build outputs ==="
find . -path "./dist" -prune -o -name "exposedInMainWorld.d.ts" -type f -print 2>/dev/nullRepository: kortex-hub/kortex
Length of output: 1109
🏁 Script executed:
#!/bin/bash
set -euo pipefail
echo "=== Checking dts-cb package in package.json ==="
rg "dts-cb" . --type json -A 1 -B 1 | head -20
echo
echo "=== Checking if dts-cb is installed/available ==="
which dts-cb || echo "dts-cb not in PATH"
echo
echo "=== Verifying the 6 workspace methods are in preload source ==="
grep -n "listAgentWorkspaces\|getAgentWorkspace\|createAgentWorkspace\|startAgentWorkspace\|stopAgentWorkspace\|deleteAgentWorkspace" packages/preload/src/index.ts | head -10Repository: kortex-hub/kortex
Length of output: 1357
Ensure generated preload typings include the new Agent Workspace APIs.
The six workspace methods (listAgentWorkspaces, getAgentWorkspace, createAgentWorkspace, startAgentWorkspace, stopAgentWorkspace, deleteAgentWorkspace) are exposed at runtime via contextBridge.exposeInMainWorld() in packages/preload/src/index.ts, but the generated type declaration file (packages/preload/exposedInMainWorld.d.ts) does not currently exist. Renderer TypeScript consumers need these method signatures in the generated exposedInMainWorld.d.ts to access proper type definitions. Verify that running pnpm run build:preload:types generates this file with all six workspace method declarations included.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@packages/preload/src/index.ts` around lines 409 - 435, The generated preload
type declarations are missing the six Agent Workspace APIs exposed via
contextBridge in index.ts; update the preload type generation so
packages/preload/exposedInMainWorld.d.ts includes type signatures for
listAgentWorkspaces, getAgentWorkspace, createAgentWorkspace,
startAgentWorkspace, stopAgentWorkspace, and deleteAgentWorkspace (matching
AgentWorkspaceInfo and AgentWorkspaceCreateOptions types). Modify the
type-generation entry (the code that emits exposedInMainWorld.d.ts) to pick up
the new exports from packages/preload/src/index.ts and then run/verify the build
task (pnpm run build:preload:types) to ensure the file is created and contains
the exact method signatures exposedInMainWorld expects.
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
Signed-off-by: Marcel Bertagnini <mbertagn@redhat.com>
…en running stopping Signed-off-by: Marcel Bertagnini <mbertagn@redhat.com>
…ck file and align with CLI Signed-off-by: Marcel Bertagnini <mbertagn@redhat.com>
Signed-off-by: Marcel Bertagnini <mbertagn@redhat.com>
dd65415 to
184b147
Compare
|
Added 2 commits that:
|
|
|
||
| import type { components } from '@kortex-hub/kortex-cli-api'; | ||
|
|
||
| export type AgentType = 'claude' | 'cursor' | 'goose'; |
There was a problem hiding this comment.
IMHO it can't really be coded in the UI, I would guess the cli is giving the available supported providers
There was a problem hiding this comment.
Yes, you can have a mock for the moment, mocking kortex-cli workspace supported-agents or similar command (kortex-hub/kortex-cli#35)
There was a problem hiding this comment.
@benoitf Changed to have a getSupportedAgents function that will get supported agents from CLI
| skills: string[]; | ||
| mcpServers: string[]; | ||
| }; | ||
| createdAt?: string; |
There was a problem hiding this comment.
shouldn't it go first in the spec rather than diverging from the spec ?
There was a problem hiding this comment.
@benoitf Removed from the interface definition. Now the interface matches the CLI spec.
There was a problem hiding this comment.
@MarsKubeX but it's still part of
export interface AgentWorkspaceInfo extends AgentWorkspaceSummary, AgentWorkspaceStatus {
fileAccess?: FileAccessLevel;
customPaths?: string[];
stats?: {
messages: number;
toolCalls: number;
filesModified: number;
linesChanged: number;
};
}
I would expect that UI is not defining anything that is not provided by the CLI
…ynamic agent type Signed-off-by: Marcel Bertagnini <mbertagn@redhat.com>
Add a mock backend component to manage agent workspaces in memory, as a foundation for the Agentic Coding Workspaces feature.
The services added to the backend are:
All mutating operations emit an agent-workspace:updated event so the renderer can refresh the workspace list.
Added test unit for agent-workspace-manager.ts
Closes #1039