Commit Graph

154 Commits

Author SHA1 Message Date
ajaysi
917be873df Fix: add missing deps, lazy-load heavy modules in podcast mode 2026-04-06 07:37:02 +05:30
ajaysi
63bb937796 feat: podcast demo mode with ALWRITY_ENABLED_FEATURES support
- Add ALWRITY_ENABLED_FEATURES env var for feature gating
- Podcast-only mode: skip LLM bootstrap, scheduler, persona services
- Enhance video generation prompt with scene context, analysis, narration
- Add voice cloning support via custom_voice_id in WaveSpeed
- Add text-to-speech for research results (browser speechSynthesis)
- Fix render queue to sync images from script phase
- Add WaveSpeed LLM pricing (gpt-oss-120b)
- Fix podcast bible generation error handling
- Refactor RouterManager for feature-based router loading
2026-04-03 06:59:59 +05:30
ajaysi
c52b1eabc9 Remove hardcoded huggingface provider from all podcast handlers
- script.py: set preferred_provider=None to respect GPT_PROVIDER
- research.py: set preferred_provider=None to respect GPT_PROVIDER
- Now all podcast handlers use GPT_PROVIDER env var
2026-04-01 06:55:31 +05:30
ajaysi
746a5eeeb9 Fix LLM provider selection in podcast handlers
- Remove hardcoded preferred_provider=huggingface in podcast handlers
- Set preferred_provider=None to respect GPT_PROVIDER env var
- Change default model from Qwen to gpt-oss-120b:cerebras (the model user had access to)
- WaveSpeed will now use gpt-oss-120b model instead of Qwen
2026-04-01 06:54:37 +05:30
ajaysi
35fd700b22 Propagate LLM errors in podcast handlers to frontend
- analysis.py: enhance_podcast_idea now re-raises HTTPException (429)
- analysis.py: analyze_podcast_idea already re-raises HTTPException
- research.py: re-raise HTTPException instead of silent fallback
- script.py: re-raise HTTPException instead of generic 500

Ensures 429 errors with usage_info reach frontend for modal display
2026-03-31 19:32:23 +05:30
ajaysi
92bcd27004 Fix generate_image() call in podcast analysis handler
Use options dict instead of direct width/height params to match
the generate_image() function signature in main_image_generation.py
2026-03-31 18:16:19 +05:30
ajaysi
92bbe1d878 Merge PR #456: Add forced user_id lint check and demo router gating 2026-03-30 08:18:50 +05:30
ي
636989f75b Add forced user_id lint check and demo router gating 2026-03-30 08:13:48 +05:30
ajaysi
2a41e94c07 Merge PR #454: Use tenant-scoped dubbed audio paths with safe file resolution 2026-03-30 08:07:39 +05:30
ي
27c167ebe8 Use tenant-scoped dubbed audio paths with safe file resolution 2026-03-30 08:07:01 +05:30
ي
b54c2978c3 Restrict podcast task status access by owner 2026-03-30 08:05:44 +05:30
ajaysi
557f700f68 fix: Resolve APIProvider enum mismatch causing dashboard errors
- Fix import path in subscriptions.py (pricing_service location)
- Add values_callable to APIUsageLog.provider enum column
- Normalize provider values to lowercase in usage trends helpers
- Add migration script for existing databases
2026-03-29 12:50:50 +05:30
ajaysi
d6ad903e3d feat: Improve image generation prompts with visual data extraction
- Add dedicated image_generation module with statistical extraction
- Support 16 industry domains with visual concept detection
- Add model-specific guidance for Ideogram, FLUX, GLM, Qwen, MAI
- Extract statistics, rankings, comparisons, and trends automatically
- Refactor backend/api/images.py to use new module
2026-03-29 10:16:40 +05:30
ajaysi
f503a24b3b feat: Add Auto-Dubbing feature for Podcast Maker
This commit adds the Auto-Dubbing feature for Podcast Maker with support
for translating podcast audio to different languages with optional voice
cloning to preserve the original speaker's voice.

New Features:
- Translation Service (common module): DeepL integration for low-cost
  translation, WaveSpeed integration for high-quality translation
- Audio Dubbing Service: STT -> Translate -> TTS pipeline with
  voice cloning support
- 9 new API endpoints for dubbing and voice cloning
- Support for 34+ languages
- Cost estimation utilities
- Comprehensive documentation

Files Added:
- services/translation/ (5 files): Translation service module
- services/dubbing/: Audio dubbing service
- api/podcast/handlers/dubbing.py: API endpoints
- docs/AUTO_DUBBING.md: Feature documentation
- CHANGELOG.md: Change log

Files Modified:
- api/podcast/models.py: Added dubbing request/response models
- api/podcast/router.py: Added dubbing routes
- services/__init__.py: Export translation and dubbing services
- scene_animation.py: Fixed missing Path import
2026-03-24 15:45:51 +05:30
ajaysi
16be2b21f4 Fix user data endpoints to require authenticated user ID
- Add get_current_user authentication to all user data endpoints
- Pass authenticated user_id from auth context to service methods
- Add proper HTTPException handling for missing data
- Fix user_id type from int to str in service methods
- Ensure endpoints only return data for authenticated user
2026-03-22 11:02:35 +05:30
ajaysi
acc5e1f72c Merge_PR_415_enforce_runtime_only_workspace_creation 2026-03-12 16:01:23 +05:30
ajaysi
e7171df5db Merge branch 'pr-413' 2026-03-12 15:46:43 +05:30
ajaysi
f23e99558f Merge branch 'pr-412' 2026-03-12 15:41:04 +05:30
ajaysi
d4bec3c791 Merge_PR_411_tenant_aware_video_studio_storage 2026-03-12 15:39:12 +05:30
ajaysi
d0267c7608 Merge branch 'pr-409' 2026-03-12 15:33:33 +05:30
ajaysi
901470eb8b Merge_PR_408_flat_context_and_txtai_file_tools 2026-03-12 15:29:08 +05:30
ajaysi
e90a29c27e Merge_PR_410_with_local_changes 2026-03-12 15:21:08 +05:30
ي
3ebe884a37 Enforce runtime-only workspace directory creation policy 2026-03-12 15:00:59 +05:30
ي
22df52f9d6 Unify story media path resolution across services and routes 2026-03-12 14:59:45 +05:30
ي
d4baf8828e Refactor podcast media storage to lazy tenant resolver 2026-03-12 14:59:03 +05:30
ي
29c268dda8 Add tenant-aware video studio storage path resolver 2026-03-12 14:58:27 +05:30
ajaysi
01881bb405 "feat:enhance-podcast-topic-ai" 2026-03-11 19:09:27 +05:30
ي
7619604324 Harden logging config with safer overrides and optional JSON/file sinks 2026-03-11 16:31:28 +05:30
ي
cbe41ef8c7 Add Step 5 flat context and txtai file tools for agents 2026-03-11 10:42:05 +05:30
ajaysi
b410ece4ca Commit_remaining_local_changes_after_PR_407_merge 2026-03-10 17:17:04 +05:30
ajaysi
8c2d88efb9 Commit_all_local_changes_after_PR_406_merge 2026-03-10 17:01:36 +05:30
ajaysi
098424f696 fix: Make TxtaiIntelligenceService initialization non-blocking
- Modified _ensure_initialized() to run in background thread (non-blocking)
- Added _ensure_initialized_async() for truly async initialization
- Updated index_content() to return immediately without waiting for initialization
- Weights now load in background thread instead of blocking event loop
- Added initialization tracking to prevent duplicate initialization
- Modified today_workflow API to handle non-blocking indexing gracefully
- This prevents dashboard refresh from blocking other services

When a user accesses the dashboard, the indexing now happens in background
instead of blocking the HTTP response, allowing other services to function
normally while weights are being loaded.
2026-03-09 16:25:56 +05:30
ajaysi
7747174f00 Merge branch 'pr-404' 2026-03-09 16:20:06 +05:30
ajaysi
9fe9f819d8 Merge branch 'pr-401' 2026-03-09 15:33:08 +05:30
ajaysi
1c3524964e Merge branch 'pr-400' 2026-03-09 15:19:47 +05:30
ajaysi
b3cc83ed6e fix: resolve onboarding session not found warnings and frontend build OOM
- Use canonical Clerk user id (clerk_user_id) across all onboarding entrypoints to ensure consistent OnboardingSession.user_id lookup
- Fix API key persistence in api_key_manager.py to use correct APIKey model columns (session_id, provider, key)
- Increase Node heap for frontend build to 8GB and add build:nomap script to disable sourcemaps and reduce memory usage
- Update onboarding endpoints (endpoints_core.py, onboarding_control_service.py, step_management_service.py) to prefer clerk_user_id over id
- Fix frontend workflowStore.ts TypeScript error by returning WorkflowError instance
- Add website_automation_service.py for onboarding automation
2026-03-09 13:36:34 +05:30
ي
a19a18d9b4 Add competitor_analysis fallback for deep competitor task scheduling 2026-03-09 12:07:18 +05:30
ي
c3bd04e259 Fix huddle SSE auth fallback with query token support 2026-03-09 12:06:49 +05:30
ي
6b141ee554 Merge branch 'main' into codex/implement-central-visibility-for-seo-onboarding-tasks 2026-03-08 23:13:08 +05:30
ي
936dd14e0d Add consolidated onboarding SEO task health API and dashboard panel 2026-03-08 23:09:02 +05:30
ajaysi
39bc3e3008 Merge PR #397: Add typed request model for task status endpoint
- Add TaskStatusEnum to enumerate valid status values (pending, in_progress, completed, skipped, dismissed)
- Add TaskStatusUpdateRequest Pydantic model with validation
- Constrain completion_notes to max 4000 characters
- Automatically enforce schema validation and improve OpenAPI docs
- Update set_task_status endpoint to use typed request body
- Remove need for manual status validation (FastAPI handles it)
- Preserve dependencies normalization helper and all usages
- Preserve date validation and narrower exception handling from PR #396
- Keep proper feedback scoring using task.status from database
- Keep contextuality validation response fields intact
- Maintain all observability and error handling improvements
- Improve API robustness through type safety
2026-03-08 22:51:17 +05:30
ajaysi
92715661e3 Merge PR #396: Validate plan.date and add narrower exception handling
- Add date validation: validate plan.date is ISO format before computing yesterday
- Log clear warning (plan_id, user_id, plan_date, reason) if date parsing fails
- Replace silent 'except Exception: pass' with explicit SQLAlchemyError handling
- Log detailed warnings (plan_id, user_id, plan_date, yesterday_date, error details) on DB errors
- Keep failures non-fatal to indexing behavior (continue with today's indexing)
- Preserve dependencies normalization helper and its usage in yesterday payloads
- Preserve proper feedback scoring (uses task.status, handles all negative statuses)
- Keep contextuality validation response fields (quality_status, contextuality_validation)
- Improve observability while maintaining system robustness
2026-03-08 18:39:55 +05:30
ajaysi
0aaaf07900 Merge PR #395: Normalize dependencies in today workflow API payloads
- Add _normalize_dependencies() helper to handle all dependency type variations
- Handle None, list, JSON string, and invalid types with safe fallback to []
- Apply normalization to today and yesterday task payloads for consistency
- Ensure indexing pipeline receives normalized list dependencies
- Preserve task status feedback scoring logic (uses task.status, handles all negative cases)
- Keep contextuality validation and quality status response fields
- Improve data consistency across API and indexing surfaces
2026-03-08 18:31:48 +05:30
ajaysi
38444f4508 Merge PR #394: Derive task memory feedback_score from persisted task.status
- Use canonical persisted task.status (from DB) instead of incoming request parameter
- Implement explicit status-to-score mapping: completed→+1, skipped/dismissed/rejected→-1, other→0
- Normalize all negative outcomes uniformly for self-learning memory
- Ensure memory feedback aligns with backend status normalization rules
- Preserve contextuality_validation and quality_status response fields
- Keep failures non-fatal to API behavior with exception handling
- Improve code clarity with explicit conditional logic over ternary operators
2026-03-08 18:28:52 +05:30
ajaysi
f0f73eb003 Merge branch 'pr-385' 2026-03-07 12:02:50 +05:30
ajaysi
a00212ca4d refactor: Unify canonical task outcome statuses (completed, skipped) across workflow and memory services (Closes #384) 2026-03-07 12:00:04 +05:30
ي
62d5cf773e Add typed request model for today workflow task status updates 2026-03-06 21:45:48 +05:30
ي
e694e6172f Validate plan date before yesterday workflow indexing 2026-03-06 21:45:25 +05:30
ي
2403d92f9d Normalize today workflow task dependencies payload 2026-03-06 21:44:23 +05:30
ي
acecf2a3f4 Fix task outcome feedback scoring to use normalized status 2026-03-06 21:43:40 +05:30