agent-team/web/src/types.ts
scorpio de773586c7 feat: implement full agent-team platform
Go backend:
- LLM client with DeepSeek/Kimi/Ollama/OpenAI support (OpenAI-compat)
- Agent loader: AGENT.md frontmatter, SOUL.md, memory read/write
- Skill system following agentskills.io standard
- Room orchestration: master assign→execute→review loop with streaming
- Hub: GitHub repo clone and team package install
- Echo HTTP server with WebSocket and full REST API

React frontend:
- Discord-style 3-panel layout with Tailwind v4
- Zustand store with WebSocket streaming message handling
- Chat view: streaming messages, role styles, right panel, drawer buttons
- Agent MD editor with Monaco Editor (AGENT.md + SOUL.md)
- Market page for GitHub team install/publish

Docs:
- plan.md with full progress tracking and next steps

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-04 21:57:46 +08:00

38 lines
919 B
TypeScript

export type RoomStatus = 'pending' | 'thinking' | 'working'
export type RoomType = 'dept' | 'leader'
export interface Room {
id: string
name: string
type: RoomType
status: RoomStatus
master: string
activeAgent?: string
action?: string
}
export interface Message {
id: string
agent: string
role: 'user' | 'master' | 'member'
content: string
streaming?: boolean
}
export interface AgentInfo {
name: string
}
export interface SkillMeta {
name: string
description: string
path: string
}
export type WsEvent =
| { type: 'agent_message'; agent: string; role: 'master' | 'member'; content: string; streaming: boolean }
| { type: 'room_status'; status: RoomStatus; active_agent?: string; action?: string }
| { type: 'task_assign'; from: string; to: string; task: string }
| { type: 'tasks_update'; content: string }
| { type: 'workspace_file'; filename: string; content: string }