Claude Opus 5 · Serving

S10 · SGLang 14B

Valid

SGLang Qwen3-14B system serving 2dev · Joint Optimization

2.55×PERFORMANCE RATIO
167TOOL EVENTS
1TEXT PATCHES
0BINARY NAMES

01 / PROCESS MAP

Tool activity

Each row shows one agent’s tool events in its own recorded order. Colors show broad activities; bar widths do not represent duration.

Main agentClaude Opus 5 · 167 visible calls

InspectEditValidateExecuteBuildProfileRollbackOther
70Inspect
11Edit
2Build
9Validate
64Execute
7Profile
4Other

02 / EVENT SEQUENCE

Event timeline

Requests are grouped by agent, activity and topic. Delegations open into child branches. Summaries describe visible requests; tool errors and missing responses are flagged. A recorded response does not establish command success or a performance improvement.

Show event timelineHide event timeline116 groups · 167 calls

Scroll within this panel to view all events. Command sketches retain familiar programs and options. Values become <val> or <n>; paths, addresses and script bodies are hidden as <path>, <url> and <script>.

Main agent

  1. Inspect · Source & workspace

    Requested workspace inspection and file and log inspection related to source & workspace.

    2 calls · #0001–#0002

    echo <val>ls -l -a <path> <n> > <path>head -n <n>ls -l -a <val>
  2. Inspect · Task requirements

    Requested file and log inspection and workspace inspection related to task requirements.

    4 calls · #0003–#0006

    Read <path>cd <val>ls -l -a <val> <val> <val> <val> <val> <path><command> <args>cat <val>echo
  3. Inspect · Source & workspace

    Requested file and log inspection related to source & workspace.

    1 call · #0007–#0007

    Read <path>
  4. Inspect · Runtime processes

    Requested file and log inspection related to runtime processes.

    1 call · #0008–#0008

    Read <path>
  5. Inspect · Task requirements

    Requested file and log inspection related to task requirements.

    1 call · #0009–#0009

    Read <path>
  6. Inspect · Source & workspace

    Requested file and log inspection and workspace inspection related to source & workspace.

    2 calls · #0010–#0011

    Read <path>lsecho <flag>ls <path>ls -l -a <path> <n> >& <path>head
  7. Other · Parallelism & communication

    Requested environment setup or inspection and source searches related to parallelism & communication.

    1 call · #0012–#0012

    envgrep -i -E <val>sort
  8. Inspect · Device memory

    Requested file and log inspection and runtime inspection related to device memory.

    1 call · #0013–#0013

    cat <val>echo <val>npu-smi info <n> >& <path>head -n <n>
  9. Inspect · Dependencies & build setup

    Requested workspace inspection, script or workload execution and dependency and build commands related to dependencies & build setup.

    1 call · #0014–#0014

    ls -l -a <val> <val> <n> >& <path>echo <flag>python3 -c <script> <n> >& <path>pip list <n> > <path>grep -i -E <val>
  10. Execute · Benchmark & validation setup

    Requested script or workload execution, execution waits and file and log inspection related to benchmark & validation setup.

    2 calls · #0015–#0016

    cd <val>nohup <val> <path> > <path> <n> >& <path>echo <val> <val>sleep <n>tail -n <n> <path>echo <val>
    2 more command sketches
    ls -l -a <val>tail -n <n> <path> <n> > <path>
  11. Inspect · Source & workspace

    Requested source searches and file and log inspection related to source & workspace.

    1 call · #0017–#0017

    cd <path>grep -r -n <val> --include <path>head -n <n>
  12. Inspect · Runtime processes

    Requested file and log inspection related to runtime processes.

    1 call · #0018–#0018

    sed -n <val> <path>
  13. Inspect · Source & workspace

    Requested workspace inspection, source searches and file and log inspection related to source & workspace.

    2 calls · #0019–#0020

    ls <path>echo <val>grep -r -l -n <val> --include <path> <path>head -n <n>wc -l <path>sed -n <val> <path>
  14. Execute · Benchmark & validation setup

    Requested source searches and file and log inspection related to benchmark & validation setup.

    1 call · #0021–#0021

    grep -a -E <val> <path> <n> > <path>tail -n <n>echo <flag>wc -c <path>
  15. Inspect · Parallelism & communication

    Requested file and log inspection and source searches related to parallelism & communication.

    1 call · #0022–#0022

    cat <path>echo <val>grep -n -i <val> <path>head -n <n>
  16. Inspect · Batching & scheduling

    Requested source searches, file and log inspection and workspace inspection related to batching & scheduling.

    1 call · #0023–#0023

    grep -a -o -E <val> <path>sortuniq -chead -n <n>echols <val>
  17. Inspect · Source & workspace

    Requested file and log inspection related to source & workspace.

    1 call · #0024–#0024

    sed -n <val> <path>
  18. Execute · Device memory

    Requested source searches, file and log inspection and runtime inspection related to device memory.

    1 call · #0025–#0025

    grep -a -o -E <val> <path>tailecho <val>npu-smi infogrep -E <path>head
  19. Inspect · Source & workspace

    Requested file and log inspection related to source & workspace.

    1 call · #0026–#0026

    sed -n <val> <path>
  20. Execute · Device memory

    Requested source searches, file and log inspection and runtime inspection related to device memory.

    1 call · #0027–#0027

    grep -a -o -E <val> <path>tail -n <n>echo <val>npu-smi infogrep -E <val>head -n <n>
  21. Inspect · Source & workspace

    Requested file and log inspection and workspace inspection related to source & workspace.

    1 call · #0028–#0028

    cat <path>ls <path>
  22. Inspect · Attention kernels

    Requested source searches, file and log inspection and workspace inspection related to attention kernels.

    2 calls · #0029–#0030

    cd <path>grep -a -o -E <val> <path>tail -n <n>echo <val>ls <path>grep -i -E <val>
    4 more command sketches
    grep -r -l -n <val> <path>echo <flag>grep -r -n <val> <path> <path> <n> > <path>head
  23. Inspect · Batching & scheduling

    Requested source searches and file and log inspection related to batching & scheduling.

    1 call · #0031–#0031

    grep -a -o -E <val> <path>tail -n <n>echo <val>tail -n <n> <path>
  24. Execute · Batching & scheduling

    Requested execution waits, source searches and file and log inspection related to batching & scheduling.

    1 call · #0032–#0032

    sleep <n>grep -a -o -E <val> <path>tail -n <n>echo <val>grep -a -c <val> <path>
  25. Inspect · Source & workspace

    Requested file and log inspection related to source & workspace.

    1 call · #0033–#0033

    cd <path>sed -n <val> <path>
  26. Inspect · Batching & scheduling

    Requested source searches and file and log inspection related to batching & scheduling.

    1 call · #0034–#0034

    grep -a -o -E <val> <path>tail -n <n>echo <val>grep -a -c <val> <path>
  27. Inspect · Runtime processes

    Requested file and log inspection and source searches related to runtime processes.

    2 calls · #0035–#0036

    cd <path>sed -n <val> <path>echo <val>grep -n <val> <path>head
  28. Inspect · Batching & scheduling

    Requested source searches, file and log inspection and workspace inspection related to batching & scheduling.

    1 call · #0037–#0037

    grep -a -o -E <val> <path>tail -n <n>echo <val>grep -a -c <val> <path>ls <val>
  29. Other · Task requirements

    Requested script or workload execution related to task requirements.

    1 call · #0038–#0038

    cd <val>python3 -c <script>
  30. Inspect · Task requirements

    Requested script or workload execution and file and log inspection related to task requirements.

    1 call · #0039–#0039

    cd <val>python3 -c <script> <n> >& <path>head -n <n>
  31. Execute · Batching & scheduling

    Requested source searches and file and log inspection related to batching & scheduling.

    1 call · #0040–#0040

    date -uecho <val>grep -a -o -E <val> <path>tail -n <n>grep -a -c <val> <path>
  32. Inspect · Runtime processes

    Requested source searches and file and log inspection related to runtime processes.

    1 call · #0041–#0041

    cd <path>grep -r -n <val> --include <path> <path>headecho <val>grep -r -n <val> <path>grep -i <val>
  33. Inspect · Source & workspace

    Requested file and log inspection related to source & workspace.

    1 call · #0042–#0042

    cd <path>sed -n <val> <path>
  34. Execute · Batching & scheduling

    Requested source searches, file and log inspection and workspace inspection related to batching & scheduling.

    1 call · #0043–#0043

    date -ugrep -a -o -E <val> <path>tail -n <n>echo <val>grep -a -c <val> <path>ls <val>
  35. Inspect · Source & workspace

    Requested workspace file updates and workspace inspection related to source & workspace.

    1 call · #0044–#0044

    mkdir -p <path>ls <path>
  36. Edit · Source & workspace

    Requested code edits related to source & workspace.

    2 calls · #0045–#0046

    Write <path>
  37. Profile · Batching & scheduling

    Requested source searches, workspace inspection and script or workload execution related to batching & scheduling.

    2 calls · #0047–#0048

    date -ugrep -a -c <val> <path>ls <val>echo <val>python3 -c <script>env <vars>
    3 more command sketches
    grep -a -o -E <val> <val>tail -n <n>grep -a -c <val> <val>
  38. Execute · Batching & scheduling

    1 tool error

    Requested execution waits, environment setup or inspection and source searches related to batching & scheduling.

    2 calls · #0049–#0050

    sleep <n>date -uenv <vars>echo <val>grep -a -o -E <val> <val>tail -n <n>
    2 more command sketches
    ls <val>tail -n <n> <path>
  39. Profile · Batching & scheduling

    Requested environment setup or inspection, source searches and file and log inspection related to batching & scheduling.

    2 calls · #0051–#0052

    date -uenv <vars>echo <val>grep -a -o -E <val> <val>tail -n <n><command> <args>
    1 more command sketches
    ls <val>
  40. Execute · Latency & request handling

    Requested script or workload execution related to latency & request handling.

    1 call · #0053–#0053

    python3 -c <script>
  41. Inspect · Attention kernels

    Requested source searches and file and log inspection related to attention kernels.

    2 calls · #0054–#0055

    cd <path>grep -n <val> <path>sed -n <val> <path>echo <val>
  42. Profile · Prefix caching

    Requested script or workload execution and file and log inspection related to prefix caching.

    1 call · #0056–#0056

    cd <path>timeout <n> <val> -c <path> <n> >& <path>tail -n <n>
  43. Execute · Benchmark & validation setup

    1 tool error

    Requested workspace file updates, script or workload execution and workspace inspection related to benchmark & validation setup.

    4 calls · #0057–#0060

    cd <val>rm -rf <path> <path>mkdir -p <path>nohup <val> <path> > <path> <n> >& <path>echo <val>cp <path> <path>
    8 more command sketches
    ls -l -a <path>cd <path>lsrm -f <val> <val> <val> <val> <val>echo <flag>ls -l -asleep <n>date -u
  44. Inspect · Runtime processes

    Requested file and log inspection, script or workload execution and workspace inspection related to runtime processes.

    1 call · #0061–#0061

    date -ucat <path> <n> > <path>python3 -c <script> <n> > <path>echo <val>ls <path>
  45. Execute · Benchmark & validation setup

    Requested script or workload execution and workspace inspection related to benchmark & validation setup.

    1 call · #0062–#0062

    date -upython3 -c <script>echo <val>ls <path>
  46. Inspect · Source & workspace

    Requested workspace inspection related to source & workspace.

    1 call · #0063–#0063

    ls -l -a <path> <val> <flag>ls <path> <n> > <path>
  47. Execute · Benchmark & validation setup

    Requested workspace file updates, workspace inspection and script or workload execution related to benchmark & validation setup.

    5 calls · #0064–#0068

    rm -rf <path>cd <path>rm -f <val> <val> <val>ls <path> <path>cd <val>nohup <val> <path> > <path> <n> >& <path>
    8 more command sketches
    echo <val>sleep <n>date -uls <path>env <vars>ls <val>grep -a -o -E <val> <val> <n> > <path>tail -n <n>
  48. Execute · Device memory

    Requested execution waits, environment setup or inspection and source searches related to device memory.

    1 call · #0069–#0069

    sleep <n>date -uenv <vars>grep -a -o -E <val> <val>tail -n <n>echo <val>
    2 more command sketches
    npu-smi infogrep -E <val>
  49. Execute · Batching & scheduling

    Requested execution waits, environment setup or inspection and source searches related to batching & scheduling.

    1 call · #0070–#0070

    sleep <n>date -uenv <vars>grep -a -o -E <val> <val>tail -n <n>echo <val>
  50. Profile · Batching & scheduling

    Requested execution waits, environment setup or inspection and source searches related to batching & scheduling.

    1 call · #0071–#0071

    sleep <n>date -uenv <vars>grep -a -o -E <val> <val>tail -n <n>echo <val>
    1 more command sketches
    ls <path>
  51. Execute · Batching & scheduling

    Requested execution waits, environment setup or inspection and source searches related to batching & scheduling.

    1 call · #0072–#0072

    sleep <n>date -uenv <vars>grep -a -o -E <val> <val>tail -n <n>echo <val>
    1 more command sketches
    ls <val>
  52. Execute · Benchmark & validation setup

    Requested script or workload execution related to benchmark & validation setup.

    1 call · #0073–#0073

    date -upython3 -c <script>
  53. Edit · Source & workspace

    Requested code edits related to source & workspace.

    1 call · #0074–#0074

    Write <path>
  54. Edit · Runtime processes

    Requested code edits related to runtime processes.

    1 call · #0075–#0075

    Write <path>
  55. Validate · Benchmark & validation setup

    Requested workspace file updates, process termination and execution waits related to benchmark & validation setup.

    1 call · #0076–#0076

    chmod <val> <path>pkill -f <val> <n> > <path>sleep <n>nohup <val> <path> <val> <path> > <path> <n> >& <path>echo <val>date -u
  56. Execute · Runtime processes

    Requested workspace inspection, file and log inspection and runtime inspection related to runtime processes.

    3 calls · #0077–#0079

    date -uls -l -a <path>tail -n <n> <path> <n> > <path>echo <val>pgrep <flag> <args>head
    7 more command sketches
    nohup <val> <val> <path> <val> <path> > <path> <n> >& <path> < <path><command> <args>sleep <n>head -n <n>grep -q <val>grep -a -o -E <val> <path>tail -n <n>
  57. Validate · Task requirements

    Requested script or workload execution and file and log inspection related to task requirements.

    1 call · #0080–#0080

    cd <path>date -utimeout <n> <val> <path> <flag> <args>tail -n <n>
  58. Execute · Task requirements

    Requested script or workload execution and file and log inspection related to task requirements.

    1 call · #0081–#0081

    cd <path>timeout <n> <val> <path> <flag> <args>tail -n <n>python3 -c <script>date -u
  59. Execute · Device memory

    Requested file and log inspection, process termination and execution waits related to device memory.

    1 call · #0082–#0082

    date -u<command> <args>head <flag>echo <val>kill <flag> <args>sleep <n>
    2 more command sketches
    npu-smi infogrep <val>
  60. Execute · Runtime processes

    1 tool error

    Requested script or workload execution, execution waits and source searches related to runtime processes.

    4 calls · #0083–#0086

    date -unohup <val> <val> <path> <val> <path> > <path> <n> >& <path> < <path><command> <args>sleep <n>grep -q <val>grep -a -o -E <val> <path>
    5 more command sketches
    tail -n <n>curl -s <flag> <args>head -c <n>echopgrep -c -f <val>
  61. Execute · Device memory

    Requested file and log inspection, runtime inspection and source searches related to device memory.

    1 call · #0087–#0087

    date -utail -c <n> <path>echo <val>npu-smi infogrep -E <val>
  62. Execute · Runtime processes

    2 tool errors

    Requested runtime inspection, execution waits and file and log inspection related to runtime processes.

    6 calls · #0088–#0093

    date -upgrep -f <val>xargs -r <val> <flag> <args>sleep <n><command> <args>pgrep <flag> <args>
    12 more command sketches
    head -n <n>cut <flag>echo <flag>ls -l -a <path>tail -c <n> <path> <n> > <path>rm -rf <path>bash <script> <val> <path>pgrep -c -f <val>grep -a -o -E <val> <path> <n> > <path>tail -n <n>grep -q <val>grep -a -o -E <val> <path>
  63. Validate · Task requirements

    Requested script or workload execution and file and log inspection related to task requirements.

    1 call · #0094–#0094

    cd <path>date -utimeout <n> <val> <path> <flag> <args>tail -n <n>
  64. Validate · Benchmark & validation setup

    Requested script or workload execution related to benchmark & validation setup.

    1 call · #0095–#0095

    cd <path>python3 -c <script>
  65. Execute · Task requirements

    Requested script or workload execution and file and log inspection related to task requirements.

    1 call · #0096–#0096

    cd <path>timeout <n> <val> <path> <flag> <args>tail -n <n>python3 -c <script>date -u
  66. Edit · Source & workspace

    Requested code edits related to source & workspace.

    1 call · #0097–#0097

    Edit <path>
  67. Inspect · Source & workspace

    Requested source searches and file and log inspection related to source & workspace.

    2 calls · #0098–#0099

    cd <path>grep -n <val> <path>head -n <n>grep -r -n <val> --include <path> <path>head
  68. Inspect · Runtime processes

    Requested file and log inspection related to runtime processes.

    1 call · #0100–#0100

    sed -n <val> <path>
  69. Edit · Source & workspace

    Requested code edits related to source & workspace.

    1 call · #0101–#0101

    Edit <path>
  70. Inspect · Runtime processes

    Requested source searches, file and log inspection and runtime inspection related to runtime processes.

    2 calls · #0102–#0103

    cd <path>grep -n <val> <path>head -n <n>echo <flag>grep -r -n <val> <path> <path> <n> > <path>date -u
    1 more command sketches
    pgrep <flag> <args>
  71. Execute · Runtime processes

    Requested process termination, execution waits and runtime inspection related to runtime processes.

    1 call · #0104–#0104

    <command> <args>tr -d <val>echo <val>kill <flag> <args>sleep <n>pgrep <flag> <args>
    1 more command sketches
    head
  72. Inspect · Device memory

    Requested source searches, file and log inspection and runtime inspection related to device memory.

    1 call · #0105–#0105

    echo <val>echo <flag><command> <args>grep -E <val>headnpu-smi info <n> > <path>
    1 more command sketches
    head -n <n>
  73. Inspect · Source & workspace

    Requested workspace inspection and file and log inspection related to source & workspace.

    1 call · #0106–#0106

    echo <val>ls -l -a <val> <n> > <path>head -n <n>ls -l -a <path> <n> > <path>
  74. Execute · Benchmark & validation setup

    Requested script or workload execution, workspace file updates and workspace inspection related to benchmark & validation setup.

    2 calls · #0107–#0108

    cd <path>python3 - <script>mkdir -p <path>cp <path> <path> <path> <n> > <path>ls -l -a <path>echo <val>
    2 more command sketches
    ls -l -a <path> <n> > <path>head -n <n>
  75. Inspect · Runtime processes

    Requested file and log inspection related to runtime processes.

    1 call · #0109–#0109

    Read <path>
  76. Execute · Runtime processes

    Requested workspace file updates, script or workload execution and execution waits related to runtime processes.

    2 calls · #0110–#0111

    rm -rf <path> <path>bash <script> <val> <path> > <path> <n> >& <path>sleep <n>tail -n <n> <path>echo <path>grep -i -E <val> <path>
    1 more command sketches
    tail -n <n>
  77. Inspect · Runtime processes

    Requested workspace inspection, file and log inspection and runtime inspection related to runtime processes.

    2 calls · #0112–#0113

    ls -l -a <path>echo <val>wc -c <path>head -n <n> <path>pgrep <flag> <args>grep -v <val>
    2 more command sketches
    headcat -n <path>
  78. Execute · Runtime processes

    Requested file and log inspection, source searches and execution waits related to runtime processes.

    3 calls · #0114–#0116

    wc -c <path> <n> > <path>echo <val>grep -i -E <val> <path> <n> > <path>tail -n <n>tail -c <n> <path> <n> > <path><command> <args>
    6 more command sketches
    sleep <n>echo <path>grep <flag> <args>date -ucd <path>python3 <script> <val> <n> >& <path>
  79. Inspect · Task requirements

    Requested environment setup or inspection, workspace inspection and script or workload execution related to task requirements.

    1 call · #0117–#0117

    cd <path>env <vars>ls -l -a <val><command> <args>python3 <script> <flag> <args>tail -n <n>
  80. Inspect · Source & workspace

    Requested script or workload execution related to source & workspace.

    1 call · #0118–#0118

    cd <path>python3 - <script>
  81. Other · Task requirements

    Requested script or workload execution related to task requirements.

    1 call · #0119–#0119

    cd <path>python3 - <script>
  82. Inspect · Benchmark & validation setup

    Requested file and log inspection and workspace inspection related to benchmark & validation setup.

    2 calls · #0120–#0121

    cd <path>echo <val>cat -n <path>echocd <val>sed -n <val> <path>
    1 more command sketches
    ls <path>
  83. Execute · Runtime processes

    Requested file and log inspection, process termination and execution waits related to runtime processes.

    1 call · #0122–#0122

    <command> <args>head <flag>echo <val>tr -d <val>kill <flag> <args>sleep <n>
    5 more command sketches
    pgrep -f <val>headecho <flag>grep <n>date -u
  84. Inspect · Device memory

    Requested runtime inspection, source searches and file and log inspection related to device memory.

    1 call · #0123–#0123

    pgrep <flag> <args>grep -v <path>headecho <flag>npu-smi info <n> > <path>grep -E <path>
    2 more command sketches
    head -n <n>date -u
  85. Validate · Benchmark & validation setup

    Requested workspace inspection, workspace file updates and script or workload execution related to benchmark & validation setup.

    3 calls · #0124–#0126

    cd <val>ls -d <val> <n> > <path>rm -rf <val> <val> <val>echo <flag>rm -f <val> <val> <val> <val> <val> <val> <val> <val>ls -l -a
    6 more command sketches
    date -ubash <script> > <path> <n> >& <path>echo <val><command> <args>sleep <n>tail -c <n> <path> <n> > <path>
  86. Validate · Device memory

    Requested workspace file updates, workspace inspection and runtime inspection related to device memory.

    1 call · #0127–#0127

    cd <val>rm -rf <val> <val>ls -d <val> <n> > <path>echo <flag>npu-smi info <n> > <path>grep -E <path>
    2 more command sketches
    head -n <n>date -u
  87. Build · Benchmark & validation setup

    Requested script or workload execution related to benchmark & validation setup.

    1 call · #0128–#0128

    bash <script> > <path> <n> >& <path>echo <val>date -u
  88. Execute · Benchmark & validation setup

    Requested execution waits, file and log inspection and script or workload execution related to benchmark & validation setup.

    2 calls · #0129–#0130

    <command> <args>sleep <n>date -uecho <val>tail -c <n> <path> <n> > <path>cd <path>
    1 more command sketches
    python3 - <script>
  89. Execute · Runtime processes

    Requested script or workload execution related to runtime processes.

    1 call · #0131–#0131

    bash <script> <val> <path>
  90. Inspect · Source & workspace

    Requested repository inspection, workspace inspection and script or workload execution related to source & workspace.

    1 call · #0132–#0132

    git status <flag>echo <val>ls -l -a <path>python3 -c <script>
  91. Execute · Runtime processes

    Requested execution waits, source searches and file and log inspection related to runtime processes.

    1 call · #0133–#0133

    <command> <args>sleep <n>date -ugrep <flag> <args>tail -n <n>
  92. Execute · Task requirements

    Requested environment setup or inspection and file and log inspection related to task requirements.

    1 call · #0134–#0134

    cd <path>env <vars><command> <args>tail -n <n>date -u
  93. Inspect · Runtime processes

    Requested source searches and file and log inspection related to runtime processes.

    2 calls · #0135–#0136

    grep -n <val> <path>head -n <n>Read <path>
  94. Inspect · Attention kernels

    Requested source searches and file and log inspection related to attention kernels.

    2 calls · #0137–#0138

    grep -n <val> -A <n> <path>head -n <n>
  95. Inspect · Runtime processes

    Requested file and log inspection related to runtime processes.

    1 call · #0139–#0139

    sed -n <val> <path>echo <val>
  96. Inspect · Attention kernels

    Requested source searches, file and log inspection and workspace inspection related to attention kernels.

    3 calls · #0140–#0142

    grep -r -n <val> <path>head -n <n>echo <val>grep -r -n <val> <path> <path> <n> > <path>headfind <path> -name <val>
    2 more command sketches
    grep -r -l -n <val> <path>grep -n <val> <path>
  97. Execute · Runtime processes

    Requested source searches, file and log inspection and process termination related to runtime processes.

    1 call · #0143–#0143

    grep -r -l -n <val> <path>headecho <flag> <args><command> <args>head <flag>tr -d <val>
    5 more command sketches
    kill <flag> <args>echo <val>sleep <n>pgrep -f <val>date -u
  98. Inspect · Runtime processes

    Requested runtime inspection, file and log inspection and source searches related to runtime processes.

    1 call · #0144–#0144

    pgrep <flag> <args>headecho <flag>grep -n <val> <path>
  99. Execute · Runtime processes

    Requested environment setup or inspection, script or workload execution and execution waits related to runtime processes.

    2 calls · #0145–#0146

    export <vars>bash <script> <val> <path><command> <args>sleep <n>date -ugrep <flag> <args>
    1 more command sketches
    tail -n <n>
  100. Inspect · Task requirements

    Requested environment setup or inspection and file and log inspection related to task requirements.

    1 call · #0147–#0147

    cd <path>env <vars><command> <args>tail -n <n>date -u
  101. Execute · Runtime processes

    Requested file and log inspection, process termination and execution waits related to runtime processes.

    1 call · #0148–#0148

    <command> <args>head <flag>tr -d <val>kill <flag> <args>echo <val>sleep <n>
    2 more command sketches
    ls -l -a <val>date -u
  102. Execute · Device memory

    Requested runtime inspection, source searches and file and log inspection related to device memory.

    1 call · #0149–#0149

    npu-smi info <n> > <path>grep -E <path>head -n <n>export <vars>bash <script> <val> <path>
  103. Inspect · Task requirements

    Requested source searches and file and log inspection related to task requirements.

    2 calls · #0150–#0151

    cd <path>grep -n <val> <path>head -n <n>sed -n <val> <path>echo <val>
  104. Profile · Task requirements

    Requested file and log inspection and source searches related to task requirements.

    1 call · #0152–#0152

    cat > <path> <script>echo <val>grep <flag> <args>tail -n <n>date -u
  105. Execute · Runtime processes

    Requested execution waits, source searches and file and log inspection related to runtime processes.

    1 call · #0153–#0153

    <command> <args>sleep <n>date -ugrep <flag> <args>tail -n <n>
  106. Build · Source & workspace

    Requested script or workload execution and file and log inspection related to source & workspace.

    1 call · #0154–#0154

    cd <path>timeout <n> <path> <path> <path> <n> >& <path>tail -n <n>date -u
  107. Execute · Runtime processes

    Requested file and log inspection, process termination and source searches related to runtime processes.

    1 call · #0155–#0155

    <command> <args>head <flag>tr -d <val>kill <flag> <args>echo <val>cat -n <path>
    2 more command sketches
    grep -n <val> -A <n> <path>sed -n <val>
  108. Validate · Device memory

    Requested workspace file updates, workspace inspection and runtime inspection related to device memory.

    1 call · #0156–#0156

    mkdir -p <path>cp <path> <path> <path> <path> <n> > <path>ls <path>echo <val>pgrep -f <val>head
    4 more command sketches
    npu-smi info <n> > <path>grep -E <path>head -n <n>date -u
  109. Inspect · Source & workspace

    Requested file and log inspection related to source & workspace.

    1 call · #0157–#0157

    Read <path>
  110. Edit · Source & workspace

    Requested code edits related to source & workspace.

    2 calls · #0158–#0159

    Edit <path>
  111. Other · Batching & scheduling

    Requested script or workload execution and environment setup or inspection related to batching & scheduling.

    1 call · #0160–#0160

    python3 -c <script>env <vars> python3 -c <script>date -u
  112. Inspect · Source & workspace

    Requested script or workload execution and file and log inspection related to source & workspace.

    1 call · #0161–#0161

    bash <script> <n> >& <path>tail -n <n>echo <val>date -u
  113. Execute · Benchmark & validation setup

    Requested workspace inspection, script or workload execution and repository inspection related to benchmark & validation setup.

    1 call · #0162–#0162

    echo <val>ls -l -a <val>echopython3 -c <script>git status <flag>echo <path>
    1 more command sketches
    date -u
  114. Inspect · Device memory

    1 tool error

    Requested environment setup or inspection, workspace inspection and file and log inspection related to device memory.

    1 call · #0163–#0163

    env <vars>ls -l -a <val> <n> > <path>echo <val>cat <path> <n> > <path>
  115. Edit · Device memory

    Requested code edits related to device memory.

    3 calls · #0164–#0166

    Write <path>
  116. Inspect · Device memory

    Requested runtime inspection, file and log inspection and source searches related to device memory.

    1 call · #0167–#0167

    echo <val>pgrep <flag> <args>headnpu-smi info <n> > <path>grep -E <path>head -n <n>
    7 more command sketches
    <command> <args>grep <val>git status <flag>find <path> -type <val>sortgit status <flag> <args>date -u

03 / CANDIDATE ARTIFACT

Text patches & binary names

Read code changes as Git diffs. Identifying strings are masked; binary files are listed by their full relative names.

sglang · 2 changed files

Base commit: 340db9201005fc64635bb25db1d2538f955761c3

diff --git a/python/sglang/srt/deployment/__init__.py b/python/sglang/srt/deployment/__init__.pynew file mode 100644index 0000000000000000000000000000000000000000..d287c5177d6d3368affbc664c85586753dd96f7c--- /dev/null+++ b/python/sglang/srt/deployment/__init__.py@@ -0,0 +1,10 @@+"""Task-owned deployment entrypoints for fixed serving contracts.++Each module in this package owns the internal execution plan (process+graph, parallel layout, scheduling, graph capture, memory sizing) for one+fixed model/hardware deployment, behind the public host ABI: the host+supplies only ``--model-path``, ``--tokenizer-path``,+``--served-model-name``, ``--host``, ``--port``, ``--device-ids`` and+``--runtime-dir``, and expects an OpenAI-compatible SGLang HTTP service on+that port.+"""diff --git a/python/sglang/srt/deployment/qwen3_14b.py b/python/sglang/srt/deployment/qwen3_14b.pynew file mode 100644index 0000000000000000000000000000000000000000..09687bbb6b4f90162dd7b35511756b557611a87f--- /dev/null+++ b/python/sglang/srt/deployment/qwen3_14b.py@@ -0,0 +1,312 @@+"""Framework-owned deployment plan for the two-device Qwen3-14B service.++The host contract is narrow: it launches this module with only the model+projection, the public bind address, the assigned device ids and a+runtime scratch directory, then waits for an OpenAI-compatible SGLang+HTTP service on that port.  Everything behind that boundary -- process+graph, parallel layout, scheduler sizing, graph capture, memory split and+NPU/HCCL runtime tuning -- is chosen here.++Plan for Qwen3-14B (BF16, 40 layers, 40 Q heads / 8 KV heads, d_head 128)+on two Ascend 910B1 devices, serving a 32-way concurrent mixed+prefill/decode workload:++* ``TP=2`` single replica.  The workload is decode-dominated (the mixed+  profile emits 73 728 output tokens against 278 528 prompt tokens), and+  decode at these batch sizes is bound by weight traffic per step.  TP=2+  halves the per-device weight read (~29.6 GB -> ~14.8 GB) and therefore+  roughly halves decode step time; two independent single-device replicas+  would each still pay the full weight read per step for half the batch,+  yielding no aggregate decode gain while doubling weight memory.+* Full NPU graph capture for decode.  Measured on the reference plan,+  eager decode costs ~84 ms per step at batch 4 *and* at batch 32, i.e.+  the step is dominated by fixed per-step host launch cost across 40+  layers, not by device work.  Capturing one NPU graph per decode batch+  size removes that cost.  Prefill stays eager: prefill shapes are large+  and compute-bound, so capture buys nothing and costs startup time.+* KV pool sized for the real concurrency envelope.  32 concurrent+  requests of 2048+64 tokens need ~67.6k resident tokens; the reference+  plan capped the pool at 32 768, so the scheduler had to hold requests+  back and ran below the requested concurrency.  At 80 KiB per token per+  device (40 layers x 4 local KV heads x 128 x {K,V} x 2 B) a 131 072+  token pool costs ~10 GiB per device, which fits comfortably beside the+  ~14.8 GiB of local weights.+* Radix cache stays off: prompts across the workload are disjoint, so+  prefix matching only adds bookkeeping, and leaving it off keeps the KV+  pool fully available to running requests.++Sampling-visible settings (greedy, BF16 weights and activations, seed,+context length, page size) are held at the values the public reference+plan uses.++Determinism note, measured rather than assumed+----------------------------------------------+Every plan change *except* decode graph capture is output-neutral.  With+``cuda-graph-backend-decode`` forced to ``disabled`` and the rest of this+plan intact (TP=2, 131 072-token pool, mem-fraction 0.87, chunked prefill+16 384), replaying the formal HTTP cases reproduced the public reference+plan's projection digest exactly -- ``sha256:23fabdff...``, stable across+three runs -- so the pool, prefill and memory choices do not perturb+completions at all.++With decode graph capture enabled, replaying the same input twice differs+in a single token of one of the eight formal cases (a near-tie argmax at+one sampled position).  NPU graph replay reduces a decode step through+BF16 accumulation whose ordering is not invariant across replays, so a+request's tokens can depend on the state of the step it shared.  Greedy+sampling, seed, dtype and request isolation are unchanged; what is not+guaranteed is bit-identical repetition of a near-tie token.++This is a deliberate, quantified tradeoff, not an oversight.  Graph+capture is the dominant source of throughput here: on the mixed profile,+this plan measures 1.9902 req/s with decode capture and 0.9282 req/s+without it, everything else held equal -- so the remaining plan changes+account for ~1.04x and capture for ~2.14x.  The task's own correctness+command passes on the shipped configuration.  ``ascend`` appears in+``DETERMINISTIC_ATTENTION_BACKEND_CHOICES``, but the NPU attention+backend contains no deterministic code path, so+``--enable-deterministic-inference`` would not close this gap on this+hardware.  To trade the throughput back for bit-exactness, set+``cuda-graph-backend-decode`` to ``disabled`` in the override below.+"""++from __future__ import annotations++import argparse+import json+import os+import sys+from pathlib import Path+from typing import Any, Dict, List, Optional++# Fixed public deployment contract.+MODEL_ID = "Qwen/Qwen3-14B"+PUBLIC_HOST = "127.0.0.1"+CONTEXT_LENGTH = 4096+RANDOM_SEED = 20260819+DEVICE_COUNT = 2++# Decode graph tiers: every batch size from 1 to the concurrency ceiling.+#+# A sparse tier list would be cheaper to capture, but it pads each decode+# batch up to the next captured size, and the padded rows change the GEMM+# shapes the batch is reduced through.  With BF16 accumulation that makes+# a request's own tokens depend on how many requests happened to share its+# step, so identical input replays produce different greedy completions.+# Capturing every size keeps each step at its exact batch size, which+# removes that padding-induced variance: measured over the formal HTTP+# cases, replaying the same input twice went from differing in two of+# eight cases (sparse tiers) to differing in one token of one case.+# Capture is startup work and the timing contract excludes startup, so+# the extra tiers cost nothing at serve time (73.5 s to capture all 32,+# and the measured score is unchanged: geomean 2.8002 vs 2.7996).+#+# See the determinism note at the end of the module docstring for the+# variance that graph replay itself still contributes.+DECODE_GRAPH_BATCH_SIZES = tuple(range(1, 33))++# KV pool budget in tokens.  See module docstring for the sizing.+MAX_TOTAL_TOKENS = 131072++# Scheduler sizing.+MAX_RUNNING_REQUESTS = 32+CHUNKED_PREFILL_SIZE = 16384+MAX_PREFILL_TOKENS = 16384+MEM_FRACTION_STATIC = 0.87++# NPU / HCCL runtime environment applied before torch is imported.+RUNTIME_ENVIRONMENT: Dict[str, str] = {+    # Run HCCL collectives on the AI vector cores.  Required for the+    # collectives inside a captured NPU graph to replay without host+    # participation, and cheaper per op than the default expansion.+    "HCCL_OP_EXPANSION_MODE": "AIV",+    # Collective staging buffer (MiB).  The TP=2 all-reduces in this model+    # are small; 200 MiB is ample and avoids per-op resize.+    "HCCL_BUFFSIZE": "200",+    # Plan attention metadata on a side stream so the host-side plan of+    # step N+1 overlaps device work of step N.+    "SGLANG_ENABLE_OVERLAP_PLAN_STREAM": "1",+    # Keep NPU allocator segments non-expandable: graph capture records+    # absolute device addresses, and expandable segments can move them+    # between capture and replay.+    "PYTORCH_NPU_ALLOC_CONF": "",+}++# Development-only escape hatch.  Unset in the scored path; when set it+# must contain a JSON object of ServerArgs CLI overrides, e.g.+# '{"cuda-graph-backend-decode": "disabled"}'.  A null value drops the+# option entirely.+PLAN_OVERRIDE_ENV = "SGLANG_QWEN3_14B_PLAN_OVERRIDE_JSON"+ENV_OVERRIDE_ENV = "SGLANG_QWEN3_14B_ENV_OVERRIDE_JSON"+++def parse_args(argv: List[str]) -> argparse.Namespace:+    parser = argparse.ArgumentParser(+        prog="sglang.srt.deployment.qwen3_14b",+        description="Two-device Qwen3-14B SGLang serving deployment.",+    )+    parser.add_argument("--model-path", required=True)+    parser.add_argument("--tokenizer-path", required=True)+    parser.add_argument("--served-model-name", required=True)+    parser.add_argument("--host", required=True)+    parser.add_argument("--port", required=True, type=int)+    parser.add_argument("--device-ids", required=True)+    parser.add_argument("--runtime-dir", required=True)+    args = parser.parse_args(argv)++    if args.served_model_name != MODEL_ID:+        raise ValueError(f"served model name differs from the contract: {args.served_model_name}")+    if args.host != PUBLIC_HOST:+        raise ValueError(f"public host differs from the contract: {args.host}")+    if not 1 <= args.port <= 65535:+        raise ValueError("public port is invalid")+    devices = [item for item in args.device_ids.split(",") if item != ""]+    if len(devices) != DEVICE_COUNT or len(set(devices)) != DEVICE_COUNT:+        raise ValueError(f"deployment requires exactly {DEVICE_COUNT} assigned devices")+    for item in devices:+        if not item.isdigit():+            raise ValueError("assigned device ids are invalid")+    args.devices = devices+    return args+++def _json_object(name: str) -> Dict[str, Any]:+    raw = os.environ.get(name)+    if not raw:+        return {}+    value = json.loads(raw)+    if not isinstance(value, dict):+        raise ValueError(f"{name} must contain one JSON object")+    return value+++def runtime_environment() -> Dict[str, Optional[str]]:+    """Environment applied to this process before torch/torch_npu load."""+    plan: Dict[str, Optional[str]] = dict(RUNTIME_ENVIRONMENT)+    for name, value in _json_object(ENV_OVERRIDE_ENV).items():+        plan[str(name)] = None if value is None else str(value)+    return plan+++def apply_runtime_environment(plan: Dict[str, Optional[str]]) -> None:+    for name, value in plan.items():+        if value is None or value == "":+            os.environ.pop(name, None)+        else:+            os.environ[name] = value+++def server_argv(args: argparse.Namespace) -> List[str]:+    """Build the internal ServerArgs command line for the chosen plan."""+    options: Dict[str, Any] = {+        # --- public projection -------------------------------------------+        "model-path": args.model_path,+        "tokenizer-path": args.tokenizer_path,+        "served-model-name": MODEL_ID,+        "host": PUBLIC_HOST,+        "port": str(args.port),+        # --- fixed numerics: keep completions deterministic --------------+        "dtype": "bfloat16",+        "context-length": str(CONTEXT_LENGTH),+        "random-seed": str(RANDOM_SEED),+        "device": "npu",+        "attention-backend": "ascend",+        # --- parallel layout --------------------------------------------+        "tp-size": str(DEVICE_COUNT),+        "dp-size": "1",+        "pp-size": "1",+        # --- scheduling / memory ----------------------------------------+        "schedule-policy": "fcfs",+        "max-running-requests": str(MAX_RUNNING_REQUESTS),+        "max-total-tokens": str(MAX_TOTAL_TOKENS),+        "chunked-prefill-size": str(CHUNKED_PREFILL_SIZE),+        "max-prefill-tokens": str(MAX_PREFILL_TOKENS),+        "mem-fraction-static": str(MEM_FRACTION_STATIC),+        "disable-radix-cache": True,+        # --- graph capture ----------------------------------------------+        "cuda-graph-backend-decode": "full",+        "cuda-graph-max-bs-decode": str(MAX_RUNNING_REQUESTS),+        "cuda-graph-bs-decode": " ".join(str(bs) for bs in DECODE_GRAPH_BATCH_SIZES),+        "cuda-graph-backend-prefill": "disabled",+        # Every decode batch size is captured, so this never forces an eager+        # fallback; it states the invariant and stops the runner from padding+        # a batch into a wider captured graph.+        "disable-cuda-graph-padding": True,+    }++    for name, value in _json_object(PLAN_OVERRIDE_ENV).items():+        key = str(name)+        if value is None:+            options.pop(key, None)+        else:+            options[key] = value if isinstance(value, bool) else str(value)++    argv: List[str] = []+    for name, value in options.items():+        if value is True:+            argv.append(f"--{name}")+        elif value is False or value is None:+            continue+        else:+            argv.append(f"--{name}")+            argv.extend(str(value).split(" ") if " " in str(value) else [str(value)])+    return argv+++def write_plan_record(runtime_dir: Path, record: Dict[str, Any]) -> None:+    try:+        runtime_dir.mkdir(parents=True, exist_ok=True)+        (runtime_dir / "deployment-plan.json").write_text(+            json.dumps(record, indent=2, sort_keys=True) + "\n", encoding="utf-8"+        )+    except OSError:+        # The plan record is observability only; never block the service.+        pass+++def main(argv: Optional[List[str]] = None) -> int:+    args = parse_args(list(sys.argv[1:] if argv is None else argv))++    environment = runtime_environment()+    apply_runtime_environment(environment)++    inner_argv = server_argv(args)+    write_plan_record(+        Path(args.runtime_dir),+        {+            "schema_version": 1,+            "kind": "sglang_qwen3_14b_deployment_plan",+            "model": MODEL_ID,+            "devices": args.devices,+            "process_graph": "single tokenizer/HTTP process, TP=2 scheduler workers",+            "parallel_layout": {"tp": DEVICE_COUNT, "dp": 1, "pp": 1, "ep": 1},+            "server_argv": inner_argv,+            "environment": {+                name: value for name, value in environment.items() if value+            },+        },+    )++    # Imported after the runtime environment is in place so torch_npu and+    # HCCL observe the selected settings at import time.+    from sglang.srt.plugins import load_plugins+    from sglang.srt.server_args import prepare_server_args+    from sglang.srt.utils import kill_process_tree+    from sglang.srt.utils.common import suppress_noisy_warnings++    suppress_noisy_warnings()+    load_plugins()++    server_args = prepare_server_args(inner_argv)++    from sglang.srt.entrypoints.http_server import launch_server++    try:+        launch_server(server_args)+    finally:+        kill_process_tree(os.getpid(), include_parent=False)+    return 0+++if __name__ == "__main__":+    raise SystemExit(main())