How baitc-hacks/hack-dddbf484-netrix works
HackAlem is a demonstration service for finding event contractors by city, category, date, format, and budget. The main workflow is: a user submits search criteria in the React UI, the UI calls the FastAPI match endpoint, and the backend returns up to three recommendations with exclusion counts and reasons for the interface to display. The repository also includes catalog preparation and a development-only preview using fixed mock scenarios. Relationships are limited to those shown in excerpts or documented in the README; unsampled matching internals are kept together.
Main entry points: SearchPage.tsx Search page · useVendorSearch.ts Search state · vendorService.ts Service selector · apiVendorService.ts HTTP adapter
Components 19
Search interface
- App entry
frontend/src/main.tsx - Search page
frontend/src/pages/SearchPage.tsx - Search form
frontend/src/components/SearchForm.tsx - Results view
frontend/src/components/SearchResults.tsx - Vendor card
frontend/src/components/VendorCard.tsx - Page layout
frontend/src/components/PageLayout.tsx - Preview page
frontend/src/pages/PreviewPage.tsx
Frontend services
- Search state
frontend/src/hooks/useVendorSearch.ts - Service selector
frontend/src/services/vendorService.ts - HTTP adapter
frontend/src/services/apiVendorService.ts - Mock adapter
frontend/src/services/mockVendorService.ts - Search contract
frontend/src/services/contracts.ts - UI profile data
frontend/src/mocks/profiles.json
Matching API
- FastAPI routes
app.py - Validation and matching
matching.py
Profile catalog
- Profile preparation
prepare_profiles.py - Anonymized dataset
data/hackathon_dataset_anonymized.csv - Backend catalog
profiles.json
Other components
- Event organizer
Connections 20
- Event organizer → Search page: opens search
README.md - App entry → Search page: renders
frontend/src/main.tsx - App entry → Preview page: loads preview
frontend/src/main.tsx - Search page → Page layout: renders
frontend/src/pages/SearchPage.tsx - Search page → Search form: renders
frontend/src/pages/SearchPage.tsx - Search page → Results view: renders
frontend/src/pages/SearchPage.tsx - Search page → Search state: uses state
frontend/src/pages/SearchPage.tsx - Search form → Search state: submits request
frontend/src/pages/SearchPage.tsx - Search state → Service selector: requests options and matches
frontend/src/hooks/useVendorSearch.ts - Service selector → HTTP adapter: selects live adapter
frontend/src/services/vendorService.ts - HTTP adapter → FastAPI routes: posts match request
frontend/src/services/apiVendorService.ts - FastAPI routes → Validation and matching: dispatches matching
app.py - Validation and matching → Backend catalog: uses catalog
README.md - HTTP adapter → UI profile data: reads profile details
frontend/src/services/apiVendorService.ts - Search state → Results view: returns response
frontend/src/pages/SearchPage.tsx - Results view → Vendor card: renders cards
frontend/src/components/SearchResults.tsx - Preview page → Service selector: creates preview service
frontend/src/pages/PreviewPage.tsx - Service selector → Mock adapter: creates mock adapter
frontend/src/services/vendorService.ts - Profile preparation → Anonymized dataset: prepares from
README.md - Profile preparation → Backend catalog: prepares catalog
README.md