feat: admin UI for assigning custom writing model to premium users #110
Labels
No labels
a11y
backlog
beta-feedback
bug
enhancement
feature-request
frontend
needs-triage
question
vue
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: Circuit-Forge/peregrine#110
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Premium users can have a personal fine-tuned writing model routed via cf-orch. Currently provisioning is fully manual (env var on server). This needs a managed path when multiple premium customers have personal models.
Required pieces
1. Heimdall: expose user_preferences in resolve response.
POST /admin/cloud/resolve already has a user_preferences JSON column on license_keys -- just needs to return it. The cf-core _resolve_tier forward-merges unknown fields into session.meta so session.meta["custom_writing_model"] will work automatically once returned.
2. Heimdall: PATCH /admin/keys/{key_id}/preferences endpoint.
Idempotent merge into the user_preferences JSON column. Admin bearer token required.
3. Admin UI (internal, not public).
A page in /account/admin/ with user lookup (email or UUID), product selector, model name input, Save button calling the Heimdall endpoint.
4. Drop the env var path once Heimdall is updated.
Remove USER_WRITING_MODELS from the peregrine backend .env and the parsing code in cloud_session.py.
Current workaround
Out of scope for now