Skip to content

Commit

Permalink
sync
Browse files Browse the repository at this point in the history
  • Loading branch information
ngxson committed Aug 15, 2024
1 parent d6e882b commit b9ef1bc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
2 changes: 1 addition & 1 deletion examples/server/bench/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ services:
export SERVER_BENCH_DATASET=/dataset.json
export SERVER_BENCH_N_PROMPTS=50
export SERVER_BENCH_MAX_TOKENS=50
./k6 run /src/script.js --duration 5m --iterations 250
./k6 run /src/script.js --duration 5m --iterations 100
volumes:
- ./:/src:Z
5 changes: 1 addition & 4 deletions examples/server/bench/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import {Counter, Rate, Trend} from 'k6/metrics'
import exec from 'k6/execution';

// Number of virtual users
const n_uvs = 50;
const n_uvs = 16;

// Server chat completions prefix
const server_url = __ENV.SERVER_BENCH_URL ? __ENV.SERVER_BENCH_URL : 'http://localhost:8080/v1'
Expand Down Expand Up @@ -130,9 +130,6 @@ export default function () {
completions_tokens = chunk.usage.completion_tokens
metric_completion_tokens.add(completions_tokens)
metric_completion_tokens_total_counter.add(completions_tokens)
} else {
metric_completion_tokens.add(1)
metric_completion_tokens_total_counter.add(1)
}
})

Expand Down

0 comments on commit b9ef1bc

Please sign in to comment.