[PR #2605] [CLOSED] bench: a bench-started server also drops the config's "expert_profile_save" key, not only the argument (#2088) #4161

Closed
opened 2026-11-07 15:33:42 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Niko1221/Strata/pull/2605
Author: @qiuzan2001
Created: 10/15/2026
Status: ❌ Closed

Base: main ← Head: chief-serve/bench-profile-key


📝 Commits (1)

  • 044439e bench: a bench-started server also drops the config's "expert_profile_save" key, not only the argument (#2088)

📊 Changes

2 files changed (+25 additions, -4 deletions)

View changed files

📝 tools/strata_bench.py (+10 -4)
📝 tools/test_strata_bench.py (+15 -0)

📄 Description

On #2088; the gap docs PR #2601 describes.

What it changes. When the bench starts the server itself, without_profile_save() in tools/strata_bench.py
gives it a copy of the config without --expert-profile-save, so the bench's short prompts do not overwrite the
user's profile (017a672a). But serve/server.py learned_profile_args() adds that same argument back from a
config's "expert_profile_save" key (#477, opt-in): a bench-started server from such a config still saved its
profile at QUIT and every 10 minutes, and started from the learned profile instead of the config's own
--expert-profile, against the pinned-profile rule in docs/COMMUNITY_BENCHMARKS.md. The copy now also leaves out
"expert_profile_save" and "expert_profile_save_every", and the stderr note names the key.

What it leaves alone. The user's config file (only the temporary copy beside the bench log changes). A config
with neither the argument nor the key: the same object, started from the user's own file as before. --url runs
(the bench does not start that server). The server's handling of the key.

How it was checked. tools/test_strata_bench.py
ReportTests.test_a_bench_server_never_saves_over_the_users_profile now also covers a config with the key: the copy
has no key, learned_profile_args() on the copy adds no --expert-profile-save (on the original it does), and
start_server writes the copy without the key. Fails on main; 17 tests OK. Python 3.14, Ubuntu (Linux 7.0); no GPU.

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Niko1221/Strata/pull/2605 **Author:** [@qiuzan2001](https://github.com/qiuzan2001) **Created:** 10/15/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `chief-serve/bench-profile-key` --- ### 📝 Commits (1) - [`044439e`](https://github.com/Niko1221/Strata/commit/044439ecc0792a1530755c928ff2ee00b6a8e2f0) bench: a bench-started server also drops the config's "expert_profile_save" key, not only the argument (#2088) ### 📊 Changes **2 files changed** (+25 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `tools/strata_bench.py` (+10 -4) 📝 `tools/test_strata_bench.py` (+15 -0) </details> ### 📄 Description On #2088; the gap docs PR #2601 describes. **What it changes.** When the bench starts the server itself, `without_profile_save()` in `tools/strata_bench.py` gives it a copy of the config without `--expert-profile-save`, so the bench's short prompts do not overwrite the user's profile (017a672a). But `serve/server.py` `learned_profile_args()` adds that same argument back from a config's `"expert_profile_save"` key (#477, opt-in): a bench-started server from such a config still saved its profile at QUIT and every 10 minutes, and started from the learned profile instead of the config's own `--expert-profile`, against the pinned-profile rule in docs/COMMUNITY_BENCHMARKS.md. The copy now also leaves out `"expert_profile_save"` and `"expert_profile_save_every"`, and the stderr note names the key. **What it leaves alone.** The user's config file (only the temporary copy beside the bench log changes). A config with neither the argument nor the key: the same object, started from the user's own file as before. `--url` runs (the bench does not start that server). The server's handling of the key. **How it was checked.** `tools/test_strata_bench.py` `ReportTests.test_a_bench_server_never_saves_over_the_users_profile` now also covers a config with the key: the copy has no key, `learned_profile_args()` on the copy adds no `--expert-profile-save` (on the original it does), and `start_server` writes the copy without the key. Fails on `main`; 17 tests OK. Python 3.14, Ubuntu (Linux 7.0); no GPU. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-07 15:33:42 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#4161
No description provided.