Skip to content

Support Custom Patterns for Model Endpoint #89

@siarhei-fedziukovich

Description

@siarhei-fedziukovich

Name and Version

0.4.2

What is the problem this feature will solve?

The current implementation of the model endpoint enforces a strict pattern for API requests, which limits flexibility. To improve usability and accommodate different deployment scenarios, the model endpoint should support additional patterns.

Current Behavior

The model endpoint must follow the pattern:

<adapter_base_url>/<model_name>(/chat/completion | /embeddings)

Proposed Enhancements

  1. Support for Direct OpenAI Endpoint Links
    Allow the endpoint to handle requests in the following format:
    <adapter_base_endpoint>/(/chat/completion | /embeddings)

    • Here, <adapter_base_endpoint> is of the form <host_name>/v1.
  2. Support for Custom Deployment Names
    Enable the use of custom deployment names that may not match the model_name. The new pattern should look like:
    <adapter_base_url>/<custom_deployment_name>(/chat/completion | /embeddings)

What is the feature you are proposing to solve the problem?

Acceptance Criteria

  • Requests with the direct OpenAI endpoint pattern (<host_name>/v1) are processed successfully.
  • Requests using custom deployment names are processed successfully.
  • Existing functionality with the current pattern remains unaffected.
  • Unit tests and integration tests are updated to cover the new patterns.
  • Documentation is updated to reflect the new patterns.

Additional Notes

  • Consider backward compatibility to ensure no disruption to existing users.
  • Ensure proper error handling for invalid patterns.

What alternatives have you considered?

No response

Metadata

Metadata

Assignees

Labels

PRIORITY-highSIA-scheduledTasks that require Security Impact Analysis (SIA) and it's already have been scheduled.documentationImprovements or additions to documentationenhancementNew feature or request

Type

No type

Projects

Status

Ready for auto QA

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions