trypost/app/Models
Paulo Castellano aaa4db1dbb feat: add workspace content_language setting for AI generation
Users can now pick the language AI uses for captions, hashtags,
descriptions, AND on-image / on-screen text — independent of the
app UI locale. A user with pt-BR UI who writes for an English
audience gets English content, and vice versa.

- New content_language column on workspaces (added to the existing
  create_workspaces_table migration since we're pre-production),
  defaulting to 'en'. Fillable on the model.
- Dropdown in Settings → Workspace → Brand, side-by-side with Tone.
  Options: English, Português (Brasil), Español. Short helper copy
  explains what the setting controls.
- Validation: sometimes|string|in:en,pt-BR,es — optional on update
  so existing callers that don't post the field keep the current
  value (DB default handles fresh workspaces).
- System prompt now uses $content_language (sourced from the
  workspace) instead of app()->getLocale(). The rule was also
  strengthened: the AI must always write in this language regardless
  of what language the user types instructions in, and must instruct
  image/video tools to render on-media text in this language too.
- Image and video Blade prompts received a new line forcing any text
  rendered inside the generated media to use $content_language.
- GenerateImage tool and VideoGenerationService pass the workspace's
  content_language into their respective prompt templates.

Previously the caption would be in Portuguese (since it followed the
user's input language) but the image could render with English text
because there was no explicit constraint. Now the whole pipeline is
aligned to one per-workspace language.
2026-04-16 10:37:03 -03:00
..
Traits feat: add PostCommentCreated broadcast event 2026-04-15 20:11:36 -03:00
Account.php feat: redesign billing, onboarding, sidebar, and settings architecture 2026-04-15 00:33:38 -03:00
AiMessage.php feat: complete AI assistant with custom services and brand config 2026-04-16 09:25:08 -03:00
AiUsageLog.php feat: complete AI assistant with custom services and brand config 2026-04-16 09:25:08 -03:00
ApiToken.php refactor: code review fixes — policies, enums, data_get, tests 2026-03-31 00:40:18 -03:00
Invite.php feat: introduce Account entity as billing owner and refactor architecture 2026-04-14 22:22:04 -03:00
Media.php fix: overhaul social publishing — validation, uploads, token refresh 2026-03-31 19:25:19 -03:00
Notification.php feat: notification system with SendNotification job, dialog UI, tests 2026-03-30 16:47:03 -03:00
NotificationPreference.php refactor: notification preferences, header slots, calendar layout, UI polish 2026-03-30 18:18:17 -03:00
Plan.php feat: introduce Account entity as billing owner and refactor architecture 2026-04-14 22:22:04 -03:00
Post.php feat: add ai_messages table and model 2026-04-15 21:01:26 -03:00
PostComment.php feat: add post_comments table, model, and factory 2026-04-15 20:08:16 -03:00
PostPlatform.php feat: add PostCommentCreated broadcast event 2026-04-15 20:11:36 -03:00
SocialAccount.php feat: introduce Account entity as billing owner and refactor architecture 2026-04-14 22:22:04 -03:00
Subscription.php feat: Implement soft deletes for workspace hashtags and labels, and integrate content_type into the initial post platforms table creation. 2026-01-17 14:44:37 -03:00
SubscriptionItem.php feat: Implement soft deletes for workspace hashtags and labels, and integrate content_type into the initial post platforms table creation. 2026-01-17 14:44:37 -03:00
User.php feat: introduce Account entity as billing owner and refactor architecture 2026-04-14 22:22:04 -03:00
Workspace.php feat: add workspace content_language setting for AI generation 2026-04-16 10:37:03 -03:00
WorkspaceHashtag.php refactor: settings redesign, Spanish translations, language system, strict_types 2026-03-30 00:20:43 -03:00
WorkspaceInvite.php refactor: restructure to Actions, subdomain routes (app/api), API tokens 2026-03-29 19:24:28 -03:00
WorkspaceLabel.php refactor: settings redesign, Spanish translations, language system, strict_types 2026-03-30 00:20:43 -03:00