본문으로 건너뛰기
Skillpedia
API 및 서버 (백엔드)21k · #10365

debug-inference

하는 일

이 스킬은 모델 호출이 OpenShell 제공자를 거칠 때 왜 실패하는지 AI가 알아내도록 돕습니다. 제공자, 허용된 엔드포인트, 로컬 모델 서버가 실행되는 위치를 확인합니다. 호스팅 또는 로컬 모델에 AI 앱을 연결하는 개발자를 위한 스킬입니다.

사용하는 경우

  • ✓OpenShell 안에서 앱의 모델 호출이 실패하는데 이유를 모를 때.
  • ✓Ollama나 vLLM 같은 로컬 모델을 OpenShell 샌드박스에 연결하고 싶을 때.
  • ✓오래된 관리형 추론 엔드포인트에서 제공자의 기본 엔드포인트로 옮기는 중일 때.

스킬 링크

https://github.com/NVIDIA/OpenShell/blob/main/skills/debug-inference/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/NVIDIA/OpenShell/blob/main/skills/debug-inference/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“내 앱이 OpenShell 안에서 로컬 Ollama 모델에 접근하지 못합니다. 이유를 찾도록 도와주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

AI는 게이트웨이와 샌드박스를 확인하고, 제공자와 프로필을 살펴본 다음, 엔드포인트에 닿는지와 허용되는지를 테스트합니다. 그 뒤 가능성 높은 원인을 설명합니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Debug Inference

Diagnose inference as ordinary provider-authorized network traffic. OpenShell no longer supplies a managed inference route, rewrites request shapes, or selects a model. The application calls the provider's native endpoint and owns its base URL, model, request format, and timeout.

Use installed openshell --help output as the authority for command syntax. Refer to the published provider management guide and provider profile guide for current behavior.

Diagnostic Workflow

1. Confirm Gateway and Sandbox Context

openshell status
openshell gateway info
openshell sandbox get <sandbox>

For a host-local model server, host.openshell.internal identifies the machine running the gateway. It does not identify the operator's laptop when the gateway is remote. A server listening only on 127.0.0.1 may also be unreachable from a container; bind it to an address reachable from the gateway runtime.

2. Inspect the Provider and Its Profile

openshell provider get <provider>
openshell profile export <profile-id> -o yaml

Check that the profile:

  • Names the exact endpoint host, port, and protocol the client calls.
  • Allows the client binary.
  • Declares the credential key and intended authentication style.
  • Uses narrow HTTP rules when the provider should expose only part of an API.

For a custom or self-hosted OpenAI-compatible endpoint, import an endpoint-bearing profile. A base URL stored only in provider configuration does not authorize a new endpoint.

openshell profile lint -f ./provider-profile.yaml
openshell profile import -f ./provider-profile.yaml
openshell provider create --name <provider> --type <profile-id>

Add the required --credential KEY or --credential KEY=VALUE arguments shown by the profile. Never broaden endpoint policy merely to silence a credential binding error.

3. Confirm Attachment

openshell sandbox provider list <sandbox>
openshell sandbox provider attach <sandbox> <provider> --wait --timeout 30

Save the change's receipt_id and use openshell sandbox provider status <sandbox> <provider> --receipt <receipt-id> --wait --timeout 30 to check when it takes effect. Success confirms that the sandbox applied the credentials, policy, and environment for new processes. If the result is pending, failed, withheld, or superseded, inspect its reason before launching the client.

Launch the client after the attachment wait succeeds so it receives the updated environment:

openshell sandbox exec <sandbox> -- <client-command>

After updating an ordinary static provider, wait for that change and launch a new client. An existing process keeps its revision-scoped reference; readiness does not make the old reference resolve the replacement value. Diagnose managed-refresh credentials according to their own lifecycle.

Keep credentials and issued references out of diagnostic output. Acknowledged detach revokes future credential resolution and removes the reference from future process environments. Requests already forwarded may still finish:

openshell sandbox provider detach <sandbox> <provider> --wait --timeout 30

4. Verify Native Client Configuration

The application must use the real upstream contract:

  • Native provider base URL, not the retired managed virtual endpoint.
  • Real model ID, not a placeholder that OpenShell used to rewrite.
  • Native OpenAI, Anthropic, Vertex, or other provider request shape.
  • Application-owned timeout and retry settings.
  • The credential environment variable declared by the attached profile.

Probe the exact endpoint from a newly launched sandbox process. Start with a non-secret discovery endpoint when the provider offers one, then send a minimal inference request using the provider's documented API shape.

5. Interpret Common Failures

Symptom Likely cause Fix
credential_placeholder_in_request_body A body reference is invalid/revoked, or classification metadata is unavailable Check the controlled denial reason; remove the reference from conversation history or restore provider access. Do not enable body credential rewriting or bypass flags to send tool output. Unknown literals and valid issued placeholders pass unchanged, including the model provider’s own placeholder. Header resolution
자주 묻는 질문

OpenShell이 모델을 고르거나 요청을 바꾸나요?

아닙니다. 앱이 제공자의 기본 엔드포인트를 호출하고, 자체 모델, 기본 URL, 요청 형식을 설정합니다.

로컬 모델 서버도 도울 수 있나요?

네. 게이트웨이 기기에서 실행되는 Ollama, vLLM, LM Studio 같은 서버를 다룹니다.

모델 서버가 localhost에서만 듣는다면요?

컨테이너에서는 접근할 수 없을 수 있으므로, 게이트웨이가 닿을 수 있는 주소에서 듣도록 해야 한다고 스킬이 알려 줍니다.

상세 정보

작성자의 원본 설명

Debug inference clients that use an attached provider and its native endpoint, including hosted APIs and host-local Ollama, vLLM, SGLang, TRT-LLM, LM Studio, or NIM. Use for provider attachment, endpoint policy, credential substitution, topology, and migration from the removed managed inference endpoint. Trigger keywords - debug inference, managed inference endpoint, local inference, ollama, lm studio, vllm, sglang, trtllm, NIM, inference failing, model server unreachable, credential_endpoint_mismatch, host.openshell.internal.

repo: NVIDIA/OpenShell

인기도

GitHub 스타
21k
순위
#10365
라이선스
Apache-2.0
업데이트
2026. 11. 2.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬