navigation: confidence gate on create_skill/create_category

The create branches share a softmax with the real options, so a weak
plurality win was enough to trigger authoring. Require P(create) to clear
navigation.create_tau and lead the best existing option by
navigation.create_margin; otherwise fall back to the best existing option
(the intent guard remains a second door) and trace create_suppressed.
An empty tree/category still short-circuits straight to create.
This commit is contained in:
Denton Social committed 2026-09-29 02:47:43 -05:00
1 parent 6e197596c8
commit a29371f510
5 files changed
+234 -1

No files matched your search

+12 -1
View File
@@ -224,6 +224,9 @@ class Scheduler:
self.trace = trace if trace is not None else TraceLog()
self.config = config
self.tau = tau
nav_cfg = config.get("navigation", {}) or {}
self.create_tau = float(nav_cfg.get("create_tau", 0.4))
self.create_margin = float(nav_cfg.get("create_margin", 0.15))
self.max_reentries = max_reentries
self.codegen = codegen
self.degeneration_check_factory = degeneration_check_factory
@@ -455,7 +458,15 @@ class Scheduler:
# ---- dispatch ----
def _dispatch(self, request: Request, weight: float = 0.0) -> DispatchResult:
navigation = navigate(self.engine, self.log, self.trace, request, self.tree)
navigation = navigate(
self.engine,
self.log,
self.trace,
request,
self.tree,
create_tau=self.create_tau,
create_margin=self.create_margin,
)
if isinstance(navigation, CreateCategory):
created = self._create_category(request)
if created.kind != "create_category":