{"id":23841878,"url":"https://github.com/johnpertoft/llm-inference-benchmark","last_synced_at":"2026-06-20T22:31:21.178Z","repository":{"id":211414417,"uuid":"716505894","full_name":"johnPertoft/llm-inference-benchmark","owner":"johnPertoft","description":"Comparing inference frameworks for LLMs","archived":false,"fork":false,"pushed_at":"2024-04-24T12:56:41.000Z","size":90,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-02T18:23:42.000Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/johnPertoft.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-11-09T09:31:08.000Z","updated_at":"2024-04-24T12:56:46.000Z","dependencies_parsed_at":"2023-12-08T11:45:04.458Z","dependency_job_id":null,"html_url":"https://github.com/johnPertoft/llm-inference-benchmark","commit_stats":null,"previous_names":["johnpertoft/llm-inference-benchmark"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnPertoft%2Fllm-inference-benchmark","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnPertoft%2Fllm-inference-benchmark/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnPertoft%2Fllm-inference-benchmark/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/johnPertoft%2Fllm-inference-benchmark/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/johnPertoft","download_url":"https://codeload.github.com/johnPertoft/llm-inference-benchmark/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240127707,"owners_count":19752044,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-01-02T18:21:39.677Z","updated_at":"2026-05-20T12:30:18.841Z","avatar_url":"https://github.com/johnPertoft.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# LLM Inference Benchmark\nComparing inference frameworks for LLMs for my usecase at work. Currently just a big mess:)\n\n## Delimitations\nInitially just focusing on comparing performance for a 7B Llama2 model on a single a100 40gb.\n\n## Usage\n\n### Setup\nTODO\n\n### Run LLM inference framework\nEvery framework folder has at least one run script without arguments that will run a container with\nthat framework with different model dtype settings.\n\n## TODO\n\n### Misc\n- [ ] Run benchmark code etc in another container?\n- [ ] Compare with paid solutions?\n- [ ] Validate outputs too, run over some datasets and compute metrics?\n- [ ] Better benchmark with varying input/output lengths\n- [ ] Code from tensorrt-llm wants to load llamatokenizer in legacy mode. Consequences for other frameworks? See if it's still a problem\n- [ ] Pin all versions\n- [ ] Where does FasterTransformers position itself here really?\n- [ ] Need to make sure we generate the same number of tokens for proper comparison\n- [ ] Compare with llama.cpp etc too\n- [ ] Enable input params to control generation for all setups\n- [ ] Can we get some metrics for how full the batches are?\n- [ ] And to what extent / whether continuous batching is used\n- [ ] How to increase gpu utilization? Even with a lot of concurrent users it doesn't go to 100% Bad configuration?\n- [ ] TODO: Check https://github.com/mistralai/mistral-src/blob/main/deploy/Dockerfile\n- [ ] TorchServe https://hamel.dev/notes/serving/torchserve/hf.html\n\n### Frontends\n- [ ] RayServe\n- [ ] FastApi maybe doesn't make so much sense unless the batching is implemented in the backend solution\n  - For fastapi + vllm, is it better to just run the vllm server entrypoint? Just delete the fastapi+vllm one.\n\n### Triton + TensorrtLLM\n- [ ] Initial results with this setup are worse than others, user error?\n- [ ] Try with and without inflight/continuous batching?\n- [ ] Try different quantization configs\n- [ ] Improve build model/engine script to be more automatic. Write the config.pbtxt files too.\n- [ ] Compare prebuilt image vs building our own (at least by building our own we can reduce build time)\n- [ ] Change the tokenizer to not include special tokens maybe? (Need to change the tokenizer triton model)\n- [ ] There's some warnings when running the build model script about skipping stuff. Fix.\n- [ ] Are we / can we use CudaGraph?\n- [ ] All scripts so far are for llama(2). There's some extra considerations to take for codellama for example\n      because of different vocab size. See documentation.\n\n### Triton + vllm\n- [ ] Try with and without inflight batching?\n- [ ] Is quantization supported?\n\n### Text Generation Inference\n- [ ] Try quantization options\n- [x] Continuous/in-flight batching. On by default I think?\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjohnpertoft%2Fllm-inference-benchmark","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjohnpertoft%2Fllm-inference-benchmark","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjohnpertoft%2Fllm-inference-benchmark/lists"}