n8n

How to Analyze Hacker News Comments for Insights?

Get fast, clear insights from community discussions. The flow collects all comments from a chosen Hacker News story, groups similar opinions, and writes easy to read summaries into a Google Sheet. It suits product marketing, growth teams, and founders who need quick voice of customer research.

Work begins with a manual start. Old records for the story are cleared from a Qdrant collection. The flow pulls comments and replies, flattens the thread, and creates embeddings with OpenAI. Those vectors and metadata go into Qdrant. A subworkflow then finds the story’s vectors, runs K means clustering in a code step, and keeps clusters with at least three comments. The system fetches the full comment text for each point, sends grouped text to an OpenAI chat model and information extractor, and returns themes, quotes, and summaries. Results are prepared and appended to Google Sheets.

You will need an OpenAI API key, a Qdrant endpoint and API key, and Google Sheets access. Set the story ID in the Set Variables node. Expect to cut manual review from hours to minutes while handling more threads with the same team. Use it for product feedback scans, competitive tracking, and content research. Follow the steps below to connect accounts, set credentials, and validate the pipeline end to end.

What are the key features?

  • Manual and subworkflow triggers separate collection and analysis for clear control
  • Pulls comments and nested replies for a chosen story using the Hacker News node
  • Flattens the comment tree into a single list for clean processing
  • Generates embeddings with OpenAI text embedding 3 small for similarity search
  • Stores vectors and metadata in a Qdrant collection and clears old story data when starting
  • Runs K means clustering in a Code node and filters clusters with at least three points
  • Fetches full comment payloads by vector IDs to restore original text
  • Creates cluster summaries and themes using an OpenAI chat model and an information extractor
  • Appends final insights to a chosen Google Sheet for easy sharing

What are the benefits?

  • Reduce manual review of long threads from 3 hours to 10 minutes
  • Streamline feedback analysis by about 80 percent with auto clustering
  • Improve insight quality by grouping similar comments and filtering noise
  • Handle up to 10 times more discussions with the same team size
  • Connect Hacker News, Qdrant, OpenAI, and Google Sheets in one flow

How do you set it up?

  1. Import the template into n8n: Create a new workflow in n8n > Click the three dots menu > Select 'Import from File' > Choose the downloaded JSON file.
  2. You'll need accounts with Hacker News, Qdrant, OpenAI and Google Sheets. See the Tools Required section above for links to create accounts with these services.
  3. OpenAI credentials: In n8n, go to Credentials > New > OpenAI API. Enter your OpenAI API key from your OpenAI account. Save the credential and select it in the Embeddings and Chat Model nodes.
  4. Qdrant credentials: In n8n, go to Credentials > New > Qdrant API. Add your Qdrant base URL and API key from your Qdrant dashboard. Save and assign this credential in the Qdrant Vector Store, Clear Existing Comments, Get Payload of Points, and Find Comments nodes.
  5. Google Sheets credentials: In n8n, go to Credentials > New > Google Sheets OAuth2. Sign in to your Google account and allow access. Save and select this credential in the Export To Sheets node.
  6. Set the story ID: Open the Set Variables node and update the story_id value with a valid Hacker News story ID. You can copy this ID from the story URL.
  7. Configure the Qdrant collection: Confirm the collection name is hn_comments in the Qdrant nodes. Create the collection in Qdrant if it does not exist.
  8. Map the Google Sheet: In the Export To Sheets node, choose your spreadsheet, worksheet, and ensure columns match the output fields prepared by the flow.
  9. Test the run: Click Test workflow. Watch nodes succeed in order. Confirm that Clear Existing Comments returns success and that the Qdrant Vector Store inserts points.
  10. Validate clustering: Check the Apply K means Clustering and Only Clusters With 3+ points results. Adjust cluster count or minimum size in those nodes if the data is sparse.
  11. Review output: Open the chosen Google Sheet and confirm new rows show themes, summaries, and supporting comments.
  12. Optional scheduling: If you want regular runs, add a Cron node at the top and connect it to Set Variables, or trigger this workflow from another n8n workflow using Execute Workflow.
  13. Troubleshooting: If no rows appear, verify the story has comments, check API keys, confirm the hn_comments collection exists, and ensure the OpenAI models text-embedding-3-small and gpt-4o-mini are available in your account.

Tools Required

$24 / mo or $20 / mo billed annually to use n8n in the cloud. However, the local or self-hosted n8n Community Edition is free.

Google Sheets

Sign up

Free: $0 (Google Sheets API usage has no additional cost; quota limits apply)

Hacker News

Sign up

Free: $0 / mo, public read-only API (no auth, no stated rate limit)

OpenAI

Sign up

Pay-as-you-go: GPT-5 at $1.25 per 1M input tokens and $10 per 1M output tokens

Qdrant

Sign up

Free tier: $0, 1 GB free cluster (no credit card), accessible via REST/GRPC API

Similar Templates

Join Futurise to access 1,200+ automation templates

Get instant access to ready-made automation workflows for n8n, Make.com, AI agents, and more. Download, customise, and deploy in minutes.