Summary
gpt_oss.responses_api.serve defaults --checkpoint to ~/model and passes that string directly to the selected backend:
infer_next_token = setup_model(args.checkpoint)
Python file APIs do not expand ~ automatically. In the Triton reference path, Transformer.from_checkpoint() eventually joins the literal value with config.json and opens ~/model/config.json, which is not the user's home-directory path.
Impact
The launcher's own default checkpoint value can fail unless the caller overrides it with an already-expanded path. The same unresolved value is also forwarded to the other backends.
Proposed resolution
Expand the checkpoint path in the launcher with os.path.expanduser() before passing it to any backend, so backend behavior stays consistent.
Add a small regression with a controlled HOME value verifying ~/model resolves to the expected absolute home-relative path.
Summary
gpt_oss.responses_api.servedefaults--checkpointto~/modeland passes that string directly to the selected backend:Python file APIs do not expand
~automatically. In the Triton reference path,Transformer.from_checkpoint()eventually joins the literal value withconfig.jsonand opens~/model/config.json, which is not the user's home-directory path.Impact
The launcher's own default checkpoint value can fail unless the caller overrides it with an already-expanded path. The same unresolved value is also forwarded to the other backends.
Proposed resolution
Expand the checkpoint path in the launcher with
os.path.expanduser()before passing it to any backend, so backend behavior stays consistent.Add a small regression with a controlled
HOMEvalue verifying~/modelresolves to the expected absolute home-relative path.