AnyscaleBackendAdapter
Defined in: backend/src/providers/anyscale.ts:100
Backend adapter for Anyscale Endpoints Chat Completions API.
Features:
- OpenAI-compatible API
- Platform-oriented features
- Text-only (no vision support)
- No function calling
- Pricing around $1.00 per 1M tokens
Implements
Section titled “Implements”Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new AnyscaleBackendAdapter(
config):AnyscaleBackendAdapter
Defined in: backend/src/providers/anyscale.ts:105
Parameters
Section titled “Parameters”config
Section titled “config”Returns
Section titled “Returns”AnyscaleBackendAdapter
Properties
Section titled “Properties”metadata
Section titled “metadata”
readonlymetadata:AdapterMetadata
Defined in: backend/src/providers/anyscale.ts:101
Adapter metadata for identification and capabilities.
Implementation of
Section titled “Implementation of”Methods
Section titled “Methods”estimateCost()
Section titled “estimateCost()”estimateCost(
request):Promise<number|null>
Defined in: backend/src/providers/anyscale.ts:440
Estimate cost.
Parameters
Section titled “Parameters”request
Section titled “request”Returns
Section titled “Returns”Promise<number | null>
Implementation of
Section titled “Implementation of”execute()
Section titled “execute()”execute(
request,signal?):Promise<IRChatResponse>
Defined in: backend/src/providers/anyscale.ts:240
Execute non-streaming request.
Parameters
Section titled “Parameters”request
Section titled “request”signal?
Section titled “signal?”AbortSignal
Returns
Section titled “Returns”Promise<IRChatResponse>
Implementation of
Section titled “Implementation of”executeStream()
Section titled “executeStream()”executeStream(
request,signal?):IRChatStream
Defined in: backend/src/providers/anyscale.ts:282
Execute streaming request.
Parameters
Section titled “Parameters”request
Section titled “request”signal?
Section titled “signal?”AbortSignal
Returns
Section titled “Returns”Implementation of
Section titled “Implementation of”fromIR()
Section titled “fromIR()”fromIR(
request):AnyscaleRequest
Defined in: backend/src/providers/anyscale.ts:136
Convert IR to Anyscale format.
Parameters
Section titled “Parameters”request
Section titled “request”Returns
Section titled “Returns”Implementation of
Section titled “Implementation of”healthCheck()
Section titled “healthCheck()”healthCheck():
Promise<boolean>
Defined in: backend/src/providers/anyscale.ts:424
Health check.
Returns
Section titled “Returns”Promise<boolean>
Implementation of
Section titled “Implementation of”toIR()
Section titled “toIR()”toIR(
response,originalRequest,latencyMs):IRChatResponse
Defined in: backend/src/providers/anyscale.ts:183
Convert Anyscale response to IR.
Parameters
Section titled “Parameters”response
Section titled “response”originalRequest
Section titled “originalRequest”latencyMs
Section titled “latencyMs”number