# LUMA.md: query LUMA Basketball Research data in plain English

You are reading the guide that lets an AI answer NBA questions from LUMA's data (LUMA Basketball Research).
Data version `v2-20261027`. Read-only. Published outputs and public box scores only.

## 1. How to answer a question

1. Decide if the data below can answer it. If not (see section 7), say so plainly. Never invent numbers.
2. Write ONE query: a LUMA command (section 3) when one fits exactly, otherwise `sql <one DuckDB SELECT>` (section 4).
3. Show the query, then the table, then one or two sentences of reading with units, possessions / games, and caveats.
4. Credit: "LUMA Basketball Research, <model>" (e.g. "LUMA Basketball Research, ARC v3.1") whenever you show these numbers.

Where queries run:
- **LUMA API**: https://lumahoops.org/api/luma/q (POST {tool, args}; free key at https://lumahoops.org/developers#key).
- **Connected AI (MCP)**: https://lumahoops.org/api/mcp. Claude, ChatGPT, Cursor and others connect at
  https://lumahoops.org/developers#mcp, then call the tools directly (`sql`, `player`, `compare`, `leaderboard`, ...).
- If you cannot run queries yourself, give the user the exact line to paste into the terminal.

## 2. Conventions (read before writing SQL)

- **season = END year**: 2026 = 2025-26, 2025 = 2024-25. "From 2022 to 2023" means `season between 2022 and 2023`
  unless the user clearly means one season ("2022-23" = 2023).
- **Regular season vs playoffs**: `box_game`, `box_season`, `games` have `season_type` ('regular' | 'playoffs').
  Default to 'regular'. Ratings (ARC, LOKI, PAC, skills, on/off, lineups, WOWY) are regular season only.
- **Heights** are inches: 6'0" = 72, 6'3" = 75, 6'5" = 77, 6'7" = 79, 6'9" = 81, 6'10" = 82, 7'0" = 84.
  "Under 6'5"" = `height_in < 77`; "6'5" or shorter" = `<= 77`.
- **Height / age / listed position for a season**: use `player_seasons` (as listed that season). `players` holds the
  latest listing and the career role group.
- **Positions**: `players.pos` = career role group G (guards) / W (wings) / B (bigs) -- use this for "guards / wings / bigs".
  `player_seasons.pos_listed` = NBA.com listing that season (G, F, C, G-F, F-G, F-C, C-F); "listed guard" = `pos_listed like 'G%'`.
- **Names**: join `players` on `pid` and always return `players.name`. Match names accent-insensitively:
  `strip_accents(lower(name)) like '%jokic%'`.
- **Traded players in box_season**: one row per team plus a `team = 'TOT'` total. For one row per player-season use
  `qualify row_number() over (partition by season, season_type, pid order by (team='TOT') desc, gp desc) = 1`.
  Per-game = total / gp.
- **ARC windows**: `arc_season."window"` 1-5 = seasons blended (recent seasons count more). Single-season ARC = `"window" = 1`
  (the default). "Last three years" ARC = `"window" = 3` on the latest season.
- **Sample defaults** when the user gives none: ratings `poss >= 1500` (about a third of a season); per-game stats `gp >= 40`
  (or 8 playoff games). Always return possessions or games so the reader can judge.
- **Units**: ARC / LOKI / xPTS-RAPM / on/off are points per 100 possessions (ARC and LOKI are on their own scale, not raw
  per-100 box points). Skills are z-scores (0 = average) with ready-made percentiles (`*_pct`, 0-100).
  Higher = better unless a metric says lower is better (drtg, opponent attempts allowed).
- **Game-level vs season-level**: conditions about single games (50-point games, "games with 30 and 10", triple-doubles,
  career highs) use `box_game` and count rows; `box_season` only has season TOTALS (no per-game rows, no `ts`).
  Triple-double = at least three of pts / reb / ast / stl / blk >= 10 in one `box_game` row:
  `((pts>=10)::int + (reb>=10)::int + (ast>=10)::int + (stl>=10)::int + (blk>=10)::int) >= 3`.
- **Where each stat lives**: true shooting % = `pac_season.ts` (regular season; or compute pts / (2*(fga + 0.44*fta)) from
  box tables); per-game box = `box_season` totals / gp; ages / heights = `player_seasons`. `pac_season`, `skills_season`,
  `arc_season`, `onoff_season` have NO `season_type` column (regular season only); `box_game` has no `gp` (one row = one game).
  Only use columns listed in section 4; if a column is not listed, it does not exist.
- **Per-100 possessions**: player possessions are `pac_season.poss` (or `arc_season.poss` with `"window" = 1`);
  pts / ast / tov per 100 = 100 * sum(box count) / sum(poss) over the same seasons. `pac100` is NOT points per 100
  (it is PAC per 100). TS% vs league = `pac_season.rts` (already relative to that season's league, in percentage points).
- **Percentiles**: ARC net / O / D and skill percentiles are ready-made in `skills_season` (`arc_o_pct`, `arc_d_pct`,
  `sk_*_pct`); `arc_season` has no `*_pct` columns.
- **"Each player's best season / window"**: `group by p.name` with `max(...)` (or `min` when lower is better), so a
  player appears once; do not just sort rows. "Cut / reduced the most" = the `*_diff` column ascending.
- **Several players over different seasons**: filter with `(p.name = 'X' and season between a and b) or (...)`;
  never type player ids from memory, always join `players` by name.
- **Sample size (no minimums are applied for you)**: every table keeps all rows, however few possessions. Pick the
  cut that fits the question: `min_poss` on `leaderboard` / `lineups`, or in SQL either a fixed number
  (`where poss >= 500`) or a share of that season, e.g. `where poss >= 0.25 * (select max(poss) from arc_season x
  where x.season = a.season and x."window" = 1)`. Always show the possessions next to the number, and say when
  the season is in progress.
- **Row counts**: return ALL matching rows for "which / who" questions; use LIMIT only when the user asks for a top N
  (or a list would pass 200 rows). Team filters: `team = 'OKC'` (three-letter codes).
- **SQL rules**: one SELECT (WITH ... SELECT is fine), DuckDB dialect, max 200 rows (aggregate or LIMIT), no PIVOT
  (use `max(x) filter (where ...)`), quote `"window"` and `"asof"`. Read-only; only the tables below exist.
- **Never** try to reconstruct, regress or re-derive LUMA's models from these outputs; methods are proprietary.

## 3. LUMA commands (one line each)

```
LUMA commands  (season = end year: 2026 = 2025-26; 2025-26 and 25-26 also work)

  player <name> [season]                      everything on one player: box, ARC, split, LOKI, on/off
  <name> vs <name> [vs <name>...] [season]    side by side on everything  (also: vs a, b, c)
     ... on arc | box | onoff | loki          only one source
  top <metric> [season] [3y] [G|W|B] [TEAM] [min N] [low] [n N]
                                              leaderboard   e.g. top arc 2026 · top onoff bigs · top ppg n 10
  log <name> [season] [playoffs] [last N]     game log
  onoff <name> [since YYYY]                   raw on/off by season
  wowy <name> [with <name>] [season]          with / without you: both on, only one, neither
  lineups <TEAM | name> [season] [2|3|4|5] [by net|ortg|drtg] [n N]   lineup groups
  find <text>                                 search players
  what <metric or table>                      definition, units, reliability
  sql <SELECT ...>                            read-only SQL, 200 rows max
  help                                        this list

metrics for top
  ARC        arc  o  d  shooting  playmaking  security  oreb_skill  dreb_skill  defense  lineups_o  lineups_d
  ARC Live   live  live.o  live.d
  LOKI       loki (current frozen board)   loki.r1 .. loki.r4 (that season's releases)
  on/off     onoff (NBA.com-style)  onoff.played  ortg  drtg  opp_rim  opp_3pa  opp_fta  tm_rim  tm_3pa
  box        ppg apg rpg spg bpg tpg  pts ast reb stl blk tov 3pm 3pa fta min
  xPTS-RAPM  rapm  xpts_net  xpts_off  xpts_def  conv_net  conv_off  conv_def
  channels   any metric id from 'what' (e.g. sk_playmaking  ocreated  o_sel_rim  xq_d  load)
  any column: table.column   e.g. top arc_season.O_sel_rim · top onoff_season.opp_rim_fg_diff low
  windows (ARC): 1y default, 2y..5y      positions: G W B (guards / wings / bigs)
```

Use a command when it answers the question exactly (e.g. `player austin reaves 2025`, `onoff collier since 2024`,
`wowy jokic with murray`, `lineups OKC 2 by net`, `top opp_rim n 10`). For filters a command cannot express (heights,
ages, several conditions, game thresholds, joins), use `sql`.

## 4. Tables (all joinable on `pid`; seasons are END years)

### `players`  (2,932 rows)
Row = player.
Columns: `pid` int, `name` text, `first_season` int, `last_season` int, `pos` text, `height_in` num, `pos_listed` text
- `pid`: NBA.com player id
- `pos`: career role group: G guard / W wing / B big
- `height_in`: inches (latest)
- `pos_listed`: latest NBA.com listed position (G, F, C, G-F, F-C, ...)

### `player_seasons`  (15,338 rows, seasons 1997-2027)
Row = player-season (one row; team = roster he finished the season on).
Columns: `season` int, `pid` int, `team` text, `pos_listed` text, `height_in` int, `weight_lb` int, `age` int, `source` text
- `pos_listed`: NBA.com listed position that season (G, F, C, G-F, F-G, F-C, C-F)
- `height_in / weight_lb / age`: as listed that season
- `source`: 'nba.com roster' (end-of-season roster) or 'bio' (no position; players not on a final roster)

### `box_game`  (787,949 rows, seasons 1997-2027)
Row = player-game box score.
Columns: `season` int, `season_type` text, `game_id` int, `date` text, `pid` int, `team` text, `opp` text, `home` bool, `wl` text, `min` int, `fgm` int, `fga` int, `fg3m` int, `fg3a` int, `ftm` int, `fta` int, `oreb` int, `dreb` int, `reb` int, `ast` int, `stl` int, `blk` int, `tov` int, `pf` int, `pts` int, `plus_minus` int
- `min`: minutes
- `plus_minus`: raw +/- in the game
- `*`: standard NBA box score counts

### `box_season`  (24,766 rows, seasons 1997-2027)
Row = player-season-team totals (team TOT = all teams combined).
Columns: `season` int, `season_type` text, `pid` int, `team` text, `gp` int, `min` int, `fgm` int, `fga` int, `fg3m` int, `fg3a` int, `ftm` int, `fta` int, `oreb` int, `dreb` int, `reb` int, `ast` int, `stl` int, `blk` int, `tov` int, `pf` int, `pts` int, `plus_minus` int
- `gp`: games played
- `*`: season totals; divide by gp for per game

### `games`  (76,078 rows, seasons 1997-2027)
Row = team-game.
Columns: `season` int, `season_type` text, `game_id` int, `date` text, `team` text, `opp` text, `home` bool, `wl` text, `pts` int, `opp_pts` int
- `season_type`: regular | playoffs
- `home`: true if home team

### `arc_season`  (66,986 rows, seasons 1998-2027)
Row = player-season-window (window = 1-5 seasons, recent seasons count more). Unit: ARC points per 100 possessions vs an average possession.
Columns: `season` int, `window` int, `pid` int, `team` text, `net` num, `O` num, `D` num, `shooting` num, `playmaking` num, `ball_security` num, `off_rebounding` num, `def_rebounding` num, `defense` num, `lineups_o` num, `lineups_d` num, `poss` int, `gp` int, `SV` num, `PV` num, `PV_ret` num, `PV_gen` num, `SV_O` num, `SV_D` num, `PV_O` num, `PV_D` num, `sel_O` num, `make_O` num, `sel_D` num, `make_D` num, `O_sel_rim` num, `O_sel_mid` num, `O_sel_thr` num, `O_sel_ft` num, `O_make_rim` num, `O_make_mid` num, `O_make_ft` num, `O_oreb` num, `O_tov` num, `D_sel_rim` num, `D_sel_mid` num, `D_sel_ft` num, `D_tov` num
- `net`: overall ARC = O + D
- `O / D`: offense / defense halves
- `shooting, playmaking, ball_security, off_rebounding, def_rebounding, defense`: individual-skill groups (from what he records)
- `lineups_o / lineups_d`: team results beyond his recorded skills (noisy)
- `SV / PV`: shot value vs possession value
- `sel_* / make_*`: shot selection (diet) vs shot making
- `O_*/D_* zone columns`: same split by zone: rim, mid, three, free throws; oreb, tov
- `poss / gp`: possessions / games in the window
- identity: net = shooting + playmaking + ball_security + off_rebounding + def_rebounding + defense + lineups_o + lineups_d

### `arc_live`  (394,900 rows, seasons 1998-2027)
Row = player-weekly snapshot (ARC Live: career-weighted, as of the date). Unit: ARC points per 100 possessions vs an average possession.
Columns: `season` int, `asof` text, `games` int, `pid` int, `team` text, `net` num, `O` num, `D` num, `shooting` num, `playmaking` num, `ball_security` num, `off_rebounding` num, `def_rebounding` num, `defense` num, `lineups_o` num, `lineups_d` num, `poss_season` int, `gp_season` int, `SV` num, `PV` num, `PV_ret` num, `PV_gen` num, `SV_O` num, `SV_D` num, `PV_O` num, `PV_D` num, `sel_O` num, `make_O` num, `sel_D` num, `make_D` num, `O_sel_rim` num, `O_sel_mid` num, `O_sel_thr` num, `O_sel_ft` num, `O_make_rim` num, `O_make_mid` num, `O_make_ft` num, `O_oreb` num, `O_tov` num, `D_sel_rim` num, `D_sel_mid` num, `D_sel_ft` num, `D_tov` num
- `asof`: snapshot date
- `games`: league games played by then
- `*`: as arc_season

### `loki`  (46,111 rows, seasons 2008-2027)
Row = player-release (R1 preseason, R2 ~a third of the season, R3 after the trade deadline, R4 end of season). Unit: LOKI points per 100.
Columns: `season` int, `release` text, `asof` text, `pid` int, `team` text, `net` num, `O` num, `D` num, `poss_season` int, `gp_season` int
- `net / O / D`: predictive rating and its halves

### `loki_release`  (747 rows, seasons 2027-2027)
Row = player, current frozen LOKI board.
Columns: `season` int, `release` text, `pid` int, `name` text, `team` text, `net` num, `lo80` num, `hi80` num, `lo90` num, `hi90` num, `rank_lo90` num, `rank_hi90` num, `p_no1` num, `p_top5` num, `p_top10` num, `evidence` text, `status` text, `poss_prev` int, `release_sha256` text
- `lo80/hi80, lo90/hi90`: 80% / 90% ranges for the rating
- `rank_lo90 / rank_hi90`: 90% range for his rank
- `p_no1 / p_top5 / p_top10`: probability of finishing #1 / top 5 / top 10
- `evidence`: how much data stands behind him
- `release_sha256`: hash of the frozen file

### `pac_season`  (14,082 rows, seasons 1998-2026)
Row = player-season, regular season. Unit: points.
Columns: `season` int, `pid` int, `gp` int, `pts` int, `tsa` num, `poss` num, `ts` num, `rts` num, `tsadd` num, `pac` num, `pac_g` num, `pac100` num, `cap` num, `cap_g` num
- `pac100`: PAC per 100 possessions: scoring value after charging for the shots he takes (efficiency x volume, load-adjusted)
- `pac / pac_g`: season total / per game
- `ts`: true shooting %
- `rts`: TS% vs league that season
- `tsa`: true-shot attempts
- `tsadd`: TS points added vs league
- `cap / cap_g`: scoring load carried
- `poss / gp / pts`: possessions on court, games, points
- credit: PAC (open method, LUMA Basketball Research): github.com/aayoawoyemi/pac

### `skills_season`  (14,124 rows, seasons 1998-2026)
Row = player-season: 19 skill groups (season z-scores) plus percentiles. Unit: value = z-score (0 = average); *_pct = percentile 0-100.
Columns: `season` int, `pid` int, `arc_poss` num, `in_pool` bool, `sk_creation` num, `sk_rim_pressure` num, `sk_foul_drawing` num, `sk_pullup_mid` num, `sk_spacing` num, `sk_playmaking` num, `sk_connector` num, `sk_roll_cut` num, `sk_post` num, `sk_off_glass` num, `sk_screening` num, `sk_ball_security` num, `sk_rim_protection` num, `sk_help` num, `sk_point_of_attack` num, `sk_switchability` num, `sk_disruption` num, `sk_def_glass` num, `sk_clean_defense` num, `sk_creation_pct` num, `sk_rim_pressure_pct` num, `sk_foul_drawing_pct` num, `sk_pullup_mid_pct` num, `sk_spacing_pct` num, `sk_playmaking_pct` num, `sk_connector_pct` num, `sk_roll_cut_pct` num, `sk_post_pct` num, `sk_off_glass_pct` num, `sk_screening_pct` num, `sk_ball_security_pct` num, `sk_rim_protection_pct` num, `sk_help_pct` num, `sk_point_of_attack_pct` num, `sk_switchability_pct` num, `sk_disruption_pct` num, `sk_def_glass_pct` num, `sk_clean_defense_pct` num, `pac100_pct` num, `arc_net_pct` num, `arc_o_pct` num, `arc_d_pct` num
- `<skill>`: skill value (z-score)
- `<skill>_pct`: percentile within the season vs the pool (share of the pool below him)
- `in_pool / arc_poss`: pool = players with 1,500+ ARC possessions that season; others are placed against the same pool
- `pac100_pct, arc_net_pct, arc_o_pct, arc_d_pct`: PAC per 100 and ARC net / O / D as percentiles vs the same pool
- `coverage`: sk_point_of_attack, sk_help, sk_switchability from 2018; sk_screening 2016; sk_connector 2014; sk_disruption 2000; the rest 1998
- `sk_creation`: self-created scoring
- `sk_rim_pressure`: getting to the rim
- `sk_foul_drawing`: drawing fouls
- `sk_pullup_mid`: pull-up / midrange shooting
- `sk_spacing`: spacing (catch-and-shoot threes)
- `sk_playmaking`: playmaking (creating shots for others)
- `sk_connector`: connective passing
- `sk_roll_cut`: finishing plays (rolls, cuts)
- `sk_post`: post scoring
- `sk_off_glass`: offensive rebounding
- `sk_screening`: screening
- `sk_ball_security`: ball security
- `sk_rim_protection`: primary rim protection
- `sk_help`: secondary (help) rim protection
- `sk_point_of_attack`: point-of-attack defense
- `sk_switchability`: versatility (guarding across positions)
- `sk_disruption`: disruption (steals, deflections)
- `sk_def_glass`: defensive rebounding
- `sk_clean_defense`: clean defense (defending without fouling)

### `onoff_season`  (16,339 rows, seasons 1998-2027)
Row = player-season-team, regular season, raw (unadjusted). Unit: per 100 possessions.
Columns: `season` int, `pid` int, `team` text, `on_poss` num, `off_poss` num, `ortg_on` num, `ortg_off` num, `ortg_diff` num, `drtg_on` num, `drtg_off` num, `drtg_diff` num, `net_on` num, `net_off` num, `net_diff` num, `opp_rim100_on` num, `opp_rim100_off` num, `opp_rim100_diff` num, `opp_3pa100_on` num, `opp_3pa100_off` num, `opp_3pa100_diff` num, `opp_fta100_on` num, `opp_fta100_off` num, `opp_fta100_diff` num, `opp_rim_fg_on` num, `opp_rim_fg_off` num, `opp_rim_fg_diff` num, `tm_rim100_on` num, `tm_rim100_off` num, `tm_rim100_diff` num, `tm_3pa100_on` num, `tm_3pa100_off` num, `tm_3pa100_diff` num, `tm_fta100_on` num, `tm_fta100_off` num, `tm_fta100_diff` num, `tm_efg_on` num, `tm_efg_off` num, `tm_efg_diff` num, `tm_tov100_on` num, `tm_tov100_off` num, `tm_tov100_diff` num, `tm_oreb_pct_on` num, `tm_oreb_pct_off` num, `tm_oreb_pct_diff` num, `tm_ftr_on` num, `tm_ftr_off` num, `tm_ftr_diff` num, `opp_efg_on` num, `opp_efg_off` num, `opp_efg_diff` num, `opp_tov100_on` num, `opp_tov100_off` num, `opp_tov100_diff` num, `dreb_pct_on` num, `dreb_pct_off` num, `dreb_pct_diff` num, `opp_ftr_on` num, `opp_ftr_off` num, `opp_ftr_diff` num, `tenure_off_poss` num, `ortg_off_tenure` num, `drtg_off_tenure` num, `net_off_tenure` num, `net_diff_tenure` num
- `on_poss / off_poss`: possessions with him on / off the floor (his team's games he played)
- `ortg_* / drtg_* / net_*`: team points scored / allowed / margin per 100 possessions
- `opp_rim100_* / opp_3pa100_* / opp_fta100_*`: opponent rim attempts / threes / free throws per 100
- `opp_rim_fg_*`: opponent field-goal % at the rim
- `tm_rim100_* / tm_3pa100_* / tm_fta100_*`: his team's rim attempts / threes / free throws per 100
- `*_on / *_off / *_diff`: with him on / off / on minus off
- `*_off_tenure, net_diff_tenure`: NBA.com-style: 'off' includes the team's games he missed
- `tm_efg_* / opp_efg_*`: effective FG% for his team / opponents
- `tm_tov100_* / opp_tov100_*`: turnovers per 100 possessions, team / opponents
- `tm_oreb_pct_*`: share of the team's misses it rebounds (offensive glass)
- `dreb_pct_*`: share of opponents' misses the team rebounds (defensive glass)
- `tm_ftr_* / opp_ftr_*`: free-throw attempts per field-goal attempt, team / opponents
- `rebound shares`: count team rebounds and use missed FGs + missed FTs, so levels sit a few points off NBA.com OREB% / DREB%; compare within this warehouse

### `lineups`  (1,530,587 rows, seasons 1998-2027)
Row = 2-, 3-, 4- or 5-man group on the floor together for a team-season. Unit: per 100 possessions.
Columns: `season` int, `team` text, `size` int, `p1` int, `p2` int, `p3` int, `p4` int, `p5` int, `poss` num, `ortg` num, `drtg` num, `net` num, `opp_rim100` num, `opp_3pa100` num, `opp_fta100` num, `tm_rim100` num, `tm_3pa100` num, `tm_fta100` num, `tm_efg` num, `tm_tov100` num, `tm_oreb_pct` num, `tm_ftr` num, `opp_efg` num, `opp_tov100` num, `dreb_pct` num, `opp_ftr` num
- `size`: players in the group
- `p1..p5`: player ids (sorted)
- `poss`: possessions together
- `ortg/drtg/net, opp_*, tm_*, dreb_pct`: as onoff_season, for the group (incl. four factors and rebound shares)
- floor: no possession minimum: every group that shared the floor is kept; read poss (small groups are noise)

### `wowy`  (118,754 rows, seasons 1998-2027)
Row = pair of teammates in a team-season (with or without you). Unit: per 100 possessions.
Columns: `season` int, `team` text, `pid_a` int, `pid_b` int, `poss_together` num, `ortg_together` num, `drtg_together` num, `net_together` num, `poss_a_only` num, `ortg_a_only` num, `drtg_a_only` num, `net_a_only` num, `poss_b_only` num, `ortg_b_only` num, `drtg_b_only` num, `net_b_only` num, `poss_neither` num, `ortg_neither` num, `drtg_neither` num, `net_neither` num
- `*_together`: both on
- `*_a_only`: pid_a on, pid_b off
- `*_b_only`: pid_b on, pid_a off
- `*_neither`: both off (same games)
- `poss_*`: possessions in each state

### `xpts_rapm`  (827 rows, seasons 2025-2026)
Row = player, three-season trailing window ending at season. Unit: points per 100 possessions.
Columns: `season` int, `pid` int, `net_rapm` num, `pure_rapm` num, `xpts_net` num, `xpts_off` num, `xpts_def` num, `conv_net` num, `conv_off` num, `conv_def` num, `poss` num, `min` num, `gp` int
- `net_rapm`: overall plus-minus impact = shot quality + conversion
- `xpts_net / xpts_off / xpts_def`: impact on shot QUALITY (defense: positive = good)
- `conv_net / conv_off / conv_def`: impact on shot MAKING above expectation (defense: positive = good)
- `pure_rapm`: independent check of net_rapm
- `poss`: weighted possessions

### `channels`  (2,539,522 rows, seasons 1998-2026)
Row = player-season value of one metric channel (see channels list); window 1-5, or 0 = LOKI end-of-season value.
Columns: `channel` text, `window` int, `season` int, `pid` int, `value` num, `poss` int, `gp` num, `min` num, `qualified` int
- `channel`: metric id (see channels)
- `value`: metric value
- `qualified`: 1 if he met the minutes bar

## 5. Metric channels (`channels` table: `where channel = '<id>'`, plus `season`, `"window"`, `pid`, `value`, `poss`, `qualified`)

`window` 1-5 as in arc_season (0 = LOKI end-of-season value). Sample filter: ARC / LOKI / Skills channels have `poss` and `qualified` (use `qualified = 1` or `poss >= 1500`); Box, Lens and xPTS channels have only `gp` (`poss` and `qualified` are NULL), so use `gp >= 40`.

**ARC** (unit: ARC points per 100 possessions vs an average possession)
- `arc` ARC: Overall impact rating for the season window: his own skills plus what lineup results add
- `arc_o` Offense: Offensive half of ARC (own offensive skill + offensive lineups)
- `arc_d` Defense: Defensive half of ARC (recorded defense + defensive glass + defensive lineups)
- `own` Own skill: The individual-skill half of ARC: value of everything he records
- `own_shooting` Shooting: Value of his scoring: makes and misses by zone vs league, given his shooting load
- `own_playmaking` Playmaking: Value of his assists
- `own_ballsec` Ball security: Value lost to his turnovers (closer to zero is better) [lower is better]
- `own_oreb` Offensive glass: Value of his offensive rebounding
- `own_dreb` Defensive glass: Value of his defensive rebounding
- `own_def` Recorded defense: Value of his recorded defense: steals, blocks, charges drawn, fouls
- `lineups` Lineups: What team results with him on the floor add beyond his own recorded skills (offense + defense) [team-heavy: much of it is team context; not ranked on its own]
- `lineups_o` Lineups O: Offensive team results beyond his recorded skills: spacing, gravity, screening, anything not in the box score [team-heavy: much of it is team context; not ranked on its own]
- `lineups_d` Lineups D: Defensive team results beyond his recorded skills: deterrence, positioning, scheme [team-heavy: much of it is team context; not ranked on its own]

**LOKI** (unit: LOKI points per 100)
- `loki` LOKI: predictive rating as of the end of the season (what we expect next), offense + defense
- `loki_o` Offense: Offensive half of LOKI
- `loki_d` Defense: Defensive half of LOKI [team-heavy: much of it is team context]
- `o_sv` Shot value: Selection + making, all zones
- `o_sel` Shot diet: Value of where his team's shots come from, vs the league diet (relative to an average field-goal attempt)
- `o_sel_rim` Rim pressure: more shots at the rim than the league diet
- `o_sel_mid` Mid-range diet (mid-heavy = negative: the mid is the worst shot)
- `o_sel_thr` Three-point diet
- `o_sel_ft` Free throws: Foul drawing: free-throw chances above the league rate
- `o_make` Shot-making: Conversion vs league by zone (his team's makes with him on)
- `o_make_rim` Rim making: Rim finishing vs league [team-heavy: much of it is team context]
- `o_make_mid` Mid-range making vs league
- `o_make_thr` Three making: Three-point making vs league: mostly luck year to year (shown, not boarded) [luck: little year-to-year signal, never rank on it; team-heavy: much of it is team context; not ranked on its own]
- `o_make_ft` Free throws making: Free-throw making vs league
- `o_pv` Possession value: Extra possessions (glass) and lost possessions (turnovers) [team-heavy: much of it is team context]
- `o_oreb` Offensive glass: His team's OREB rate with him on vs league
- `o_tov` Turnovers: His team's turnover rate with him on (fewer = positive) [team-heavy: much of it is team context]
- `o_other` Other: Rows with points but no counted attempt (~0). Accounting residual [luck: little year-to-year signal, never rank on it; not ranked on its own]
- `d_sv` Shot value: Opponent shot value: diet allowed + making allowed [team-heavy: much of it is team context; not ranked on its own]
- `d_sel` Diet allowed: Value of the shots opponents get with him on (rim / mid / three / free-throw share). The real part of shot defense [team-heavy: much of it is team context; not ranked on its own]
- `d_sel_rim` Rim denial: opponents get fewer rim attempts [team-heavy: much of it is team context]
- `d_sel_mid` Mid-range funnel: opponents pushed into mids = positive [team-heavy: much of it is team context]
- `d_sel_thr` Three-point denial [team-heavy: much of it is team context]
- `d_sel_ft` Free throws: Foul discipline: opponents get fewer free throws [team-heavy: much of it is team context]
- `d_make_rim` Rim making allowed: Opponent rim finishing with him on vs league. Real (player + team) [team-heavy: much of it is team context]
- `d_luck` Opponent shooting luck: Opponent mid / three / free-throw making allowed. Luck: no year-to-year signal. In the sum, never ranked [luck: little year-to-year signal, never rank on it; team-heavy: much of it is team context; not ranked on its own]
- `d_pv` Possession value: Extra possessions (glass) and lost possessions (turnovers)
- `d_oreb` Defensive glass: Opponent OREB rate with him on (his team's DREB) [team-heavy: much of it is team context]
- `d_tov` Forced turnovers: Opponent turnover rate with him on
- `d_other` Other: Rows with points but no counted attempt (~0). Accounting residual [luck: little year-to-year signal, never rank on it; not ranked on its own]

**Skills** (unit: season z-score (0 = average))
- `skills` Skills: Measured skill types (box + play-by-play + tracking + matchups), season z-scores. Describe what he does; never summed [not ranked on its own]
- `skills_o` Offense: Offensive skill types [not ranked on its own]
- `skills_d` Defense: Defensive skill types [not ranked on its own]
- `sk_creation` Self-creation (own shot)
- `sk_rim_pressure` Rim pressure / slashing
- `sk_foul_drawing` Foul drawing
- `sk_pullup_mid` Pull-up / mid-range scoring
- `sk_spacing` Spacing / catch-and-shoot shooting
- `sk_playmaking` Playmaking (creation for others)
- `sk_connector` Connective passing
- `sk_roll_cut` Play finishing
- `sk_post` Post scoring
- `sk_off_glass` Offensive glass
- `sk_screening` Screening
- `sk_ball_security` Ball security
- `sk_rim_protection` Rim protection (anchor)
- `sk_help` Help / secondary rim protection
- `sk_point_of_attack` Ball-handler defense (point of attack)
- `sk_switchability` Versatility (stops players outside his position)
- `sk_disruption` Disruption
- `sk_def_glass` Defensive glass
- `sk_clean_defense` Clean defense

**Box** (unit: value per 100 possessions)
- `scoring` Scoring: Total scoring value across all shot types
- `rim` Rim: Points created at the rim
- `dunk` Dunks: Rim value arriving via dunk
- `layup` Layups: Rim value via layups and floaters
- `rimother` Other rim: Tips, putbacks, everything else inside
- `mid` Mid-range: Two-point value away from the rim
- `three` Three-point: Value from behind the arc
- `catchshoot` Catch & shoot: Threes in rhythm off the pass
- `offdribble` Off the dribble: Self-created threes off the bounce
- `ft` Free throws: Getting to the line and converting
- `playmaking` Playmaking: Value created for teammates
- `setuprim` Setups at the rim: Assists creating rim attempts
- `setupmid` Setups mid-range: Assists creating mid-range attempts
- `setupthree` Setups for three: Assists creating threes
- `turnovers` Turnover economy: Value kept by protecting the ball
- `badpass` Bad passes: Giveaways through errant passing
- `handle` Ball handling: Giveaways off the dribble
- `system` System: Clock, travel, and structural giveaways
- `steals` Steals: Live-ball takeaways
- `offpass` Off bad passes: Steals jumping passing lanes
- `offlost` Off the dribble: Steals stripping the handler
- `blocks` Rim protection: Shots deterred and rejected
- `blockrim` At the rim: Blocks protecting the basket
- `blockmid` Mid-range: Blocks on two-point jumpers
- `blockthree` Perimeter: Blocks chasing shooters off the line [team-heavy: much of it is team context]

**Lens** (unit: value per 100 possessions)
- `creation` Creation lens: Offense re-sliced by how points arrive: self-created vs teammate-created, half-court vs transition [team-heavy: much of it is team context]
- `oself` Self-creation: Value from unassisted scoring while on the floor
- `ocreated` Teammate creation: Value delivered via assisted teammate scoring [team-heavy: much of it is team context]
- `ohc` Half-court offense: Value generated in the half court [team-heavy: much of it is team context]
- `dcreation` Creation denial (D): Suppressing how opponents create: assisted looks, self-creation, transition [team-heavy: much of it is team context]
- `loadeff` Load & Efficiency: Offensive burden and how efficiently a player carries it [not ranked on its own]
- `load` LOAD: Possessions a player ends by a shot taken or a shot created for a teammate
- `lusage` Usage load: Possessions ended by the player shooting
- `lcreation` Creation load: Possessions ended by a pass that creates a teammate shot
- `lctov` cTOV%: Share of a player’s load lost to turnovers. Lower is better [lower is better]
- `luwrts` UW-rTS: Scoring efficiency above league, weighted by usage
- `ltwohat` TWOHAT: Scoring efficiency and playmaking security, each weighted by volume

**xPTS** (unit: expected points per 100 possessions (or per shot where stated))
- `xpts` xPTS: Expected-points family: the quality of shots a player creates and allows, separated from shot-making
- `xquality` xPTS per shot: Expected points per shot from the shots he takes
- `xmaking` Conversion above expected: Points per shot above or below what his shots are expected to yield
- `xrapm` xPTS-RAPM: Opponent-adjusted two-way impact on shot-quality margin per 100 poss [team-heavy: much of it is team context; not ranked on its own]
- `xrsupp` Suppression: How much you lower opponent shot quality (rim protection, deterrence) [team-heavy: much of it is team context]
- `xquality_rapm` Shot quality (net): Opponent-adjusted effect on net expected-points margin per 100 possessions. The shot geometry a player creates minus what he allows
- `xq_o` Chance creation (O): How much a player raises his own team expected points per 100 - rim pressure, gravity, shot diet
- `xq_d` Chance suppression (D): How much a player lowers opponent expected points per 100 - rim protection, deterrence, funnelling
- `xconv` Conversion (net): Opponent-adjusted points scored above expectation, minus points allowed above expectation, per 100 possessions
- `xconv_o` Shot-making (O): Points his team scores above what the shot profile predicts, per 100 possessions
- `xconv_d` Make suppression (D): Points opponents score above expectation while he is on the floor, per 100 possessions

## 6. Recipes (patterns to copy; adapt filters, seasons, thresholds)

**Guards under 6'5" in 2022 and 2023, with single-season ARC (1,500+ poss)**
```
sql select p.name, a.season, s.height_in, a.net, a.O, a.D, a.poss
from arc_season a
join player_seasons s on s.pid = a.pid and s.season = a.season
join players p on p.pid = a.pid
where a.season between 2022 and 2023 and a."window" = 1 and a.poss >= 1500
  and p.pos = 'G' and s.height_in < 77
order by a.net desc
```
**Several conditions in one season: 20+ ppg, 5+ apg, positive ARC defense, 2025-26**
```
sql with b as (
  select * from box_season where season = 2026 and season_type = 'regular'
  qualify row_number() over (partition by pid order by (team='TOT') desc, gp desc) = 1)
select p.name, round(b.pts/b.gp,1) ppg, round(b.ast/b.gp,1) apg, a.D, b.gp
from b join arc_season a on a.pid = b.pid and a.season = 2026 and a."window" = 1
join players p on p.pid = b.pid
where b.gp >= 40 and b.pts/b.gp >= 20 and b.ast/b.gp >= 5 and a.D > 0
order by ppg desc
```
**Game thresholds: 40-point playoff games since 2015, by player**
```
sql select p.name, count(*) games, max(g.pts) best
from box_game g join players p using (pid)
where g.season >= 2015 and g.season_type = 'playoffs' and g.pts >= 40
group by p.name order by games desc
```
**Skill percentiles: 80th+ percentile in both playmaking and rim pressure, 2025-26**
```
sql select p.name, k.sk_playmaking_pct, k.sk_rim_pressure_pct, k.arc_net_pct
from skills_season k join players p using (pid)
where k.season = 2026 and k.in_pool and k.sk_playmaking_pct >= 80 and k.sk_rim_pressure_pct >= 80
order by k.arc_net_pct desc
```
**On/off: bigs whose teams allowed the fewest rim attempts with them on, 2025-26**
```
sql select p.name, o.team, o.opp_rim100_on, o.opp_rim100_off, o.opp_rim100_diff, o.on_poss
from onoff_season o join players p using (pid)
where o.season = 2026 and p.pos = 'B' and o.on_poss >= 1500
order by o.opp_rim100_diff asc limit 15
```
**Lineups with names: Knicks 5-man groups 2025-26 by net**
```
sql select p1.name, p2.name, p3.name, p4.name, p5.name, l.poss, l.net
from lineups l
join players p1 on p1.pid = l.p1 join players p2 on p2.pid = l.p2 join players p3 on p3.pid = l.p3
join players p4 on p4.pid = l.p4 join players p5 on p5.pid = l.p5
where l.season = 2026 and l.team = 'NYK' and l.size = 5
order by l.net desc limit 10
```
**Multi-season: best 3-year ARC ending 2026**
```
sql select p.name, a.net, a.O, a.D, a.poss from arc_season a join players p using (pid)
where a.season = 2026 and a."window" = 3 and a.poss >= 4000 order by a.net desc limit 20
```
**Career totals and averages across seasons (regular season, no double counting traded seasons)**
```
sql select p.name, count(*) seasons, sum(b.pts) pts, round(sum(b.pts)/sum(b.gp),1) ppg
from box_season b join players p using (pid)
where b.season_type = 'regular' and b.team <> 'TOT'
group by p.name order by pts desc limit 20
```
**A metric channel: teammate creation (ocreated), 2025-26, qualified players**
```
sql select p.name, c.value, c.gp from channels c join players p using (pid)
where c.channel = 'ocreated' and c.season = 2026 and c."window" = 1 and c.gp >= 40
order by c.value desc limit 15
```
**Year-over-year change: ARC net 2025 -> 2026 for one player and the league leaders**
```
sql select p.name, a.net net_2025, b.net net_2026, b.net - a.net change
from arc_season a join arc_season b on b.pid = a.pid and b.season = 2026 and b."window" = 1
join players p on p.pid = a.pid
where a.season = 2025 and a."window" = 1 and a.poss >= 1500 and b.poss >= 1500
order by change desc limit 15
```
**A team's record and point margin by season (games table, one row per team-game)**
```
sql select season, count(*) filter (where wl = 'W') wins, count(*) filter (where wl = 'L') losses,
  round(avg(pts - opp_pts),1) margin
from games where team = 'DEN' and season_type = 'regular' and season >= 2020
group by season order by season
```
**LOKI: current board with ranges and odds**
```
sql select name, team, net, lo90, hi90, p_top5, evidence from loki_release order by net desc limit 15
```

## 7. Not in LUMA's query data (say so; do not guess)

- College players / college ARC (C-ARC is being rebuilt), the draft, prospects.
- WNBA (separate board at lumahoops.org/wnba, not queryable here).
- Playoff ARC / playoff ratings (playoff BOX SCORES are available).
- Contracts, salaries, injuries, awards, shot charts / shot locations per shot, play-by-play events, tracking data.
- How ARC / LOKI / skills are built (proprietary). Describe what a metric MEANS (section 4-5), never its method.
If part of a question is answerable, answer that part and name the missing part.

## 8. Credit

Data: LUMA Basketball Research (models: LUMA ARC, ARC Live, LOKI). PAC is an open method (LUMA Basketball
Research, github.com/aayoawoyemi/pac). Keep the credit line whenever you show numbers from this data.
