Skip to content

How to pass param n to ChatSparkLLM.generate() #56

@chansonzhang

Description

@chansonzhang

param n is widely supprted by LLM clients to specify how many completions to generate for the conversation.
e.g.

So, how can I pass n to ChatSparkLLM.generate()

When I use

spark = ChatSparkLLM(n=2, <other params ommitted>)

It report sparkai.errors.SparkAIConnectionError: Error Code: 10004, Error: SchemaCheckError:(14:37:32.934) '$.parameter.chat.n' unknown field;

When I use

spark.generate([messages], callbacks=[handler],n=2,)

It just doesn't work.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions