microsoft / semantic-kernel

Integrate cutting-edge LLM technology quickly and easily into your apps
https://aka.ms/semantic-kernel
MIT License
21.38k stars 3.14k forks source link

.Net: Inconsistent StopSequences Properties in PromptExecutionSettings classes #8652

Closed akordowski closed 6 days ago

akordowski commented 1 week ago

In the GeminiPromptExecutionSettings and the OpenAIPromptExecutionSettings class the StopSequences property is defined as IList<string>? StopSequences.

But in the HuggingFacePromptExecutionSettings and the OllamaPromptExecutionSettings class the property is defined as List<string>? Stop.

It would be nice if the naming and the data type would be consistent through the PromptExecutionSettings classes. If wished I could provide PR for this issue. Thank you for consideration.

RogerBarreto commented 6 days ago

@akordowski I agree that we could use IList<string> for the Stop property in HuggingFace.

On the naming though, we have dedicated settings each provider uses a different name and since we are using specialized classes we try to be as coherent as possible to their documentation.

You may notice this also happening for names like Top_P that can be named as Nucleus Sampling depending on the provider.

I hope though that the documentation (XmlDocs) of those properties make it clear the purpose of those properties.

I would be happy to accept a PR that improve the docs or updates the List<string> to IList<string> on hugging face connector.

Thanks for reaching out!