You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Delete the unreachable legacy optimizer decorator path in sessionmanager #6103
#6033 (review follow-through) adds a constructor guard in sessionmanager.New: configuring an optimizer (FactoryConfig.OptimizerFactory or OptimizerConfig) without AdvertiseFromCore is now rejected at startup. Previously that configuration installed the optimizer decorator (factory.go, the optimizerFactory != nil && !cfg.AdvertiseFromCore branch) but the Serve layer discarded its advertised tools (serve_optimizer.go returns raw core tools when s.optimizerFactory == nil) — the decorator indexed the FTS5 store (including an embedding round-trip per tool when configured) and served no one, and the Modern capability gate failed open.
What to do
With the guard in place, the !cfg.AdvertiseFromCore optimizer branch in pkg/vmcp/server/sessionmanager/factory.go is unreachable. Delete:
optimizerDecoratorFn (factory.go:160-178)
the && !cfg.AdvertiseFromCore condition and the branch it guards (factory.go:151)
adaptToolsForFactory and the optimizerdec import, if nothing else uses them
and simplify any comments that still describe the "legacy decorator" composition path. Kept out of #6033 to avoid growing an already-XL diff with a cascading deletion.
Activity
Address capability-gate review feedback
Replace vMCP Modern kill-switch with a capability gate (#6033)