feat(rah-light): remove agent delegation system

- Delete src/services/agents/delegation.ts (AgentDelegationService)
- Delete app/api/rah/delegations/ directory (all routes)
- Delete src/components/agents/DelegationIndicator.tsx
- Update workflowExecutor.ts to work without delegation streaming
- Update executeWorkflow.ts tool to execute workflows directly
- Update quickAdd.ts to execute directly without delegation tracking
- Add stub AgentDelegation types to UI components for compatibility
- Add stub voice hooks to RAHChat.tsx (will be removed in story 2)

Files deleted:
- src/services/agents/delegation.ts
- app/api/rah/delegations/route.ts
- app/api/rah/delegations/stream/route.ts
- app/api/rah/delegations/[sessionId]/route.ts
- app/api/rah/delegations/[sessionId]/summary/route.ts
- src/components/agents/DelegationIndicator.tsx

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
“BeeRad”
2026-01-29 15:11:15 +11:00
co-authored by Claude Opus 4.5
parent 08012a8e5a
commit 6b7bb5a5f9
19 changed files with 234 additions and 819 deletions
+1 -2
View File
@@ -3,8 +3,7 @@
import { useState, useCallback, useEffect, useMemo } from 'react';
import RAHChat from '@/components/agents/RAHChat';
import PaneHeader from './PaneHeader';
import { WorkflowsPaneProps, PaneType } from './types';
import type { AgentDelegation } from '@/services/agents/delegation';
import { WorkflowsPaneProps, PaneType, AgentDelegation } from './types';
import { parseAndRenderContent } from '@/components/helpers/NodeLabelRenderer';
import type { ChatMessage } from '@/components/agents/hooks/useSSEChat';
+13 -1
View File
@@ -1,6 +1,18 @@
import React from 'react';
import { Node } from '@/types/database';
import type { AgentDelegation } from '@/services/agents/delegation';
// Stub type for delegation (delegation system removed in rah-light)
export type AgentDelegation = {
id: number;
sessionId: string;
task: string;
context: string[];
status: 'queued' | 'in_progress' | 'completed' | 'failed';
summary?: string | null;
agentType: string;
createdAt: string;
updatedAt: string;
};
// The six pane types
export type PaneType = 'node' | 'chat' | 'workflows' | 'dimensions' | 'map' | 'views';