ai icon indicating copy to clipboard operation
ai copied to clipboard

Support initial input as an option for useAssistant api

Open abdifardin opened this issue 11 months ago • 1 comments

Feature Description

Initial input could be passed in as an option to the useAssistant api. This would allow for the ability to pre-populate the assistant with initial input, which could be useful for a variety of use cases.

Use Case

 useAssistant({
     initialInput: "Hello, i want you to consider this information before we start",
      api: "/api/assistant",
    });
}

Additional context

Initial input is availabe in the useChat api, but not in the useAssistant api. This would be a great feature to add to the library.

If there's a workaround for this, I'd love to hear it. Otherwise, I think this would be a great feature to add to the library.

abdifardin avatar Mar 28 '24 16:03 abdifardin