diff --git a/agent-ops/skills/project/dev-corp-runtime-deploy/SKILL.md b/agent-ops/skills/project/dev-corp-runtime-deploy/SKILL.md index bf9bc4e..a0766b1 100644 --- a/agent-ops/skills/project/dev-corp-runtime-deploy/SKILL.md +++ b/agent-ops/skills/project/dev-corp-runtime-deploy/SKILL.md @@ -1,6 +1,6 @@ --- name: dev-corp-runtime-deploy -version: 1.0.0 +version: 1.0.1 description: dev-corp 배포, 회사망 mac-mini Edge와 내부 DGX/Mac Studio provider pool 배포 및 OpenAI-compatible capacity smoke 절차 --- @@ -8,7 +8,7 @@ description: dev-corp 배포, 회사망 mac-mini Edge와 내부 DGX/Mac Studio p ## 목적 -dev-corp provider pool을 현재 dev-runtime과 같은 구조로 배포한다. 배포는 mac-mini checkout 준비, source clean sync, 테스트, dev-corp runtime rebuild, Edge/Node 재시작, provider snapshot 기반 capacity 검증까지 포함한다. +dev-corp provider pool을 현재 dev-runtime과 같은 구조로 배포한다. 배포는 mac-mini checkout 준비, source clean sync, 테스트, dev-corp runtime rebuild, native Control Plane 활성화, Edge/Node 재시작, provider snapshot 기반 capacity 검증까지 포함한다. ## 언제 호출할지 @@ -32,27 +32,28 @@ dev-corp provider pool을 현재 dev-runtime과 같은 구조로 배포한다. - [ ] mac-mini에 `/Users/fe/agent-work/iop-dev-corp` checkout이 없으면 배포를 시작하지 말고 checkout 생성과 source sync를 setup blocker로 보고한다. - [ ] mac-mini에서 `192.168.2.2:8002`, `192.168.2.4:8004`, `192.168.2.3:8004`의 `/health`와 `/v1/models`가 성공하는지 확인한다. - [ ] Edge config의 OpenAI-compatible adapter endpoint는 각 Node process 기준으로 평가된다. direct preflight는 `192.168.2.x` 주소로 하되, Edge가 Node에 내려주는 provider endpoint는 node-local `127.0.0.1:`를 우선한다. -- [ ] DGX Spark 02가 mac-mini `172.24.63.178:18085/18086/18087`에 직접 접근하지 못하면 mac-mini에서 reverse SSH tunnel을 유지하고 node02 Edge addr을 tunnel local port로 설정한다. -- [ ] `gemma4:26b` alias와 총 capacity `13`은 target 후보이다. Edge config 반영과 capacity smoke가 통과하기 전에는 확정값으로 보고하지 않는다. +- [ ] DGX Spark 01/02가 mac-mini `172.24.63.178:18085/18086/18087`에 직접 접근하지 못하면 mac-mini에서 reverse SSH tunnel을 유지하고 해당 Node Edge addr을 tunnel local port로 설정한다. +- [ ] `gemma4:26b` alias와 총 capacity `13`은 `agent-test/dev-corp/inventory.yaml`의 최신 검증 상태를 기준으로 판단한다. 새 배포에서 Edge config 반영과 capacity smoke가 통과하기 전에는 새 결과를 확정값으로 보고하지 않는다. - [ ] DGX Spark vLLM provider는 capacity `4`, 호출당 최대 context window `262144`, requested KV `262144x2` 이상을 기준으로 한다. vLLM에는 vLLM-MLX식 `--max-kv-size`가 없으므로 실제 KV cache는 `gpu_memory_utilization` 적용 후 startup log의 `GPU KV cache size`와 `Maximum concurrency for 262,144 tokens per request`로 검증한다. DGX01/02 검증 기준은 `--max-num-seqs 4`, `--max-model-len 262144`, `--gpu-memory-utilization 0.40`이고, FP4 MoE 커널 한계 보정을 위해 `VLLM_MAX_TOKENS_PER_EXPERT_FP4_MOE=4194304`도 함께 둔다. - [ ] DGX Spark 02 endpoint는 Docker publish 때문에 `192.168.2.4:8004`이다. `8000`, `8001`, `8002`를 기본 endpoint로 쓰지 않는다. - [ ] Mac Studio `192.168.2.3:8005` DiffusionGemma endpoint는 secondary provider 후보이며 기본 pool에 자동 포함하지 않는다. -- [ ] Mac Studio `192.168.2.3:8004` vLLM-MLX runtime은 capacity `5`, 호출당 최대 context window `262144`, requested KV `262144x3` 기준으로 `--max-num-seqs 5`, `--max-request-tokens 262144`, `--max-kv-size 786432`을 사용한다. +- [ ] Mac Studio `192.168.2.3:8004` provider catalog type은 `openai_compat`이고 실제 runtime은 vLLM-MLX이다. vLLM-MLX runtime은 capacity `5`, 호출당 최대 context window `262144`, requested KV `262144x3` 기준으로 `--max-num-seqs 5`, `--max-request-tokens 262144`, `--max-kv-size 786432`을 사용한다. - [ ] Mac Studio `192.168.2.3:8004` vLLM-MLX runtime은 2026-06-25 기준 detached `screen` session `vllm_mlx_8004`로 관리한다. 이 host는 Python `pyexpat` 로딩에 `DYLD_LIBRARY_PATH=/opt/homebrew/opt/expat/lib`가 필요하므로 재시작 명령에 반드시 포함한다. - [ ] 현재 구현의 completion 검증 대상은 legacy `/v1/completions`가 아니라 `/v1/chat/completions`이다. `/v1/completions`는 route가 구현되어 있을 때만 별도 검증한다. - [ ] dev-corp current runtime은 OpenAI-compatible bearer token이 켜져 있다. smoke는 token 원문을 출력하지 말고 `OPENAI_API_KEY=$(cat build/dev-corp-runtime/.secrets/openai_api_key)` 또는 `--api-key-file`로 실행한다. - [ ] token, secret header, bootstrap token, private key 경로는 최종 보고에 원문으로 출력하지 않는다. -## 2026-06-25 known runtime update notes +## known/current runtime update notes - DGX Spark 01/02의 requested KV `262144x2`는 vLLM에서 직접 `--max-kv-size`로 표현하지 않는다. `--max_num_batched_tokens`는 scheduler iteration budget이므로 KV cache 총량으로 취급하지 않는다. dev-corp 기준은 `--max-model-len 262144`와 `gpu_memory_utilization` 적용 후 startup log의 KV cache/concurrency 확인이다. - DGX Spark에서 explicit `--max-num-batched-tokens 524288`를 사용하는 경우 first profile 중 FP4 MoE token-per-expert 기본 한계에 걸릴 수 있다. `VLLM_MAX_TOKENS_PER_EXPERT_FP4_MOE=4194304`를 반드시 유지한다. - DGX Spark 01은 FlashInfer FP4 JIT가 first compile 중 `ninja` 실행 파일을 PATH에서 찾는다. `ninja`는 venv에 있으므로 `/home/digitalcommerce_dgx_spark_01/vllm_env/bin`을 PATH 앞에 둔다. - DGX Spark 02 Docker image `vllm/vllm-openai:latest`의 entrypoint는 이미 `vllm serve`이다. container command에는 `serve`를 중복으로 넣지 말고 positional model `/models/gemma-4-26B-A4B-it-NVFP4`부터 둔다. 현재 Docker publish는 host `8004` -> container `8004` 기준이다. - Mac Studio는 `DYLD_LIBRARY_PATH=/opt/homebrew/opt/expat/lib` 없이 Python `pyexpat` import가 실패할 수 있다. `screen` session `vllm_mlx_8004` 안에서 이 환경변수를 export한 뒤 시작한다. -- 2026-06-25 재확인 기준 DGX Spark 01은 `--gpu-memory-utilization 0.40`로 재기동 후 mac-mini public forward `http://172.24.63.178:8002`에서 `/health` 200, `/v1/models`, `/v1/chat/completions` 단문 smoke를 통과했고 startup log에서 GPU KV cache `804,421` tokens, full-context concurrency `3.07x`를 확인했다. +- 2026-07-02 재확인 기준 DGX Spark 01은 `--gpu-memory-utilization 0.40`로 재기동 후 mac-mini 내부 endpoint `http://192.168.2.2:8002`에서 `/health` 200과 `/v1/models` smoke를 통과했고 startup log에서 GPU KV cache `834,507` tokens, full-context concurrency `3.18x`를 확인했다. - 2026-06-25 재확인 기준 DGX Spark 02는 Docker `vllm-gemma4` host/container `8004`, `--gpu-memory-utilization 0.40`, `--max-model-len 262144`, `--max-num-seqs 4`로 동작하며 mac-mini와 node-local `/health`, `/v1/models`, 직접 동시성 `1..4` chat completion benchmark를 통과했다. startup log에서 GPU KV cache `860,222` tokens, full-context concurrency `3.28x`를 확인했다. -- 2026-06-25 재확인 기준 Mac Studio provider는 새 설정으로 `/health`와 직접 동시성 `1..5` benchmark를 통과했다. provider-pool 전체 Edge OpenAI-compatible capacity smoke는 별도로 검증해야 한다. +- 2026-07-02 기준 native Control Plane은 mac-mini provider-pool runtime에서 `18002/19004/19005`를 listen하고, Edge id `dev-corp-edge`가 `127.0.0.1:19005`로 connected 상태다. status URL은 `http://127.0.0.1:18002/edges/dev-corp-edge/status`이다. +- 2026-07-02 기준 provider-pool 전체 Edge OpenAI-compatible capacity smoke는 `/v1/responses`와 `/v1/chat/completions` 모두 14개 동시 요청 14/14 성공, peak total `in_flight=13`, `queued=3`, 완료 후 provider별 `in_flight=0`, `queued=0` 회복을 확인했다. ## 실행 절차 @@ -80,7 +81,7 @@ dev-corp provider pool을 현재 dev-runtime과 같은 구조로 배포한다. - mac-mini 또는 로컬 PATH에 Go가 없으면 시스템 전역 설치 대신 `build/.tools` 같은 ignored runtime 경로에 임시 Go toolchain을 두고 사용한다. 5. **dev-corp runtime rebuild** - - 같은 source ref에서 dev-corp Edge binary, mac node binary, Linux ARM64 node binary를 다시 빌드한다. + - 같은 source ref에서 dev-corp Control Plane binary, Edge binary, mac node binary, Linux ARM64 node binary를 다시 빌드한다. - mac-mini에서 직접 빌드할 수 없으면 같은 source ref 기준으로 로컬에서 빌드한 뒤 `rsync/scp`로 mac-mini runtime 경로에 배포한다. - Windows AMD64 node binary는 dev-corp 기본 provider pool 대상이 아니다. - stale binary가 의심되거나 `config refresh` subcommand, admin port, version 출력이 맞지 않으면 clean sync부터 다시 시작한다. @@ -91,13 +92,14 @@ dev-corp provider pool을 현재 dev-runtime과 같은 구조로 배포한다. - dry-run이 `rejected` 또는 예상 밖 `restart_required`를 반환하면 배포를 멈추고 config diff를 보고한다. 7. **배포와 재시작** - - Edge는 mac-mini에서 빌드 산출물 기준으로 재시작한다. + - Control Plane은 mac-mini에서 `build/dev-corp-runtime/bin/control-plane` 기준으로 `18002/19004/19005` dev-corp port를 listen하게 재시작한다. + - Edge는 mac-mini에서 빌드 산출물 기준으로 재시작하고, Edge config의 `control_plane.enabled=true`, `wire_addr=127.0.0.1:19005`를 확인한다. - DGX Spark 01/02는 Linux ARM64 node binary를 mac-mini 경유로 배포하고 기존 node process를 재시작한다. - Mac Studio는 macOS node binary를 mac-mini 경유로 배포하고 기존 node process를 재시작한다. - provider runtime 옵션을 갱신하는 배포라면 DGX Spark 01은 `/home/digitalcommerce_dgx_spark_01/start_vllm_8002.sh`의 `PATH=/home/digitalcommerce_dgx_spark_01/vllm_env/bin:$PATH`, `VLLM_MAX_TOKENS_PER_EXPERT_FP4_MOE=4194304`, `--max-num-seqs 4`, `--max-model-len 262144`, `--gpu-memory-utilization 0.40`를 확인하고 tmux `vllm_server_8002`를 재기동한다. FlashInfer FP4 JIT가 first compile 중 `ninja`를 PATH에서 찾는다. - provider runtime 옵션을 갱신하는 배포라면 DGX Spark 02는 Docker container `vllm-gemma4`를 image entrypoint `vllm serve` 기준으로 재생성한다. container env에는 `VLLM_MAX_TOKENS_PER_EXPERT_FP4_MOE=4194304`를 넣고, container args는 positional model `/models/gemma-4-26B-A4B-it-NVFP4` 뒤에 `--max-model-len 262144`, `--gpu-memory-utilization 0.40`, `--max-num-seqs 4`, `--port 8004`를 둔다. - provider runtime 옵션을 갱신하는 배포라면 Mac Studio는 `screen -dmS vllm_mlx_8004` 안에서 `DYLD_LIBRARY_PATH=/opt/homebrew/opt/expat/lib`를 export한 뒤 `vllm_mlx.cli serve`를 `--max-num-seqs 5`, `--max-kv-size 786432`, `--max-request-tokens 262144`로 재기동한다. - - Node bootstrap은 Edge의 `node register`가 출력한 OS별 완성 명령을 우선한다. 다만 node-local provider endpoint, 별도 `IOP_HOME`, 또는 node02 reverse tunnel처럼 host별 Edge addr이 필요한 경우에는 `~/iop-dev-corp-field/node.yaml`을 수동 배치할 수 있고, token 원문은 로그/보고에 남기지 않는다. + - Node bootstrap은 Edge의 `node register`가 출력한 OS별 완성 명령을 우선한다. 다만 node-local provider endpoint, 별도 `IOP_HOME`, 또는 DGX Spark 01/02 reverse tunnel처럼 host별 Edge addr이 필요한 경우에는 `~/iop-dev-corp-field/node.yaml`을 수동 배치할 수 있고, token 원문은 로그/보고에 남기지 않는다. 8. **배포 후 연결 검증** - Edge, OpenAI-compatible listener, Node TCP, admin port, Control Plane status port가 열려 있는지 확인한다. @@ -124,7 +126,7 @@ dev-corp provider pool을 현재 dev-runtime과 같은 구조로 배포한다. - [ ] mac-mini checkout이 배포 기준 ref로 clean sync되었는가 - [ ] provider direct endpoint 3개가 mac-mini에서 `/health`와 `/v1/models`에 성공했는가 - [ ] 빌드 전 `go test ./...`와 필요한 추가 테스트가 통과했는가 -- [ ] dev-corp Edge/mac/Linux ARM64 binary가 같은 source ref에서 rebuild되었는가 +- [ ] dev-corp Control Plane/Edge/mac/Linux ARM64 binary가 같은 source ref에서 rebuild되었는가 - [ ] 빌드 후 config check, refresh help, refresh dry-run이 통과했는가 - [ ] Edge와 3개 provider node가 재시작되고 connected 상태인가 - [ ] `/v1/responses` capacity smoke에서 총 capacity만큼 `in_flight`가 차고 초과 요청이 queue에 잡혔는가 @@ -139,9 +141,9 @@ dev-corp runtime 배포 결과 - Source: , clean= - Provider preflight: dgx01=, dgx02=, mac-studio= - Pre-build tests: - -- Build: edge=, mac-node=, linux-arm64-node= +- Build: control-plane=, edge=, mac-node=, linux-arm64-node= - Post-build checks: config-check=, refresh-help=, refresh-dry-run= -- Deployment: edge=, dgx01=, dgx02=, mac-studio= +- Deployment: control-plane=, edge=, dgx01=, dgx02=, mac-studio= - Ports: - Nodes: - Providers: diff --git a/agent-test/dev-corp/control-plane-smoke.md b/agent-test/dev-corp/control-plane-smoke.md index 071384d..426be42 100644 --- a/agent-test/dev-corp/control-plane-smoke.md +++ b/agent-test/dev-corp/control-plane-smoke.md @@ -3,7 +3,7 @@ test_env: dev-corp test_profile: control-plane-smoke domain: control-plane verification_type: smoke -last_rule_updated_at: 2026-06-29 +last_rule_updated_at: 2026-07-02 --- # control-plane-smoke dev-corp 테스트 @@ -33,7 +33,7 @@ last_rule_updated_at: 2026-06-29 - port: Control Plane HTTP `18002`, Client WS `19004`, CP-Edge wire `19005`, Edge-Node TCP transport `19006`, web/dev preview `13002`. - runtime: Go `1.24`, Docker compose - package manager: Go modules / Makefile -- docker: compose 검증은 mac-mini에서 `.env.dev-corp.example` 기준으로 수행한다. 파일 생성 전에는 compose 검증을 차단으로 보고한다. +- docker: compose 검증은 mac-mini에서 `.env.dev-corp.example` 기준으로 수행한다. 파일 생성 전에는 compose 검증을 차단으로 보고한다. provider-pool native runtime 검증은 `build/dev-corp-runtime/bin/control-plane`과 env override를 사용할 수 있다. - external service: postgres host publish `15402`, redis host publish `16302` - model endpoint: - credential: DB/Redis credential 원문은 문서에 기록하지 않는다. @@ -41,9 +41,10 @@ last_rule_updated_at: 2026-06-29 ## 명령 - setup: mac-mini 환경에서 `IOP_EDGE_NODE_TOKEN`을 안전하게 주입한 뒤 `docker compose --env-file .env.dev-corp.example up -d postgres redis control-plane edge web` +- setup-native: mac-mini `/Users/fe/agent-work/iop-dev-corp`에서 `IOP_LISTEN=0.0.0.0:18002 IOP_WIRE_LISTEN=0.0.0.0:19004 IOP_EDGE_WIRE_LISTEN=0.0.0.0:19005 build/dev-corp-runtime/bin/control-plane serve --config configs/control-plane.yaml` - lint: - unit: `go test ./apps/control-plane/...` -- smoke: `curl -fsS http://127.0.0.1:18002/healthz`, `curl -fsS http://127.0.0.1:18002/readyz` +- smoke: `curl -fsS http://127.0.0.1:18002/healthz`, `curl -fsS http://127.0.0.1:18002/readyz`, `curl -fsS http://127.0.0.1:18002/edges/dev-corp-edge/status` - e2e: `make test-control-plane-edge-wire`는 보조 smoke이며 기본 포트를 쓰는 스크립트이므로 dev-corp 포트 override 가능 여부를 먼저 확인한다. - model: - full-cycle: Control Plane command, health/readiness, wire hello 수동 검증 @@ -60,6 +61,14 @@ last_rule_updated_at: 2026-06-29 - docker compose control-plane service healthcheck를 확인한다. - Edge 포함 compose 검증에서는 `IOP_EDGE_NODE_TOKEN`을 mac-mini 환경에서 주입하고, token 원문은 tracked 파일에 기록하지 않는다. +## 2026-07-02 native Control Plane 상태 + +- mac-mini provider-pool runtime에서 Control Plane native binary `build/dev-corp-runtime/bin/control-plane`을 `18002/19004/19005` dev-corp 포트로 실행한다. +- Edge config는 `control_plane.enabled=true`, `wire_addr=127.0.0.1:19005`이며 Edge id는 `dev-corp-edge`다. +- `/edges`에서 `dev-corp-edge`가 `connected=true`로 관측된다. +- `/edges/dev-corp-edge/status`는 Edge-owned snapshot을 반환하며 3개 provider node의 `provider_snapshots`를 포함한다. 이 status는 provider capacity smoke의 `in_flight`/`queued` evidence 기준이다. +- 2026-07-02 capacity smoke에서 `/v1/responses`와 `/v1/chat/completions` 모두 peak total `in_flight=13`, `queued=3`, 완료 후 provider별 `in_flight=0`, `queued=0` 회복을 확인했다. + ## 판정 기준 - control-plane service가 dev-corp stack으로 기동되고 health endpoint가 성공 응답을 반환한다. diff --git a/agent-test/dev-corp/edge-smoke.md b/agent-test/dev-corp/edge-smoke.md index b7ddc4f..e544f5d 100644 --- a/agent-test/dev-corp/edge-smoke.md +++ b/agent-test/dev-corp/edge-smoke.md @@ -3,7 +3,7 @@ test_env: dev-corp test_profile: edge-smoke domain: edge verification_type: smoke -last_rule_updated_at: 2026-06-29 +last_rule_updated_at: 2026-07-02 --- # edge-smoke dev-corp 테스트 @@ -48,8 +48,9 @@ dev-corp provider pool과 3-node 연결 상태를 점검할 때는 `agent-test/d - Edge host: `Mac-mini.local`, `fe@172.24.63.178`, Apple M2 Pro / 16GB - Edge config: `build/dev-corp-runtime/edge.yaml` -- Edge id: `edge-dev-corp` -- Control Plane HTTP 후보: `http://127.0.0.1:18002` +- Edge id: `dev-corp-edge` +- Control Plane HTTP/status 후보: `http://127.0.0.1:18002`, `http://127.0.0.1:18002/edges/dev-corp-edge/status` +- Control Plane-Edge wire 후보: `127.0.0.1:19005` - bootstrap HTTP 후보: `http://172.24.63.178:18085` - Edge OpenAI-compatible base URL 후보: `http://172.24.63.178:18086/v1` - Edge-Node TCP transport 후보: `172.24.63.178:18087` @@ -61,14 +62,15 @@ dev-corp provider pool과 3-node 연결 상태를 점검할 때는 `agent-test/d - SSH/user: mac-mini에서 `ssh digitalcommerce_dgx_spark_01@192.168.2.2` - provider endpoint: `http://192.168.2.2:8002/v1` - Edge adapter endpoint: node-local `http://127.0.0.1:8002/v1` + - Edge connectivity: current native runtime uses mac-mini reverse SSH tunnel `127.0.0.1:28085/28087`; tunnel pid file is `build/dev-corp-runtime/node01-tunnel.pid`. - served model: `gemma-4-26B-A4B-it-NVFP4` - capacity baseline 후보: `4` - - runtime: tmux `vllm_server_8002`, start script `/home/digitalcommerce_dgx_spark_01/start_vllm_8002.sh`, `vllm=0.23.0`, `PATH=/home/digitalcommerce_dgx_spark_01/vllm_env/bin:$PATH`, `--max-num-seqs 4`, `--max-model-len 262144`, `--gpu-memory-utilization 0.40`, startup log GPU KV cache `804,421` tokens / full-context concurrency `3.07x`, `VLLM_MAX_TOKENS_PER_EXPERT_FP4_MOE=4194304` + - runtime: tmux `vllm_server_8002`, start script `/home/digitalcommerce_dgx_spark_01/start_vllm_8002.sh`, `vllm=0.23.0`, `PATH=/home/digitalcommerce_dgx_spark_01/vllm_env/bin:$PATH`, `--max-num-seqs 4`, `--max-model-len 262144`, `--gpu-memory-utilization 0.40`, 2026-07-02 startup log GPU KV cache `834,507` tokens / full-context concurrency `3.18x`, `VLLM_MAX_TOKENS_PER_EXPERT_FP4_MOE=4194304` - DGX Spark 02 vLLM node: `corp-dgx-spark-02-vllm-node` / `corp-dgx-spark-02-vllm` - SSH/user: mac-mini에서 `ssh dplab@192.168.2.4` - provider endpoint: `http://192.168.2.4:8004/v1` - Edge adapter endpoint: node-local `http://127.0.0.1:8004/v1` - - Edge connectivity: node02는 mac-mini `172.24.63.178:18085/18086` 직접 접근이 timeout이므로 mac-mini의 reverse SSH tunnel `127.0.0.1:28085/28087`을 사용한다. + - Edge connectivity: node02는 mac-mini `172.24.63.178:18085/18086/18087` 직접 접근이 timeout이므로 mac-mini의 reverse SSH tunnel `127.0.0.1:28085/28087`을 사용한다. - served model: `gemma-4-26B-A4B-it-NVFP4` - capacity baseline 후보: `4` - runtime: Docker container `vllm-gemma4`, start script `/home/dplab/start_vllm_gemma4_8004.sh`, host `8004` -> container `8004`, `vllm=0.23.0`, `--max-num-seqs 4`, `--max-model-len 262144`, `--gpu-memory-utilization 0.40`, startup log GPU KV cache `860,222` tokens / full-context concurrency `3.28x`, `VLLM_MAX_TOKENS_PER_EXPERT_FP4_MOE=4194304` @@ -76,6 +78,7 @@ dev-corp provider pool과 3-node 연결 상태를 점검할 때는 `agent-test/d - SSH/user: mac-mini에서 `ssh dc_dev@192.168.2.3` - provider endpoint: `http://192.168.2.3:8004/v1` - Edge adapter endpoint: node-local `http://127.0.0.1:8004/v1` + - Edge provider catalog type: `openai_compat`; provider runtime type remains `vllm-mlx`. - served model: `mlx-community/gemma-4-26b-a4b-it-nvfp4` - capacity baseline 후보: `5` (`--max-num-seqs 5` 기준) - runtime: `vllm-mlx=0.3.0`, start script `/Users/dc_dev/iop-dev-corp-field/start_vllm_mlx_8004.sh`, `--max-num-seqs 5`, `--max-kv-size 786432`, `--max-request-tokens 262144` @@ -83,13 +86,22 @@ dev-corp provider pool과 3-node 연결 상태를 점검할 때는 `agent-test/d Mac Studio의 `http://192.168.2.3:8005/v1` mlx-vlm DiffusionGemma endpoint는 확인된 secondary provider 후보지만, 기본 provider pool에는 넣지 않는다. 별도 alias와 capacity policy가 결정된 뒤 추가한다. -## 2026-06-25 provider runtime update 상태 +## provider runtime 설정/검증 상태 -- DGX Spark 01 provider runtime은 capacity `4`, context window `262144`, requested KV `262144x2` 이상의 기준으로 재설정했다. dev-corp DGX01 vLLM 기준으로는 `--max-num-seqs 4`, `--max-model-len 262144`, `--gpu-memory-utilization 0.40`, `VLLM_MAX_TOKENS_PER_EXPERT_FP4_MOE=4194304` 조합이며, startup log에서 GPU KV cache `804,421` tokens와 `262144` tokens/request concurrency `3.07x`를 확인했다. +- DGX Spark 01 provider runtime은 capacity `4`, context window `262144`, requested KV `262144x2` 이상의 기준으로 재설정했다. dev-corp DGX01 vLLM 기준으로는 `--max-num-seqs 4`, `--max-model-len 262144`, `--gpu-memory-utilization 0.40`, `VLLM_MAX_TOKENS_PER_EXPERT_FP4_MOE=4194304` 조합이며, 2026-07-02 startup log에서 GPU KV cache `834,507` tokens와 `262144` tokens/request concurrency `3.18x`를 확인했다. - DGX Spark 02 provider runtime은 capacity `4`, context window `262144`, requested KV `262144x2` 이상의 기준으로 설정됐다. Docker `vllm-gemma4`는 host/container `8004` 기준으로 동작하며 startup log에서 GPU KV cache `860,222` tokens와 `262144` tokens/request concurrency `3.28x`를 확인했다. - DGX Spark 01은 FlashInfer FP4 JIT가 `ninja`를 PATH에서 호출하므로 start script에 `PATH=/home/digitalcommerce_dgx_spark_01/vllm_env/bin:$PATH`를 둔다. - Mac Studio provider runtime은 capacity `5`, context window `262144`, requested KV `262144x3` 기준으로 `--continuous-batching`, `--max-num-seqs 5`, `--prefill-batch-size 5`, `--completion-batch-size 5`, `--chunked-prefill-tokens 1024`, `--max-request-tokens 262144`, `--max-kv-size 786432`, `--reasoning-parser gemma4`을 적용했고 `/health`, `/v1/models`, 직접 동시성 `1..5` chat completion benchmark 통과를 확인했다. -- 2026-06-25 재확인 기준 DGX Spark 01은 mac-mini public forward `http://172.24.63.178:8002`에서 `/health` 200, `/v1/models`, `/v1/chat/completions` 단문 smoke를 통과했다. DGX Spark 02는 mac-mini에서 SSH, provider `/health`, `/v1/models`가 회복됐고 직접 provider benchmark를 통과했다. Edge OpenAI-compatible capacity smoke는 별도로 재검증해야 한다. +- 2026-07-02 재확인 기준 DGX Spark 01은 mac-mini 내부 endpoint `http://192.168.2.2:8002`에서 `/health` 200과 `/v1/models`를 통과했다. DGX Spark 02는 mac-mini에서 SSH, provider `/health`, `/v1/models`가 회복됐고 직접 provider benchmark를 통과했다. Edge OpenAI-compatible capacity smoke는 Control Plane status snapshot 기준으로 재검증 완료됐다. + +## 2026-07-02 dev-corp native runtime 상태 + +- mac-mini checkout은 `5b1255a` 기준으로 clean sync/rebuild되었고, runtime 경로는 `/Users/fe/agent-work/iop-dev-corp/build/dev-corp-runtime`이다. +- Control Plane native runtime이 활성화되어 `18002` HTTP, `19004` Client WS, `19005` CP-Edge wire를 listen한다. Edge config의 `control_plane.enabled=true`, `wire_addr=127.0.0.1:19005`로 `dev-corp-edge`가 connected 상태다. +- Edge native runtime은 `18085` bootstrap, `18086` OpenAI-compatible, `18087` Edge-Node TCP, `19094` refresh admin을 listen한다. +- Mac Studio provider catalog `type`은 최신 config validator 기준으로 `openai_compat`를 사용한다. 실제 provider runtime은 vLLM-MLX이고 `runtime_type: vllm-mlx`로 추적한다. +- `/v1/responses` capacity smoke: 14개 동시 요청 14/14 성공, Control Plane `provider_snapshots` peak `in_flight=13`, `queued=3`, provider별 peak DGX01 `4/1`, DGX02 `4/1`, Mac Studio `5/1`, 완료 후 모두 `in_flight=0`, `queued=0`. +- `/v1/chat/completions` capacity smoke: 14개 동시 요청 14/14 성공, Control Plane `provider_snapshots` peak `in_flight=13`, `queued=3`, provider별 peak DGX01 `4/1`, DGX02 `4/1`, Mac Studio `5/1`, 완료 후 모두 `in_flight=0`, `queued=0`. ## 명령 diff --git a/agent-test/dev-corp/inventory.yaml b/agent-test/dev-corp/inventory.yaml index caccb3c..3b4ae1b 100644 --- a/agent-test/dev-corp/inventory.yaml +++ b/agent-test/dev-corp/inventory.yaml @@ -1,6 +1,6 @@ test_env: dev-corp profile: dev-corp-provider-pool -last_updated_at: "2026-06-29" +last_updated_at: "2026-07-02" source: remote_runner: @@ -8,7 +8,7 @@ source: repo_root: /Users/fe/agent-work/iop-dev-corp setup_required: true setup_status: deployed - current_observation: /Users/fe/agent-work/iop-dev-corp checkout and build/dev-corp-runtime runtime were created on 2026-06-25; /Users/fe/iop-field remains unrelated legacy field state + current_observation: /Users/fe/agent-work/iop-dev-corp checkout and build/dev-corp-runtime runtime were created on 2026-06-25, then clean-synced/rebuilt at source ref 5b1255a on 2026-07-02; /Users/fe/iop-field remains unrelated legacy field state clean_sync: - git fetch origin main - git reset --hard origin/main @@ -16,15 +16,17 @@ source: dirty_policy: discard edge: - id: edge-dev-corp + id: dev-corp-edge host: mac-mini ssh: fe@172.24.63.178 os: macOS 26.2 hardware: Apple M2 Pro / 16GB config_path: build/dev-corp-runtime/edge.yaml - control_plane_enabled_current_runtime: false + control_plane_enabled_current_runtime: true control_plane_http: http://127.0.0.1:18002 - control_plane_status_url: http://127.0.0.1:18002/edges/edge-dev-corp/status + control_plane_status_url: http://127.0.0.1:18002/edges/dev-corp-edge/status + control_plane_client_ws_runner: ws://127.0.0.1:19004/client + control_plane_edge_wire_addr_runner: 127.0.0.1:19005 bootstrap_http_public: http://172.24.63.178:18085 openai_base_url_public: http://172.24.63.178:18086/v1 openai_base_url_runner: http://127.0.0.1:18086/v1 @@ -36,6 +38,7 @@ edge: build: binaries: + control_plane: build/dev-corp-runtime/bin/control-plane edge: build/dev-corp-runtime/bin/iop-edge node_macos: build/dev-corp-runtime/bin/iop-node-darwin-arm64 node_linux_arm64: build/dev-corp-runtime/bin/iop-node-linux-arm64 @@ -47,7 +50,7 @@ model: alias_status: candidate alias_policy: expose one IOP model alias and map provider-specific served_model values per provider provider_capacity_total: 13 - provider_capacity_status: all_three_direct_provider_benchmarks_passed_edge_capacity_queue_not_run + provider_capacity_status: verified_with_control_plane_provider_snapshots_2026_07_02 context_window_max: 262144 runtime_capacity_targets: dgx_spark: @@ -67,12 +70,64 @@ model: - /v1/chat/completions concurrent_requests: capacity_plus_one expected_total_in_flight: 13 - expected_total_in_flight_status: target_unverified_until_edge_config_and_capacity_smoke + expected_total_in_flight_status: verified_2026_07_02 expected_min_queued: 1 extended_concurrent_requests: 16 extended_expected_min_queued: 3 prompt_policy: long_reasoning_allowed exact_output_match: false + latest_capacity_verification: + date: "2026-07-02" + source_ref: 5b1255abc5ad530ebfd7a65deecdf5575425a34c + control_plane_enabled: true + control_plane_status_url: http://127.0.0.1:18002/edges/dev-corp-edge/status + provider_snapshot_baseline: + total_capacity: 13 + providers: + corp-dgx-spark-01-vllm: + capacity: 4 + health: healthy + status: available + corp-dgx-spark-02-vllm: + capacity: 4 + health: healthy + status: available + corp-mac-studio-mlx-vllm: + capacity: 5 + health: healthy + status: available + responses: + concurrent_requests: 14 + ok: 14 + max_total_in_flight: 13 + max_total_queued: 3 + provider_max: + corp-dgx-spark-01-vllm: + max_in_flight: 4 + max_queued: 1 + corp-dgx-spark-02-vllm: + max_in_flight: 4 + max_queued: 1 + corp-mac-studio-mlx-vllm: + max_in_flight: 5 + max_queued: 1 + final_recovery: in_flight_0_queued_0 + chat_completions: + concurrent_requests: 14 + ok: 14 + max_total_in_flight: 13 + max_total_queued: 3 + provider_max: + corp-dgx-spark-01-vllm: + max_in_flight: 4 + max_queued: 1 + corp-dgx-spark-02-vllm: + max_in_flight: 4 + max_queued: 1 + corp-mac-studio-mlx-vllm: + max_in_flight: 5 + max_queued: 1 + final_recovery: in_flight_0_queued_0 latest_runtime_update: date: "2026-06-25" reason: user requested dev-corp node capacity/context/KV alignment @@ -93,15 +148,15 @@ model: - DGX Spark 01 FlashInfer FP4 JIT invokes ninja from PATH; start script now prefixes /home/digitalcommerce_dgx_spark_01/vllm_env/bin - Mac Studio vLLM-MLX pyexpat required DYLD_LIBRARY_PATH=/opt/homebrew/opt/expat/lib verification: - last_rechecked_at: "2026-06-25" + last_rechecked_at: "2026-07-02" mac_studio_health: passed dgx01_health: passed dgx02_health: passed direct_health_observation: - dgx01: public forward http://172.24.63.178:8002 returned /health 200, /v1/models exposed gemma-4-26B-A4B-it-NVFP4, and /v1/chat/completions returned OK after gpu_memory_utilization 0.40 restart + dgx01: mac-mini http://192.168.2.2:8002 returned /health 200 and /v1/models exposed gemma-4-26B-A4B-it-NVFP4 after vllm_server_8002 restart; startup log reported GPU KV cache size 834,507 tokens and 3.18x concurrency for 262,144-token requests dgx02: node-local http://127.0.0.1:8004 and mac-mini http://192.168.2.4:8004 returned /health 200, /v1/models exposed gemma-4-26B-A4B-it-NVFP4, and direct concurrency 1..4 chat completion benchmark passed mac_studio: node-local http://127.0.0.1:8004 and mac-mini http://192.168.2.3:8004 returned /health 200, /v1/models exposed mlx-community/gemma-4-26b-a4b-it-nvfp4, and direct concurrency 1..5 chat completion benchmark passed - edge_openai_smoke: target_unverified_until_edge_provider_pool_capacity_smoke + edge_openai_smoke: passed_with_control_plane_capacity_snapshot_2026_07_02 nodes: - id: corp-dgx-spark-01-vllm-node @@ -119,9 +174,16 @@ nodes: health: http://192.168.2.2:8002/health served_model: gemma-4-26B-A4B-it-NVFP4 capacity: 4 - capacity_status: configured_health_passed_direct_smoke - last_runtime_observation: restarted with gpu_memory_utilization 0.40; public forward http://172.24.63.178:8002 returned /health 200, /v1/models, and a chat completion; startup log reported GPU KV cache size 804,421 tokens and 3.07x concurrency for 262,144-token requests + capacity_status: configured_health_passed_direct_smoke_and_edge_capacity_smoke + last_runtime_observation: restarted with gpu_memory_utilization 0.40 on 2026-07-02; mac-mini http://192.168.2.2:8002 returned /health 200 and /v1/models; startup log reported GPU KV cache size 834,507 tokens and 3.18x concurrency for 262,144-token requests capacity_basis: dev-corp target baseline; vLLM --max-num-seqs 4, --max-model-len 262144, --gpu-memory-utilization 0.40; observed KV cache satisfies requested 262144x2 minimum + edge_connectivity: + mode: reverse_ssh_tunnel + reason: current node.yaml uses tunnel-local Edge addr in the native provider-pool runtime + tunnel_pid_file: /Users/fe/agent-work/iop-dev-corp/build/dev-corp-runtime/node01-tunnel.pid + remote_forwards: + artifact: 127.0.0.1:28085 -> mac-mini 127.0.0.1:18085 + edge_node_tcp: 127.0.0.1:28087 -> mac-mini 127.0.0.1:18087 runtime: host: spark-0b30 os: Ubuntu 24.04.3 LTS / aarch64 @@ -151,8 +213,8 @@ nodes: max_num_batched_tokens: auto_2496 max_num_batched_tokens_note: vLLM raised the default from 2048 to 2496 for the Gemma4 prefix-LM/video path; it is a scheduler iteration budget, not the total KV cache size context_window_max: 262144 - kv_size_tokens_effective: 804421 - full_context_concurrency_observed: 3.07 + kv_size_tokens_effective: 834507 + full_context_concurrency_observed: 3.18 - id: corp-dgx-spark-02-vllm-node alias: corp-dgx-spark-02-vllm @@ -169,7 +231,7 @@ nodes: health: http://192.168.2.4:8004/health served_model: gemma-4-26B-A4B-it-NVFP4 capacity: 4 - capacity_status: configured_health_passed_direct_smoke + capacity_status: configured_health_passed_direct_smoke_and_edge_capacity_smoke last_runtime_observation: Docker vllm-gemma4 running with gpu_memory_utilization 0.40; node-local and mac-mini /health passed, /v1/models exposed gemma-4-26B-A4B-it-NVFP4, and direct concurrency 1..4 chat completion benchmark passed; startup log reported GPU KV cache size 860,222 tokens and 3.28x concurrency for 262,144-token requests capacity_basis: dev-corp target baseline; Docker publishes host 8004 to container 8004; vLLM --max-num-seqs 4, --max-model-len 262144, --gpu-memory-utilization 0.40; observed KV cache satisfies requested 262144x2 minimum edge_connectivity: @@ -218,13 +280,14 @@ nodes: provider_pool_candidate: true provider: id: corp-mac-studio-mlx-vllm - type: vllm-mlx + type: openai_compat + runtime_type: vllm-mlx endpoint: http://192.168.2.3:8004/v1 edge_adapter_endpoint: http://127.0.0.1:8004/v1 health: http://192.168.2.3:8004/health served_model: mlx-community/gemma-4-26b-a4b-it-nvfp4 capacity: 5 - capacity_status: configured_health_passed_direct_smoke + capacity_status: configured_health_passed_direct_smoke_and_edge_capacity_smoke last_runtime_observation: screen vllm_mlx_8004 running with max_num_seqs 5, max_request_tokens 262144, max_kv_size 786432; node-local and mac-mini /health passed, /v1/models exposed mlx-community/gemma-4-26b-a4b-it-nvfp4, and direct concurrency 1..5 chat completion benchmark passed capacity_basis: vllm-mlx --max-num-seqs 5 with requested KV 262144x3 mapped to --max-kv-size 786432 runtime: diff --git a/agent-test/dev-corp/node-smoke.md b/agent-test/dev-corp/node-smoke.md index ae54a2e..356a381 100644 --- a/agent-test/dev-corp/node-smoke.md +++ b/agent-test/dev-corp/node-smoke.md @@ -3,7 +3,7 @@ test_env: dev-corp test_profile: node-smoke domain: node verification_type: smoke -last_rule_updated_at: 2026-06-29 +last_rule_updated_at: 2026-07-02 --- # node-smoke dev-corp 테스트 @@ -43,16 +43,17 @@ last_rule_updated_at: 2026-06-29 ## dev-corp Node 접속 기준 -dev-corp의 실제 3-node 연결을 점검할 때는 mac-mini `ssh fe@172.24.63.178`의 `/Users/fe/agent-work/iop-dev-corp` checkout과 `build/dev-corp-runtime/edge.yaml`을 기준으로 한다. Node는 provider pool 기준에서 Edge-Node TCP `172.24.63.178:18087`로 붙는다. -단, DGX Spark 02는 2026-06-25 기준 mac-mini Edge port 직접 접근이 timeout이므로 `127.0.0.1:28087 -> mac-mini 127.0.0.1:18087` reverse SSH tunnel로 붙는다. +dev-corp의 실제 3-node 연결을 점검할 때는 mac-mini `ssh fe@172.24.63.178`의 `/Users/fe/agent-work/iop-dev-corp` checkout과 `build/dev-corp-runtime/edge.yaml`을 기준으로 한다. Node는 provider pool 기준에서 Edge-Node TCP `172.24.63.178:18087` 또는 host별 reverse SSH tunnel로 붙는다. +2026-07-02 현재 DGX Spark 01/02는 `127.0.0.1:28087 -> mac-mini 127.0.0.1:18087` reverse SSH tunnel로 붙고, Mac Studio는 직접 Edge TCP 후보를 사용한다. tunnel pid file은 mac-mini runtime의 `build/dev-corp-runtime/node01-tunnel.pid`, `build/dev-corp-runtime/node02-tunnel.pid`다. - DGX Spark 01 vLLM node: `corp-dgx-spark-01-vllm-node` / `corp-dgx-spark-01-vllm` - SSH/user: mac-mini에서 `ssh digitalcommerce_dgx_spark_01@192.168.2.2` - provider endpoint: `http://192.168.2.2:8002/v1` - Edge adapter endpoint: node-local `http://127.0.0.1:8002/v1` + - Edge addr: `127.0.0.1:28087` via mac-mini reverse SSH tunnel in the current native runtime - served model: `gemma-4-26B-A4B-it-NVFP4` - capacity baseline 후보: `4` - - runtime capacity/context/KV: `--max-num-seqs 4`, `--max-model-len 262144`, `--gpu-memory-utilization 0.40`; 2026-06-25 startup log 기준 GPU KV cache `804,421` tokens, `262144` full-context concurrency `3.07x`; FP4 MoE env `VLLM_MAX_TOKENS_PER_EXPERT_FP4_MOE=4194304` + - runtime capacity/context/KV: `--max-num-seqs 4`, `--max-model-len 262144`, `--gpu-memory-utilization 0.40`; 2026-07-02 startup log 기준 GPU KV cache `834,507` tokens, `262144` full-context concurrency `3.18x`; FP4 MoE env `VLLM_MAX_TOKENS_PER_EXPERT_FP4_MOE=4194304` - start script: `/home/digitalcommerce_dgx_spark_01/start_vllm_8002.sh` - 주의: FlashInfer FP4 JIT가 first compile 중 `ninja`를 호출하므로 start script에서 `/home/digitalcommerce_dgx_spark_01/vllm_env/bin`을 `PATH` 앞에 둔다. - workspace: `/home/digitalcommerce_dgx_spark_01` @@ -71,6 +72,7 @@ dev-corp의 실제 3-node 연결을 점검할 때는 mac-mini `ssh fe@172.24.63. - SSH/user: mac-mini에서 `ssh dc_dev@192.168.2.3` - provider endpoint: `http://192.168.2.3:8004/v1` - Edge adapter endpoint: node-local `http://127.0.0.1:8004/v1` + - Edge provider catalog type: `openai_compat`; provider runtime type remains `vllm-mlx`. - served model: `mlx-community/gemma-4-26b-a4b-it-nvfp4` - capacity baseline 후보: `5` (`--max-num-seqs 5` 기준) - runtime capacity/context/KV: `--max-num-seqs 5`, `--max-request-tokens 262144`, requested KV `262144x3` mapped to `--max-kv-size 786432` @@ -82,15 +84,22 @@ DGX Spark nodes는 Linux/ARM64 bootstrap을 기본으로 한다. Mac Studio node Mac Studio의 secondary `http://192.168.2.3:8005/v1` endpoint는 기본 Node/provider pool 검증 대상이 아니다. 별도 alias/capacity 정책이 확정된 후 추가한다. -## 2026-06-25 런타임 설정 반영 상태 +## 런타임 설정/검증 상태 - DGX Spark 01에는 capacity `4`, context window `262144`, requested KV `262144x2` 이상의 기준을 반영했다. vLLM에는 vLLM-MLX식 `--max-kv-size`가 없으므로 DGX01은 `--max-num-seqs 4`, `--max-model-len 262144`, `--gpu-memory-utilization 0.40`로 운용하고, 실제 KV cache는 startup log의 `GPU KV cache size`로 검증한다. -- DGX Spark 01은 2026-06-25 재기동 후 mac-mini public forward `http://172.24.63.178:8002` 기준 `/health` 200, `/v1/models`, `/v1/chat/completions` 단문 smoke를 통과했다. 같은 로그에서 GPU KV cache `804,421` tokens, `262144` tokens/request concurrency `3.07x`가 확인됐다. +- DGX Spark 01은 2026-07-02 재기동 후 mac-mini 내부 endpoint `http://192.168.2.2:8002` 기준 `/health` 200, `/v1/models` smoke를 통과했다. 같은 로그에서 GPU KV cache `834,507` tokens, `262144` tokens/request concurrency `3.18x`가 확인됐다. - DGX Spark 02에는 capacity `4`, context window `262144`, requested KV `262144x2` 이상의 기준을 반영했다. Docker `vllm-gemma4`는 host/container `8004` 기준으로 동작하며, node-local과 mac-mini 경유 `/health`, `/v1/models`, 직접 동시성 `1..4` chat completion benchmark를 통과했다. - DGX Spark에서 explicit `--max-num-batched-tokens 524288`를 사용하는 경우 first profile 중 FP4 MoE 커널 한계에 걸릴 수 있어 `VLLM_MAX_TOKENS_PER_EXPERT_FP4_MOE=4194304` 보정이 필요하다. - DGX Spark 01은 FlashInfer FP4 JIT가 first compile 중 `ninja`를 PATH에서 찾으므로 `/home/digitalcommerce_dgx_spark_01/vllm_env/bin` PATH prefix가 필요하다. - Mac Studio에는 capacity `5`, context window `262144`, requested KV `262144x3` 기준을 `--max-num-seqs 5`, `--max-request-tokens 262144`, `--max-kv-size 786432`로 반영했고 `/health`, `/v1/models`, 직접 동시성 `1..5` chat completion benchmark 통과를 확인했다. -- 2026-06-25 재확인 기준 DGX Spark 02는 mac-mini에서 SSH, provider `/health`, `/v1/models`가 회복됐고 직접 provider benchmark를 통과했다. Edge OpenAI-compatible capacity smoke는 별도로 재검증해야 한다. +- 2026-07-02 재확인 기준 DGX Spark 02는 mac-mini에서 SSH, provider `/health`, `/v1/models`가 회복됐고 직접 provider benchmark를 통과했다. Edge OpenAI-compatible capacity smoke는 Control Plane status snapshot 기준으로 재검증 완료됐다. + +## 2026-07-02 연결/용량 검증 상태 + +- dev-corp Control Plane native runtime이 활성화되어 `http://127.0.0.1:18002/edges/dev-corp-edge/status`에서 3개 provider node가 connected로 관측된다. +- DGX Spark 01, DGX Spark 02, Mac Studio Node binary는 source ref `5b1255a` 기준으로 재배포되었고 각 host의 `iop-dev-corp-field/iop-node`로 실행된다. +- Control Plane `provider_snapshots` 기준 provider 상태는 DGX01 capacity `4`, DGX02 capacity `4`, Mac Studio capacity `5`, 모두 `health=healthy`, `status=available`이다. +- `/v1/responses`와 `/v1/chat/completions` 각각 14개 동시 요청에서 peak total `in_flight=13`, `queued=3`을 관측했고, 완료 후 모든 provider가 `in_flight=0`, `queued=0`으로 회복했다. ## 명령 diff --git a/agent-test/dev-corp/platform-common-smoke.md b/agent-test/dev-corp/platform-common-smoke.md index 1648e2f..24d5e60 100644 --- a/agent-test/dev-corp/platform-common-smoke.md +++ b/agent-test/dev-corp/platform-common-smoke.md @@ -3,7 +3,7 @@ test_env: dev-corp test_profile: platform-common-smoke domain: platform-common verification_type: smoke -last_rule_updated_at: 2026-06-29 +last_rule_updated_at: 2026-07-02 --- # platform-common-smoke dev-corp 테스트 @@ -55,6 +55,7 @@ last_rule_updated_at: 2026-06-29 - config 계약 변경 시 `packages/go/config` struct/default와 `configs/*.yaml` 예시가 일치하는지 확인한다. - dev-corp env/compose 계약 변경 시 `.env.dev-corp.example`, `docker-compose.yml` 또는 compose override, `agent-test/dev-corp/rules.md`의 포트가 서로 일치하는지 확인한다. - provider config 변경 시 IOP model alias 후보 `gemma4:26b` 또는 작업에서 확정한 alias와 각 provider `served_model` 값이 `agent-test/dev-corp/inventory.yaml`과 맞는지 확인한다. +- Mac Studio vLLM-MLX provider config는 catalog `type: openai_compat`를 사용하고, 실제 runtime 구분은 `agent-test/dev-corp/inventory.yaml`의 `runtime_type: vllm-mlx`로 추적한다. ## 보조 검증 @@ -68,6 +69,7 @@ last_rule_updated_at: 2026-06-29 - 설정 예시는 loader/default와 어긋나지 않는다. - dev-corp 포트는 local/test/dev 포트를 덮어쓰지 않고 dev-corp profile에서만 사용된다. - provider-specific served model id 차이는 Edge/OpenAI-compatible 경계에서 내부 `adapter + target` 매핑으로 흡수된다. +- provider catalog type은 config validator가 허용하는 값과 일치해야 하며, runtime implementation label을 catalog type으로 대신 쓰지 않는다. ## 기준 출력 예시 diff --git a/agent-test/dev-corp/rules.md b/agent-test/dev-corp/rules.md index aa45093..0479866 100644 --- a/agent-test/dev-corp/rules.md +++ b/agent-test/dev-corp/rules.md @@ -1,6 +1,6 @@ --- test_env: dev-corp -last_rule_updated_at: 2026-06-29 +last_rule_updated_at: 2026-07-02 --- # dev-corp 테스트 규칙 @@ -22,7 +22,7 @@ last_rule_updated_at: 2026-06-29 ## 기본 환경 - host: Edge runner 후보는 `ssh fe@172.24.63.178` mac-mini이다. -- repo root: 목표 checkout은 `/Users/fe/agent-work/iop-dev-corp`이다. 2026-06-25 확인 기준 해당 checkout은 없고 `/Users/fe/iop-field`만 있으므로 최초 배포 전 repo root 생성이 필요하다. +- repo root: 목표 checkout은 `/Users/fe/agent-work/iop-dev-corp`이다. 2026-07-02 기준 해당 checkout과 `build/dev-corp-runtime` runtime이 배포되어 있으며, `/Users/fe/iop-field`는 unrelated legacy field state로 본다. - sync 기준: dev-corp 배포 전 mac-mini checkout은 배포 기준 ref로 clean sync하고 dirty 변경은 보존 대상으로 보지 않는다. - env file: compose stack을 만들면 `.env.dev-corp.example`로 분리한다. 파일 생성 전에는 native/provider-pool profile만 기준으로 삼는다. - compose identity: `COMPOSE_PROJECT_NAME=iop-dev-corp-agent`, `IOP_COMPOSE_NETWORK=iop-dev-corp-agent-net`. @@ -31,7 +31,7 @@ last_rule_updated_at: 2026-06-29 - runtime: Go quick check는 local toolchain을 우선한다. Docker/Flutter/client/field/bootstrap/provider-pool evidence는 mac-mini와 내부 provider nodes를 사용한다. - package manager: Go modules / Makefile / Flutter pub - docker: 현재 작업 컨테이너에서는 Docker-in-Docker를 사용하지 않는다. Docker compose 검증은 mac-mini checkout에서 수행한다. -- external service: dev-corp Control Plane 후보 `http://172.24.63.178:18002`, Client wire 후보 `ws://172.24.63.178:19004/client`. +- external service: dev-corp Control Plane 후보는 mac-mini local 기준 `http://127.0.0.1:18002`, 외부 후보 `http://172.24.63.178:18002`이다. Client wire 후보는 mac-mini local 기준 `ws://127.0.0.1:19004/client`, 외부 후보 `ws://172.24.63.178:19004/client`이다. - model endpoint: Edge 배포 후 후보 `http://172.24.63.178:18086/v1`; 직접 provider 확인은 `agent-test/dev-corp/inventory.yaml`의 provider endpoint를 따른다. - credential: secret/token/API key 원문은 문서에 기록하지 않는다. @@ -50,7 +50,7 @@ last_rule_updated_at: 2026-06-29 | PostgreSQL host publish | `15400` | `15401` | `15402` | | Redis host publish | `16300` | `16301` | `16302` | -dev-corp native/provider-pool profile은 compose Edge-Node TCP `19006`이 아니라 native Edge listen 후보 `18087`을 사용한다. 세부 provider endpoint와 Node 접속 기준은 `agent-test/dev-corp/inventory.yaml`, `agent-test/dev-corp/edge-smoke.md`, `agent-test/dev-corp/node-smoke.md`를 따른다. +dev-corp native/provider-pool profile은 compose Edge-Node TCP `19006`이 아니라 native Edge listen 후보 `18087`을 사용한다. DGX Spark 01/02처럼 직접 접근이 막힌 host는 mac-mini reverse SSH tunnel의 `127.0.0.1:28087`을 Node Edge addr로 사용할 수 있다. 세부 provider endpoint와 Node 접속 기준은 `agent-test/dev-corp/inventory.yaml`, `agent-test/dev-corp/edge-smoke.md`, `agent-test/dev-corp/node-smoke.md`를 따른다. ## 런타임 프로필 @@ -58,7 +58,8 @@ dev-corp native/provider-pool profile은 compose Edge-Node TCP `19006`이 아니 - remote runner: dev-corp runtime evidence, Flutter client, Docker compose, field/bootstrap, provider-pool evidence는 `ssh fe@172.24.63.178`의 `/Users/fe/agent-work/iop-dev-corp` 기준으로 수행한다. - compose dev-corp stack: `.env.dev-corp.example`, `COMPOSE_PROJECT_NAME=iop-dev-corp-agent`, `IOP_COMPOSE_NETWORK=iop-dev-corp-agent-net`, Edge-Node TCP `19006`을 사용한다. - Edge direct dev-corp profile: artifact/bootstrap `18085`, OpenAI-compatible `18086`, metrics `19102`, admin `19094`를 사용한다. -- dev-corp provider pool: `/Users/fe/agent-work/iop-dev-corp/build/dev-corp-runtime/edge.yaml`과 Edge-Node TCP `172.24.63.178:18087`을 사용한다. 3-node/provider 세부는 `agent-test/dev-corp/edge-smoke.md`와 `agent-test/dev-corp/node-smoke.md`를 따른다. +- dev-corp provider pool: `/Users/fe/agent-work/iop-dev-corp/build/dev-corp-runtime/edge.yaml`과 Edge-Node TCP `172.24.63.178:18087` 또는 host별 reverse SSH tunnel을 사용한다. 3-node/provider 세부는 `agent-test/dev-corp/edge-smoke.md`와 `agent-test/dev-corp/node-smoke.md`를 따른다. +- current native Control Plane: 2026-07-02 기준 provider-pool runtime에서 `build/dev-corp-runtime/bin/control-plane`이 `18002/19004/19005`를 listen하고, Edge id `dev-corp-edge`가 `127.0.0.1:19005`로 연결된다. provider snapshot status 기준은 `http://127.0.0.1:18002/edges/dev-corp-edge/status`다. - external provider field: DGX Spark 01/02와 Mac Studio는 mac-mini에서 내부 SSH로 접속한다. 직접 접속 경로와 provider endpoint는 `agent-test/dev-corp/inventory.yaml`을 따른다. ## 프리플라이트 @@ -67,7 +68,7 @@ dev-corp native/provider-pool profile은 compose Edge-Node TCP `19006`이 아니 - 테스트 환경 프리플라이트에는 runner, repo root/workdir, branch/HEAD/dirty 상태, local 변경과 원격 source 동기화 여부, binary/artifact 경로와 필요한 help/version 출력, config path, runtime identity, port/process 상태, 외부 host, OS/arch 가정을 포함한다. - mac-mini에 `/Users/fe/agent-work/iop-dev-corp` checkout이 없으면 배포/검증을 시작하지 말고 checkout 생성과 source sync를 setup blocker로 보고한다. - provider pool 검증 전 mac-mini에서 `192.168.2.2:8002`, `192.168.2.4:8004`, `192.168.2.3:8004`의 `/health`와 `/v1/models`를 먼저 확인한다. -- `gemma4:26b` alias와 총 capacity `13`은 dev-corp target 후보이며, Edge config 반영과 capacity smoke가 통과하기 전에는 확정값으로 보고하지 않는다. +- `gemma4:26b` alias와 총 capacity `13`은 `agent-test/dev-corp/inventory.yaml`의 최신 검증 상태를 기준으로 판단한다. 새 배포에서 Edge config 반영과 capacity smoke가 통과하기 전에는 새 결과를 확정값으로 보고하지 않는다. - 프리플라이트에서 dirty/divergent checkout 또는 stale artifact가 확인되면 dev-corp 배포에서는 먼저 원격 checkout을 clean sync하고 dev-corp runtime 바이너리를 rebuild한다. 잘못된 identity, missing command, closed port, host OS 불일치, source 미동기화가 확인되면 plan은 setup/sync/rebuild 단계를 만들거나 blocker로 보고한다. ## 노드/Provider 인벤토리 위치 @@ -85,7 +86,7 @@ dev-corp native/provider-pool profile은 compose Edge-Node TCP `19006`이 아니 - Node bootstrap은 Edge의 `node register`가 출력한 OS별 완성 명령을 그대로 사용한다. 사용자에게 안내하는 명령에는 임의 placeholder, 수동 token 치환, `IOP_*=` named environment parameter를 넣지 않는다. - token, API key, private credential 원문은 tracked docs, roadmap, 테스트 규칙에 기록하지 않는다. 실행 증거에는 token을 마스킹하거나 명령 생성 사실만 남긴다. - Linux/macOS Node는 생성된 `curl | bash` 계열 명령을 사용한다. Windows Node는 dev-corp provider pool의 기본 대상이 아니다. -- dev-corp runtime 배포는 clean sync 후 `build/dev-corp-runtime/bin/iop-edge`, mac node, Linux ARM64 node binary를 같은 source 기준으로 rebuild한다. +- dev-corp runtime 배포는 clean sync 후 `build/dev-corp-runtime/bin/control-plane`, `build/dev-corp-runtime/bin/iop-edge`, mac node, Linux ARM64 node binary를 같은 source 기준으로 rebuild한다. - provider capacity, model/provider mapping은 `config check`와 `config refresh --mode dry-run`을 통과한 뒤 `config refresh --mode apply`로 반영한다. refresh subcommand 또는 `19094` admin port가 없으면 바이너리 rebuild 누락으로 보고 먼저 rebuild한다. - Edge process restart 또는 일시 단절 후에는 Node reconnect 정책을 검증한다. retry 한계를 넘겨 Node process가 종료된 경우에만 해당 Node host에서 새 bootstrap 실행이 필요하다. diff --git a/agent-test/dev-corp/testing-smoke.md b/agent-test/dev-corp/testing-smoke.md index d5befbd..77b0646 100644 --- a/agent-test/dev-corp/testing-smoke.md +++ b/agent-test/dev-corp/testing-smoke.md @@ -3,7 +3,7 @@ test_env: dev-corp test_profile: testing-smoke domain: testing verification_type: smoke -last_rule_updated_at: 2026-06-29 +last_rule_updated_at: 2026-07-02 --- # testing-smoke dev-corp 테스트 @@ -37,7 +37,7 @@ last_rule_updated_at: 2026-06-29 - runtime: Go `1.24` - package manager: Go modules / Makefile - docker: quick check는 Docker를 요구하지 않는다. 현재 작업 컨테이너에서는 Docker-in-Docker를 사용하지 않으며, Docker compose 검증은 mac-mini 환경에서 수행한다. -- external service: dev-corp Control Plane 후보 `http://172.24.63.178:18002`, dev-corp Client wire 후보 `ws://172.24.63.178:19004/client`, dev-corp Edge runtime 후보 `172.24.63.178:18087` +- external service: dev-corp Control Plane 후보는 mac-mini local 기준 `http://127.0.0.1:18002`, 외부 후보 `http://172.24.63.178:18002`이다. Client wire 후보는 mac-mini local 기준 `ws://127.0.0.1:19004/client`, 외부 후보 `ws://172.24.63.178:19004/client`이다. dev-corp Edge runtime 후보는 `172.24.63.178:18087` 또는 host별 reverse SSH tunnel이다. - model endpoint: dev-corp OpenAI-compatible base URL 후보 `http://172.24.63.178:18086/v1` - credential: token/secret/API key 원문은 문서에 기록하지 않는다. @@ -49,6 +49,7 @@ last_rule_updated_at: 2026-06-29 - smoke: `./scripts/e2e-smoke.sh` - compose-smoke: mac-mini 환경에서 `IOP_EDGE_NODE_TOKEN`을 안전하게 주입한 뒤 `docker compose --env-file .env.dev-corp.example up -d postgres redis control-plane edge web` - compose-health: `curl -fsS http://127.0.0.1:18002/healthz` +- control-plane-status: mac-mini에서 `curl -fsS http://127.0.0.1:18002/edges/dev-corp-edge/status` - provider-health: mac-mini에서 `curl -fsS http://192.168.2.2:8002/health`, `curl -fsS http://192.168.2.4:8004/health`, `curl -fsS http://192.168.2.3:8004/health` - e2e: `make test-e2e` - model: `./scripts/e2e-openai-ollama.sh` 또는 dev-corp OpenAI-compatible smoke @@ -63,6 +64,7 @@ last_rule_updated_at: 2026-06-29 - field/bootstrap/deploy 작업은 one-line bootstrap UX 기준을 적용한다. - 사용자에게 전달하는 Node bootstrap 명령은 완성된 URL과 token positional value 하나만 포함한다. - dev-corp provider-pool 작업은 mac-mini에서 provider direct endpoint health를 먼저 확인한다. +- dev-corp native provider-pool capacity 검증은 Control Plane status의 `provider_snapshots`에서 `in_flight`/`queued`를 관측한다. ## 보조 검증 @@ -77,6 +79,7 @@ last_rule_updated_at: 2026-06-29 - node 로컬 `[node-message]` payload 라인 목록과 edge `[node-*-message]` payload 라인 목록이 run별로 내용/순서까지 동일해야 한다. - Node bootstrap UX는 Edge가 출력한 완성된 bootstrap URL과 실제 positional token 값 하나만 포함하는 한 줄 명령 형태를 유지한다. - dev-corp provider pool의 기본 endpoint 3개가 mac-mini에서 `/health`와 `/v1/models`에 성공 응답한다. +- native Control Plane이 활성화된 provider-pool 검증에서는 `dev-corp-edge`가 connected이고 capacity smoke 완료 후 provider `in_flight=0`, `queued=0`으로 회복해야 한다. ## 기준 출력 예시