triflux 10.50.2 → 10.52.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CLAUDE.md +57 -41
- package/README.ko.md +41 -45
- package/README.md +41 -45
- package/adapters/codex/skills/tfx-live/SKILL.md +25 -11
- package/bin/tfx-live.mjs +341 -104
- package/bin/triflux.mjs +147 -2624
- package/config/mcp-registry.json +3 -12
- package/cto/brief.mjs +0 -20
- package/cto/collect.mjs +1 -200
- package/cto/current.schema.json +2 -23
- package/cto/hygiene.mjs +2 -61
- package/cto/lake-root.mjs +0 -56
- package/cto/status.mjs +5 -187
- package/hooks/agy-session-hook.mjs +11 -56
- package/hooks/codex-session-hook.mjs +11 -101
- package/hub/bridge.mjs +65 -1250
- package/hub/cli-adapter-base.mjs +12 -90
- package/hub/codex-adapter.mjs +0 -1
- package/hub/codex-preflight.mjs +5 -28
- package/hub/lib/process-utils.mjs +1 -156
- package/hub/lib/spawn-trace.mjs +3 -2
- package/hub/lib/timeout-defaults.mjs +0 -1
- package/hub/team/agent-map.json +0 -1
- package/hub/team/agents-row-attach.py +120 -0
- package/hub/team/agents-row.mjs +200 -0
- package/hub/team/ansi.mjs +1 -35
- package/hub/team/backend.mjs +9 -145
- package/hub/team/claude-daemon-control.mjs +1 -2
- package/hub/team/claude-session-projection.mjs +5 -73
- package/hub/team/cli/commands/attach.mjs +1 -17
- package/hub/team/cli/commands/control.mjs +12 -38
- package/hub/team/cli/commands/debug.mjs +2 -39
- package/hub/team/cli/commands/focus.mjs +5 -31
- package/hub/team/cli/commands/interrupt.mjs +6 -25
- package/hub/team/cli/commands/kill.mjs +1 -30
- package/hub/team/cli/commands/list.mjs +0 -16
- package/hub/team/cli/commands/send.mjs +6 -26
- package/hub/team/cli/commands/start/index.mjs +42 -133
- package/hub/team/cli/commands/start/parse-args.mjs +15 -40
- package/hub/team/cli/commands/start/start-headless.mjs +138 -105
- package/hub/team/cli/commands/start/start-mux.mjs +2 -7
- package/hub/team/cli/commands/status.mjs +2 -57
- package/hub/team/cli/commands/stop.mjs +14 -19
- package/hub/team/cli/help.mjs +4 -5
- package/hub/team/cli/manifest.mjs +5 -1
- package/hub/team/cli/render.mjs +0 -12
- package/hub/team/cli/services/runtime-mode.mjs +27 -98
- package/hub/team/cli/services/state-store.mjs +5 -20
- package/hub/team/codex-queue.mjs +385 -0
- package/hub/team/handoff.mjs +3 -34
- package/hub/team/headless.mjs +108 -1296
- package/hub/team/orchestrator.mjs +4 -30
- package/hub/team/pane.mjs +6 -28
- package/hub/team/psmux.mjs +3 -34
- package/hub/team/remote-session.mjs +1 -2
- package/hub/team/session-context.mjs +1 -1
- package/hub/team/session.mjs +7 -91
- package/hub/team/tui-core.mjs +1 -1
- package/hub/team/tui-viewer.mjs +11 -58
- package/hub/team/tui.mjs +8 -306
- package/hub/team/uds-orchestrator.mjs +2 -580
- package/hub/team/wt-manager.mjs +2 -2
- package/hub/workers/factory.mjs +6 -84
- package/hub/workers/interface.mjs +1 -7
- package/hub/workers/lib/jsonrpc-core.mjs +11 -0
- package/hub/workers/lib/jsonrpc-ws-uds.mjs +5 -8
- package/hud/cli-policy.mjs +0 -22
- package/hud/constants.mjs +13 -26
- package/hud/hud-qos-status.mjs +42 -54
- package/hud/providers/gemini.mjs +125 -20
- package/hud/renderers.mjs +101 -122
- package/hud/utils.mjs +10 -6
- package/package.json +7 -12
- package/scripts/__tests__/mcp-guard-engine-http-headers.test.mjs +6 -6
- package/scripts/__tests__/mcp-guard-engine-policy-sync.test.mjs +1 -4
- package/scripts/__tests__/mcp-guard-engine-proactive-sync.test.mjs +16 -21
- package/scripts/__tests__/mcp-guard-engine-stdio-sync.test.mjs +1 -1
- package/scripts/__tests__/mcp-guard-engine-sync-http-headers.test.mjs +2 -2
- package/scripts/__tests__/mcp-guard-engine.test.mjs +56 -63
- package/scripts/__tests__/spawn-trace.test.mjs +16 -0
- package/scripts/check-codex-config-stable.mjs +4 -37
- package/scripts/claude-login-detect.mjs +0 -1
- package/scripts/claudemd-sync.mjs +1 -28
- package/scripts/lib/agent-route-policy.mjs +143 -62
- package/scripts/lib/cli-claude.mjs +0 -14
- package/scripts/lib/env-probe.mjs +2 -131
- package/scripts/lib/gemini-profiles.mjs +2 -69
- package/scripts/lib/legacy-mcp-cleanup.mjs +283 -0
- package/scripts/lib/machine-profile.mjs +3 -17
- package/scripts/lib/mcp-filter.mjs +109 -53
- package/scripts/lib/mcp-guard-engine.mjs +40 -98
- package/scripts/lib/mcp-health.mjs +2 -2
- package/scripts/lib/mcp-server-catalog.mjs +2 -2
- package/scripts/lib/psmux-info.mjs +11 -59
- package/scripts/lib/session-presence.mjs +2 -100
- package/scripts/lib/skill-template.mjs +0 -245
- package/scripts/pack.mjs +8 -83
- package/scripts/preflight-cache.mjs +5 -18
- package/scripts/release/check-packages-mirror.mjs +2 -8
- package/scripts/release/version-manifest.json +9 -1
- package/scripts/setup.mjs +100 -417
- package/scripts/test-lock.mjs +0 -1
- package/scripts/tfx-route-post.mjs +5 -69
- package/scripts/tfx-route-worker.mjs +4 -79
- package/scripts/tfx-route.sh +169 -1495
- package/scripts/wt-cli.mjs +1 -2
- package/skills/tfx-auto/SKILL.md +123 -741
- package/skills/tfx-auto/references/consensus-schema.md +161 -0
- package/skills/tfx-auto/references/tmux-observation.md +97 -0
- package/skills/tfx-doctor/SKILL.md +5 -6
- package/skills/tfx-lead/SKILL.md +195 -0
- package/skills/tfx-live/SKILL.md +25 -11
- package/skills/tfx-remote/SKILL.md +24 -87
- package/skills/tfx-research/SKILL.md +13 -20
- package/skills/tfx-review/SKILL.md +33 -35
- package/skills/tfx-setup/SKILL.md +1 -1
- package/skills/tfx-ship/SKILL.md +6 -27
- package/skills/tfx-wt/SKILL.md +34 -68
- package/bin/tfx-doctor-tui.mjs +0 -7
- package/bin/tfx-setup-tui.mjs +0 -7
- package/config/routing-policy.json +0 -124
- package/docs/assets/consensus-flow.svg +0 -125
- package/docs/assets/deep-vs-light.svg +0 -193
- package/docs/assets/demo-dark.gif +0 -0
- package/docs/assets/demo-light.gif +0 -0
- package/docs/assets/demo-psmux.gif +0 -0
- package/hub/adaptive-diagnostic.mjs +0 -350
- package/hub/adaptive-inject.mjs +0 -224
- package/hub/adaptive-memory.mjs +0 -277
- package/hub/adaptive.mjs +0 -172
- package/hub/assign-callbacks.mjs +0 -170
- package/hub/delegator/contracts.mjs +0 -38
- package/hub/delegator/index.mjs +0 -14
- package/hub/delegator/schema/delegator-tools.schema.json +0 -250
- package/hub/delegator/service.mjs +0 -336
- package/hub/delegator/tool-definitions.mjs +0 -35
- package/hub/dynamic-routing-engine.mjs +0 -511
- package/hub/hitl.mjs +0 -202
- package/hub/hub-lifecycle.mjs +0 -248
- package/hub/lib/known-errors.json +0 -72
- package/hub/lib/memory-store.mjs +0 -1001
- package/hub/lib/phase-manager.mjs +0 -493
- package/hub/lib/risk-tier.mjs +0 -53
- package/hub/lib/ssh-command.mjs +0 -231
- package/hub/lib/staged-file-detect.mjs +0 -43
- package/hub/lib/state-snapshot.mjs +0 -293
- package/hub/lib/tfx-route-args.mjs +0 -353
- package/hub/lib/trace-recorder.mjs +0 -153
- package/hub/lib/uuidv7.mjs +0 -45
- package/hub/memory-doctor.mjs +0 -640
- package/hub/middleware/quota-middleware.mjs +0 -70
- package/hub/middleware/request-logger.mjs +0 -191
- package/hub/paths.mjs +0 -24
- package/hub/pipe.mjs +0 -825
- package/hub/pipeline/index.mjs +0 -163
- package/hub/pipeline/state.mjs +0 -191
- package/hub/pipeline/transitions.mjs +0 -131
- package/hub/promote-penalties.mjs +0 -138
- package/hub/public/dashboard.html +0 -416
- package/hub/reflexion.mjs +0 -290
- package/hub/role-contract.mjs +0 -314
- package/hub/router.mjs +0 -2026
- package/hub/routing-snapshot.mjs +0 -261
- package/hub/schema.sql +0 -209
- package/hub/server.mjs +0 -3048
- package/hub/session-fingerprint.mjs +0 -418
- package/hub/state.mjs +0 -300
- package/hub/store-adapter.mjs +0 -182
- package/hub/store.mjs +0 -1736
- package/hub/team/build-worker-prompt.mjs +0 -92
- package/hub/team/check-mcp-hub.mjs +0 -49
- package/hub/team/claude-native-bridge.mjs +0 -987
- package/hub/team/cli/commands/start/start-in-process.mjs +0 -50
- package/hub/team/cli/commands/start/start-wt.mjs +0 -86
- package/hub/team/cli/services/hub-client.mjs +0 -264
- package/hub/team/cli/services/native-control.mjs +0 -145
- package/hub/team/codex-review.mjs +0 -520
- package/hub/team/conductor-mesh-bridge.mjs +0 -122
- package/hub/team/conductor-registry.mjs +0 -121
- package/hub/team/conductor.mjs +0 -1529
- package/hub/team/consensus-meta.mjs +0 -176
- package/hub/team/cto-auto-collect.mjs +0 -115
- package/hub/team/cto-pull.mjs +0 -31
- package/hub/team/daemon-pty-tmux-bridge.mjs +0 -146
- package/hub/team/dashboard.mjs +0 -322
- package/hub/team/event-log.mjs +0 -84
- package/hub/team/execution-mode.mjs +0 -324
- package/hub/team/extract-completion-payload.mjs +0 -110
- package/hub/team/headless-bridge-session.mjs +0 -17
- package/hub/team/health-probe.mjs +0 -435
- package/hub/team/interactive-native-launcher.mjs +0 -119
- package/hub/team/interactive-native-worker.mjs +0 -80
- package/hub/team/interactive-tui-transport.mjs +0 -479
- package/hub/team/launcher-template.mjs +0 -144
- package/hub/team/lead-control.mjs +0 -191
- package/hub/team/mcp-selector.mjs +0 -145
- package/hub/team/native-supervisor.mjs +0 -460
- package/hub/team/native.mjs +0 -727
- package/hub/team/recovery-store.mjs +0 -149
- package/hub/team/remote-probe.mjs +0 -292
- package/hub/team/remote-watcher.mjs +0 -506
- package/hub/team/runtime-strategy.mjs +0 -200
- package/hub/team/schemas/worker-completion.json +0 -39
- package/hub/team/sentinel-capture.mjs +0 -127
- package/hub/team/session-sync.mjs +0 -316
- package/hub/team/swarm-cli.mjs +0 -390
- package/hub/team/swarm-hypervisor.mjs +0 -2206
- package/hub/team/swarm-intent.mjs +0 -216
- package/hub/team/swarm-locks.mjs +0 -335
- package/hub/team/swarm-planner.mjs +0 -371
- package/hub/team/swarm-preflight.mjs +0 -366
- package/hub/team/swarm-reconciler.mjs +0 -242
- package/hub/team/synapse-cli.mjs +0 -458
- package/hub/team/synapse-http.mjs +0 -311
- package/hub/team/synapse-registry.mjs +0 -618
- package/hub/team/tui-remote-adapter.mjs +0 -377
- package/hub/team/tui-synapse.mjs +0 -223
- package/hub/team/worker-completion-validator.mjs +0 -79
- package/hub/team/worker-sandbox.mjs +0 -125
- package/hub/team/worktree-lifecycle.mjs +0 -639
- package/hub/team/wt-templates.json +0 -43
- package/hub/team-bridge.mjs +0 -27
- package/hub/tools.mjs +0 -900
- package/hub/workers/antigravity-route-worker.mjs +0 -179
- package/hub/workers/codex-app-server-worker.mjs +0 -1067
- package/hub/workers/delegator-mcp.mjs +0 -1098
- package/hub/workers/lib/jsonrpc-stdio.mjs +0 -204
- package/mesh/index.mjs +0 -69
- package/mesh/mesh-budget.mjs +0 -137
- package/mesh/mesh-heartbeat.mjs +0 -100
- package/mesh/mesh-protocol.mjs +0 -96
- package/mesh/mesh-queue.mjs +0 -163
- package/mesh/mesh-registry.mjs +0 -78
- package/mesh/mesh-router.mjs +0 -77
- package/scripts/__tests__/skill-surface.test.mjs +0 -93
- package/scripts/cache-doctor.mjs +0 -156
- package/scripts/cache-warmup.mjs +0 -630
- package/scripts/completions/tfx.bash +0 -74
- package/scripts/completions/tfx.fish +0 -57
- package/scripts/completions/tfx.zsh +0 -98
- package/scripts/demo.mjs +0 -197
- package/scripts/doctor-dynamic-routing.mjs +0 -87
- package/scripts/hub-ensure.mjs +0 -842
- package/scripts/hub-watchdog.mjs +0 -90
- package/scripts/lib/claudemd-scanner.mjs +0 -223
- package/scripts/lib/context.mjs +0 -67
- package/scripts/lib/dynamic-route-cli.mjs +0 -107
- package/scripts/lib/handoff.mjs +0 -187
- package/scripts/lib/logger.mjs +0 -122
- package/scripts/lib/stealth-fetch.mjs +0 -176
- package/scripts/notion-read.mjs +0 -686
- package/scripts/snapshot-codex-state.mjs +0 -37
- package/scripts/snapshot-gemini-state.mjs +0 -37
- package/scripts/sync-codex-auth.mjs +0 -71
- package/scripts/sync-hub-mcp-settings.mjs +0 -697
- package/skills/_templates/base.md +0 -4
- package/skills/_templates/deep.md +0 -6
- package/skills/shared/telemetry-segment.md +0 -6
- package/tui/core.mjs +0 -266
- package/tui/doctor.mjs +0 -375
- package/tui/monitor-data.mjs +0 -152
- package/tui/monitor.mjs +0 -318
- package/tui/setup.mjs +0 -506
package/CLAUDE.md
CHANGED
|
@@ -1,20 +1,25 @@
|
|
|
1
|
-
# triflux
|
|
1
|
+
# triflux Claude Code 운영 가이드
|
|
2
2
|
|
|
3
3
|
<core-systems>
|
|
4
|
-
##
|
|
4
|
+
## 스킬 시스템
|
|
5
5
|
|
|
6
6
|
이 프로젝트는 3개의 스킬 시스템을 동시에 사용한다. 어떤 작업이든 해당 시스템의 스킬이 있는지 먼저 확인한다.
|
|
7
7
|
|
|
8
8
|
| 시스템 | 접두사 | 용도 | 스킬 수 |
|
|
9
9
|
|--------|--------|------|---------|
|
|
10
|
-
| **triflux** | `/tfx-*` | CLI 라우팅·다중 모델
|
|
10
|
+
| **triflux** | `/tfx-*` | CLI 라우팅·다중 모델 조정·원격 실행 | 10개 |
|
|
11
11
|
| **gstack** | `/` (접두사 없음) | QA·출시·조사·설계·검토·점검 지점 | ~35개 |
|
|
12
12
|
| **omc** | `/oh-my-claudecode:*` | autopilot·ralph·team·execute·ultragoal | ~37개 |
|
|
13
13
|
|
|
14
|
-
|
|
15
|
-
세션 종료 전 메모리 파일이 3개+ 변경됐으면 `/memory-hygiene` 제안을 검토한다.
|
|
14
|
+
필요한 스킬은 이름으로 호출한다.
|
|
16
15
|
</core-systems>
|
|
17
16
|
|
|
17
|
+
<code-principles>
|
|
18
|
+
## 코드 작성 원칙
|
|
19
|
+
|
|
20
|
+
코드는 간결하게 쓰고 의미 있는 이름을 쓴다. 주석은 이유만 짧게 한국어로 쓴다. 테스트는 회귀를 막는 핵심 경로만 최소한으로 둔다. 제거 여부는 해당 파일을 끝까지 직접 읽고 판단한다.
|
|
21
|
+
</code-principles>
|
|
22
|
+
|
|
18
23
|
<psmux-wt>
|
|
19
24
|
## psmux/WT 규칙 (Windows 한정)
|
|
20
25
|
|
|
@@ -28,7 +33,7 @@ macOS/Linux는 플랫폼 보호기가 아무 작업도 하지 않게 처리하
|
|
|
28
33
|
|
|
29
34
|
위 `<psmux-wt>` 룰셋은 Windows 전용이다. macOS/Linux 환경에서 triflux가 터미널/세션을 다루는 방식.
|
|
30
35
|
|
|
31
|
-
###
|
|
36
|
+
### 터미널 실행 경로
|
|
32
37
|
|
|
33
38
|
`openCommand()` 가 순차 평가하는 분기:
|
|
34
39
|
|
|
@@ -37,9 +42,9 @@ macOS/Linux는 플랫폼 보호기가 아무 작업도 하지 않게 처리하
|
|
|
37
42
|
| 1 | `platform === "win32"` | `wt-manager.createTab` | `hub/team/wt-manager.mjs` |
|
|
38
43
|
| 2 | `isTmuxLikeMux(mux)` (`detectMultiplexer()` → `getMultiplexerType()`/`hasMultiplexer()`/`hasTmux()`) | `tmux new-window -n <title> <command>` | 셸 직접 호출 |
|
|
39
44
|
| 3 | `platform === "darwin"` (대체 경로) | `open -a Terminal` | macOS `open` 명령 |
|
|
40
|
-
|
|
|
45
|
+
| 없음 | Linux(멀티플렉서 없음) | 미지원(`false` 반환) | 없음 |
|
|
41
46
|
|
|
42
|
-
###
|
|
47
|
+
### 터미널 관리 방식
|
|
43
48
|
|
|
44
49
|
| 후보 | 필요성 | 이유 |
|
|
45
50
|
|------|--------|------|
|
|
@@ -47,21 +52,19 @@ macOS/Linux는 플랫폼 보호기가 아무 작업도 하지 않게 처리하
|
|
|
47
52
|
| tmux 관리자 | **불필요** | `terminal-opener.mjs`가 `tmux new-window`로 직접 호출한다. |
|
|
48
53
|
| psmux 관리자 | **이미 있음** | `hub/team/psmux.mjs`가 Windows에서는 psmux, macOS/Linux에서는 tmux를 사용한다. |
|
|
49
54
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
### 플랫폼 보호기 위치(참고)
|
|
55
|
+
### 플랫폼 보호기
|
|
53
56
|
|
|
54
|
-
| 파일 |
|
|
57
|
+
| 파일 | 함수 | 보호기 |
|
|
55
58
|
|------|------|-------|
|
|
56
|
-
| `hub/team/wt-manager.mjs` |
|
|
57
|
-
| `hub/team/headless.mjs` |
|
|
58
|
-
| `tfx-route.sh` |
|
|
59
|
+
| `hub/team/wt-manager.mjs` | `createWtManager` | `if (platform() !== "win32") return createNonWindowsStubManager();` |
|
|
60
|
+
| `hub/team/headless.mjs` | `autoAttachTerminal` | `if (process.platform !== "win32") return false;` + `WT_SESSION` 체크 |
|
|
61
|
+
| `scripts/tfx-route.sh` | `resolve_machine_profile_path`, `heartbeat_monitor` | `case "$(uname -s)"` 분기 |
|
|
59
62
|
|
|
60
|
-
|
|
63
|
+
Windows 전용 경로는 플랫폼과 `WT_SESSION` 조건을 확인한다.
|
|
61
64
|
|
|
62
|
-
### macOS 알림
|
|
65
|
+
### macOS 알림
|
|
63
66
|
|
|
64
|
-
`hub/team/notify.mjs
|
|
67
|
+
`hub/team/notify.mjs`의 `sendToast`가 `osascript`로 macOS 기본 알림을 보낸다. 별도 의존성은 없다.
|
|
65
68
|
</macos-terminal>
|
|
66
69
|
|
|
67
70
|
<codex-config>
|
|
@@ -74,25 +77,24 @@ mac에서 위 코드가 호출돼도 일찍 반환하므로 실행되지 않는
|
|
|
74
77
|
| `approval_policy` (`on-request` / `never` / granular) | `--dangerously-bypass-approvals-and-sandbox` |
|
|
75
78
|
| `sandbox_mode` (`read-only` / `workspace-write` / `danger-full-access`) | `-s`, `--sandbox` |
|
|
76
79
|
|
|
77
|
-
`--full-auto` 는 Codex 0.147 에서
|
|
80
|
+
`--full-auto` 는 Codex 0.147 에서 제거되었다. 안전한 방식: `config.toml`에 기본값을 두고 CLI에서는 `--profile`만 선택한다.
|
|
78
81
|
프로필은 `$CODEX_HOME/<이름>.config.toml` 파일이다(인라인 `[profiles.*]` 아님).
|
|
79
82
|
</codex-config>
|
|
80
83
|
|
|
81
84
|
<account-broker>
|
|
82
85
|
## AccountBroker (계정 브로커)
|
|
83
86
|
|
|
84
|
-
|
|
87
|
+
headless 워커는 AccountBroker를 사용한다.
|
|
85
88
|
|
|
86
89
|
| 항목 | 설명 |
|
|
87
90
|
|------|------|
|
|
88
|
-
| 계정별 회로 차단기 | 장애
|
|
91
|
+
| 계정별 회로 차단기 | 장애 격리: 한 계정 오류가 다른 계정에 전파되지 않음 |
|
|
89
92
|
| 사용 중 플래그 | 동일 계정 이중 임대 방지 |
|
|
90
|
-
|
|
|
93
|
+
| `reloadBroker()` | accounts.json을 다시 불러온다. 활성 임대 소유권은 다시 불러온 뒤에도 보존한다. 허브가 없어 HTTP 엔드포인트는 없고 모듈 함수로만 부를 수 있다. |
|
|
91
94
|
| 어댑터의 임대 없음 정책 | headless 어댑터는 브로커가 비활성·비어 있음이면 기본 CLI 인증 경로로 실행하고, 브로커가 활성인데 임대가 없으면 `circuit_open`으로 실패한다. |
|
|
92
|
-
|
|
|
93
|
-
|
|
|
94
|
-
|
|
|
95
|
-
| EventEmitter 이벤트 | `lease`, `release`, `cooldown`, `tierFallback`, `circuitOpen`, `circuitClose`, `noAvailableAccounts` — HUD 연동용 |
|
|
95
|
+
| 공개 스냅숏 정책 | 밖에 보여 줄 때는 `publicSnapshot()`만 쓴다. `env`, `authFile`, `profile`, `host`, 파일 경로, 가공하지 않은 실패 시각은 공개하지 않는다. |
|
|
96
|
+
| 진단 이벤트 | `securityViolation`, `authSyncError`는 이벤트로만 내보낸다. 구독하는 쪽이 없으면 기록되지 않는다. |
|
|
97
|
+
| EventEmitter 이벤트 | `lease`, `release`, `cooldown`, `tierFallback`, `circuitOpen`, `circuitClose`, `noAvailableAccounts`: HUD 연동용 |
|
|
96
98
|
</account-broker>
|
|
97
99
|
|
|
98
100
|
<remote>
|
|
@@ -102,7 +104,6 @@ conductor·headless·swarm-hypervisor가 하나의 AccountBroker 단일 인스
|
|
|
102
104
|
|
|
103
105
|
| 스킬 | 대상 | 방식 |
|
|
104
106
|
|------|------|------|
|
|
105
|
-
| tfx-swarm | 로컬 worktree + shard `host:` 원격 분배 | PRD별 worktree, 다중 모델·기기 |
|
|
106
107
|
| tfx-remote | Claude Code 원격 | SSH → Claude Code 세션 → 내부 tfx 라우팅 |
|
|
107
108
|
|
|
108
109
|
Codex를 SSH 너머로 직접 실행하지 않는다. `config.toml` 충돌과 TTY 문제가 있다.
|
|
@@ -137,18 +138,30 @@ Codex를 SSH 너머로 직접 실행하지 않는다. `config.toml` 충돌과 TT
|
|
|
137
138
|
</headless-retrieval>
|
|
138
139
|
|
|
139
140
|
<native-bridge>
|
|
141
|
+
## 팀 실행 모드
|
|
142
|
+
|
|
143
|
+
`tfx multi`는 tmux/psmux와 headless를 지원한다. in-process와 WT 팀 모드는 지원하지 않는다.
|
|
144
|
+
headless 워커도 tmux/psmux 방에서 돈다. 멀티플렉서가 없으면 모드와 관계없이 설치 안내 오류로 끝난다.
|
|
145
|
+
Windows Terminal의 독립 탭 열기는 유지한다.
|
|
146
|
+
|
|
140
147
|
## 기본 연결 UI(`claude agents` 노출)
|
|
141
148
|
|
|
142
|
-
|
|
149
|
+
워커는 tmux 방에서 돌고, `claude agents` 행은 그 방에 붙는 attach client다. 행에서 Enter를 누르면
|
|
150
|
+
워커가 도는 tmux pane이 열린다. 행은 공식 `claude --bg --exec`로 만든다(macOS/Linux).
|
|
151
|
+
|
|
152
|
+
| 대상 | 기본값 | 행에서 할 수 있는 것 |
|
|
153
|
+
|------|--------|----------------------|
|
|
154
|
+
| `tfx-auto` / `tfx multi` headless 워커 | 켬, `--no-native-bridge-ui`로 끔 | 읽기 전용 관찰 |
|
|
155
|
+
| `tfx-live start` 로 띄운 Claude 외 세션 | 켬 | 입력 가능. python3가 없으면 읽기 전용이고 행 이름에 `[read-only]`가 붙음 |
|
|
156
|
+
| 대화형 `tfx multi`(tmux/psmux) | 끔 | 해당 없음 |
|
|
143
157
|
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
| 대화식(tmux/wt) | 끔 | 해당 없음 |
|
|
158
|
+
- 행을 닫거나 Ctrl+Z로 목록에 돌아가도 워커는 계속 돈다.
|
|
159
|
+
- headless 워커 여럿이 한 방을 나눠 쓰면 행마다 방 전체가 보이고, 활성 pane은 행끼리 공유한다.
|
|
160
|
+
- 방이 사라지면 행이 스스로 지워진다. headless 실행은 끝날 때 자기가 연 행을 직접 지운다.
|
|
161
|
+
- 바깥 터미널의 질의 응답이 방 입력으로 새지 않게, 읽기 전용 attach 또는 `hub/team/agents-row-attach.py` 중계를 쓴다.
|
|
162
|
+
- 행 생성에는 cwd가 Claude에서 trust 된 워크스페이스여야 한다. 실패하면 워커는 그대로 돌고 경고만 남는다.
|
|
150
163
|
|
|
151
|
-
|
|
164
|
+
근거: [ADR-0026](docs/adr/0026-agents-row-tmux-attach.md).
|
|
152
165
|
</native-bridge>
|
|
153
166
|
|
|
154
167
|
<cross-review>
|
|
@@ -176,19 +189,22 @@ Codex를 SSH 너머로 직접 실행하지 않는다. `config.toml` 충돌과 TT
|
|
|
176
189
|
|
|
177
190
|
| 파일 | 내용 |
|
|
178
191
|
|------|------|
|
|
179
|
-
| `.claude/rules/tfx-
|
|
180
|
-
| `.claude/rules/tfx-execution-skill-map.md` | tfx-auto / multi / swarm 실행 엔진 매핑, 격리 기준, 안티패턴 |
|
|
181
|
-
| `.claude/rules/tfx-autoplan-principles.md` | gstack autoplan의 여섯 가지 결정 원칙·단계 우선순위·충돌 해소 규칙 추출본 |
|
|
192
|
+
| `.claude/rules/tfx-execution-skill-map.md` | tfx-auto / multi 실행 경로와 코드 변경 병렬 작업의 worktree 격리 기준 |
|
|
182
193
|
| `.claude/rules/tfx-update-logic.md` | triflux / OMC / gstack / Codex / Antigravity 업데이트 로직 |
|
|
183
194
|
| `.claude/rules/tfx-stack-coexistence.md` | gstack / superpowers / triflux 공존 원칙, 레이어 분리, 의존 방향, 충돌 해소 |
|
|
184
195
|
| `.claude/rules/tfx-mirror-policy.md` | packages/ 3계층 미러 정책(핵심 단순 복사 / 원격 가져오기 변환 / triflux 바이트 동일), 테스트 제외 규칙, 불일치 차단 |
|
|
196
|
+
| `.claude/rules/tfx-cto-hub-boundary.md` | CTO lake 조회 표면과 의존 방향 |
|
|
197
|
+
| `.claude/rules/tfx-doc-governance.md` | 실행 규칙, ADR, 설계, 계획 문서의 배치 |
|
|
198
|
+
| `.claude/rules/tfx-escalation-chain.md` | 자동 재시도와 CLI 전환 체인 |
|
|
199
|
+
| `.claude/rules/tfx-machine-profile.md` | 기기 프로필 우선순위와 실행 정책 |
|
|
200
|
+
| `.claude/rules/tfx-psmux.md` | Windows psmux와 WT 실행 규칙 |
|
|
201
|
+
| `.claude/rules/tfx-routing.md` | 역할별 CLI 라우팅과 직접 호출 제한 |
|
|
202
|
+
| `.claude/rules/tfx-skill-authoring.md` | 스킬 frontmatter, 프로필 표기, 검증 규약 |
|
|
185
203
|
|
|
186
204
|
Claude Code는 `.claude/rules/*.md`를 자동으로 불러온다. Codex CLI는 `@import`를 지원하지 않으므로 필요하면 `AGENTS.md`를 독립적으로 유지한다.
|
|
187
205
|
|
|
188
206
|
## GBrain
|
|
189
207
|
|
|
190
|
-
설정 정본은 `~/Projects/CLAUDE.md
|
|
191
|
-
`2026-04-25`로 오래되어 전역·Projects 블록과 서로 모순됐다(2026-07-26 제거).
|
|
192
|
-
실제 엔진은 postgres(Supabase), gbrain 0.42.51.0이다.
|
|
208
|
+
설정 정본은 `~/Projects/CLAUDE.md`다.
|
|
193
209
|
|
|
194
210
|
- 이 저장소 정책: 읽기·쓰기(github.com/tellang/triflux)
|
package/README.ko.md
CHANGED
|
@@ -24,15 +24,28 @@
|
|
|
24
24
|
|
|
25
25
|
triflux는 코딩 작업을 Claude, Codex, Antigravity 사이에서 나눠 맡기는 Claude Code 플러그인이자
|
|
26
26
|
npm CLI다. `/tfx-auto`에 할 일을 한 번 적으면 triflux가 CLI 레인(기본은 Codex)을 고르고, 임의
|
|
27
|
-
셸 명령 대신 관리된 경로로 실행한다. 필요하면 로컬 병렬 워커,
|
|
28
|
-
|
|
27
|
+
셸 명령 대신 관리된 경로로 실행한다. 필요하면 로컬 병렬 워커, Claude↔Codex 라이브 세션, 원격 호스트로 작업을 나눈다.
|
|
28
|
+
코드 변경을 병렬로 진행할 때는 작업별 worktree와 세션을 분리한다. 설치, 진단, 팀 실행은 `tfx`
|
|
29
29
|
셸 CLI가 맡는다.
|
|
30
30
|
|
|
31
31
|
## 설치
|
|
32
32
|
|
|
33
33
|
```bash
|
|
34
34
|
npm install -g triflux # postinstall이 setup 스크립트를 실행한다
|
|
35
|
-
tfx doctor # CLI, tmux,
|
|
35
|
+
tfx doctor # CLI, tmux, MCP, 프로필, 스킬 점검
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
npm 12 이상은 기본적으로 설치 스크립트를 막는다. setup 스크립트를 허용해 설치한다.
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
npm i -g triflux --allow-scripts=triflux
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
기본 setup은 `triflux` 마켓플레이스를 등록하고 mods 설치 안내만 출력한다. 사용량 band와
|
|
45
|
+
서브에이전트 effort 강제 기능은 따로 설치한다(Claude Code 2.1.287 이상).
|
|
46
|
+
|
|
47
|
+
```bash
|
|
48
|
+
tfx setup --mods
|
|
36
49
|
```
|
|
37
50
|
|
|
38
51
|
이 저장소의 마켓플레이스에서 Claude Code 플러그인으로 설치할 수도 있다.
|
|
@@ -52,8 +65,6 @@ claude plugin install triflux@triflux
|
|
|
52
65
|
/tfx-auto "마이그레이션 끝내고 검증까지" --mode deep --retry ralph --max-iterations 10
|
|
53
66
|
```
|
|
54
67
|
|
|
55
|
-
실행하지 않고 라우팅 판정만 보려면 셸에서 `tfx auto "<작업>" --json`을 실행한다.
|
|
56
|
-
|
|
57
68
|
## 스킬
|
|
58
69
|
|
|
59
70
|
직접 쓰는 스킬:
|
|
@@ -61,10 +72,10 @@ claude plugin install triflux@triflux
|
|
|
61
72
|
| 스킬 | 용도 |
|
|
62
73
|
| --- | --- |
|
|
63
74
|
| `/tfx-auto` | 구현, 수정, 리뷰, 병렬 작업의 진입점. 동작은 아래 플래그로 정한다. |
|
|
64
|
-
| `/tfx-live` | Claude↔Codex 라이브 세션. `start`/`ask`/`stop`, `peer` 중계, `
|
|
65
|
-
| `/tfx-remote` | SSH
|
|
75
|
+
| `/tfx-live` | Claude↔Codex 라이브 세션. `start`/`ask`/`wait`/`stop`, `peer` 중계, `list-sessions`. |
|
|
76
|
+
| `/tfx-remote` | SSH 원격 Claude Code 세션 시작, 조회, 재부착, 메시지 전송, 준비 상태 확인, 모니터링, 종료. |
|
|
66
77
|
| `/tfx-setup` | 대화형 설정. 파일 동기화, HUD, Codex 프로필, MCP, 훅 우선순위. |
|
|
67
|
-
| `/tfx-doctor` | 진단과 복구.
|
|
78
|
+
| `/tfx-doctor` | 진단과 복구. |
|
|
68
79
|
| `/tfx-ship` | triflux 릴리즈 절차(메인테이너용). |
|
|
69
80
|
| `/tfx-wt` | Windows Terminal 탭·패인 조작. `tfx setup`은 Windows에만 설치한다. |
|
|
70
81
|
|
|
@@ -88,13 +99,10 @@ Codex 프로필은 `~/.codex/<프로필>.config.toml`에서 직접 관리한다.
|
|
|
88
99
|
| `--shape` | `consensus`, `debate`, `panel` | `--mode consensus`의 결과 형태 |
|
|
89
100
|
| `--cli` | `auto`, `codex`, `antigravity`, `claude` | CLI 레인 고정 |
|
|
90
101
|
| `--cli-set` | `triad`, `no-antigravity`, `custom` | 합의 참여자 구성 |
|
|
91
|
-
| `--parallel` | `1`, `N
|
|
92
|
-
| `--isolation` | `none`, `worktree` | 샤드별 worktree 격리(`swarm`이면 강제) |
|
|
93
|
-
| `--remote` | `<host>` | 스웜 샤드를 `hosts.json`의 호스트로 보냄 |
|
|
102
|
+
| `--parallel` | `1`, `N` | `N` = 로컬 워커(`tfx multi`) |
|
|
94
103
|
| `--retry` | `0`, `1`(기본), `ralph`, `auto-escalate` | `ralph` = 막힘 감지가 있는 재시도 상태 기계, `auto-escalate` = 모델 체인을 한 단계씩 올림 |
|
|
95
104
|
| `--max-iterations` | `N` | `ralph`/`auto-escalate` 상한(`0`은 무제한) |
|
|
96
105
|
| `--rounds` | `N`(기본 4) | `--mode live` 왕복 횟수 |
|
|
97
|
-
| `--risk-tier` | `auto`, `low`, `medium`, `high` | 변경 범위로 검증 강도를 정함. `--mode`가 있으면 무시 |
|
|
98
106
|
| `--skill` | `<name>` | `skills/<name>/SKILL.md`를 Codex/Antigravity 프롬프트 앞에 붙임 |
|
|
99
107
|
| `--no-native-bridge-ui` | | headless 워커를 `claude agents` 패널에 띄우지 않음 |
|
|
100
108
|
|
|
@@ -124,27 +132,22 @@ Codex는 이름 붙은 프로필로 실행한다. 모델 ID는 `~/.codex/<프로
|
|
|
124
132
|
| 명령 | 용도 |
|
|
125
133
|
| --- | --- |
|
|
126
134
|
| `tfx setup` / `tfx doctor` | 파일·HUD·MCP·프로필 동기화 / 진단과 복구(`--fix`, `--json`) |
|
|
127
|
-
| `tfx
|
|
128
|
-
| `tfx multi` | tmux + Hub 기반 로컬 멀티 CLI 팀 |
|
|
129
|
-
| `tfx swarm` | PRD 기반 worktree 격리 실행: `plan`, `preflight`, `run`, `list` |
|
|
130
|
-
| `tfx synapse` | 스웜 세션 레지스트리와 lease |
|
|
131
|
-
| `tfx hub` | 로컬 Hub: `start`, `stop`, `status`, `ensure` |
|
|
135
|
+
| `tfx multi` | tmux 기반 로컬 멀티 CLI 팀 |
|
|
132
136
|
| `tfx mcp` | 관리형 MCP 레지스트리: `list`, `sync`, `add`, `remove` |
|
|
133
|
-
| `tfx handoff` | 현재 맥락을 다른 세션이나 호스트로 넘길 프롬프트로 묶음 |
|
|
134
137
|
| `tfx cto` | 저장소 단위 권위 콘솔: `collect`, `status`, `hygiene`(dry-run) |
|
|
135
|
-
| `
|
|
136
|
-
| `tfx
|
|
137
|
-
| `tfx notion-read`, `tfx why`, `tfx schema`, `tfx list`, `tfx monitor`, `tfx update`, `tfx version` | Notion → Markdown, 커밋 intent 트레일러, CLI 스키마, 설치된 스킬, TUI 모니터, 업데이트, 버전 |
|
|
138
|
+
| `bash ~/.claude/scripts/tfx-route.sh code-reviewer "<지시>"` | 정책에 따라 `codex exec review`로 리뷰 전달 |
|
|
139
|
+
| `tfx list`, `tfx update`, `tfx version` | 설치된 스킬, 업데이트, 버전 |
|
|
138
140
|
| `tfx-live` | 라이브 세션 브리지(`/tfx-live` 스킬과 같은 명령) |
|
|
139
141
|
|
|
140
|
-
정확한 인자는 `tfx <명령> --help
|
|
142
|
+
정확한 인자는 `tfx <명령> --help`로 확인한다.
|
|
141
143
|
|
|
142
144
|
## 런타임 기능
|
|
143
145
|
|
|
144
146
|
**라이브 세션.** `tfx-live`는 Claude Code와 Codex TUI 세션을 조종한다. Claude 데몬 대상
|
|
145
147
|
(`--short`/`--session-id`)은 UDS를 먼저 시도하고, `--session`도 주면 실패 시 tmux로 넘어간다.
|
|
146
|
-
Codex
|
|
147
|
-
`--
|
|
148
|
+
Codex `ask`는 `codex queue`로 메시지를 쌓고(TUI에 `[from <보낸 세션>]` 첫 줄로 보인다) 못 쓰면 이유를
|
|
149
|
+
남기고 tmux로 보낸다. `--transport uds --thread <id|auto>`로 UDS도 쓸 수 있다. `peer`는 두 세션 사이를
|
|
150
|
+
`--rounds`만큼 중계한다. triflux의 Codex
|
|
148
151
|
훅이 실행 중인 Codex 세션을 `~/.local/state/triflux/codex-sessions/`에 기록하므로
|
|
149
152
|
`tfx-live list-sessions --cli codex|claude`로 직접 띄운 tmux 세션도 찾을 수 있다.
|
|
150
153
|
|
|
@@ -152,10 +155,8 @@ Codex는 tmux를 쓰거나 `--transport uds --thread <id|auto>`로 UDS를 쓴다
|
|
|
152
155
|
Claude Code Bash 도구의 600초 제한에 걸리지 않는다. 이후 `--job-status`, `--job-wait`,
|
|
153
156
|
`--job-result`로 확인한다.
|
|
154
157
|
|
|
155
|
-
**
|
|
156
|
-
|
|
157
|
-
`tfx-auto`, `tfx multi`, 로컬 스웜 샤드의 headless 워커는 `claude agents` 패널에 행으로 보인다.
|
|
158
|
-
끄려면 `--no-native-bridge-ui`를 준다.
|
|
158
|
+
**Headless 워커.** `tfx-auto`, `tfx multi`의 headless 워커는 `claude agents` 패널에 행으로 보인다.
|
|
159
|
+
행에서 Enter를 누르면 그 워커가 도는 tmux pane이 열린다. 끄려면 `--no-native-bridge-ui`를 준다.
|
|
159
160
|
|
|
160
161
|
**재시도와 승격.** `--retry ralph`는 끝나거나 막힐 때(같은 실패 3회 연속)까지 반복한다.
|
|
161
162
|
`--retry auto-escalate`는 Codex `gpt6_astra_max`에서 Claude `fable`로 올라간다. 체인은
|
|
@@ -169,12 +170,13 @@ Claude Code Bash 도구의 600초 제한에 걸리지 않는다. 이후 `--job-s
|
|
|
169
170
|
|
|
170
171
|
**CTO lake.** `tfx cto collect`로 `.triflux/lake/`의 저장소 스냅샷을 갱신하고,
|
|
171
172
|
`tfx cto status`로 생성 시각과 경과 시간을 확인한다. `tfx cto hygiene --dry-run`는 dry-run 결과를
|
|
172
|
-
보고한다. 트레이와 쓰이지 않는 CTO 운영 명령은
|
|
173
|
-
([ADR-0024](docs/adr/0024-cto-explicit-queries-only.md)). 자동 수집은 기본으로 꺼져 있고 `TFX_CTO_AUTO_COLLECT=1` 로 켠다([ADR-0018](docs/adr/0018-cto-auto-behaviors-opt-in.md)).
|
|
173
|
+
보고한다. 트레이와 쓰이지 않는 CTO 운영 명령은 제거하였다
|
|
174
|
+
([ADR-0024](docs/adr/0024-cto-explicit-queries-only.md)). 자동 수집은 기본으로 꺼져 있고 `TFX_CTO_AUTO_COLLECT=1` 로 켠다([ADR-0018](docs/_archive/adr/0018-cto-auto-behaviors-opt-in.md)).
|
|
174
175
|
|
|
175
|
-
**원격 호스트.** `/tfx-remote
|
|
176
|
-
(Windows는 `%APPDATA%\triflux\hosts.json`)에서 호스트를 읽는다.
|
|
177
|
-
|
|
176
|
+
**원격 호스트.** `/tfx-remote`는 `~/.config/triflux/hosts.json`
|
|
177
|
+
(Windows는 `%APPDATA%\triflux\hosts.json`)에서 호스트를 읽는다. 세션 시작은
|
|
178
|
+
`remote-spawn.mjs`의 `--host <host> --prompt "<요청>"` 옵션을 사용한다.
|
|
179
|
+
[실행 옵션](skills/tfx-remote/SKILL.md)을 따른다.
|
|
178
180
|
|
|
179
181
|
## 구조
|
|
180
182
|
|
|
@@ -184,18 +186,14 @@ graph TD
|
|
|
184
186
|
User --> CLI[tfx CLI]
|
|
185
187
|
Skills --> Route[tfx-route.sh]
|
|
186
188
|
Skills --> Live[tfx-live]
|
|
187
|
-
CLI --> Team["tfx multi
|
|
189
|
+
CLI --> Team["tfx multi"]
|
|
188
190
|
Route --> Codex[Codex CLI]
|
|
189
191
|
Route --> Agy[Antigravity agy]
|
|
190
192
|
Route --> Claude[Claude Code]
|
|
191
193
|
Team --> Route
|
|
192
|
-
Team --> WT[(git worktrees)]
|
|
193
194
|
Live -->|UDS 또는 tmux| Sessions[Claude / Codex TUI 세션]
|
|
194
|
-
Route -->
|
|
195
|
-
Team -->
|
|
196
|
-
Hub --> Store[(SQLite 또는 메모리 저장소)]
|
|
197
|
-
Hub --> MCP[MCP 도구]
|
|
198
|
-
Hub --> UI["HUD · claude agents 패널"]
|
|
195
|
+
Route --> UI["HUD · claude agents 패널"]
|
|
196
|
+
Team --> UI
|
|
199
197
|
CLI --> Lake[(".triflux/lake (tfx cto)")]
|
|
200
198
|
```
|
|
201
199
|
|
|
@@ -210,8 +208,8 @@ graph TD
|
|
|
210
208
|
| Linux | tmux | 지원. |
|
|
211
209
|
| Windows | psmux + Windows Terminal | 아래 참고. |
|
|
212
210
|
|
|
213
|
-
**Windows.** psmux(tmux 포크)의 기본 셸은 PowerShell이다.
|
|
214
|
-
|
|
211
|
+
**Windows.** psmux(tmux 포크)의 기본 셸은 PowerShell이다. `wt.exe`와 psmux `kill-session`은 직접 호출하지
|
|
212
|
+
않고, 탭과 패인은 `tfx-wt` 스킬(Windows에만 설치)과
|
|
215
213
|
`hub/team/wt-manager.mjs`를 거친다. 에이전트 규칙은
|
|
216
214
|
[`.claude/rules/tfx-psmux.md`](.claude/rules/tfx-psmux.md).
|
|
217
215
|
|
|
@@ -219,9 +217,7 @@ graph TD
|
|
|
219
217
|
|
|
220
218
|
| 층 | 보호 |
|
|
221
219
|
| --- | --- |
|
|
222
|
-
| 관리된 경로 | Codex와 Antigravity는 `tfx-route.sh`,
|
|
223
|
-
| safety-guard 훅 | 위험한 셸 명령(루트 `rm -rf`, main 강제 push, `git clean -fd`, SQL `DROP`), `wt.exe`·psmux 종료 직접 호출, Windows 호스트로 SSH 보내는 bash 문법을 막고 관리된 대안을 알려 준다. |
|
|
224
|
-
| Hub | localhost에만 붙는다. bearer 토큰(`TFX_HUB_TOKEN`)은 선택. |
|
|
220
|
+
| 관리된 경로 | Codex와 Antigravity는 `tfx-route.sh`, headless 워커, `tfx`로만 부르고 맨 `codex exec`나 `agy`로 부르지 않는다. 호출자가 지키는 규칙이며 이를 막는 훅은 없다. |
|
|
225
221
|
| MCP 레지스트리 | 낡았거나 지원하지 않는 MCP 항목을 관리형 항목으로 바꾼다. |
|
|
226
222
|
| 합의 결과 | deep·consensus 실행은 일부 레인이 빠졌거나 의견이 갈린 결과를 숨기지 않고 표시한다. |
|
|
227
223
|
|
package/README.md
CHANGED
|
@@ -25,15 +25,29 @@
|
|
|
25
25
|
triflux is a Claude Code plugin and npm CLI that routes coding work across Claude, Codex,
|
|
26
26
|
and Antigravity. You describe the task once with `/tfx-auto`; triflux picks the CLI lane
|
|
27
27
|
(Codex by default), runs it through managed routes instead of ad-hoc shell commands, and
|
|
28
|
-
can fan the work out to parallel workers,
|
|
29
|
-
|
|
28
|
+
can fan the work out to parallel workers, live Claude↔Codex sessions, or remote
|
|
29
|
+
hosts. Parallel code changes use separate worktrees and one session per worktree.
|
|
30
|
+
The `tfx` shell CLI covers setup, diagnostics,
|
|
30
31
|
and team orchestration.
|
|
31
32
|
|
|
32
33
|
## Install
|
|
33
34
|
|
|
34
35
|
```bash
|
|
35
36
|
npm install -g triflux # postinstall runs the setup script
|
|
36
|
-
tfx doctor # check CLIs, tmux,
|
|
37
|
+
tfx doctor # check CLIs, tmux, MCP, profiles, skills
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
npm 12 and newer block install scripts by default. Allow the setup script:
|
|
41
|
+
|
|
42
|
+
```bash
|
|
43
|
+
npm i -g triflux --allow-scripts=triflux
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
Setup registers the `triflux` marketplace and prints a mods installation hint. To install
|
|
47
|
+
usage bands and subagent effort enforcement (Claude Code 2.1.287 or newer):
|
|
48
|
+
|
|
49
|
+
```bash
|
|
50
|
+
tfx setup --mods
|
|
37
51
|
```
|
|
38
52
|
|
|
39
53
|
Or install the Claude Code plugin from this repository's marketplace:
|
|
@@ -53,8 +67,6 @@ claude plugin install triflux@triflux
|
|
|
53
67
|
/tfx-auto "finish the migration and verify it" --mode deep --retry ralph --max-iterations 10
|
|
54
68
|
```
|
|
55
69
|
|
|
56
|
-
Run `tfx auto "<task>" --json` in a shell to preview the routing decision without executing it.
|
|
57
|
-
|
|
58
70
|
## Skills
|
|
59
71
|
|
|
60
72
|
Skills you invoke directly:
|
|
@@ -62,10 +74,10 @@ Skills you invoke directly:
|
|
|
62
74
|
| Skill | Use |
|
|
63
75
|
| --- | --- |
|
|
64
76
|
| `/tfx-auto` | Front door for implementing, fixing, reviewing, and parallel work. Behavior is set by flags (below). |
|
|
65
|
-
| `/tfx-live` | Live Claude↔Codex sessions: `start`/`ask`/`stop`, `peer` relay, `
|
|
66
|
-
| `/tfx-remote` |
|
|
77
|
+
| `/tfx-live` | Live Claude↔Codex sessions: `start`/`ask`/`wait`/`stop`, `peer` relay, `list-sessions`. |
|
|
78
|
+
| `/tfx-remote` | SSH 원격 Claude Code 세션 시작, 조회, 재부착, 메시지 전송, 준비 상태 확인, 모니터링, 종료. |
|
|
67
79
|
| `/tfx-setup` | Interactive setup: file sync, HUD, Codex profiles, MCP, hook priority. |
|
|
68
|
-
| `/tfx-doctor` | Diagnose and repair
|
|
80
|
+
| `/tfx-doctor` | Diagnose and repair. |
|
|
69
81
|
| `/tfx-ship` | triflux release flow (maintainers). |
|
|
70
82
|
| `/tfx-wt` | Windows Terminal tabs and panes. `tfx setup` installs it on Windows only. |
|
|
71
83
|
|
|
@@ -89,13 +101,10 @@ and execution. Manage Codex profiles directly in `~/.codex/<profile>.config.toml
|
|
|
89
101
|
| `--shape` | `consensus`, `debate`, `panel` | Output shape for `--mode consensus` |
|
|
90
102
|
| `--cli` | `auto`, `codex`, `antigravity`, `claude` | Force a CLI lane |
|
|
91
103
|
| `--cli-set` | `triad`, `no-antigravity`, `custom` | Consensus participants |
|
|
92
|
-
| `--parallel` | `1`, `N
|
|
93
|
-
| `--isolation` | `none`, `worktree` | Worktree isolation per shard (forced on with `swarm`) |
|
|
94
|
-
| `--remote` | `<host>` | Send swarm shards to a host from `hosts.json` |
|
|
104
|
+
| `--parallel` | `1`, `N` | `N` = local workers (`tfx multi`) |
|
|
95
105
|
| `--retry` | `0`, `1` (default), `ralph`, `auto-escalate` | `ralph` = retry state machine with stuck detection; `auto-escalate` = move up the model chain |
|
|
96
106
|
| `--max-iterations` | `N` | Cap for `ralph` / `auto-escalate` (`0` = unlimited) |
|
|
97
107
|
| `--rounds` | `N` (default 4) | Round trips for `--mode live` |
|
|
98
|
-
| `--risk-tier` | `auto`, `low`, `medium`, `high` | Pick verification strength from the change; ignored when `--mode` is set |
|
|
99
108
|
| `--skill` | `<name>` | Prepend `skills/<name>/SKILL.md` to the Codex/Antigravity prompt |
|
|
100
109
|
| `--no-native-bridge-ui` | | Hide headless workers from the `claude agents` panel |
|
|
101
110
|
|
|
@@ -125,28 +134,22 @@ escalation chain: [`.claude/rules/tfx-escalation-chain.md`](.claude/rules/tfx-es
|
|
|
125
134
|
| Command | Use |
|
|
126
135
|
| --- | --- |
|
|
127
136
|
| `tfx setup` / `tfx doctor` | Sync files, HUD, MCP, profiles / diagnose and repair (`--fix`, `--json`) |
|
|
128
|
-
| `tfx
|
|
129
|
-
| `tfx multi` | Local multi-CLI team in tmux + Hub |
|
|
130
|
-
| `tfx swarm` | PRD-based, worktree-isolated work: `plan`, `preflight`, `run`, `list` |
|
|
131
|
-
| `tfx synapse` | Swarm session registry and leases |
|
|
132
|
-
| `tfx hub` | Local Hub: `start`, `stop`, `status`, `ensure` |
|
|
137
|
+
| `tfx multi` | Local multi-CLI team in tmux |
|
|
133
138
|
| `tfx mcp` | Managed MCP registry: `list`, `sync`, `add`, `remove` |
|
|
134
|
-
| `tfx handoff` | Serialize the current context for another session or host |
|
|
135
139
|
| `tfx cto` | Repo-local authority console: `collect`, `status`, `hygiene` (dry-run) |
|
|
136
|
-
| `
|
|
137
|
-
| `tfx
|
|
138
|
-
| `tfx notion-read`, `tfx why`, `tfx schema`, `tfx list`, `tfx monitor`, `tfx update`, `tfx version` | Notion → Markdown, commit intent trailers, CLI schemas, installed skills, TUI monitor, update, version |
|
|
140
|
+
| `bash ~/.claude/scripts/tfx-route.sh code-reviewer "<instruction>"` | Send review to Codex (`codex exec review` via policy) |
|
|
141
|
+
| `tfx list`, `tfx update`, `tfx version` | Installed skills, update, version |
|
|
139
142
|
| `tfx-live` | Live session bridge (same as the `/tfx-live` skill) |
|
|
140
143
|
|
|
141
|
-
`tfx <command> --help`
|
|
144
|
+
`tfx <command> --help` prints the exact arguments.
|
|
142
145
|
|
|
143
146
|
## Runtime features
|
|
144
147
|
|
|
145
148
|
**Live sessions.** `tfx-live` drives Claude Code and Codex TUI sessions. Claude daemon targets
|
|
146
149
|
(`--short`/`--session-id`) try UDS first and fall back to tmux when `--session` is also given;
|
|
147
|
-
Codex
|
|
148
|
-
|
|
149
|
-
`
|
|
150
|
+
Codex `ask` queues the message with `codex queue` (shown in the TUI with a
|
|
151
|
+
`[from <sender>]` first line) and falls back to tmux with a reported reason; UDS stays available with
|
|
152
|
+
`--transport uds --thread <id|auto>`. `peer` relays between two sessions for `--rounds`. triflux's Codex hook records running Codex
|
|
150
153
|
sessions under `~/.local/state/triflux/codex-sessions/`, so `tfx-live list-sessions --cli codex|claude`
|
|
151
154
|
also finds sessions you started yourself in tmux.
|
|
152
155
|
|
|
@@ -154,10 +157,9 @@ also finds sessions you started yourself in tmux.
|
|
|
154
157
|
gets past Claude Code's 600-second Bash limit. Follow up with `--job-status`, `--job-wait`, and
|
|
155
158
|
`--job-result`.
|
|
156
159
|
|
|
157
|
-
**
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
the `claude agents` panel unless you pass `--no-native-bridge-ui`.
|
|
160
|
+
**Headless workers.** Workers from `tfx-auto` and `tfx multi` appear in
|
|
161
|
+
the `claude agents` panel unless you pass `--no-native-bridge-ui`. Press Enter on a row to open the
|
|
162
|
+
tmux pane the worker runs in.
|
|
161
163
|
|
|
162
164
|
**Retry and escalation.** `--retry ralph` loops until done or stuck (three identical failures).
|
|
163
165
|
`--retry auto-escalate` steps from Codex `gpt6_astra_max` to Claude `fable`; override the chain in
|
|
@@ -171,11 +173,11 @@ falling back. Details: [`.claude/rules/tfx-machine-profile.md`](.claude/rules/tf
|
|
|
171
173
|
**CTO lake.** Run `tfx cto collect` to refresh the repo snapshot in `.triflux/lake/`, then
|
|
172
174
|
`tfx cto status` to inspect it with its generation time and age. `tfx cto hygiene --dry-run` reports
|
|
173
175
|
dry-run findings. The tray and unused CTO operating commands were removed
|
|
174
|
-
([ADR-0024](docs/adr/0024-cto-explicit-queries-only.md)). Automatic collection stays off unless `TFX_CTO_AUTO_COLLECT=1` is set ([ADR-0018](docs/adr/0018-cto-auto-behaviors-opt-in.md)).
|
|
176
|
+
([ADR-0024](docs/adr/0024-cto-explicit-queries-only.md)). Automatic collection stays off unless `TFX_CTO_AUTO_COLLECT=1` is set ([ADR-0018](docs/_archive/adr/0018-cto-auto-behaviors-opt-in.md)).
|
|
175
177
|
|
|
176
|
-
|
|
177
|
-
(Windows: `%APPDATA%\triflux\hosts.json`).
|
|
178
|
-
|
|
178
|
+
**원격 호스트.** `/tfx-remote`는 `~/.config/triflux/hosts.json`에서 호스트를 읽는다
|
|
179
|
+
(Windows: `%APPDATA%\triflux\hosts.json`). 세션 시작은 `remote-spawn.mjs`의
|
|
180
|
+
`--host <host> --prompt "<요청>"` 옵션을 사용한다. [실행 옵션](skills/tfx-remote/SKILL.md)을 따른다.
|
|
179
181
|
|
|
180
182
|
## Architecture
|
|
181
183
|
|
|
@@ -185,18 +187,14 @@ graph TD
|
|
|
185
187
|
User --> CLI[tfx CLI]
|
|
186
188
|
Skills --> Route[tfx-route.sh]
|
|
187
189
|
Skills --> Live[tfx-live]
|
|
188
|
-
CLI --> Team["tfx multi
|
|
190
|
+
CLI --> Team["tfx multi"]
|
|
189
191
|
Route --> Codex[Codex CLI]
|
|
190
192
|
Route --> Agy[Antigravity agy]
|
|
191
193
|
Route --> Claude[Claude Code]
|
|
192
194
|
Team --> Route
|
|
193
|
-
Team --> WT[(git worktrees)]
|
|
194
195
|
Live -->|UDS or tmux| Sessions[Claude / Codex TUI sessions]
|
|
195
|
-
Route -->
|
|
196
|
-
Team -->
|
|
197
|
-
Hub --> Store[(SQLite or memory store)]
|
|
198
|
-
Hub --> MCP[MCP tools]
|
|
199
|
-
Hub --> UI["HUD · claude agents panel"]
|
|
196
|
+
Route --> UI["HUD · claude agents panel"]
|
|
197
|
+
Team --> UI
|
|
200
198
|
CLI --> Lake[(".triflux/lake (tfx cto)")]
|
|
201
199
|
```
|
|
202
200
|
|
|
@@ -211,8 +209,8 @@ Package layout and execution paths: [ARCHITECTURE.md](ARCHITECTURE.md). Document
|
|
|
211
209
|
| Linux | tmux | Supported. |
|
|
212
210
|
| Windows | psmux + Windows Terminal | See below. |
|
|
213
211
|
|
|
214
|
-
**Windows.** psmux (a tmux fork) runs PowerShell by default.
|
|
215
|
-
|
|
212
|
+
**Windows.** psmux (a tmux fork) runs PowerShell by default. Callers do not run `wt.exe` or raw
|
|
213
|
+
`psmux kill-session` directly; tabs and panes go through the `tfx-wt` skill (set up only on
|
|
216
214
|
Windows) and `hub/team/wt-manager.mjs`. Agent rules:
|
|
217
215
|
[`.claude/rules/tfx-psmux.md`](.claude/rules/tfx-psmux.md).
|
|
218
216
|
|
|
@@ -220,9 +218,7 @@ Windows) and `hub/team/wt-manager.mjs`. Agent rules:
|
|
|
220
218
|
|
|
221
219
|
| Layer | Protection |
|
|
222
220
|
| --- | --- |
|
|
223
|
-
| Managed routes | Codex and Antigravity are called through `tfx-route.sh`,
|
|
224
|
-
| safety-guard hook | Blocks destructive shell commands (root `rm -rf`, force push to main, `git clean -fd`, SQL `DROP`), direct `wt.exe`, raw psmux kill, and bash syntax sent over SSH to Windows hosts, and points to the managed alternative. |
|
|
225
|
-
| Hub | Binds to localhost; optional bearer token (`TFX_HUB_TOKEN`). |
|
|
221
|
+
| Managed routes | Codex and Antigravity are called through `tfx-route.sh`, headless workers, or `tfx`, never through a bare `codex exec` or `agy`. This is a rule for callers; no hook enforces it. |
|
|
226
222
|
| MCP registry | Replaces stale or unsupported MCP entries with managed ones. |
|
|
227
223
|
| Consensus | Deep and consensus runs report degraded or disputed results instead of hiding them. |
|
|
228
224
|
|