package com.ruoyi.web.kb.service;

import java.io.IOException;
import java.io.OutputStream;

import com.ruoyi.web.kb.support.KbApiProperties;
import org.springframework.http.ResponseEntity;

/**
 * 大模型 OpenAI 兼容接口转发（{@code /v1/models}、{@code /v1/chat/completions}），与知识库共用 {@link KbApiProperties}。
 */
public interface KbOpenAiProxyService
{
    ResponseEntity<byte[]> listModels();

    ResponseEntity<byte[]> chatCompletions(byte[] requestBody);

    boolean isStreamRequest(byte[] requestBody);

    void streamChatCompletions(byte[] requestBody, OutputStream output) throws IOException;
}
