feat(docs): add structured output example and details
This commit is contained in:
@@ -962,7 +962,7 @@ export class OpenWebUIProvider extends BaseAIProvider {
|
||||
* @returns Promise resolving to formatted completion response
|
||||
* @throws {Error} If API request fails
|
||||
*/
|
||||
protected async doComplete(params: CompletionParams): Promise<CompletionResponse> {
|
||||
protected async doComplete<T = any>(params: CompletionParams<T>): Promise<CompletionResponse> {
|
||||
if (this.useOllamaProxy) {
|
||||
return this.completeWithOllama(params);
|
||||
} else {
|
||||
@@ -978,7 +978,7 @@ export class OpenWebUIProvider extends BaseAIProvider {
|
||||
* @returns AsyncIterable yielding completion chunks
|
||||
* @throws {Error} If streaming request fails
|
||||
*/
|
||||
protected async *doStream(params: CompletionParams): AsyncIterable<CompletionChunk> {
|
||||
protected async *doStream<T = any>(params: CompletionParams<T>): AsyncIterable<CompletionChunk> {
|
||||
if (this.useOllamaProxy) {
|
||||
yield* this.streamWithOllama(params);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user