콘텐츠로 이동

🗺️ 구조도

애드캐리 AI 캐리 운영 구조. 5 카테고리 × 5 HQ × 5 에이전트 분산 모델.


1. 카테고리 ↔ HQ ↔ 에이전트 (한눈에)

%%{init: {'theme':'base', 'themeVariables': {'fontSize':'15px','fontFamily':'Pretendard, sans-serif','primaryColor':'#EDE9FE','primaryTextColor':'#0F172A','primaryBorderColor':'#7C3AED','lineColor':'#94A3B8'}, 'flowchart':{'nodeSpacing':40,'rankSpacing':70,'padding':12}}}%% flowchart LR User([👤 장캐리·직원]):::user subgraph DC["💬 Discord 5 카테고리"] direction TB G1["🌎 글로벌셀링<br/>15 채널"]:::gs G2["🇰🇷 콘텐츠마케팅<br/>9 채널"]:::cm G3["💰 재무/지원<br/>8 채널"]:::fo G4["📊 경영<br/>2 채널"]:::mg G5["🧪 AI-LAB<br/>3 채널"]:::main end subgraph HQ["🦞 HQ 채널 (Opus)"] direction TB H1[#gs-hq]:::gs H2[#cm-hq]:::cm H3[#finance-hq]:::fo H4[#mgmt-hq]:::mg H5[#ai-lab-hq]:::main end subgraph Agents["🤖 에이전트 5"] direction TB A1[global-selling<br/>Sonnet·HQ만 Opus]:::gs A2[content-marketing<br/>Sonnet·HQ만 Opus]:::cm A3[finance-ops<br/>Sonnet·HQ만 Opus]:::fo A4[management<br/>Sonnet·HQ만 Opus]:::mg A5[main<br/>Sonnet·HQ만 Opus]:::main end User --> G1 & G2 & G3 & G4 & G5 G1 --> H1 G2 --> H2 G3 --> H3 G4 --> H4 G5 --> H5 H1 --> A1 H2 --> A2 H3 --> A3 H4 --> A4 H5 --> A5 classDef user fill:#0F172A,stroke:#0F172A,color:#fff classDef main fill:#EDE9FE,stroke:#7C3AED,color:#5B21B6 classDef cm fill:#FCE7F3,stroke:#DB2777,color:#831843 classDef gs fill:#CFFAFE,stroke:#0891B2,color:#155E75 classDef fo fill:#DCFCE7,stroke:#16A34A,color:#14532D classDef mg fill:#FEF3C7,stroke:#F59E0B,color:#78350F

핵심 사실

  • 카테고리 = 에이전트 1:1 매핑
  • HQ 채널 = 카테고리 게이트 (라우팅 안내·스킬 의뢰 접수·의사결정 박제)
  • HQ 채널만 Opus, 나머지 일반 채널은 Sonnet (modelByChannel 오버라이드)
  • 채널 owner agent 자율: AGENTS.local.md + 자기 카테고리 채널 가이드 자유 편집

2. 파일 분산 모델 (정본 책임자 = 작성자)

AGENTS·SOUL·채널 가이드 모두 분산. 다만 헌법(partial)·SOUL·표준은 main이 정본 → 모두 읽기.

%%{init: {'theme':'base','themeVariables': {'fontSize':'14px','fontFamily':'Pretendard, sans-serif'}, 'flowchart':{'nodeSpacing':28,'rankSpacing':40,'padding':10}}}%% flowchart TB subgraph Shared["📚 shared/ (main 정본·모두 읽기)"] direction TB SP[AGENTS.partial.×5]:::shared SS[SOUL.md]:::shared SW[wiki/concepts/channel-guide-standard-v1.md]:::shared end subgraph WS5["📁 5 Workspace"] direction LR subgraph M["workspace (main)"] MA[AGENTS.local.md]:::main Mch[memory/channels/<br/>3개]:::ch end subgraph CM["workspace-content-marketing"] CMA[AGENTS.local.md]:::cm CMch[memory/channels/<br/>9개]:::ch end subgraph GS["workspace-global-selling"] GSA[AGENTS.local.md]:::gs GSch[memory/channels/<br/>15개]:::ch end subgraph FO["workspace-finance-ops"] FOA[AGENTS.local.md]:::fo FOch[memory/channels/<br/>8개]:::ch end subgraph MG["workspace-management"] MGA[AGENTS.local.md]:::mg MGch[memory/channels/<br/>2개]:::ch end end Shared --> M Shared --> CM Shared --> GS Shared --> FO Shared --> MG classDef shared fill:#FEF3C7,stroke:#F59E0B,color:#78350F classDef main fill:#EDE9FE,stroke:#7C3AED,color:#5B21B6 classDef cm fill:#FCE7F3,stroke:#DB2777,color:#831843 classDef gs fill:#CFFAFE,stroke:#0891B2,color:#155E75 classDef fo fill:#DCFCE7,stroke:#16A34A,color:#14532D classDef mg fill:#FEF3C7,stroke:#F59E0B,color:#78350F classDef ch fill:#F1F5F9,stroke:#94A3B8,color:#334155

분산 원칙 (drift 방지)

자산 정본 위치 작성자 누가 읽음
헌법 partial (5개) ~/.openclaw/shared/ main 모두
SOUL.md ~/.openclaw/shared/ main 모두 (symlink)
가이드 표준 v1.3 workspace/wiki/concepts/ main 모두
AGENTS.local.md 각 workspace 각 부서 본인만
채널 가이드 채널 owner agent workspace owner owner만 (DM은 main)

3. AGENTS.md 빌드 흐름

%%{init: {'theme':'base','themeVariables': {'fontSize':'14px','fontFamily':'Pretendard, sans-serif'}, 'flowchart':{'nodeSpacing':35,'rankSpacing':50}}}%% flowchart LR P1[partial.header]:::shared P2[partial.principles]:::shared P3[partial.workflow]:::shared P4[partial.routing]:::shared P5[partial.safety]:::shared L1[workspace/AGENTS.local.md]:::main L2[workspace-cm/AGENTS.local.md]:::cm L3[workspace-gs/AGENTS.local.md]:::gs L4[workspace-fo/AGENTS.local.md]:::fo L5[workspace-mg/AGENTS.local.md]:::mg B[[build-agents-md.sh]]:::build P1 & P2 & P3 & P4 & P5 --> B L1 & L2 & L3 & L4 & L5 --> B B --> O1[workspace/AGENTS.md<br/>9095 chars]:::main B --> O2[workspace-cm/AGENTS.md<br/>8656]:::cm B --> O3[workspace-gs/AGENTS.md<br/>8954]:::gs B --> O4[workspace-fo/AGENTS.md<br/>8683]:::fo B --> O5[workspace-mg/AGENTS.md<br/>8354]:::mg classDef shared fill:#FEF3C7,stroke:#F59E0B,color:#78350F classDef main fill:#EDE9FE,stroke:#7C3AED,color:#5B21B6 classDef cm fill:#FCE7F3,stroke:#DB2777,color:#831843 classDef gs fill:#CFFAFE,stroke:#0891B2,color:#155E75 classDef fo fill:#DCFCE7,stroke:#16A34A,color:#14532D classDef mg fill:#FEF3C7,stroke:#F59E0B,color:#78350F classDef build fill:#0F172A,stroke:#0F172A,color:#fff

5개 partial × 5개 local → 5개 AGENTS.md. 빌드 스크립트가 일괄 처리. 모든 AGENTS.md 9,500 이내.


4. 세션 라이프사이클 & 자동 로드

%%{init: {'theme':'base','themeVariables': {'fontSize':'14px','fontFamily':'Pretendard, sans-serif'}, 'flowchart':{'nodeSpacing':35,'rankSpacing':50}}}%% flowchart LR S([🔄 새 세션]) --> WS{어느 에이전트?} WS -->|main| LM[workspace/] WS -->|content-marketing| LCM[workspace-cm/] WS -->|global-selling| LGS[workspace-gs/] WS -->|finance-ops| LFO[workspace-fo/] WS -->|management| LMG[workspace-mg/] LM & LCM & LGS & LFO & LMG --> Always[항상 로드] Always --> A1[AGENTS.md] Always --> A2[SOUL.md] Always --> A3[IDENTITY.md] Always --> A4[USER.md] Always --> CT{채널 유형?} CT -->|DM| DM[+ MEMORY.md] CT -->|채널| CH[+ memory/channels/channel-id-name.md] classDef start fill:#0F172A,stroke:#0F172A,color:#fff classDef decision fill:#FEF3C7,stroke:#F59E0B,color:#78350F classDef load fill:#EDE9FE,stroke:#7C3AED,color:#5B21B6 class S start class WS,CT decision class LM,LCM,LGS,LFO,LMG,Always load

자동 로드 규칙 - AGENTS·SOUL·IDENTITY·USER = 모든 세션 - MEMORY = DM만 (그룹 노출 ❌) - 채널 가이드 = 그 채널 세션만


5. 채널 가이드 표준 v1.3

가이드 종류 정본 위치 작성자 5섹션
일반 채널 채널 owner agent workspace owner 계약·범위·워크플로우·정본·KPI
HQ 채널 HQ 에이전트 workspace HQ 계약·범위·카테고리 라우팅 정책·스킬 의뢰 SOP·정본/KPI

금지 (안티패턴) - Frontmatter (런타임이 다 안다) - AGENTS·SOUL·wiki 중복 - AI 자체 측정·판단 룰 (3회 카운트, confidence 기반 등) - main이 부서 채널 가이드 정본 보유

상세는 거버넌스 > 채널 가이드 표준.


6. 채널 신설·삭제 흐름

%%{init: {'theme':'base','themeVariables': {'fontSize':'14px','fontFamily':'Pretendard, sans-serif','actorFontSize':'14px'}}}%% sequenceDiagram autonumber participant E as 직원·장캐리 participant HQ as 카테고리 HQ participant U as 장캐리 participant M as main E->>HQ: "A 업무 어디서 해요?" HQ->>HQ: 라우팅 점검 Note over HQ: 적합 채널 ❌ + 반복 패턴 HQ->>HQ: 신설 안건 박제 (채널명·topic·이유) HQ->>M: sessions_send 의뢰 HQ-->>E: "#X 신설 제안·의뢰 완료" M->>U: 승인 요청 U->>M: 승인 M->>M: ~/.openclaw/scripts/channel-create.sh Note over M: Discord 생성·bindings·가이드·restart M->>HQ: 완료 회신

핵심 룰 - HQ는 주권 판단·제안 + main 의뢰까지 1세트 (답변만 하고 끝 ❌) - main은 장캐리 명시 승인 후에만 channel-create.sh 실행 - HQ가 직접 생성 ❌ (MEMORY Principle 8)

의뢰 양식

[채널 신설 의뢰]
채널명: <hyphen-case 영문, 30자 이내>
카테고리: <해당 카테고리 정확 명>
담당 에이전트: <main / management / finance-ops / global-selling / content-marketing>
topic: <한 줄, 100자 이내, 이모지·줄바꿈 ❌>
모델: <opus / sonnet / haiku / 미지정(=default)>

[이유]
<1-3줄, 반복 패턴·적합 기존 채널 없는 이유·예상 사용 빈도>

[KPI 후보]
<측정 가능 지표 1-3개 또는 "TBD">

실행

# 양식 파일로 (권장)
~/.openclaw/scripts/channel-create.sh --from-form /tmp/request.md

# 인자 직접
~/.openclaw/scripts/channel-create.sh \
  --name "mgmt-okr" --category "📊경영" \
  --agent management --topic "분기 OKR 추적" --model opus

# 계획만 확인
~/.openclaw/scripts/channel-create.sh --from-form ... --dry-run

7. 스킬 의뢰 SOP (폐지, v1.4)

스크립트·자동화 작성은 사람이 직접 진행. AI 의뢰 흐름 ❌.

  • 필요 시 채널에서 /model opus 슬래시로 일시 승격 (세션만, gateway restart ❌)
  • 영구 승격 = openclaw config set channels.modelByChannel.discord.<id> anthropic/claude-opus-4-7 (hot-reload 자동)
  • HQ가 의뢰 받아 서브 세션 spawn = 토큰 낭비 (수정 시 재로딩) → 폐지

자동화 스크립트 인덱스는 작성자가 박제 (현재 일관 인덱스 ❌, 별건 작업 필요).