Skill detail
bim-clash-detection
Detects architectural, structural, and MEP clashes before construction.
Inspect before use
Automated review checks relevance, not safety or endorsement. Read the source instructions before using this skill.
SKILL.md
The saved excerpt is a snapshot from review. The external source remains the complete and most current version.
---
name: "bim-clash-detection"
description: "Detect and analyze geometric clashes in BIM models. Identify MEP, structural, and architectural conflicts before construction."
homepage: "https://datadrivenconstruction.io"
metadata: {"openclaw": {"emoji": "🔍", "os": ["darwin", "linux", "win32"], "homepage": "https://datadrivenconstruction.io", "requires": {"bins": ["python3"]}}}
---
# BIM Clash Detection
## Business Case
### Problem Statement
Coordination issues cause significant rework:
- MEP vs structural conflicts discovered on site
- Late design changes increase costs
- Manual clash review is time-consuming
- No standardized clash categorization
### Solution
Automated clash detection and analysis system that identifies conflicts between building systems and provides prioritized resolution recommendations.
### Business Value
- **Cost savings** - Detect issues before construction
- **Time reduction** - Automated clash identification
- **Better coordination** - Systematic conflict resolution
- **Quality improvement** - Fewer field issues
## Technical Implementation
```python
import pandas as pd
from datetime import datetime
from typing import Dict, Any, List, Optional, Tuple
from dataclasses import dataclass, field
from enum import Enum
import math
class ClashType(Enum):
"""Types of clashes."""
HARD = "hard" # Physical intersection
SOFT = "soft" # Clearance violation
WORKFLOW = "workflow" # Sequencing conflict
DUPLICATE = "duplicate" # Duplicated elements
class ClashStatus(Enum):
"""Clash resolution status."""
NEW = "new"
ACTIVE = "active"
RESOLVED = "resolved"
APPROVED = "approved"
IGNORED = "ignored"
class ClashSeverity(Enum):
"""Clash severity level."""
CRITICAL = "critical"
MAJOR = "major"
MINOR = "minor"
INFO = "info"
class Discipline(Enum):
"""BIM disciplines."""
ARCHITECTURAL = "architectural"
STRUCTURAL = "structural"
MECHANICAL = "mechanical"
ELECTRICAL = "electrical"
PLUMBING = "plumbing"
FIRE_PROTECTION = "fire_protection"
CIVIL = "civil"
@dataclass
class BoundingBox:
"""3D bounding box."""
min_x: float
min_y: float
min_z: float
max_x: float
max_y: float
max_z: float
def intersects(self, other: 'BoundingBox') -> bool:
"""Check if boxes intersect."""
return (self.min_x <= other.max_x and self.max_x >= other.min_x and
self.min_y <= other.max_y and self.max_y >= other.min_y and
self.min_z <= other.max_z and self.max_z >= other.min_z)
def volume(self) -> float:
"""Calculate bounding box volume."""
return ((self.max_x - self.min_x) *
(self.max_y - self.min_y) *
(self.max_z - self.min_z))
def center(self) -> Tuple[float, float, float]:
"""Get center point."""
return (
(self.min_x + self.max_x) / 2,
(self.min_y + self.max_y) / 2,
(self.min_z + self.max_z) / 2
)
@dataclass
class BIMElement:
"""BIM element representation."""
element_id: str
name: str
discipline: Discipline
category: str # e.g., "Duct", "Beam", "Pipe"
level: str
bounding_box: BoundingBox
properties: Dict[str, Any] = field(default_factory=dict)
def distance_to(self, other: 'BIMElement') -> float:
"""Calculate distance between element centers."""
c1 = self.bounding_box.center()
c2 = other.bounding_box.center()
return math.sqrt(
(c2[0] - c1[0])**2 +
(c2[1] - c1[1])**2 +
(c2[2] - c1[2])**2
)
@dataclass
class Clash:
"""Clash between two elements."""
clash_id: str
element_a: BIMElement
element_b: BIMElement
clash_type: ClashType
severity: ClashSeverity
status: ClashStatus
distance: float # Penetration depth (negative) or clearance gap
location: Tuple[float, float, float]
detected_at:Read the full source on GitHub (opens external page)