Skip to content

[Feature]: Support cost mapping for OpenAI-compatible API #5008

@xingyaoww

Description

@xingyaoww

The Feature

Support a custom field like actual_model that allows an OpenAI-compatible API to point to an existing model in https://github.com/BerriAI/litellm/blob/main/model_prices_and_context_window.json, so that the user can get price and context info about the model.

Motivation, pitch

When using LiteLLM Proxy Server, we create OpenAI-compatible APIs.
However, when users directly call it using litellm via OpenAI-compatible API, they might not fully benefit from LiteLLM, including cost tracking and model info.

Twitter / LinkedIn details

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions