-
Notifications
You must be signed in to change notification settings - Fork 222
feat(config): add router and KV transfer metadata #2096
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -114,6 +114,16 @@ | |
| return f"kv{kv_offloading}-{kv_offload_backend}" | ||
|
|
||
|
|
||
| def component_metadata(benchmark: dict, config: dict) -> dict: | ||
| """Resolve optional component metadata, preferring search-space overrides.""" | ||
| metadata = {} | ||
| for field in (Fields.ROUTER, Fields.KV_TRANSFER): | ||
| value = benchmark.get(field.value, config.get(field.value)) | ||
| if value is not None: | ||
| metadata[field.value] = value | ||
| return metadata | ||
|
Check failure on line 124 in utils/matrix_logic/generate_sweep_configs.py
|
||
|
Comment on lines
+117
to
+124
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🔴 Extended reasoning...The bugThe new Downstream, key = tuple(sorted((k, v) for k, v in entry.items() if k != "conc"))
groups.setdefault(key, []).append(len(out))Because Step-by-step proof
I reproduced this directly against the current tree: → Why existing code doesn't prevent itThe exact hazard is already solved elsewhere in ImpactLatent — no master config currently ships FixTwo clean options:
Option 1 is a one-liner and preserves the emitted schema everywhere else. Either way, the fix should ship with this PR before the first |
||
|
|
||
|
|
||
| def chunk_multinode_agentic_concurrencies(conc_values: list[int]) -> list[list[int]]: | ||
| """Bound sequential agentic profiles sharing one server allocation.""" | ||
| size = MAX_MULTINODE_AGENTIC_CONCURRENCIES_PER_ALLOCATION | ||
|
|
@@ -457,6 +467,7 @@ | |
| Fields.DISAGG.value: disagg, | ||
| Fields.RUN_EVAL.value: False, # Default, may be overridden by mark_eval_entries | ||
| } | ||
| entry.update(component_metadata(bmk, val)) | ||
|
|
||
| validate_matrix_entry(entry, is_multinode) | ||
| matrix_values.append(entry) | ||
|
|
@@ -570,6 +581,7 @@ | |
| if dp_attn is not None: | ||
| entry[Fields.DP_ATTN.value] = dp_attn | ||
|
|
||
| entry.update(component_metadata(bmk, val)) | ||
| validate_matrix_entry(entry, is_multinode) | ||
| matrix_values.append(entry) | ||
|
|
||
|
|
@@ -654,6 +666,7 @@ | |
| Fields.DISAGG.value: disagg, | ||
| Fields.SCENARIO_TYPE.value: "agentic-coding", | ||
| } | ||
| entry.update(component_metadata(bmk, val)) | ||
| validate_agentic_matrix_entry(entry) | ||
| matrix_values.append(entry) | ||
| else: | ||
|
|
@@ -681,6 +694,7 @@ | |
| } | ||
| if kv_offload_backend is not None: | ||
| entry[Fields.KV_OFFLOAD_BACKEND.value] = kv_offload_backend | ||
| entry.update(component_metadata(bmk, val)) | ||
| validate_agentic_matrix_entry(entry) | ||
| matrix_values.append(entry) | ||
|
|
||
|
|
@@ -797,6 +811,7 @@ | |
| Fields.DISAGG.value: disagg, | ||
| Fields.RUN_EVAL.value: False, | ||
| } | ||
| entry.update(component_metadata(bmk, val)) | ||
| matrix_values.append(validate_matrix_entry(entry, is_multinode=True)) | ||
| else: | ||
| # Single-node config | ||
|
|
@@ -849,6 +864,7 @@ | |
| Fields.DISAGG.value: disagg, | ||
| Fields.RUN_EVAL.value: False, | ||
| } | ||
| entry.update(component_metadata(bmk, val)) | ||
| matrix_values.append(validate_matrix_entry(entry, is_multinode=False)) | ||
|
|
||
| # ---- Agentic-coding scenarios ---- | ||
|
|
@@ -921,6 +937,7 @@ | |
| Fields.DISAGG.value: disagg, | ||
| Fields.SCENARIO_TYPE.value: "agentic-coding", | ||
| } | ||
| entry.update(component_metadata(bmk, val)) | ||
| matrix_values.append(validate_agentic_matrix_entry(entry)) | ||
| else: | ||
| for conc in conc_values: | ||
|
|
@@ -947,6 +964,7 @@ | |
| } | ||
| if kv_offload_backend is not None: | ||
| entry[Fields.KV_OFFLOAD_BACKEND.value] = kv_offload_backend | ||
| entry.update(component_metadata(bmk, val)) | ||
| matrix_values.append(validate_agentic_matrix_entry(entry)) | ||
|
|
||
| return matrix_values | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
📊 Line Count Report