Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

weave-instrument

БесплатноБез исполняемых скриптовНе проверен

Add Weave tracing to Python or TypeScript agents and LLM applications. Use when asked to instrument model calls, tools, or agent turns with Weave.

wandbот wandb★ 77 звёзд на GitHub

Об этом скилле

Weave instrumentation

Complete the login check before initializing tracing or sending data from this session. If no valid login exists, send only that section's reply and stop. The check does not gate code changes that read their credentials at runtime; see that section.

After a valid login, inspect the application's dependencies, agent boundaries, and existing OTel provider. Confirm entity/project and runtime credentials before sending data; never read, print, or commit API keys. Read trace fidelity before changing any instrumentation path. Initialize once at startup with weave.init("entity/project") in Python or await weave.init(...) in Node.

Fail open

Tracing must never stop or change the application. init contacts the trace server and raises when it is unreachable or rejects the credentials: catch that at startup, log it, and run untraced. If the application keeps its tracing settings in its own configuration rather than WANDB_* variables, build the exporter from them as in endpoint configuration, which does not contact the server at startup; do not rewrite process environment variables to feed init. Test startup and one full request with the trace URL pointed at a refused port, and with tracing unconfigured.

Check login first

The login check gates sending trace data from this session. If the request is to change code that reads its credentials at runtime, and this environment won't send data (CI, an offline sandbox, or a request that says it can't reach a trace server), skip the check: make the change, verify it with local tests and an in-memory exporter, and report backend delivery as unverified.

Otherwise, before editing code or initializing tracing, verify the existing W&B login for the target deployment with a noninteractive, read-only identity request through the configured SDK or connector. Use credentials in place; never print, copy, or inspect secret values. Do not call login or tracing init as a login probe.

If no valid login exists, stop. Do not edit, initialize, or continue this skill. Do not run wandb login in this session. This session's shell is not a normal terminal, so wandb login --verify exits with No API key configured instead of prompting. Do not ask for a key in this chat or create credentials.

Send only this, and nothing else. No decisions, notes, plans, or documentation links:

There's no W&B login yet, so this stops here. Open a new terminal tab and run wandb login --verify. Create an API key at https://wandb.ai/authorize?ref=models. If the browser opens a different page, open that link again. Paste the key in that terminal, not here, and type continue.

On a self-hosted or dedicated deployment, use wandb login --verify --host <base-url> and the authorize page that command prints. Still send only that.

  • If the check is unavailable or fails because of connectivity or permissions, report login/access as unverified and stop; do not assume credentials are invalid.
  • After the user continues, confirm the application runtime can use its own configured credentials and access entity/project. A browser login does not establish SDK authentication. Node/Forge runtimes without a .netrc fallback need credentials configured by the user through their runtime secret mechanism.

Choose the mechanism

  • Explicit agent spans: use the Session SDK for turns, model calls, tools, and delegation when auto-instrumentation cannot produce the required tree. Read the Python or TypeScript reference. Create spans with the SDK even when the application owns the TracerProvider: the SDK writes messages, usage, and tool results to the attributes the Agents view reads. Do not set gen_ai.* content attributes by hand; if the SDK cannot express a span, report that gap instead.
  • Auto-instrumentation: use only when the installed SDK captures the library and desired span shape. Check Python's INTEGRATION_MODULE_MAPPING or Node's integrations/hooks.ts, then verify emitted spans. Read auto-instrumentation caveats; registry membership alone does not prove capture is active. Avoid duplicate manual wrapping. Patched LLM-client integrations (OpenAI and LiteLLM among them) record each call as a classic Weave Call (a weave.op), not a chat span, so the call doesn't appear under a Session SDK turn. If turns come from the Session SDK, open LLM spans with it too and disable implicit patching (WEAVE_IMPLICITLY_PATCH_INTEGRATIONS=false) so calls aren't logged twice.
  • Existing OTel pipeline: add Weave export to that provider using endpoint configuration.

A turn spans one user exchange, including its tool loop. An LLM span covers one model call through stream completion; a Tool covers execution; a S

Полный SKILL.md на GitHub

Установить weave-instrument в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

references/otel_auto.mdreferences/otel_endpoint.mdreferences/read_back.mdreferences/session_sdk_python.mdreferences/session_sdk_typescript.mdreferences/trace_fidelity.md

FAQ

Что делает скилл weave-instrument?

Add Weave tracing to Python or TypeScript agents and LLM applications. Use when asked to instrument model calls, tools, or agent turns with Weave.

Как установить скилл weave-instrument?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл weave-instrument запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить weave-instrument с