Use Ollama parallelism for startup benchmark
This commit is contained in:
1 parent
3a7f02acba
commit
0758059bd1
1 file changed
+2
-1
@@ -12,6 +12,7 @@ MODEL_SERVER_URL = 'http://127.0.0.1'
|
|||||||
MODEL_SERVER_PORT = 11434
|
MODEL_SERVER_PORT = 11434
|
||||||
MODEL_LOG_FILE = os.environ.get('MODEL_LOG', '/var/log/ollama.log')
|
MODEL_LOG_FILE = os.environ.get('MODEL_LOG', '/var/log/ollama.log')
|
||||||
MODEL_HEALTHCHECK_ENDPOINT = "/"
|
MODEL_HEALTHCHECK_ENDPOINT = "/"
|
||||||
|
BENCHMARK_CONCURRENCY = max(1, int(os.environ.get("OLLAMA_NUM_PARALLEL", "1")))
|
||||||
|
|
||||||
# Ollama-specific log messages
|
# Ollama-specific log messages
|
||||||
def request_parser(request):
|
def request_parser(request):
|
||||||
@@ -66,7 +67,7 @@ worker_config = WorkerConfig(
|
|||||||
max_queue_time=600.0,
|
max_queue_time=600.0,
|
||||||
benchmark_config=BenchmarkConfig(
|
benchmark_config=BenchmarkConfig(
|
||||||
generator=completions_benchmark_generator,
|
generator=completions_benchmark_generator,
|
||||||
concurrency=10,
|
concurrency=BENCHMARK_CONCURRENCY,
|
||||||
runs=3
|
runs=3
|
||||||
)
|
)
|
||||||
),
|
),
|
||||||
|
|||||||
Reference in new issue
Block a user