API Key Setup for IFC Chat
The IFCChat.ChatWithIFCModel node requires a Google AI Studio API key to enable AI-powered conversations with your IFC model.
Getting Your API Key
Step 1: Go to Google AI Studio
Visit https://aistudio.google.com/app/api-keys
Step 2: Sign In
Sign in with your Google account. If you do not have one, create a free Google account first.
Step 3: Create an API Key
- Click Create API Key
- Select a Google Cloud project or create a new one
- Click Create API Key in New Project
- Your API key will be displayed
Step 4: Copy Your Key
Copy the API key. It looks something like this: AIzaSyB1234567890abcdefghijklmnop
Important: Keep your API key private. Do not share it publicly or commit it to version control.
Using the API Key in Dynamo
Method 1: Direct Input
- Add IFCChat.ChatWithIFCModel to your canvas
- Connect a String node to the
apiKeyinput - Enter your API key in the String node
- Connect your IFCModel to the
ifcModelinput
Method 2: Environment Variable
For better security, store your API key as an environment variable:
- Press Windows + R, type
sysdm.cpland press Enter - Go to Advanced tab
- Click Environment Variables
- Under User Variables, click New
- Variable name:
GOOGLE_AI_API_KEY - Variable value: Your API key
- Click OK and restart Dynamo
Then use a Python node or custom node to read the environment variable.
IFC Chat Features
Once connected, the IFC Chat opens an interactive window with:
- 3D Model View: Visualize your IFC model
- Tree View: Navigate the model hierarchy
- Chat Interface: Ask questions in natural language
Available AI Tools
The AI assistant can use these tools to help you:
filter_elements
Find elements by type, property, or other criteria
get_element_details
Get detailed information about specific elements
analyze_relationships
Explore connections between elements
detect_clashes
Find geometric conflicts between elements
web_search
Search the web for IFC or BIM related information
get_user_selection
Get elements currently selected in the viewer
visualize_elements
Highlight or isolate elements in the 3D view
capture_view
Capture the current 3D view as an image
Example Questions
You can ask the AI assistant questions like:
- "Show me all the walls on Level 1"
- "What is the fire rating of the selected door?"
- "Find all elements made of concrete"
- "Are there any clashes between the structural and MEP elements?"
- "What properties does this wall have?"
- "Highlight all windows in the model"
Troubleshooting
Chat window does not open
- Verify your API key is correct
- Check your internet connection
- Ensure the IFCModel is properly loaded
AI responses are slow
- Complex queries require more computation
- Check your internet connection speed
API key errors
- Verify the key is copied correctly with no extra spaces
- Check that your Google Cloud project has the Generative AI API enabled
- Ensure you have not exceeded API usage limits