Files
0bd13e7584 feat(cli): forward --trust-remote-code to SMG (#3987)
## Summary

Forward the effective `--trust-remote-code` setting from `ts serve` to
SMG so the gateway can render text chat with a checkpoint's custom
Python tokenizer. The engine receives the supplied trust flags in order.
When both forms are present, the last form determines whether the
gateway receives the opt-in.

## Dependency

This change depends on the SMG Python renderer and its startup opt-in.
[smg-project/smg#9376](https://github.com/smg-project/smg/pull/9376)

The `tokenspeed-smg` dependency is updated to `1.16.0.post20261203`.

## Test Plan

- `pre-commit run --all-files` passed.
- `python -m pytest -q test/cli/test_argsplit.py` passed 47 tests,
including defaults, both flag forms, and repeated settings.
- Exercised `ts serve` offline with a locally built SMG wheel, a local
checkpoint, and a CPU fake backend. The enabled case matched the
reference Python prompt token IDs. The disabled case returned the opt-in
error.

---------

Signed-off-by: tuanzhangCS <26617745+tuanzhangCS@users.noreply.github.com>
Signed-off-by: tuanzhangCS <tuan@lightseek.org>
Co-authored-by: tuanzhangCS <26617745+tuanzhangCS@users.noreply.github.com>
Co-authored-by: minedec <37043133+minedec@users.noreply.github.com>
2026-12-03 20:45:31 +08:00
..