Canonical Runtime Name • AI Agent SDK

canonical_runtime_name: Normalise a runtime name; reject typos but allow genuine plugin names.

Next

canonical_runtime_name

Function

</div>

This function is defined in the feature_configs module.

Normalise a runtime name; reject typos but allow genuine plugin names.

Matching is case-insensitive, ignores surrounding whitespace, and treats `-/_` as interchangeable, mirroring the other preset resolvers.

A value that names a known runtime resolves to its canonical spelling, so `NATIVE/ native all map to native and pick up the full matrix instead of silently dropping capabilities. A value that is a close typo of a known runtime (e.g. nativ`) raises with a suggestion rather than degrading silently. A genuinely unknown name (e.g. a third-party plugin runtime registered later) is returned as-is so it can fall back to the reduced harness — matching the runtime registry, not a closed literal.

Signature

python
def canonical_runtime_name(value: str) -> str

Parameters

ParamField str

No description available.

Returns

ResponseField str

The result of the operation.

Uses

  • canonical_preset_key
  • suggest_similar
  • make_preset_error

Used By

Source

View on GitHub

praisonaiagents/config/feature_configs.py at line 1950