๐Ÿ”ฌ Estimate construction costs from text with Telegram, OpenAI and DDC CWICR

โšก 76 views ยท ๐Ÿ”ฌ Document Extraction & Analysis

๐Ÿ’ก Pro Tip โ€” HTTP Request scraping tends to break when sites update their markup. If youโ€™re scraping a major platform, check if ScraperNode covers it โ€” it has maintained scrapers for LinkedIn, Instagram, TikTok, YouTube, and 20+ other platforms that return structured data.

View All Scrapers

Description

A Telegram bot that converts natural-language work descriptions into detailed cost estimates using AI parsing, vector search, and the open-source DDC CWICR database with 55,000+ construction work items.

Whoโ€™s it for

What it does

  1. Receives text messages in Telegram (work lists, specifications, notes)
  2. Parses input with AI (OpenAI/Claude/Gemini) into structured work items
  3. Searches DDC CWICR vector database via Qdrant for matching rates
  4. Calculates costs with full breakdown (labor, materials, machines)
  5. Exports results as HTML report, Excel, or PDF

Supports 9 languages: ๐Ÿ‡ฉ๐Ÿ‡ช DE ยท ๐Ÿ‡ฌ๐Ÿ‡ง EN ยท ๐Ÿ‡ท๐Ÿ‡บ RU ยท ๐Ÿ‡ช๐Ÿ‡ธ ES ยท ๐Ÿ‡ซ๐Ÿ‡ท FR ยท ๐Ÿ‡ง๐Ÿ‡ท PT ยท ๐Ÿ‡จ๐Ÿ‡ณ ZH ยท ๐Ÿ‡ฆ๐Ÿ‡ช AR ยท ๐Ÿ‡ฎ๐Ÿ‡ณ HI

How it works

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚  Telegram   โ”‚ โ†’  โ”‚  AI Parse    โ”‚ โ†’  โ”‚  Embeddings โ”‚ โ†’  โ”‚   Qdrant     โ”‚
โ”‚  Text Input โ”‚    โ”‚  (GPT/Claude)โ”‚    โ”‚  (OpenAI)   โ”‚    โ”‚   Search     โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                                                                  โ†“
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚   Export    โ”‚ โ†  โ”‚  Aggregate   โ”‚ โ†  โ”‚  Calculate  โ”‚ โ†  โ”‚  AI Rerank   โ”‚
โ”‚ HTML/XLS/PDFโ”‚    โ”‚   Results    โ”‚    โ”‚    Costs    โ”‚    โ”‚   Results    โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Step-by-step:

  1. User sends /start โ†’ selects language โ†’ enters work description
  2. AI Parse extracts work items: name, quantity, unit, room
  3. Query Transform optimizes search terms for construction domain
  4. Embeddings API converts query to vector (OpenAI text-embedding-3-small)
  5. Qdrant Search finds top-10 matching rates from DDC CWICR
  6. AI Rerank selects best match considering context and units
  7. Calculate applies quantities, sums labor/materials/machines
  8. Report sends Telegram message + optional Excel/PDF export

Prerequisites

ComponentRequirement
n8nv1.30+ (AI nodes support)
Telegram BotToken from @BotFather
OpenAI APIFor embeddings + LLM parsing
QdrantVector DB with DDC CWICR collections loaded
DDC CWICR Datagithub.com/datadrivenconstruction/DDC-CWICR

Setup

1. Credentials (n8n Settings โ†’ Credentials)

2. Configuration (๐Ÿ”‘ TOKEN node)

bot_token     = YOUR_TELEGRAM_BOT_TOKEN
QDRANT_URL    = http://localhost:6333
QDRANT_API_KEY = (if using Qdrant Cloud)

3. Qdrant Setup

Load DDC CWICR collections for your target languages:

  1. Open OpenAI Model nodes
  2. Select your OpenAI credential
  3. (Optional) Enable Claude/Gemini nodes for alternative models

5. Telegram Webhook

  1. Activate workflow
  2. Telegram Trigger auto-registers webhook
  3. Test with /start in your bot

Features

FeatureDescription
๐Ÿค– Multi-LLMSwap between OpenAI, Claude, Gemini
๐ŸŒ 9 LanguagesFull UI + database localization
๐Ÿ“ Smart ParsingHandles lists, tables, free-form text
๐Ÿ” Semantic SearchVector similarity + AI reranking
๐Ÿ“Š Cost BreakdownLabor, materials, machines, hours
โœ๏ธ Inline EditModify quantities, delete items
๐Ÿ“ค ExportHTML report, Excel, PDF
๐Ÿ’พ Session StateMulti-turn conversation support

Example Input/Output

Input (Telegram message):

Living room renovation:
- Laminate flooring 25 mยฒ
- Wall painting 60 mยฒ
- Ceiling plasterboard 25 mยฒ
- 3 electrical outlets

Output:

โœ… Estimate Ready โ€” 4 items found

1. Laminate flooring โœ“
   25 mยฒ ร— โ‚ฌ18.50 = โ‚ฌ462.50
   โ”” Labor: โ‚ฌ125 ยท Materials: โ‚ฌ337.50

2. Wall painting โœ“
   60 mยฒ ร— โ‚ฌ8.20 = โ‚ฌ492.00
   โ”” Labor: โ‚ฌ312 ยท Materials: โ‚ฌ180

3. Ceiling plasterboard โœ“
   25 mยฒ ร— โ‚ฌ32.00 = โ‚ฌ800.00
   โ”” Labor: โ‚ฌ425 ยท Materials: โ‚ฌ375

4. Electrical outlets โœ“
   3 pcs ร— โ‚ฌ45.00 = โ‚ฌ135.00
   โ”” Labor: โ‚ฌ95 ยท Materials: โ‚ฌ40

โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
Total: โ‚ฌ1,889.50

[โ†“ Excel] [โ†“ PDF] [โ†ป Restart]

Notes & Tips

Categories

AI ยท Data Extraction ยท Communication ยท Files & Storage

Tags

telegram-bot, construction, cost-estimation, qdrant, vector-search, openai, multilingual, bim, cad


Author

DataDrivenConstruction.io
https://DataDrivenConstruction.io
info@datadrivenconstruction.io

Consulting & Training

We help construction, engineering, and technology firms implement:

Contact us to test with your data or adapt to your project requirements.

Resources


โญ Star us on GitHub! github.com/datadrivenconstruction/DDC-CWICR

๐Ÿ”— Nodes Used

HTTP Request, Telegram, Telegram Trigger, Basic LLM Chain, Anthropic Chat Model, OpenAI Chat Model

๐Ÿ“ฅ Import

Download workflow.json and import into n8n: Workflow menu โ†’ Import from File

๐Ÿ“– Importing guide ยท ๐Ÿ”‘ Credential setup