@lynxflow/seo-engine 2.4.0 → 2.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -4,7 +4,7 @@ High-Performance Universal Programmatic SEO & Structured Data Engine for Modern
4
4
 
5
5
  [![TypeScript](https://img.shields.io/badge/TypeScript-Ready-blue.svg)](https://www.typescriptlang.org/)
6
6
  [![License](https://img.shields.io/badge/License-Proprietary-green.svg)](LICENSE)
7
- [![Version](https://img.shields.io/badge/Version-2.4.0-orange.svg)](https://www.npmjs.com/package/@lynxflow/seo-engine)
7
+ [![Version](https://img.shields.io/badge/Version-2.6.0-orange.svg)](https://www.npmjs.com/package/@lynxflow/seo-engine)
8
8
 
9
9
  ---
10
10
 
@@ -0,0 +1,34 @@
1
+ /**
2
+ * 🥊 Competitor Gap Blueprint & "Beat Them" Content Architect
3
+ * Ported & optimized from Python competitor_gap_analyzer.py.
4
+ * Identifies thin sections, unsupported claims, missing perspectives, and outdated information in competitor content.
5
+ */
6
+ export type ContentGapType = "thin_section" | "unsupported_claim" | "missing_perspective" | "outdated_info" | "structural_gap";
7
+ export interface CompetitorContentGap {
8
+ gapType: ContentGapType;
9
+ description: string;
10
+ locationHeading: string;
11
+ competitorUrl: string;
12
+ priority: "high" | "medium" | "low";
13
+ counterOpportunity: string;
14
+ }
15
+ export interface CompetitorArticleInput {
16
+ url: string;
17
+ title: string;
18
+ wordCount: number;
19
+ headings: string[];
20
+ contentSnippet?: string;
21
+ }
22
+ export interface BeatThemBlueprint {
23
+ mustFillGaps: CompetitorContentGap[];
24
+ expectedCommonHeadings: string[];
25
+ differentiationAngles: string[];
26
+ outdatedToUpdate: string[];
27
+ winningOutlineRecommendation: string[];
28
+ }
29
+ export declare class CompetitorGapBlueprintEngine {
30
+ /**
31
+ * Analyzes competitors and builds an actionable "Beat Them" blueprint.
32
+ */
33
+ static buildBlueprint(targetTopic: string, userWordCount: number, competitors: CompetitorArticleInput[]): BeatThemBlueprint;
34
+ }
@@ -0,0 +1,40 @@
1
+ /**
2
+ * 💎 Multi-Dimensional Content Quality Scorer
3
+ * Ported & optimized from Python content_scorer.py (31 KB).
4
+ * Evaluates 5 dimensions: Humanity/Voice (30%), Specificity (25%), Structure Balance (20%), SEO Compliance (15%), Readability (10%).
5
+ * Composite quality threshold: >= 70 to pass.
6
+ */
7
+ export interface DimensionScoreBreakdown {
8
+ score: number;
9
+ weight: number;
10
+ weightedScore: number;
11
+ strengths: string[];
12
+ issues: string[];
13
+ }
14
+ export interface ContentQualityReport {
15
+ compositeScore: number;
16
+ passesQualityThreshold: boolean;
17
+ grade: "A+" | "A" | "B" | "C" | "F";
18
+ dimensions: {
19
+ humanity: DimensionScoreBreakdown;
20
+ specificity: DimensionScoreBreakdown;
21
+ structureBalance: DimensionScoreBreakdown;
22
+ seoCompliance: DimensionScoreBreakdown;
23
+ readability: DimensionScoreBreakdown;
24
+ };
25
+ proseToListRatio: number;
26
+ topPriorityFixes: string[];
27
+ }
28
+ export declare class ContentQualityScorer {
29
+ private static readonly VAGUE_WORDS;
30
+ private static readonly SPECIFICITY_DATA_PATTERNS;
31
+ private static readonly CONVERSATIONAL_DEVICES;
32
+ /**
33
+ * Scores content across all 5 dimensions.
34
+ */
35
+ static scoreContent(content: string, metadata?: {
36
+ metaTitle?: string;
37
+ primaryKeyword?: string;
38
+ }): ContentQualityReport;
39
+ private static emptyReport;
40
+ }
@@ -0,0 +1,50 @@
1
+ /**
2
+ * 🪝 Engagement Hook & Viral Reading Rhythm Analyzer
3
+ * Ported & optimized from Python engagement_analyzer.py.
4
+ * Evaluates the 4 viral reading criteria: Hook quality, sentence length variety, contextual CTA distribution, and paragraph breathability.
5
+ */
6
+ export interface HookEvaluation {
7
+ openingSentence: string;
8
+ isStrongHook: boolean;
9
+ hookType: "question" | "statistic" | "quote" | "thought_experiment" | "concrete_story" | "generic_bad_opener";
10
+ feedback: string;
11
+ suggestedHookUpgrade?: string;
12
+ }
13
+ export interface RhythmEvaluation {
14
+ sentenceCount: number;
15
+ averageWords: number;
16
+ standardDeviation: number;
17
+ hasVariedRhythm: boolean;
18
+ score: number;
19
+ }
20
+ export interface CtaDistributionEvaluation {
21
+ totalCtasDetected: number;
22
+ isDistributedAcrossArticle: boolean;
23
+ hasAboveTheFoldCta: boolean;
24
+ hasMidArticleCta: boolean;
25
+ hasBottomCta: boolean;
26
+ }
27
+ export interface ParagraphDensityEvaluation {
28
+ totalParagraphs: number;
29
+ longParagraphsCount: number;
30
+ isMobileBreathable: boolean;
31
+ }
32
+ export interface ArticleEngagementReport {
33
+ engagementScore: number;
34
+ allPassed: boolean;
35
+ passedCount: number;
36
+ hook: HookEvaluation;
37
+ rhythm: RhythmEvaluation;
38
+ ctas: CtaDistributionEvaluation;
39
+ paragraphs: ParagraphDensityEvaluation;
40
+ actionableFixes: string[];
41
+ }
42
+ export declare class EngagementHookAnalyzer {
43
+ private static readonly GENERIC_BAD_OPENERS;
44
+ private static readonly GOOD_HOOK_STARTERS;
45
+ private static readonly CTA_REGEX;
46
+ /**
47
+ * Analyzes an article's engagement mechanics.
48
+ */
49
+ static analyze(content: string): ArticleEngagementReport;
50
+ }
package/dist/index.d.ts CHANGED
@@ -122,6 +122,12 @@ import { ContextTemplatesGenerator } from "./context-templates-generator";
122
122
  import { SearchIntentClassifier } from "./search-intent-classifier";
123
123
  import { SeoOpportunityPrioritizer } from "./seo-opportunity-prioritizer";
124
124
  import { TrustSignalsExtractor } from "./trust-signals-extractor";
125
+ import { CompetitorGapBlueprintEngine } from "./competitor-gap-blueprint";
126
+ import { EngagementHookAnalyzer } from "./engagement-hook-analyzer";
127
+ import { KeywordDensityGuard } from "./keyword-density-guard";
128
+ import { ContentQualityScorer } from "./content-quality-scorer";
129
+ import { LandingCroChecker } from "./landing-cro-checker";
130
+ import { SocialCommunityInsightsAggregator } from "./social-community-insights";
125
131
  export declare function createLynxSeoEngine(config: EngineConfig): LynxSeoEngine;
126
132
  export declare const LynxSeo: {
127
133
  createEngine: typeof createLynxSeoEngine;
@@ -141,6 +147,12 @@ export declare const LynxSeo: {
141
147
  searchIntent: typeof SearchIntentClassifier;
142
148
  opportunityPrioritizer: typeof SeoOpportunityPrioritizer;
143
149
  trustSignals: typeof TrustSignalsExtractor;
150
+ competitorGap: typeof CompetitorGapBlueprintEngine;
151
+ engagementHook: typeof EngagementHookAnalyzer;
152
+ keywordDensity: typeof KeywordDensityGuard;
153
+ contentQuality: typeof ContentQualityScorer;
154
+ landingCroChecker: typeof LandingCroChecker;
155
+ socialInsights: typeof SocialCommunityInsightsAggregator;
144
156
  inspectMeta: typeof SiteAuditor.inspectMeta;
145
157
  crawlDomain: typeof DeepCrawlerAuditor.crawlAndAuditDomain;
146
158
  inspectHtmlSnapshot: typeof DeepCrawlerAuditor.inspectHtmlSnapshot;
@@ -182,6 +194,12 @@ export declare const LynxSeo: {
182
194
  marketingSkills: typeof MarketingSkillsEngine;
183
195
  regenerationTracker: typeof PageRegenerationTracker;
184
196
  };
197
+ export * from "./content-quality-scorer";
198
+ export * from "./landing-cro-checker";
199
+ export * from "./social-community-insights";
200
+ export * from "./competitor-gap-blueprint";
201
+ export * from "./engagement-hook-analyzer";
202
+ export * from "./keyword-density-guard";
185
203
  export * from "./search-intent-classifier";
186
204
  export * from "./seo-opportunity-prioritizer";
187
205
  export * from "./trust-signals-extractor";