Issues / #3504

#3504 [Terminal 0.2.1] Advanced settings mis-serialize multi-value args and "off" emits bare flags instead of removing them

open · @PTSD-Creations · 1 comentários · No GitHub

needs-format

Descrição

## Summary

Strata Terminal 0.2.1's Advanced settings/profile generation can produce invalid engine argv in two related ways:

1. A setting that requires multiple positional values is serialized as a single comma-separated value.
2. The Advanced UI says `off` removes an override, but for some options it instead leaves the flag in `args` with no value.

The resulting bare flags consume later argv values and cause misleading engine startup errors.

This appears related to #3216, but this reproduction is on Terminal 0.2.1 / Control 0.1.46.2 / Engine 0.1.46 and involves Advanced-setting serialization.

## Environment

- Strata Terminal: `0.2.1`
- Terminal/control build: `0.1.46.2`
- Engine: `0.1.46`
- Windows 11
- NVIDIA RTX 4070 12 GB
- Reproduced while creating/starting an NVFP4 128K profile through the Terminal setup flow

## Issue 1: Multi-value argument serialization

The engine expects:

`--control-vector-layer-range 4 44`

A valid profile therefore needs:

`"--control-vector-layer-range", "4", "44"`

When configured through the Terminal Advanced-settings path, the generated runtime JSON instead becomes:

`"--control-vector-layer-range", "4,44"`

The engine option itself expects two values (`A B`), so these are not equivalent argv.

## Issue 2: `off` leaves bare flags

The Advanced editor indicates that entering `off` removes the setting.

After setting the control-vector options to `off`, however, the generated `args` contained:

`"--control-vector-layer-range", "--control-vector-scaled", "--conversation-cache-mib", "8192", "--conversation-cache-slots", "4", "--cvec-dir", "--cvec-mode"`

Instead of removing the disabled options, their values were removed while the option names remained.

This corrupts parsing because valued options consume the following argv entries.

For example, the engine eventually reported:

`unknown argument: 8192`

even though the cache setting itself was correctly represented as:

`"--conversation-cache-mib", "8192"`

Another startup attempt failed with:

`--cvec-dir: per-layer or single:L, got '--cvec-mode'`

This shows `--cvec-mode` was being consumed as the missing value for the preceding bare `--cvec-dir`.

## Expected behavior

For a multi-value setting:

`--control-vector-layer-range 4 44`

should serialize as:

`"--control-vector-layer-range", "4", "44"`

If `off` means remove, the option itself and its value(s) should be completely absent from generated engine `args`.

## Actual behavior

Multi-value input can become:

`"--control-vector-layer-range", "4,44"`

and options set to `off` can become bare flags such as:

`"--control-vector-layer-range", "--control-vector-scaled", "--cvec-dir", "--cvec-mode"`

Those bare flags then shift argv parsing and cause subsequent valid settings to appear to be invalid.

## Workaround / Confirmation

Manually deleting the offending control-vector overrides/arguments completely allowed the NVFP4 profile to start and begin tuning.

This suggests the NVFP4 model/engine itself was not responsible for the startup failure.

The generated profile also contained an `args_written` array that ended cleanly before these Advanced overrides, while `args` contained the malformed appended options. This made the difference particularly visible.

## Related

Possibly related to #3216, which involves control-vector arguments being lost/regenerated, although this reproduction is specifically the Terminal 0.2.1 Advanced-settings serialization/removal behavior.

No site

Links install, modelos, releases.