Files
wehub-resource-sync e9a2f726c9
CI / test (3.11) (push) Has been cancelled
CI / test (3.12) (push) Has been cancelled
CI / test (3.13) (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 13:29:51 +08:00

39 lines
824 B
Python

# SPDX-License-Identifier: Apache-2.0
"""
API Adapters for oMLX.
This package provides adapters for different API formats (OpenAI, Anthropic),
enabling clean separation between API-specific logic and core inference.
"""
from .base import (
BaseAdapter,
InternalMessage,
InternalRequest,
InternalResponse,
StreamChunk,
)
from .openai import OpenAIAdapter
from .anthropic import AnthropicAdapter
from .sse_formatter import (
SSEFormatter,
OpenAISSEFormatter,
AnthropicSSEFormatter,
)
__all__ = [
# Base classes and types
"BaseAdapter",
"InternalMessage",
"InternalRequest",
"InternalResponse",
"StreamChunk",
# Adapters
"OpenAIAdapter",
"AnthropicAdapter",
# SSE Formatters
"SSEFormatter",
"OpenAISSEFormatter",
"AnthropicSSEFormatter",
]