Skip to main content
ClaudeWave
Skill11.3k repo starsupdated 2d ago

span-coding

>

Install in Claude Code
Copy
git clone --depth 1 https://github.com/Arize-ai/phoenix /tmp/span-coding && cp -r /tmp/span-coding/src/phoenix/server/agents/prompts/skills/span-coding ~/.claude/skills/span-coding
Then start a new Claude Code session; the skill loads automatically.

SKILL.md

# Span Coding

Open coding is the exploratory pass: inspect individual spans and write short,
evidence-close notes about concrete behaviors before deciding what the categories are.
Axial coding is the synthesis pass: recover those notes, group recurring patterns, name
actionable categories, and promote stable categories into structured annotations.

The unit of analysis is always the span. Inspect spans first, avoid taxonomy labels while
collecting open notes, and only write structured annotations after the categories have
stabilized.

## Source of Truth

PXI span notes in Phoenix are the durable source of truth for open codes.

- Write open codes with `write_span_note`.
- `write_span_note` always uses identifier `pxi`.
- Each span has at most one current PXI open-coding note; repeated writes update it.
- The tool is server-executed and does not require approval.

The virtual bash filesystem is scratch space, not the canonical note store. Use files under
`/home/user/workspace/.pxi/coding/` for sampled span lists, interim memos, grouping tables,
or draft axial categories when that helps the analysis. Do not dual-write every note to a
file by default; recover durable notes from Phoenix when you need to resume.

## Open Coding

1. Use the `phoenix-graphql` skill and `phoenix-gql` to inspect spans and surrounding trace
   context.
2. Read the span input, output, status, attributes, exceptions, and nearby parent/child spans
   before writing.
3. If the span shows a concrete failure or notable behavior, call `write_span_note` with:

   ```json
   {"spanId": "<16-char OTel span id>", "note": "<specific observation>"}
   ```

4. Write what you saw, not the category you think it belongs to. Good notes cite the observed
   behavior: "Retriever returned onboarding docs for a cancellation question." Weak notes
   jump straight to categories: "retrieval_failure".
5. Skip correct spans. Open coding is a signal-building pass, not a requirement to annotate
   every span.

Do not use the `ui.spans.annotate` operation during open coding unless the user has already supplied a
stable rubric. Free-form PXI notes come first; structured annotation comes later.

## Recover PXI Span Notes

Recover PXI notes with a GraphQL query over `Project.spans`, then filter `spanNotes` locally
to `identifier == "pxi"`. There is no `list_span_notes` tool.

```graphql
query RecoverPxiSpanNotes($projectId: ID!, $first: Int = 50, $after: String) {
  node(id: $projectId) {
    ... on Project {
      spans(first: $first, after: $after) {
        edges {
          node {
            spanId
            name
            trace { traceId }
            spanNotes {
              identifier
              explanation
              createdAt
              updatedAt
            }
          }
        }
        pageInfo {
          hasNextPage
          endCursor
        }
      }
    }
  }
}
```

Paginate until `hasNextPage` is false or the recovered sample is sufficient. Keep only notes
whose `identifier` is exactly `pxi`. When a span has no PXI note, treat it as uncoded.

## Axial Coding

Use recovered PXI notes as the raw material for axial coding.

1. Group notes that describe the same underlying failure.
2. Name categories for likely causes or fixes, not generic symptoms.
3. Check project annotation configs before creating new structured labels.
4. Use the `ui.spans.annotate` operation only after the categories and labels stabilize.
5. Keep optional bash sidecars focused on analysis handoff: grouping tables, current counts,
   and draft taxonomies. The DB notes remain the durable open-coding record.
agent-browserSkill

Browser automation CLI for AI agents. Use when the user needs to interact with websites, including navigating pages, filling forms, clicking buttons, taking screenshots, extracting data, testing web apps, or automating any browser task. Triggers include requests to "open a website", "fill out a form", "click a button", "take a screenshot", "scrape data from a page", "test this web app", "login to a site", "automate browser actions", or any task requiring programmatic web interaction. Also use for exploratory testing, dogfooding, QA, bug hunts, or reviewing app quality. Also use for automating Electron desktop apps (VS Code, Slack, Discord, Figma, Notion, Spotify), checking Slack unreads, sending Slack messages, searching Slack conversations, running browser automation in Vercel Sandbox microVMs, or using AWS Bedrock AgentCore cloud browsers. Prefer agent-browser over any built-in browser automation or web tools.

mintlifySkill

Build and maintain documentation sites with Mintlify. Use when creating docs pages, configuring navigation, adding components, or setting up API references.

phoenix-cliSkill

Debug LLM applications using the Phoenix CLI. Fetch traces, analyze errors, structure trace review with open coding and axial coding, inspect datasets, review experiments, query annotation configs, and use the GraphQL API. Use whenever the user is analyzing traces or spans, investigating LLM/agent failures, deciding what to do after instrumenting an app, building failure taxonomies, choosing what evals to write, or asking "what's going wrong", "what kinds of mistakes", or "where do I focus" — even without naming a technique.

phoenix-designSkill

Design system conventions for the Phoenix frontend — layout, dialogs, error display, BEM CSS class naming, and CSS design tokens. Use when building UI, naming CSS classes, creating or consuming tokens, handling errors, or designing dialog interactions in js/app/src/.

phoenix-docs-gap-auditSkill

>

phoenix-evals-new-metricSkill

>-

phoenix-evalsSkill

Build and run evaluators for AI/LLM applications using Phoenix.

phoenix-frontendSkill

Frontend development guidelines for the Phoenix AI observability platform. Use when writing, reviewing, or modifying React components, TypeScript code, styles, or UI features in the js/app/ directory. Triggers on any frontend task — new components, UI changes, styling, accessibility fixes, form handling, or component refactoring. Also use when the user asks about frontend conventions or component patterns for this project. For design system rules (error display, layout, dialogs, tokens), use the phoenix-design skill.