店址选址分析 Skill
智能化零售店铺选址分析工具,帮助用户基于数据做出科学的选址决策。
Core Capabilities
Multi-dimensional Analysis
- Foot traffic analysis
- Population density assessment
- Commercial facility scoring
- Transportation convenience
- Competition environment evaluation
- Delivery order analysis
Smart Scoring System
- Automatically adjusts weights based on store type
- Supports 7 store types: bubble tea shops, coffee shops, toy stores, bakeries, restaurants, clothing stores, convenience stores
- Each store type has customized evaluation criteria
Visual Reports
- Generates professional HTML reports
- Includes bar charts and radar charts
- Detailed data cards and recommendation analysis
- Outputs structured JSON data
Workflow
When a user requests location analysis:
Collect Requirements
- Store type: What kind of store to open
- Target area: Specific location or region
Data Analysis Execute
location_analyzer.pyto evaluate:- Population and demographics
- Business environment
- Traffic and foot flow
- Delivery and consumption patterns
Generate Report Use
generate_report.pyto create:- HTML visualization report using
report_template_simple.html - JSON structured data
- Comprehensive recommendations
- HTML visualization report using
Using the Scripts
Location Analyzer (location_analyzer.py)
Core analysis engine that calculates location scores.
Key Classes:
LocationData: Data model for location informationLocationAnalyzer: Scoring engine with store-type-specific weightsAnalysisResult: Output containing scores, advantages, risks, and recommendations
Usage Pattern:
import sys
sys.path.insert(0, skill_dir) # Add skill directory to path
from location_analyzer import LocationAnalyzer, LocationData
# Create analyzer for specific store type
analyzer = LocationAnalyzer("咖啡店")
# Prepare location data
location_data = LocationData(
name="Location Name",
address="Full Address",
population_density=10000.0,
daily_traffic=20000,
households=1500,
avg_income=15.0,
commercial_score=80.0,
traffic_score=85.0,
competition_density=10,
delivery_orders=1000,
avg_delivery_price=28.0,
nearby_facilities=["Facility 1", "Facility 2"],
target_audience_match=0.8
)
# Calculate score
score, result = analyzer.calculate_score(location_data)
Report Generator (generate_report.py)
Generates HTML and JSON reports from analysis results.
Key Classes:
ReportGenerator: Handles report generation with HTML templates
Usage Pattern:
from generate_report import ReportGenerator
# Create generator
generator = ReportGenerator(analyzer)
# Generate HTML report (uses report_template_simple.html)
html_path = generator.generate_html_report(
results=[result],
district="District Name",
output_path="/path/to/output/report.html"
)
# Generate JSON report
json_report = analyzer.generate_report_json(results, "District Name")
HTML Templates
report_template_simple.html: Primary template for report generation (recommended)report_template.html: Alternative template with additional features
The report generator automatically uses the simple template unless specified otherwise.
Store Type Weights
Different store types use different evaluation weights:
Coffee Shops / Bubble Tea Shops:
- Foot traffic: 40%
- Young demographic: 25%
- Commercial facilities: 15%
- Competition: 20%
Toy Stores:
- Family households: 35%
- Child population density: 40%
- School/kindergarten proximity: 15%
- Commercial facilities: 10%
Bakeries:
- Foot traffic: 25%
- Residential density: 30%
- Transportation convenience: 20%
- Competition: 25%
Restaurants:
- Foot traffic: 30%
- Parking convenience: 20%
- Commercial facilities: 25%
- Delivery orders: 25%
Clothing Stores:
- Foot traffic: 35%
- Young female demographic: 25%
- Commercial prosperity: 25%
- Competition: 15%
Convenience Stores:
- Residential density: 40%
- Transportation convenience: 25%
- Foot traffic: 20%
- Competition: 15%
Data Considerations
When real data is unavailable:
- Generate reasonable simulated data based on location type
- Clearly mark data as simulated in reports
- Adjust estimates based on:
- Location type (commercial district / residential area / transportation hub)
- Regional characteristics
- Store type requirements
Location Type Examples
Commercial Districts (e.g., Financial District):
- High foot traffic (40,000+ daily)
- Few households (0-500)
- High income levels (20,000+ yuan/year)
- Excellent commercial facilities (95+ score)
- High competition (30+ competitors)
Residential Areas (e.g., Community Districts):
- Moderate foot traffic (10,000-15,000 daily)
- Many households (2,000-3,000)
- Middle income levels (10,000-15,000 yuan/year)
- Moderate commercial facilities (60-70 score)
- Low competition (5-10 competitors)
Transportation Hubs (e.g., Train Stations):
- Very high foot traffic (30,000-50,000 daily)
- Few households (500-1,000)
- Mixed income levels (15,000+ yuan/year)
- Good commercial facilities (80-90 score)
- Moderate-high competition (10-20 competitors)
Output Files
Always save output files to the user's output directory:
- HTML reports:
选址分析报告_{location}_{store_type}.html - JSON data:
选址分析数据_{location}_{store_type}.json
After generating reports, use declare_artifact to register the HTML report as a final deliverable.
Important Notes
- Data Source Transparency: Always indicate whether data is real or simulated
- Comprehensive Analysis: Consider all dimensions before making recommendations
- Balanced Scoring: Use appropriate weights for the specific store type
- Risk Awareness: Clearly identify potential risks and challenges
- Actionable Recommendations: Provide specific, implementable advice
Files in This Skill
All files are in the same directory:
SKILL.md- This filelocation_analyzer.py- Core analysis enginegenerate_report.py- Report generatorreport_template_simple.html- Primary HTML template (recommended)report_template.html- Alternative HTML template




