fix: add Agent Teams types to types.ts, remove unused server imports

This commit is contained in:
arkon
2026-02-12 14:42:58 +01:00
parent e44f827473
commit cdc822d657
2 changed files with 44 additions and 4 deletions
+41
View File
@@ -1536,3 +1536,44 @@ export interface PaneInfo {
// ========== Plan Orchestrator Re-exports ==========
export type { PlanItem } from './plan-orchestrator.js';
// ========== Agent Teams Types ==========
/** Team configuration from ~/.claude/teams/{name}/config.json */
export interface TeamConfig {
name: string;
leadSessionId: string;
members: TeamMember[];
}
/** A single team member (lead or teammate) */
export interface TeamMember {
agentId: string;
name: string;
agentType: 'team-lead' | 'general-purpose' | string;
color?: string;
backendType?: string;
prompt?: string;
tmuxPaneId?: string;
}
/** A task from ~/.claude/tasks/{team-name}/{N}.json */
export interface TeamTask {
id: string;
subject: string;
description?: string;
activeForm?: string;
status: 'pending' | 'in_progress' | 'completed' | string;
blocks: string[];
blockedBy: string[];
owner?: string;
metadata?: Record<string, unknown>;
}
/** An inbox message from ~/.claude/teams/{name}/inboxes/{member}.json */
export interface InboxMessage {
from: string;
text: string;
timestamp: string;
read?: boolean;
}
+3 -4
View File
@@ -14,16 +14,15 @@ import Fastify, { FastifyInstance, FastifyReply } from 'fastify';
import fastifyStatic from '@fastify/static';
import path, { join, dirname, resolve, relative, isAbsolute } from 'node:path';
import { fileURLToPath } from 'node:url';
import { existsSync, mkdirSync, mkdtempSync, writeFileSync, readdirSync, readFileSync, rmSync, unlinkSync } from 'node:fs';
import { existsSync, mkdirSync, writeFileSync, readdirSync, readFileSync, rmSync } from 'node:fs';
import fs from 'node:fs/promises';
import { execSync, spawn, type ChildProcess } from 'node:child_process';
import { homedir, tmpdir, totalmem, freemem, loadavg, cpus } from 'node:os';
import { execSync } from 'node:child_process';
import { homedir, totalmem, freemem, loadavg, cpus } from 'node:os';
import { EventEmitter } from 'node:events';
import { Session, ClaudeMessage, type BackgroundTask, type RalphTrackerState, type RalphTodoItem, type ActiveBashTool } from '../session.js';
import { fileStreamManager } from '../file-stream-manager.js';
import { RespawnController, RespawnConfig, RespawnState } from '../respawn-controller.js';
import type { TerminalMultiplexer } from '../mux-interface.js';
import { TmuxManager } from '../tmux-manager.js';
import { createMultiplexer } from '../mux-factory.js';
import { getStore } from '../state-store.js';
import { generateClaudeMd } from '../templates/claude-md.js';