MCPcopy Create free account
hub / github.com/CommonstackAI/UncommonRoute / save_online_model

Function save_online_model

uncommon_route/router/classifier.py:106–112  ·  view source on GitHub ↗

Persist current weights to the online model file.

(path: Path | None = None)

Source from the content-addressed store, hash-verified

104
105
106def save_online_model(path: Path | None = None) -> None:
107 """Persist current weights to the online model file."""
108 if _model is None:
109 return
110 p = path or _get_online_model_path()
111 p.parent.mkdir(parents=True, exist_ok=True, mode=0o700)
112 _model.save(p)
113
114
115def rollback_online_model() -> bool:

Callers 2

_apply_feedbackFunction · 0.90
_do_updateMethod · 0.90

Calls 2

_get_online_model_pathFunction · 0.85
saveMethod · 0.45

Tested by

no test coverage detected