Platforms to show: All Mac Windows Linux Cross-Platform

Back to NLContextualEmbeddingMBS class.

NLContextualEmbeddingMBS.available as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Natural Language MBS MacFrameworks Plugin 26.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Whether the class is available.
Example
If NLContextualEmbeddingMBS.available Then
MessageBox "available"
Else
MessageBox "not available"
end if

Returns true on macOS 14, iOS 17 or newer.

NLContextualEmbeddingMBS.contextualEmbeddingsForValues(values as Dictionary) as NLContextualEmbeddingMBS()

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Natural Language MBS MacFrameworks Plugin 26.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Returns contextual embedding models that match the specified language, script, or revision criteria.

The dictionaries has values using the NLContextualEmbeddingKeyLanguages, NLContextualEmbeddingKeyScripts and NLContextualEmbeddingKeyRevision constants.

NLContextualEmbeddingMBS.contextualEmbeddingWithLanguage(language as String) as NLContextualEmbeddingMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Natural Language MBS MacFrameworks Plugin 26.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Creates a contextual embedding from a language.
Example
const lang = "en"
Var n As NLContextualEmbeddingMBS = NLContextualEmbeddingMBS.contextualEmbeddingWithLanguage(lang)

MessageBox n.modelIdentifier

language: The language the framework uses to find the most recent embedding suitable for the value you specify.

The language the framework uses to find the most recent embedding suitable for the value you specify.

NLContextualEmbeddingMBS.contextualEmbeddingWithModelIdentifier(modelIdentifier as String) as NLContextualEmbeddingMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Natural Language MBS MacFrameworks Plugin 26.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Creates a contextual embedding from a model identifier.

modelIdentifier: A string that uniquely identifies the embedding model.

If you train a custom model with the contextual embedding as the feature layer, keep track of this identifier and use it when loading the custom model in your app.

NLContextualEmbeddingMBS.contextualEmbeddingWithScript(script as String) as NLContextualEmbeddingMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Natural Language MBS MacFrameworks Plugin 26.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Creates a contextual embedding from a script.

script: The writing system the framework uses to find the most suitable system embedding for the value you specify; for example, Chinese or Latin.

NLContextualEmbeddingMBS.NLContextualEmbeddingKeyLanguages as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Natural Language MBS MacFrameworks Plugin 26.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Dictionary key for the languages.

For use with contextualEmbeddingsForValues function.

NLContextualEmbeddingMBS.NLContextualEmbeddingKeyRevision as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Natural Language MBS MacFrameworks Plugin 26.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Dictionary key for the revision.

For use with contextualEmbeddingsForValues function.

NLContextualEmbeddingMBS.NLContextualEmbeddingKeyScripts as String

Type Topic Plugin Version macOS Windows Linux iOS Targets
shared method Natural Language MBS MacFrameworks Plugin 26.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Dictionary key for the scripts.

For use with contextualEmbeddingsForValues function.

The items on this page are in the following plugins: MBS MacFrameworks Plugin.


The biggest plugin in space...