Skip to content

Commit

Permalink
Fix JSDoc alignment
Browse files Browse the repository at this point in the history
  • Loading branch information
sd2k committed Jul 27, 2023
1 parent d44dd00 commit 066e4a5
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/llms/openai.ts
Original file line number Diff line number Diff line change
Expand Up @@ -188,8 +188,8 @@ const isDoneMessage = (message: any): message is DoneMessage => {
}

/**
* Make a request to OpenAI's chat-completions API via the Grafana LLM plugin proxy.
*/
* Make a request to OpenAI's chat-completions API via the Grafana LLM plugin proxy.
*/
export async function chatCompletions(request: ChatCompletionsRequest): Promise<string> {
const response = await getBackendSrv().post<ChatCompletionsResponse>('/api/plugins/grafana-llm-app/resources/openai/v1/chat/completions', request, {
headers: { 'Content-Type': 'application/json' }
Expand All @@ -198,11 +198,11 @@ export async function chatCompletions(request: ChatCompletionsRequest): Promise<
}

/**
* Make a streaming request to OpenAI's chat-completions API via the Grafana LLM plugin proxy.
*
* A stream of tokens will be returned as an `Observable<string>`. Use rxjs' `scan` if you want
* to produce a new stream containing the concatenated tokens so far.
*/
* Make a streaming request to OpenAI's chat-completions API via the Grafana LLM plugin proxy.
*
* A stream of tokens will be returned as an `Observable<string>`. Use rxjs' `scan` if you want
* to produce a new stream containing the concatenated tokens so far.
*/
export function streamChatCompletions(request: ChatCompletionsRequest): Observable<string> {
const channel: LiveChannelAddress = {
scope: LiveChannelScope.Plugin,
Expand Down

0 comments on commit 066e4a5

Please sign in to comment.