Skip to content

Overview

@johannes.latzel/llm-chat-openai is the OpenAI and OpenAI-compatible provider for @johannes.latzel/llm-chat. The abstract engine stays provider-neutral; this package owns the OpenAI SDK dependency and the provider-specific request and response handling.

flowchart LR
    accTitle: OpenAI provider boundary
    accDescr: An application uses OpenAIChatService from this package. The provider extends ChatService from llm-chat and converts neutral ToolDefinition values from llm-chat-tool into OpenAI function tools before calling an OpenAI-compatible API.
    app["Application"] -->|"uses"| service["OpenAIChatService<br/>this package"]
    service -->|"extends"| engine["ChatService<br/>llm-chat"]
    engine -->|"ToolDefinition"| tool["llm-chat-tool"]
    service -->|"HTTP"| api["OpenAI-compatible API"]

This package is the OpenAI / OpenAI-compatible provider implementing ChatService.createStream().

License

MIT. See LICENSE.