<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Rasel Khan</title>
    <description>The latest articles on DEV Community by Rasel Khan (@rasel_khan_485ac8f6c6a245).</description>
    <link>https://dev.to/rasel_khan_485ac8f6c6a245</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3623803%2F90420086-d059-4856-b7a8-1d10db246755.png</url>
      <title>DEV Community: Rasel Khan</title>
      <link>https://dev.to/rasel_khan_485ac8f6c6a245</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/rasel_khan_485ac8f6c6a245"/>
    <language>en</language>
    <item>
      <title>I Built a Programmatic SEO Site with Astro &amp; DeepSeek API (300+ Pages for $1.65</title>
      <dc:creator>Rasel Khan</dc:creator>
      <pubDate>Sat, 22 Nov 2025 04:32:24 +0000</pubDate>
      <link>https://dev.to/rasel_khan_485ac8f6c6a245/i-built-a-programmatic-seo-site-with-astro-deepseek-api-300-pages-for-165-4n47</link>
      <guid>https://dev.to/rasel_khan_485ac8f6c6a245/i-built-a-programmatic-seo-site-with-astro-deepseek-api-300-pages-for-165-4n47</guid>
      <description>&lt;p&gt;The Problem: AI Fatigue 🤯&lt;/p&gt;

&lt;p&gt;There are too many AI tools. I wanted to build a "Referee" site that compares them (e.g., ChatGPT vs Claude, Notion vs Obsidian) and gives a definitive verdict.&lt;/p&gt;

&lt;p&gt;But I had two constraints:&lt;/p&gt;

&lt;p&gt;Zero Budget: I didn't want to pay for a database or expensive hosting.&lt;/p&gt;

&lt;p&gt;Scalability: I needed to generate 300+ pages, but I didn't want to write them manually.&lt;/p&gt;

&lt;p&gt;The Solution: The "pSEO" Stack 🛠️&lt;/p&gt;

&lt;p&gt;I chose a JAMstack architecture focused on speed and low cost:&lt;/p&gt;

&lt;p&gt;Frontend: Astro (SSG mode)&lt;/p&gt;

&lt;p&gt;Styling: Tailwind CSS&lt;/p&gt;

&lt;p&gt;Content Engine: Python + DeepSeek V3 API&lt;/p&gt;

&lt;p&gt;Database: A single JSON file&lt;/p&gt;

&lt;p&gt;Hosting: Vercel (Free Tier)&lt;/p&gt;

&lt;p&gt;Here is the live demo: PrismKit.xyz&lt;/p&gt;

&lt;p&gt;Step 1: The "Database" (JSON) 📂&lt;/p&gt;

&lt;p&gt;Instead of setting up Postgres or MongoDB, I just used a flat JSON file. It's fast, free, and version-controllable.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;// tools_database.json&lt;br&gt;
[&lt;br&gt;
  {&lt;br&gt;
    "id": "notion",&lt;br&gt;
    "name": "Notion",&lt;br&gt;
    "category": "Productivity",&lt;br&gt;
    "alternatives": ["obsidian", "evernote"]&lt;br&gt;
  },&lt;br&gt;
  {&lt;br&gt;
    "id": "obsidian",&lt;br&gt;
    "name": "Obsidian",&lt;br&gt;
    "category": "Productivity",&lt;br&gt;
    "alternatives": ["notion"]&lt;br&gt;
  }&lt;br&gt;
]&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Step 2: The Content Factory (Python + DeepSeek) 🤖&lt;/p&gt;

&lt;p&gt;This is the magic part. I needed unique comparisons for every pair. Writing them by hand is impossible. Using GPT-4o is expensive.&lt;/p&gt;

&lt;p&gt;I used DeepSeek V3 via their API (OpenAI compatible). It's incredibly cheap (~$0.05 for the whole site).&lt;/p&gt;

&lt;p&gt;Here is the simplified logic of my content_factory.py:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;from openai import OpenAI&lt;br&gt;
import json&lt;br&gt;
client = OpenAI(&lt;br&gt;
    api_key="sk-...", &lt;br&gt;
    base_url="&lt;a href="https://api.deepseek.com" rel="noopener noreferrer"&gt;https://api.deepseek.com&lt;/a&gt;"&lt;br&gt;
)&lt;br&gt;
def generate_verdict(tool_a, tool_b):&lt;br&gt;
    prompt = f"Compare {tool_a} and {tool_b}. Who should use which? Be concise."&lt;/p&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;response = client.chat.completions.create(
    model="deepseek-chat",
    messages=[{"role": "user", "content": prompt}]
)

return response.choices[0].message.content
&lt;/code&gt;&lt;/pre&gt;
&lt;h1&gt;
  
  
  Loop through tools and save to JSON...
&lt;/h1&gt;
&lt;/blockquote&gt;

&lt;p&gt;The script runs locally, updates the JSON file with the AI-generated insights, and then I push the JSON to GitHub.&lt;/p&gt;

&lt;p&gt;Step 3: Dynamic Routing in Astro 🚀&lt;/p&gt;

&lt;p&gt;Astro makes Programmatic SEO (pSEO) trivial with getStaticPaths. I created one file: src/pages/vs/[...slug].astro.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;// src/pages/vs/[...slug].astro&lt;br&gt;
export async function getStaticPaths() {&lt;br&gt;
  const tools = await import('../../data/tools_database.json');&lt;/p&gt;

&lt;p&gt;// Generate all possible pairs&lt;br&gt;
  const paths = [];&lt;br&gt;
  tools.forEach(tool =&amp;gt; {&lt;br&gt;
    tool.alternatives.forEach(altId =&amp;gt; {&lt;br&gt;
       paths.push({&lt;br&gt;
         params: { slug: &lt;code&gt;${tool.id}-vs-${altId}&lt;/code&gt; },&lt;br&gt;
         props: { toolA: tool, toolB: getToolById(altId) }&lt;br&gt;
       });&lt;br&gt;
    });&lt;br&gt;
  });&lt;br&gt;
  return paths;&lt;br&gt;
}&lt;br&gt;
const { toolA, toolB } = Astro.props;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;This single file generates hundreds of static HTML pages at build time. No client-side JS is needed to fetch data.&lt;/p&gt;

&lt;p&gt;Step 4: Deployment ⚡&lt;/p&gt;

&lt;p&gt;I pushed the code to GitHub, and Vercel automatically built the site.&lt;br&gt;
Because it's pure HTML/CSS, the performance is insane.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frmju4z2hoac3q7iyxuyr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frmju4z2hoac3q7iyxuyr.png" alt="Vercel Dashboard Screenshot"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The Result&lt;/p&gt;

&lt;p&gt;Cost: $1.65 (Domain) + $0.05 (API) = &lt;strong&gt;$1.70&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Performance: 100/100 Lighthouse&lt;/p&gt;

&lt;p&gt;Content: Unique, useful AI verdicts for 300+ pairs.&lt;/p&gt;

&lt;p&gt;Check it out here: 

&lt;/p&gt;
&lt;div class="crayons-card c-embed text-styles text-styles--secondary"&gt;
    &lt;div class="c-embed__content"&gt;
        &lt;div class="c-embed__cover"&gt;
          &lt;a href="https://www.prismkit.xyz/" class="c-link align-middle" rel="noopener noreferrer"&gt;
            &lt;img alt="" src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fwww.prismkit.xyz%2Fog-image-v2.png" height="auto" class="m-0"&gt;
          &lt;/a&gt;
        &lt;/div&gt;
      &lt;div class="c-embed__body"&gt;
        &lt;h2 class="fs-xl lh-tight"&gt;
          &lt;a href="https://www.prismkit.xyz/" rel="noopener noreferrer" class="c-link"&gt;
            PrismKit - Compare 100+ AI Tools &amp;amp; Find the Best Alternatives
          &lt;/a&gt;
        &lt;/h2&gt;
          &lt;p class="truncate-at-3"&gt;
            Discover and compare 129 AI tools across 40 categories. Find features, pricing, pros, cons, and alternatives.
          &lt;/p&gt;
        &lt;div class="color-secondary fs-s flex items-center"&gt;
            &lt;img alt="favicon" class="c-embed__favicon m-0 mr-2 radius-0" src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fwww.prismkit.xyz%2Ffavicon.svg"&gt;
          PrismKit.xyz
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
&lt;/div&gt;




&lt;p&gt;Let me know if you have any questions about the Astro + DeepSeek workflow! 👇&lt;/p&gt;

</description>
      <category>astro</category>
      <category>python</category>
      <category>webdev</category>
      <category>showdev</category>
    </item>
  </channel>
</rss>
