features

The insiders feature registry: FeatureSpec, INSIDERS_FEATURES and resolve_features.

Registry of the features the insiders header can switch on.

The header only overrides: a feature that is absent from InsidersConfig.features keeps the default declared here. Two gates can then force a feature off – the header itself (enabled=False) and an operator-level kill switch passed as force_disabled, which wins over everything else. Keys that are not registered in INSIDERS_FEATURES can never become active, no matter what a client sends.

novelai_image_mcp.features.EXPERIMENTAL_TOOLS = 'experimental-tools'

Identifier of the experimental-tools surface.

novelai_image_mcp.features.INSIDERS_FEATURES: Mapping[str, FeatureSpec] = {'experimental-tools': FeatureSpec(name='experimental-tools', default_enabled=True, summary='Expose the experimental tool surface to the caller.'), 'model-routing': FeatureSpec(name='model-routing', default_enabled=True, summary="Resolve the request's route and model from the routing headers instead of the single configured model.")}

Every feature a client may toggle, keyed by canonical name.

novelai_image_mcp.features.MODEL_ROUTING = 'model-routing'

Identifier of the per-request model routing feature.

class novelai_image_mcp.features.FeatureSpec(name, default_enabled, summary)[source]

Bases: object

One switchable feature: its canonical name, default and description.

Parameters:
name: str
default_enabled: bool
summary: str
novelai_image_mcp.features.resolve_features(config, *, force_disabled=())[source]

Return the names of the features active for this request.

Precedence, strongest last: registered default, per-request override from the header, then force_disabled. A disabled header yields no features at all, and names absent from INSIDERS_FEATURES never take effect.

Parameters:
Return type:

frozenset[str]