Searching Activities¶
Overview¶
The search_activities tool is your gateway to the Ecoinvent database. It allows you to find industrial processes, energy systems, transportation methods, and more using natural language keywords.
Basic Usage¶
Simple Search¶
The most basic form of search uses just keywords and a database:
Prompt:
What Happens:
Your AI assistant uses the search_activities tool with:
- Query: "electricity production"
- Database: "ecoinvent-3.11-cutoff"
Search with Filters¶
You can refine searches using location, unit, or other filters:
Prompt:
Result: Only activities with location "US" will be returned.
Understanding Search Results¶
Search results include essential information about each activity:
| Field | Description | Example |
|---|---|---|
| name | Full activity name | "steel production, converter, low-alloyed" |
| location | Geographic region | "US", "DE", "GLO" (global) |
| unit | Measurement unit | "kilogram", "kilowatt hour", "unit" |
| code | Activity identifier | "abc123def456..." |
| reference_product | Main output | "steel, low-alloyed" |
| source | Origin | "ecoinvent" or "custom" |
Activity Codes
The code field is crucial - you'll need it to run LCA calculations with calculate_standard.
Search Strategies¶
Strategy 1: Broad → Narrow¶
Start broad, then refine:
Step 1: Broad search
Step 2: Narrow down
Step 3: Specific selection
Strategy 2: Keyword Combinations¶
Use descriptive keywords:
| Good Keywords | Poor Keywords |
|---|---|
| "natural gas electricity production" | "gas" |
| "passenger car transport diesel" | "car" |
| "aluminum primary production" | "aluminum" |
| "municipal waste incineration" | "waste" |
Strategy 3: Location-Specific¶
Geographic precision matters:
Prompts:
"Search for cement production in China"
"Find solar panel manufacturing in the US"
"Show me electricity grid mix for Denmark"
Common Location Codes:
- US - United States
- DE - Germany
- CN - China
- GLO - Global average
- RoW - Rest of World
- EU-28 - European Union
Common Use Cases¶
Use Case 1: Energy Systems¶
Prompts:
"Search for solar photovoltaic electricity in Spain"
"Find wind energy production activities in Denmark"
"Show me hydroelectric power generation globally"
Use Case 2: Transportation¶
Prompts:
"Search for passenger car transport with diesel"
"Find freight truck transportation activities"
"Show me aviation fuel activities"
Use Case 3: Materials Production¶
Prompts:
"Search for primary aluminum production"
"Find recycled steel activities"
"Show me cement clinker production"
Use Case 4: Waste Management¶
Prompts:
"Search for municipal waste incineration"
"Find recycling activities for plastic"
"Show me wastewater treatment processes"
Advanced Search Techniques¶
Limiting Results¶
Control the number of results returned:
Prompt:
Unit Filtering¶
Search for activities with specific units:
Prompt:
Including Custom Activities¶
Search both Ecoinvent and your custom activities:
Prompt:
Interpreting Results¶
Activity Naming Convention¶
Ecoinvent activities follow patterns:
Format: [product/service], [technology], [specification] | [process] | [location]
Examples:
electricity production, photovoltaic, 3kWp slanted-roof installation, multi-Si, panel, mounted | GLO
steel production, electric, low-alloyed | US
transport, passenger car, medium size, diesel, EURO 5 | RER
Understanding Scope¶
Activities can represent: - Cradle-to-gate: Raw materials to factory gate - Gate-to-gate: One process step - Cradle-to-grave: Full life cycle
Check Documentation
Use read_activity tool to get detailed descriptions of what an activity includes.
Common Pitfalls¶
❌ Pitfall 1: Too Generic¶
Bad Prompt:
Why It Fails: Returns hundreds of steel-related activities
Better Prompt:
❌ Pitfall 2: Wrong Database¶
Bad Prompt:
Why It Fails: Version 3.5 doesn't exist
Better Prompt:
❌ Pitfall 3: Unclear Intent¶
Bad Prompt:
Why It Fails: "Green" is subjective
Better Prompt:
Examples with Full Workflow¶
Example 1: Solar Energy Comparison¶
Complete Conversation:
You:
AI Response:
Found 12 activities. Here are the top 5:
1. electricity production, photovoltaic, 3kWp slanted-roof, multi-Si | GLO
2. electricity production, photovoltaic, 3kWp slanted-roof, single-Si | GLO
3. electricity production, photovoltaic, 570kWp open ground, multi-Si | GLO
...
You:
AI Response:
The 3kWp slanted-roof installations represent residential rooftop solar.
The choice between multi-Si (polycrystalline) and single-Si (monocrystalline)
depends on the panel type you want to analyze.
You:
Example 2: Transportation Analysis¶
You:
AI Response:
You:
AI Response:
Here's the activity:
transport, passenger car, medium size, diesel, EURO 6 | RER
Unit: kilometer
Code: xyz789...
You:
Troubleshooting¶
No Results Found¶
Problem: Search returns 0 activities
Solutions: 1. Try broader keywords: "electricity" instead of "solar electricity production" 2. Check spelling and database version 3. Remove location filter: "GLO" is more common than specific countries 4. Ask AI: "Can you try alternative keywords?"
Too Many Results¶
Problem: Search returns hundreds of activities
Solutions: 1. Add location filter: "in Germany" 2. Specify technology: "solar" → "solar photovoltaic residential" 3. Add unit filter: "measured in kilogram" 4. Limit results: "show me top 10"
Wrong Activity Type¶
Problem: Results don't match intention
Solutions:
1. Use more specific terminology
2. Ask AI to explain differences: "What's the difference between these two activities?"
3. Use read_activity to get full descriptions
Best Practices¶
✅ DO¶
- Start with broad searches, then narrow down
- Specify database version explicitly
- Use location codes when relevant
- Ask for clarification on unclear results
- Save activity codes for later calculations
❌ DON'T¶
- Use overly generic single words
- Assume activity names match your terminology
- Forget to check the location (GLO vs specific country)
- Skip verifying the unit matches your needs
Next Steps¶
Now that you can search activities, learn to:
- Calculate Impacts - Use activity codes to run LCA
- Explore Data - Understand methods and units
- Examples - See complete workflows
Related Tools¶
- search_activities - Full tool documentation
- read_activity - Get detailed activity information
- list_activities - List activities in custom projects
Ready to calculate? Head to Calculating Impacts →