Skip to content

feat(model-config): completion_type array + CRUD endpoints#890

Open
vprashrex wants to merge 3 commits into
mainfrom
feat/model-config-crud-and-completion-type-array
Open

feat(model-config): completion_type array + CRUD endpoints#890
vprashrex wants to merge 3 commits into
mainfrom
feat/model-config-crud-and-completion-type-array

Conversation

@vprashrex
Copy link
Copy Markdown
Collaborator

@vprashrex vprashrex commented May 26, 2026

Target issue is #891

Summary

What changed

  • Migration 064completion_type scalar "stt" → array ['text', 'stt']. Old index dropped, GIN index added.
  • New endpoints on /api/v1/models:
    • POST — create one or many.
    • PATCH /{provider}/{model_name} — partial update.
    • PATCH — bulk update, atomic.
    • DELETE /{provider}/{model_name} — hard delete.
  • is_model_supported / list_supported_models use array .contains() queries.
  • Modality fields (input_modalities, output_modalities) validated against enum.
  • Swagger docs under app/api/docs/model_config/.

Checklist

  • Ran fastapi run --reload app/main.py or docker compose up in the repository root and test.
  • If you've fixed a bug or added code that is tested and has test cases,

…update related endpoints

- Added Alembic migration to change completion_type from scalar to array in model_config table.
- Updated API documentation for creating, updating, and deleting model configurations to reflect changes in completion_type.
- Implemented bulk create and update functionality for model configurations.
- Enhanced model configuration routes to support new array-based completion_type and added validation for input modalities.
- Added tests for creating, updating, and deleting model configurations with new completion_type structure.
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 26, 2026

Important

Review skipped

Auto reviews are limited based on label configuration.

🏷️ Required labels (at least one) (1)
  • ready-for-review

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 395c88b4-2b7a-43e9-ba96-49fe12e9ac61

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/model-config-crud-and-completion-type-array

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@vprashrex vprashrex linked an issue May 26, 2026 that may be closed by this pull request
@sentry
Copy link
Copy Markdown

sentry Bot commented May 26, 2026

Codecov Report

❌ Patch coverage is 98.08429% with 5 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
backend/app/crud/model_config.py 91.66% 5 Missing ⚠️

📢 Thoughts on this report? Let us know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Model Config: CRUD endpoints and completion_type as array

2 participants