Future Modules planning docs

This commit is contained in:
IGNY8 VPS (Salman)
2026-01-27 01:12:10 +00:00
parent 75deda304e
commit 2996c86893
13 changed files with 1756 additions and 2560 deletions

View File

@@ -0,0 +1,156 @@
# Content Types Writing Plan (Detailed)
**Goal:** Make IGNY8 capable of **writing content for multiple post types** (pages, products, services, company pages, taxonomy terms) using the **same Planner → Ideas → Tasks → Writer → Images** workflow as posts.
**Scope:** WordPress-only for current release. Shopify/custom support is future.
---
## 1) Core Principle
All content types follow the **same pipeline**:
```
Clusters → Ideas → Tasks → Content → Images → Review → Publish
```
Differences are handled by **content_type** and **content_structure** presets, plus targeted prompts and schema.
---
## 2) Content Types & Structures
### 2.1 Pages (Static)
- **content_type:** `page`
- **content_structure:** `landing_page`, `business_page`, `general`
- **Use cases:** About, Contact, FAQs, Pillar landing pages
### 2.2 Products (Custom Post Type)
- **content_type:** `product`
- **content_structure:** `product_page`
- **Use cases:** Individual products or product collections
### 2.3 Services (Custom Post Type)
- **content_type:** `service`
- **content_structure:** `service_page`
- **Use cases:** Service offering pages, location variants
### 2.4 Company Pages
- **content_type:** `page`
- **content_structure:** `business_page` or `general`
- **Use cases:** Team, Careers, Press, Mission
### 2.5 Taxonomy Terms (Landing Pages)
- **content_type:** `taxonomy`
- **content_structure:** `category_archive`, `tag_archive`, `attribute_archive`, `cluster_hub`
- **Use cases:** Category/tag/attribute landing pages with SEO content
---
## 3) Pipeline Mapping (Same as Posts)
### 3.1 Clusters → Ideas
- Each cluster generates ideas **per content type** based on intent.
- Example: one cluster may yield a page, a product page, and a service page idea.
### 3.2 Ideas → Tasks
- `Tasks` created with `content_type` and `content_structure`.
- Taxonomy terms can create tasks tied to `taxonomy_term`.
### 3.3 Tasks → Content
- Writer uses existing prompt system with type-specific prompts.
- Outputs HTML + meta title + meta description + structure.
### 3.4 Content → Images
- Uses existing image pipeline (featured + inarticle).
- Products/services can add attribute-based prompts.
---
## 4) WordPress Integration (Current Scope)
### 4.1 Post Types
- `post`, `page`, custom post types (`product`, `service`)
### 4.2 Taxonomies
- `category`, `post_tag`, `product_cat`, `product_tag`
- WooCommerce attributes (e.g., `pa_color`, `pa_size`)
---
## 5) Writing Rules per Content Type
### 5.1 Pages
- Clear CTA and conversion focus.
- Structured sections for trust + proof.
### 5.2 Products
- Feature/benefit sections, specs table, FAQs.
- Product schema + review snippets.
### 5.3 Services
- Service overview, process steps, outcomes, FAQs.
- Local SEO sections if location-based.
### 5.4 Company Pages
- Brand mission, values, history, team bios.
- FAQ and media/press block where relevant.
### 5.5 Taxonomy Landing Pages
- Intro + topical definition
- Key subtopics + internal links
- Related products/posts/services
- FAQ section
---
## 6) Cluster Alignment
- Each page is mapped to a **primary cluster**.
- Secondary clusters used for semantic coverage.
- Cluster keywords drive headings and metadata.
---
## 7) Required Enhancements
### 7.1 Ideas Generation
- Add type-specific idea templates:
- Product ideas (features/specs/benefits)
- Service ideas (process/outcomes)
- Company page ideas (mission/team/careers)
- Term landing ideas (taxonomy descriptions)
### 7.2 Writer Prompts
- Add prompt variants for each `content_structure`.
### 7.3 Publishing
- Map content types to WordPress post types correctly.
- Taxonomy landing pages publish to term descriptions or custom fields.
---
## 8) Rollout Phases
**Phase 1**
- Pages + services + company pages in Writer
- Task creation with new structures
**Phase 2**
- Products pages writing (WooCommerce)
- Attribute-based prompts
**Phase 3**
- Taxonomy landing pages
- Cluster hub pages
---
## 9) Success Criteria
- All content types generated via same pipeline.
- Cluster alignment across all page types.
- Improved SEO coverage beyond posts.
---
## 10) NonGoals (v1)
- Shopify/custom CMS adapters
- Autopublish without review

View File

@@ -0,0 +1,210 @@
## IGNY8 Socializer Module - Development Flow
---
### 1. Meta (Facebook) Setup
**One-time Config:**
- Create Business App at developers.facebook.com
- Add Facebook Login + Pages API products
- Set redirect URI: `https://igny8.com/auth/facebook/callback`
- Request permissions: `pages_manage_posts`, `pages_read_engagement`, `publish_to_groups`
- Submit for App Review (required for production)
**What to Build:**
| Component | Details |
|-----------|---------|
| Connect Button | Triggers OAuth, stores long-lived user token + page tokens |
| Account Picker | After auth, user selects which Pages/Groups to enable |
| Token Refresh Job | Cron to refresh tokens before 60-day expiry |
| Post Service | Accepts content + destination, calls `/{page-id}/feed` |
| Webhook Listener | Optional: receive post status updates |
**Posting Capabilities:**
- ✅ Pages (as Page)
- ⚠️ Groups (limited, user must be admin, needs approval)
- ❌ Personal profiles (blocked by Meta)
---
### 2. LinkedIn Setup
**One-time Config:**
- Create App at linkedin.com/developers
- Verify/associate with a Company Page
- Request products: "Share on LinkedIn", "Marketing Developer Platform" (for org posting)
- Set redirect URI: `https://igny8.com/auth/linkedin/callback`
- Permissions: `w_member_social`, `w_organization_social`, `r_liteprofile`, `r_organization_social`
**What to Build:**
| Component | Details |
|-----------|---------|
| Connect Button | OAuth flow, store access token + refresh token |
| Account Picker | User selects personal profile and/or Company Pages they admin |
| Token Refresh Job | Use refresh token before 60-day expiry |
| Post Service | Calls `/rest/posts` with author URN (person or organization) |
| URN Storage | Store `urn:li:person:{id}` and `urn:li:organization:{id}` per account |
**Posting Capabilities:**
- ✅ Personal profile
- ✅ Company Pages (user must be admin)
- ❌ Groups (no API)
---
### 3. Database Schema (additions)
```
SocialAccount
├── user (FK to IGNY8 user)
├── platform (facebook | linkedin)
├── platform_user_id
├── access_token (encrypted)
├── refresh_token (encrypted, LinkedIn only)
├── token_expires_at
├── scopes_granted
├── created_at / updated_at
SocialDestination
├── social_account (FK)
├── destination_type (page | group | profile | company)
├── destination_id (platform's ID)
├── destination_name
├── is_active
├── permissions_valid
SocialPost
├── site (FK to user's IGNY8 site)
├── content_source (FK to generated content)
├── destination (FK to SocialDestination)
├── platform_post_id
├── status (pending | posted | failed)
├── posted_at
├── error_message
```
---
### 4. Backend Services
| Service | Purpose |
|---------|---------|
| `SocialAuthService` | Handle OAuth callbacks, token exchange, storage |
| `TokenRefreshService` | Scheduled job to refresh expiring tokens |
| `DestinationSyncService` | After auth, fetch and store available pages/groups/companies |
| `SocialPublisherService` | Generic interface → platform-specific posting logic |
| `PostQueueWorker` | Process scheduled social posts from queue |
---
### 5. Frontend Components
| Component | Purpose |
|-----------|---------|
| Social Connections Page | List connected accounts, connect/disconnect buttons |
| Destination Selector | Per-site config: which destinations receive auto-posts |
| Post Preview Modal | Before posting: preview how content appears |
| Post History Table | Show status of all social posts per site |
| Settings per Destination | Customize format, hashtags, include link, image behavior |
---
### 6. Content-to-Social Flow
```
Content Published to WP
Check site's social destinations (active ones)
For each destination:
→ Format content (title, excerpt, link, image)
→ Apply destination-specific template
→ Queue SocialPost record
PostQueueWorker picks up
Call platform API → update status → log result
```
---
### 7. Post Formatting Options (per destination)
- Post template: `{title}\n\n{excerpt}\n\nRead more: {url}`
- Include featured image: yes/no
- Auto-hashtags from keywords
- Character limit handling (LinkedIn: 3000, Facebook: 63,206)
- Link preview behavior
---
### 8. Error Handling
- Token expired → mark account as needs reconnection, notify user
- Rate limited → exponential backoff retry
- Permission revoked → disable destination, notify user
- API error → log, retry up to 3x, then mark failed
---
---
## Rate Limits & User Limits
---
### Facebook/Meta
**No limit on number of users/pages/groups** connecting to your single app.
**But there are API call limits:**
| Limit Type | Details |
|------------|---------|
| App-level | 200 calls/user/hour baseline, scales with active users |
| Page posting | ~25 posts/page/day (soft limit, not documented hard cap) |
| Groups | Much stricter, ~5-10 posts/day/group to avoid spam flags |
| Burst protection | Too many calls in short time = temporary throttle |
**Scaling factor:** Your app's call limit increases automatically as more users connect (more users = higher pool).
---
### LinkedIn
**No limit on users/companies** connecting.
**API limits:**
| Limit Type | Details |
|------------|---------|
| Daily app limit | 100,000 calls/day (standard tier) |
| Per-user posting | ~100-150 posts/day/member (undocumented soft limit) |
| Company pages | ~100 posts/day/org |
| Rate limit | 100 requests/minute per user token |
**Marketing Developer Platform** (if approved): Higher limits for company page management.
---
### Practical Concerns
| Concern | Reality |
|---------|---------|
| 100 IGNY8 users, each with 2 pages | No problem at all |
| 1000 users, each with 5 pages | Still fine, monitor call volume |
| Spam behavior | Biggest risk - platforms will flag/ban aggressive posting |
---
### Recommendations for IGNY8
1. **Implement per-destination cooldowns** - minimum 4-6 hours between posts to same page/group
2. **Track API usage** - log calls, alert if approaching limits
3. **Queue with spreading** - don't burst 50 posts at once, spread across hours
4. **User-level limits** - cap posts/day per destination in your own system
---
No licensing fees or per-seat costs from Meta/LinkedIn for API access itself. Just respect the rate limits and avoid spammy patterns.

View File

@@ -0,0 +1,264 @@
# Linker Module Plan (Detailed)
**Scope:** Current implementation is **WordPress-only** for publishing/sync and content discovery. The design supports future Shopify and custom sites but is **not enabled** for them in v1.
**Status Today:** Linker module exists but is inactive by default and not fully protected by feature flags. See [docs/10-MODULES/LINKER.md](../../10-MODULES/LINKER.md).
---
## 1) Goal
Enable AI-driven internal and external linking for all content types that IGNY8 manages or syncs, while staying consistent with the existing pipeline and settings architecture.
**Primary objectives:**
- Increase topical authority via strategic internal linking (posts, pages, taxonomy pages, cluster pages, products, services).
- Improve UX and SEO through better anchor placement and link coverage.
- Maintain link hygiene with ongoing link health monitoring.
- Support outbound linking to authoritative sources with relevance scoring.
- Provide a pathway for **backlink discovery** (informational only in v1, no outreach automation).
---
## 2) Feature Set (Detailed)
### 2.1 Internal Linking (Core)
**What it does**
- Suggests internal links for content based on keyword clusters, topic similarity, and taxonomy alignment.
**Targets supported**
- Posts
- Pages
- Taxonomy archives (category/tag)
- Cluster pages (IGNY8-defined topical clusters)
- Product pages *(WordPress product CPT if present; Shopify later)*
- Service pages *(custom post types if configured)*
**Anchor strategies**
- Exact match
- Partial match
- Semantic match
- Brand-safe anchor constraints (from site-level settings)
**Controls**
- Max links per content item
- Per-section link density caps
- Avoid repeated anchors
- Exclude URLs or content statuses (draft, private)
---
### 2.2 External Linking (Authority Sources)
**What it does**
- Recommends outbound links to reputable domains relevant to content topic.
**Constraints**
- Domain whitelist/blacklist
- Authority threshold (DR/DA proxy)
- No competitor domains (configurable)
- Link type: dofollow/nofollow
---
### 2.3 Backlink Discovery (Read-only in v1)
**What it does**
- Lists relevant external sites that are topically related for future outreach.
**Notes**
- No automated outreach in v1.
- Future: integrate with email/outreach tools.
---
### 2.4 Link Health & Monitoring
**What it does**
- Detects broken internal/external links.
- Tracks link status and changes.
**Actions**
- Flag broken links
- Suggest replacements
- Quick-fix internal links
---
### 2.5 Automation & Pipeline Integration
**What it does**
- Can run after Writer stage to enrich IGNY8-generated content.
- Can run on synced WordPress content.
**Modes**
- Manual: per content item
- Batch: selected items
- Automation stage: optional in automation pipeline
---
## 3) App-Consistent Architecture
### 3.1 Backend Modules (Aligned with Current Structure)
- Existing: `backend/igny8_core/modules/linker/`
- Existing: `backend/igny8_core/business/content/services/content_pipeline_service.py`
**Add / Extend**
- `business/linker/` (services, scoring, health checks)
- `modules/linker/models.py` (link suggestions, health checks)
- `modules/linker/serializers.py`
- `modules/linker/views.py` (extend API)
---
### 3.2 Data Models (Proposed)
**LinkSuggestion**
- `account`, `site`, `content`
- `anchor_text`, `anchor_strategy`
- `target_url`, `target_content_id` (nullable for external)
- `target_type` (internal/external/taxonomy/cluster/product/service)
- `confidence_score`
- `status` (suggested/applied/rejected)
- `metadata` (keyword match, similarity score)
**LinkHealthStatus**
- `site`, `url`, `status_code`, `last_checked_at`, `is_broken`
**ExternalSourceCandidate**
- `topic`, `domain`, `url`, `authority_score`, `relevance_score`
---
### 3.3 API Endpoints (Aligned with Existing Style)
**Existing**
- `POST /api/v1/linker/process/`
- `POST /api/v1/linker/batch_process/`
**Add**
- `GET /api/v1/linker/suggestions/?content_id=`
- `POST /api/v1/linker/apply/`
- `POST /api/v1/linker/reject/`
- `POST /api/v1/linker/health/scan/`
- `GET /api/v1/linker/health/status/?site_id=`
- `GET /api/v1/linker/external-sources/?content_id=`
---
### 3.4 Frontend Pages (Consistent with Current UI)
**Pages**
- `/linker/content` (list content + status + batch actions)
- `/linker/content/:id` (link suggestions + apply)
**Components**
- Suggestions table
- Inline preview with anchor highlights
- Link health panel
- External sources panel
---
## 4) WordPress-Only Scope (Current Release)
### 4.1 WordPress Content Types
- Posts
- Pages
- Categories / Tags (taxonomy archives)
- Custom post types (products/services) if configured in integration
### 4.2 WordPress Sync Integration
- Leverage existing sync flows to ingest WordPress content and taxonomies.
- Maintain `wordpress_id` mapping for internal link targeting.
---
## 5) Linking Logic (High-Level)
### 5.1 Internal Link Discovery
- Cluster overlap
- Keyword match to title + headers
- Taxonomy match (category/tag)
- Content type compatibility
### 5.2 External Link Discovery
- Use curated sources or internal dataset
- Score by relevance + authority
### 5.3 Anchor Placement
- Avoid headings and existing links
- Prefer first 60% of content
- Cap per section
---
## 6) Settings & Controls (Unified Settings)
**Site Settings → Automation tab**
- Enable Linker module
- Max internal links per content
- Max external links per content
- Target link density
- Excluded URLs / domains
- Anchor text rules
---
## 7) Notifications
- “Link suggestions ready”
- “Links applied”
- “Broken links detected”
---
## 8) Rollout Phases
**Phase 1 (MVP)**
- Internal links + anchor suggestions
- Manual apply
- Content-level preview
**Phase 2**
- External link suggestions
- Batch processing
**Phase 3**
- Link health scanning
- Automation stage support
**Phase 4**
- Backlink discovery (read-only)
---
## 9) Non-Goals (v1)
- Automated outreach
- Paid backlink acquisition
- Shopify support (future)
- Custom CMS adapters (future)
---
## 10) Success Criteria
- Increased internal link coverage per content piece
- Reduced orphaned content
- Improved ranking on linked clusters
- Minimal false-positive link placements
---
## 11) Dependencies
- Content metadata quality (keywords, clusters, taxonomies)
- WordPress integration sync health
- Automation settings availability
---
## 12) Risks & Mitigations
- **Risk:** Over-linking → **Mitigation:** enforce density caps and editor review.
- **Risk:** Bad anchors → **Mitigation:** anchor validation + manual approval.
- **Risk:** Broken external links → **Mitigation:** link health checks + replacements.
---
## 13) Future Extensions (PostWordPress)
- Shopify product catalogs
- Custom CMS content ingestion
- Cross-domain linking for multi-brand portfolios
- Outreach workflows for backlink acquisition

View File

@@ -0,0 +1,235 @@
# Optimizer Module Plan (Detailed)
**Scope:** Optimizer focuses on **rewriting/optimizing existing content** across posts, pages, products, services, company pages, and taxonomy archives. Current release scope is **WordPress-only** (publish/sync + content discovery). Shopify/custom support is future.
**Status Today:** Optimizer module exists but is inactive by default and partially implemented. See [docs/10-MODULES/OPTIMIZER.md](../../10-MODULES/OPTIMIZER.md).
---
## 1) Goal
Upgrade existing content to SEOstrong, intentaligned pages by:
- Mapping content to **semantic/topic clusters**.
- Aligning page intent with cluster keyword targets.
- Rewriting structure + content to match current search intent.
- Adding schema, metadata, and onpage SEO improvements.
---
## 2) Feature Set (Detailed)
### 2.1 Content Types Supported (WordPress v1)
- Posts (blog/article)
- Pages (static)
- Products (custom post type, if configured)
- Services (custom post type, if configured)
- Company pages (about/team/careers/FAQ/press)
- Taxonomy archives (category/tag)
- Cluster pages (IGNY8 cluster views)
---
### 2.2 ClusterAligned Optimization
**What it does**
- Associates each content item with a **primary cluster** + secondary clusters.
- Uses cluster keyword list as optimization targets.
**Outputs**
- Updated content aligned to the best matching cluster intent.
- Keyword coverage improvements with semantic variants.
---
### 2.3 IntentAligned Rewrite Engine
**What it does**
- Rewrites content to match user intent (informational, commercial, transactional).
- Adjusts structure and sections to meet SERP expectations.
**Capabilities**
- Expand thin pages into full SEO pages.
- Compress overly long pages to reduce fluff.
- Add missing sections and reorder content flow.
---
### 2.4 SEORich Output (Structure + Meta + Schema)
**What it does**
- Generates SEOoptimized headings, internal structure, and metadata.
- Adds schema markup when applicable.
**Includes**
- Meta title + meta description refresh
- H1/H2/H3 structure alignment
- Internal/external link placeholders (Linker integration)
- Image alt text improvements
- Schema JSONLD (Article, Product, FAQ, Organization, Breadcrumb, Service)
---
### 2.5 PageLevel Optimization Scores
**What it does**
- Scores before/after content quality using current Optimizer scoring model.
- Tracks improvements by cluster alignment + keyword coverage.
---
## 3) AppConsistent Architecture
### 3.1 Backend Modules (Aligned with Current Structure)
- Existing: `backend/igny8_core/modules/optimizer/`
- Existing: `backend/igny8_core/business/optimization/`
**Add / Extend**
- `business/optimization/cluster_mapping.py` (cluster assignment & keyword targets)
- `modules/optimizer/models.py` (extend OptimizationTask)
- `modules/optimizer/serializers.py` (add cluster mapping + schema)
- `modules/optimizer/views.py` (extend API)
---
### 3.2 Data Models (Proposed Extensions)
**OptimizationTask** (extend)
- `primary_cluster_id`
- `secondary_cluster_ids` (JSON)
- `keyword_targets` (JSON)
- `schema_type` (article/product/service/faq/org)
- `schema_json` (JSON)
- `metadata_before` (JSON)
- `metadata_after` (JSON)
- `structure_changes` (JSON)
---
### 3.3 API Endpoints (Aligned with Existing Style)
**Existing**
- `POST /api/v1/optimizer/analyze/`
- `POST /api/v1/optimizer/optimize/`
- `POST /api/v1/optimizer/batch_optimize/`
**Add**
- `POST /api/v1/optimizer/assign_cluster/`
- `GET /api/v1/optimizer/cluster_suggestions/?content_id=`
- `POST /api/v1/optimizer/preview/` (structure + metadata + schema preview)
- `POST /api/v1/optimizer/apply/` (persist optimized version)
---
### 3.4 Frontend Pages (Consistent with Current UI)
**Pages**
- `/optimizer/content` (content list + status)
- `/optimizer/preview/:id` (analysis + diff + schema preview)
**Components**
- Cluster mapping panel
- Keyword target editor
- Structure diff viewer
- Metadata + schema preview
---
## 4) WordPressOnly Scope (Current Release)
### 4.1 WordPress Content Coverage
- Posts and Pages
- Taxonomy archives (category/tag)
- Custom post types (products/services if configured)
### 4.2 WordPress Sync Integration
- Use existing sync pipelines to pull WordPress content.
- Maintain `wordpress_id` mapping for optimized updates.
---
## 5) Optimization Logic (HighLevel)
### 5.1 Cluster Matching
- Analyze content title, headings, and keyword density.
- Match to existing cluster keyword sets.
- Provide suggestions if confidence < threshold.
### 5.2 Content Rewrite
- Rebuild structure to match intent + cluster focus.
- Inject missing sections (FAQs, comparisons, benefits, use cases).
- Normalize tone with existing Writer prompt settings.
### 5.3 SEO Enhancements
- Meta title/description refresh
- Heading structure refinement
- Internal link opportunities (handoff to Linker)
- Schema generation based on content type
---
## 6) Settings & Controls (Unified Settings)
**Site Settings → Automation tab**
- Enable Optimizer module
- Default schema type per content type
- Keyword density targets
- Content length guidelines
- Allow autoapply vs manual review
---
## 7) Notifications
- “Optimization analysis ready”
- “Optimization applied”
- “Schema generated”
---
## 8) Rollout Phases
**Phase 1 (MVP)**
- Analyze + optimize existing posts/pages
- Cluster mapping suggestions
- Manual apply
**Phase 2**
- Products/services/company pages support
- Schema + metadata output
**Phase 3**
- Taxonomy archive optimization
- Batch optimization
**Phase 4**
- Full automation stage integration
---
## 9) NonGoals (v1)
- Shopify/custom CMS support
- Automated schema validation tools
- Automatic publishing without review
---
## 10) Success Criteria
- Increased keyword coverage vs cluster targets
- Higher content quality scores (before/after)
- Improved SERP performance for optimized pages
---
## 11) Dependencies
- Cluster data quality in Planner
- WordPress sync reliability
- Unified settings availability
---
## 12) Risks & Mitigations
- **Risk:** Overoptimization → **Mitigation:** density caps + manual review.
- **Risk:** Wrong cluster mapping → **Mitigation:** suggestion + override flow.
- **Risk:** Schema mismatch → **Mitigation:** type validation + preview.
---
## 13) Future Extensions (PostWordPress)
- Shopify product catalogs
- Custom CMS adapters
- Automated schema validation pipeline
- SERPbased optimization suggestions

View File

@@ -0,0 +1,187 @@
# Socializer + Video Content Creator Plan (Detailed)
**Scope:** Q3Q4 2026 modules from https://igny8.com/upcoming. Integrations target top social platforms. Content sources are IGNY8generated and optimized (new or rewritten), linked back to the original page/post/product/service.
**Goal:** Automate multiplatform social publishing and video creation for every IGNY8 content item, using consistent app structure (Ideas → Tasks → Content → Images → Publish + Automation + Calendar).
---
## 1) Socializer Module (MultiPlatform Social Publishing)
### 1.1 Core Capabilities
- Autogenerate platformspecific social posts from any IGNY8 content item.
- Schedule and autopublish to connected social accounts.
- Maintain backlinks to the original page/post/product/service.
- Provide a unified social calendar integrated with content calendar.
### 1.2 Content Sources (What can be socialized)
- Posts (blog/article)
- Pages (static)
- Products (WooCommerce)
- Services (custom post type)
- Company pages
- Taxonomy landing pages
**Rule:** Any IGNY8 content item (new or optimized) can generate social content.
### 1.3 Platform Targets (Phase 1)
- LinkedIn
- Twitter/X
- Facebook
- Instagram (posts + reels)
- TikTok (short video)
### 1.4 PlatformSpecific Output
- **Text posts:** title + summary + CTA + link
- **Captions:** tone/length variations per platform
- **Images:** resized and cropped per platform specs
- **Short videos / reels:** generated from content (via Video module)
### 1.5 Social Post Types
- **Announcement:** “New article/product/service” with link
- **Highlights:** key takeaways + CTA
- **Quote cards:** single insight with branded template
- **FAQ snippets:** for services or product categories
- **Carousel (future):** multipanel posts
### 1.6 Scheduling & Automation
- Autopublish on content approval or scheduled publish.
- Schedule rules: time windows, frequency caps, platformspecific limits.
- Sync with Publisher scheduling (same calendar).
---
## 2) Video Content Creator (AI Video Generation & Publishing)
### 2.1 Core Capabilities
- Convert articles/pages into video scripts.
- Generate shortform videos (Reels/Shorts/TikTok).
- Generate longform YouTube videos with chapters.
- Autopublish to video platforms.
### 2.2 Video Types
- **Short:** 1560s highlights
- **Medium:** 60180s summaries
- **Long:** 512 min explainer (YouTube)
### 2.3 Video Outputs
- Script + captions
- AI voiceover or useruploaded voice
- Visuals: stock + AI images + brand templates
- Titles, descriptions, tags (SEO optimized)
### 2.4 Publishing Targets (Phase 1)
- YouTube
- TikTok
- Instagram Reels
- YouTube Shorts
---
## 3) Integration with IGNY8 Content Workflow
### 3.1 Trigger Points
- On **content approval**
- On **scheduled publish**
- On **optimizer rewrite completion**
### 3.2 LinkBack Rule
Every social/video post must link to the original page/post/product on the site.
### 3.3 Metadata Alignment
- Use IGNY8 meta title + description as base.
- Add platformspecific variations.
---
## 4) AppConsistent Architecture
### 4.1 Backend Modules (Proposed)
- `backend/igny8_core/modules/socializer/`
- `backend/igny8_core/business/social/`
- `backend/igny8_core/modules/video/`
- `backend/igny8_core/business/video/`
### 4.2 Data Models (Proposed)
**SocialAccount**
- `account`, `site`, `platform`, `auth_tokens`, `status`
**SocialPost**
- `content_id`, `platform`, `post_type`, `caption`, `media_url`, `status`, `scheduled_at`, `published_at`, `external_id`
**VideoProject**
- `content_id`, `type`, `script`, `voice`, `status`, `video_url`, `published_at`
**EngagementMetric**
- `platform`, `post_id`, `views`, `likes`, `comments`, `shares`
---
## 5) API Endpoints (Proposed)
### Socializer
- `POST /api/v1/social/accounts/connect/`
- `GET /api/v1/social/accounts/`
- `POST /api/v1/social/posts/generate/`
- `POST /api/v1/social/posts/schedule/`
- `POST /api/v1/social/posts/publish/`
- `GET /api/v1/social/posts/status/`
### Video Creator
- `POST /api/v1/video/projects/generate/`
- `POST /api/v1/video/projects/publish/`
- `GET /api/v1/video/projects/status/`
---
## 6) Frontend Pages
### Socializer
- `/social/accounts` connect platforms
- `/social/calendar` unified social calendar
- `/social/posts` list + status + actions
### Video Creator
- `/video/projects` list + status
- `/video/preview/:id` script + preview + publish
---
## 7) Scheduling & Automation Rules
- Respect perplatform rate limits.
- Enforce daily/weekly caps per site.
- Timeslot scheduling aligned with Publisher rules.
---
## 8) Rollout Phases
**Phase 1**
- Social accounts + post generation
- Manual scheduling + publish
**Phase 2**
- Autopublish on content approval
- Calendar integration
**Phase 3**
- Video creator (shortform)
- Autopublish to video platforms
**Phase 4**
- Longform video creation + analytics
---
## 9) Success Criteria
- Every IGNY8 content item can generate social + video assets.
- Social posts consistently link back to the original page.
- Improved traffic attribution from social channels.
---
## 10) NonGoals (v1)
- Social ad automation
- Outreach automation
- Shopify/custom CMS publishing

View File

@@ -0,0 +1,199 @@
# Taxonomy & Term Content Plan (Detailed)
**Scope:** WordPress-only for current release. Shopify/custom sites remain future.
**Goal:** Make taxonomy terms and archives firstclass content pages (SEO landing pages) that are generated, optimized, and mapped to clusters using the same Planner → Writer → Optimizer pipeline as posts.
---
## 1) Current App Findings (Relevant Parts)
### 1.1 Content Models Already Support Taxonomy
- `Tasks` supports `content_type='taxonomy'` and `content_structure` values including `category_archive`, `tag_archive`, `attribute_archive`, `cluster_hub`. See [backend/igny8_core/business/content/models.py](../../backend/igny8_core/business/content/models.py).
- `Content` supports `content_type='taxonomy'` and taxonomyspecific structures. See [backend/igny8_core/business/content/models.py](../../backend/igny8_core/business/content/models.py).
- `ContentTaxonomy` exists with `external_taxonomy`, `external_id`, `description`, and `metadata` for sync. See [backend/igny8_core/business/content/models.py](../../backend/igny8_core/business/content/models.py).
### 1.2 WordPress Client Already Knows Taxonomies
- WordPress REST: `get_categories`, `get_tags`, `create_category`, `create_tag`. See [backend/igny8_core/utils/wordpress.py](../../backend/igny8_core/utils/wordpress.py).
- WooCommerce: product categories + attributes and terms are fetchable. See [backend/igny8_core/utils/wordpress.py](../../backend/igny8_core/utils/wordpress.py).
### 1.3 Sync Service Partially Implemented (Then Removed)
- Taxonomy sync functions exist but are currently **skipped** with a “legacy removed” note. See [backend/igny8_core/business/integration/services/content_sync_service.py](../../backend/igny8_core/business/integration/services/content_sync_service.py).
- Posts sync assigns placeholder categories/tags by ID; product sync stores categories/tags/attributes in metadata only.
**Conclusion:** The database and data model already allow taxonomy content, but sync + content generation for terms is incomplete.
---
## 2) Target Outcome
### 2.1 FirstClass Term Landing Pages
Every taxonomy term becomes a **rich SEO landing page** rather than a simple list of posts.
**Examples**
- Category: “Electric Toothbrushes” → full landing page with intro, buyer guidance, top items, FAQs.
- Tag: “Remote Work” → topical overview + curated posts.
- Product Attribute: “Material: Stainless Steel” → attribute landing page.
### 2.2 ClusterAligned Structure
- Each term is mapped to **primary cluster** + optional secondary clusters.
- Each term page follows a **clusteraligned structure** (H2/H3 outline, keyword coverage, semantic variants).
### 2.3 Same Pipeline as Posts
Planner → Writer → Optimizer should work for taxonomy pages the same way it works for posts.
---
## 3) Functional Scope
### 3.1 Content Writer for All Terms (Default + Custom Taxonomies)
- WordPress default: category, post_tag
- WooCommerce: product_cat, product_tag
- Product attributes (e.g., `pa_color`, `pa_size`)
- Custom taxonomies (configurable list from site integration)
### 3.2 Products Pages Writing
- Use existing product sync data + clusters to generate product landing pages and individual product enhancements.
### 3.3 Services / Company Pages Writing
- Use existing Writer structures (`service_page`, `business_page`, `general`) and cluster mapping.
### 3.4 Cluster Hub Pages
- Create **cluster landing pages** that aggregate all related terms + posts + products.
---
## 4) Architecture Plan (Aligned with App)
### 4.1 Taxonomy Sync (WordPress)
**Add/Restore taxonomy sync** in `ContentSyncService`:
- Fetch categories & tags via `WordPressClient`.
- Fetch WooCommerce product categories + attributes + terms.
- Sync to `ContentTaxonomy` with correct `external_taxonomy` values.
**Why:** term metadata is required for mapping, writing, and linking.
---
### 4.2 TermtoCluster Mapping
**New service:** `business/optimization/cluster_mapping.py` (shared with Optimizer).
- Map term name/description to clusters.
- Persist mapping in `Content.cluster` and/or a `ContentClusterMap`.
---
### 4.3 Term Content Generation (Writer)
**Flow (mirrors posts):**
1. Create `ContentIdea` from term + cluster data.
2. Create `Tasks` with `content_type='taxonomy'` and appropriate `content_structure`.
3. Use Writer to generate HTML content, meta, and structure.
4. Save as `Content` linked to `ContentTaxonomy`.
**Suggested structures:**
- Category → `category_archive`
- Tag → `tag_archive`
- Attribute → `attribute_archive`
- Cluster landing → `cluster_hub`
---
### 4.4 Publishing Back to WordPress
**WordPress update targets:**
- Write generated content to **term description** for taxonomy pages.
- Store structured content in term meta (future: ACF or custom IGNY8 plugin fields).
**Notes:**
- WordPress term descriptions accept HTML and can be displayed by themes.
---
### 4.5 Optimizer Alignment
Use Optimizer to:
- Rewrite existing term descriptions.
- Align term pages with cluster keyword targets.
- Inject schema and metadata updates.
---
## 5) API & UI Plan
### 5.1 API Endpoints (Proposed)
- `GET /api/v1/taxonomy/terms/?site_id=`
- `POST /api/v1/taxonomy/terms/sync/`
- `POST /api/v1/taxonomy/terms/create_tasks/`
- `POST /api/v1/taxonomy/terms/optimize/`
- `POST /api/v1/taxonomy/terms/publish/`
### 5.2 UI Pages
- **Taxonomy Overview**: list terms, cluster mapping status, content status.
- **Term Content Editor**: preview + rewrite + publish.
- **Cluster Hub Manager**: cluster landing pages and crosslinks.
---
## 6) Keyword + Cluster Strategy
### 6.1 TermCluster Assignment
- Autoassign cluster based on keyword overlap + semantic similarity.
- Manual override in UI.
### 6.2 Term Keyword Targets
- Use cluster keywords as primary/secondary targets.
- Add termspecific modifiers (e.g., “best”, “vs”, “near me”).
---
## 7) Term Landing Page Structure (SEORich)
**Default sections (taxonomy pages):**
1. Intro + term definition
2. Key subtopics (H2/H3)
3. Top related posts/products/services
4. FAQs
5. Internal links to related clusters
**Schema:**
- `CollectionPage` or `WebPage`
- `FAQPage` if FAQs present
---
## 8) Rollout Phases
**Phase 1**
- Taxonomy sync (categories + tags)
- Term mapping to clusters
- Writer tasks for term pages
**Phase 2**
- WooCommerce product categories + attributes
- Term optimization with Optimizer
**Phase 3**
- Cluster hub pages
- Full taxonomy publish flow
**Phase 4**
- Custom taxonomies configuration
- Crosssite cluster navigation
---
## 9) Success Criteria
- All taxonomy terms have generated content and cluster mapping.
- Term landing pages outperform plain archive pages.
- Consistent internal linking between clusters, terms, and posts.
---
## 10) Risks & Mitigations
- **Risk:** Themes not showing term descriptions → **Mitigation:** IGNY8 plugin blocks or template guidance.
- **Risk:** Incorrect cluster mapping → **Mitigation:** manual override + suggestions.
- **Risk:** Overoptimization → **Mitigation:** density caps + manual review.
---
## 11) NonGoals (v1)
- Shopify taxonomy sync
- Custom CMS adapters
- Automated publishing without review