Skip to content

Use of dictionary for LanguageModelCreateOptions , LanguageModelPromptOptions #197

@sushraja-msft

Description

@sushraja-msft

Opening an issue for API shape discussion
https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/modules/ai/language_model.idl
https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/modules/ai/language_model_create_options.idl

dictionary LanguageModelPromptOptions {
object responseConstraint;
boolean omitResponseConstraintInput = false;
AbortSignal signal;
};

dictionary LanguageModelCreateOptions : LanguageModelCreateCoreOptions {
AbortSignal signal;
CreateMonitorCallback monitor;

sequence initialPrompts;
};

A developer I heard from complained that, this makes it so that when unexpected values are passed to prompt options. Like initialPrompts for the PromptOptions - it gets silently ignored.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions