Runbook: Voice clone moderation
Service overview
Section titled “Service overview”Voice cloning requires explicit user consent (via the consent flow in the app). Clone model artefacts are stored in kc-clone-eu-{env}. The voice_clone table records owner, consent timestamp, and status.
Symptoms → Diagnosis → Fix
Section titled “Symptoms → Diagnosis → Fix”Disable a specific voice clone
Section titled “Disable a specific voice clone”-- Soft-disable: prevents the clone from being used in new TTS jobsUPDATE voice_cloneSET status = 'disabled', updated_at = now()WHERE id = '<clone_id>';In-flight TTS jobs using this clone will fail with voice_not_found and enter failed state — no data is served.
Delete a voice clone and its artefacts
Section titled “Delete a voice clone and its artefacts”- Disable the clone first (above).
- Note the R2 object key from
voice_clone.artefact_key. - Delete from R2:
AWS_ACCESS_KEY_ID="$R2_ACCESS_KEY_ID" \AWS_SECRET_ACCESS_KEY="$R2_SECRET_ACCESS_KEY" \aws s3 rm "s3://$R2_BUCKET_CLONE/<artefact_key>" \ --endpoint-url "$R2_ENDPOINT"- Hard-delete the DB row (or retain for audit with
status = 'deleted'):
UPDATE voice_clone SET status = 'deleted', artefact_key = null, updated_at = now()WHERE id = '<clone_id>';Suspend a user account (suspected abuse)
Section titled “Suspend a user account (suspected abuse)”- In Coolify → API service shell, or via a
bun runscript:
# Disable all voice clones for the userpsql "$DATABASE_URL" -c "UPDATE voice_clone SET status = 'suspended' WHERE user_id = '<user_id>';"- Revoke the Better-Auth session: invalidate all sessions for the user via the admin panel or directly:
DELETE FROM session WHERE user_id = '<user_id>';- Optionally set
user.banned = truein the Better-Authusertable (if banned field exists in schema).
Consent audit
Section titled “Consent audit”-- Show consent records for a given cloneSELECT id, user_id, consent_at, status, created_atFROM voice_cloneWHERE user_id = '<user_id>'ORDER BY created_at DESC;GDPR / right to erasure
Section titled “GDPR / right to erasure”On a verified erasure request for a user:
- Disable and delete all voice clones (above).
- Delete
media_file,media_job, anduser_creditrows for the user. - Delete the Better-Auth
user+accountrows. - Document the erasure in the operator’s GDPR log (external to this repo).