Add a new podcast segment type to the Data Over Dogma segment detection and verification system. Use when the user asks to add a new segment, create a segment, or add a segment type like "Getting Angelic" or "Getting Demonic".
This skill guides you through adding a new segment type to the Data Over Dogma podcast segment detection and verification system.
Segments are recurring named sections in Data Over Dogma podcast episodes, such as:
Each segment has:
When the user asks to add a segment, follow these four steps:
File: src/config/segment-patterns.ts
Add the new segment type to the union (alphabetically or logically grouped):
export type SegmentType =
| "intro"
| "chapter-and-verse"
// ... existing segments ...
| "your-new-segment" // Add here (kebab-case)
| "advertisement"
| "main-content"
| "outro";
Naming convention: Use kebab-case (lowercase with hyphens)
File: src/config/segment-patterns.ts
Add a human-readable label:
export const SEGMENT_LABELS: Record<SegmentType, string> = {
intro: "Intro",
// ... existing labels ...
"your-new-segment": "Your New Segment", // Title Case
// ... rest of labels ...
};
Naming convention: Title Case, can include punctuation (e.g., "What Does That Mean?")
File: src/config/segment-patterns.ts
Assign a color using Tailwind CSS color values:
export const SEGMENT_COLORS: Record<SegmentType, string> = {
intro: "#6366f1", // indigo
// ... existing colors ...
"your-new-segment": "#10b981", // emerald-500
// ... rest of colors ...
};
Color guidelines:
Common Tailwind colors:
#ef4444 - red-500#f59e0b - amber-500#10b981 - emerald-500#06b6d4 - cyan-500#8b5cf6 - violet-500#ec4899 - pink-500#fbbf24 - amber-400#b91c1c - red-700File: src/config/segment-patterns.ts
Add regex patterns to automatically detect when this segment starts in transcripts:
export const SEGMENT_PATTERNS: Record<
Exclude<SegmentType, "intro" | "main-content">,
RegExp[]
> = {
// ... existing patterns ...
"your-new-segment": [
/your new segment/i,
/welcome to.*your new segment/i,
/let'?s do.*your new segment/i,
],
// ... rest of patterns ...
};
Pattern guidelines:
/i flag)Common intro patterns:
/segment name/i - Direct mention/welcome to.*segment name/i - Standard welcome/let'?s do.*segment name/i - Action-based intro/coming up.*segment name/i - Teaser/segment.*segment name/i - Meta referenceRun type checking to ensure no errors:
bun run typecheck
The segment verification UI loads metadata from the server, so restart it:
# Stop current server (Ctrl+C)
bun run src/scripts/tools-server.ts
When you add a segment, it becomes available in:
After adding a segment:
// 1. SegmentType
export type SegmentType =
| 'by-the-numbers'
| 'getting-angelic' // Added here
| 'getting-demonic'
| 'advertisement'
// 2. SEGMENT_LABELS
'getting-angelic': 'Getting Angelic',
'getting-demonic': 'Getting Demonic',
// 3. SEGMENT_COLORS
'getting-angelic': '#fbbf24', // amber-400 (golden/heavenly)
'getting-demonic': '#b91c1c', // red-700 (dark red)
// 4. SEGMENT_PATTERNS
'getting-angelic': [
/getting angelic/i,
/welcome to.*getting angelic/i,
],
'getting-demonic': [
/getting demonic/i,
/welcome to.*getting demonic/i,
],
src/config/segment-patterns.tsSegmentType unionSEGMENT_LABELSSEGMENT_COLORSSEGMENT_PATTERNSbun run --bun tsc --noEmit