← Case studiesKIM YEONJUN

풀스택 제품 · Railway 운영 중 · Google Play 출시 준비 · LIVE API

다시길 — 개인화 경로 추천 서비스

A personalized route-recommendation app that picks the best path for you, not the fastest one, by scoring candidate routes on past-route memory, POIs and safety maps.가장 빠른 길이 아니라 ‘나에게 맞는 길’을 추천합니다. 지나온 길의 기억·POI·안전 지도로 후보 경로를 점수화하는 개인화 경로 추천 앱입니다.

ROLE · 담당서비스 기획 · 추천 엔진 설계 · FastAPI/PostGIS 백엔드 · Flutter 앱 · 배치 파이프라인 · 배포
CONTEXT · 구분개인 프로젝트 · 2026.08 시작 · 커밋 330+ · 백엔드 Railway 운영
TECHNOLOGY · 기술Flutter · FastAPI · PostGIS · Mapbox · Airflow · Railway

DEMO VIDEO · 시연 영상

SYSTEM ARCHITECTURE · 시스템 구조

GPS trips & route memoryMapbox candidate routesFamiliarity · POI · safety scoring6 strategy presetsFlutter app + Airflow batch
The diagram shows only the disclosed system boundary. · 공개 가능한 시스템 범위만 표시했습니다.

Problem definition문제 정의

Navigation apps return one fastest route and GPS trackers only log the past. Walkers and cyclists choose by familiarity, slope, stairs, main-road exposure, safety facilities and places worth stopping at, and few services weigh all of these together.일반 내비게이션은 목적지까지 가장 빠른 길 하나만 알려주고, GPS 기록 앱은 지난 길을 남기기만 합니다. 걷거나 자전거를 탈 때는 익숙한 길, 경사와 계단, 큰길 여부, 안전시설, 들를 만한 장소가 선택 기준이 되는데 이를 함께 반영하는 서비스는 드뭅니다.

Data & diagnosis데이터와 진단

Inputs are the user's own GPS trips (cleaned and map-matched into route segments), Mapbox Directions candidates, public POIs from TourAPI, Kakao Local and the small-business registry, safety facilities (CCTV, emergency bells, child-safety houses), accessibility facilities (ramps, elevators), OSM road features, KMA weather, and community reports. Elevation comes from a DEM, and the 46 Alembic migrations show how the schema grew with these sources.입력은 사용자의 GPS 이동 기록(정제·맵매칭 후 경로 구간으로 집계), Mapbox Directions 후보 경로, 관광공사·카카오 로컬·소상공인 상가업소 POI, 안심시설(CCTV·비상벨·아동안전지킴이집)과 편의시설(경사로·승강기), OSM 도로 속성, 기상청 날씨, 사용자 제보입니다. 고도는 DEM에서 가져오며, 46개의 Alembic 마이그레이션이 이 데이터 소스가 늘어난 과정을 보여줍니다.

Planning접근 계획

Request path is Flutter → FastAPI → PostGIS, Redis and Mapbox; a separate Airflow batch path handles trip processing, POI refresh, route-feature refresh and preference learning. All ranking logic lives in one pure module, backend/app/recommendation: familiarity, reliability, route similarity, detour and confusion penalties, POI utility and a per-user routing profile, with six strategy presets (balanced, fastest, familiar, sightseeing, food, flat) that swap the weights.Flutter(앱) → FastAPI → PostGIS·Redis·Mapbox 요청 경로와, Airflow 배치 경로(이동 기록 처리, POI 갱신, 경로 속성 갱신, 사용자 선호 학습)를 분리했습니다. 추천 로직은 backend/app/recommendation 한 곳에 순수 함수로 모았습니다. 익숙함(Familiarity), 신뢰도(Reliability), 경로 유사도, 우회·혼란 페널티, POI 효용, 사용자 라우팅 프로필을 계산하고 알아서·빨리·익숙하게·구경하며·먹으며·평탄하게 6가지 전략 프리셋으로 가중치를 바꿉니다.

Trade-offs기술 선택과 판단

The final score is a weighted sum (time 0.30, familiarity 0.20, reliability 0.15, POI 0.15 and so on) minus detour and confusion penalties, with every weight in one config file. Traffic volume is deliberately not used as a safety signal because it raises both passersby and vehicle danger. Explanations are rule-based templates, not LLM output, so results are reproducible, and in production a missing Mapbox token returns 503 instead of a fake route.최종 점수는 시간 0.30, 익숙함 0.20, 신뢰도 0.15, POI 0.15 등 가중합에서 우회·혼란 페널티를 빼는 구조로, 가중치는 설정 파일 한 곳에서만 조정합니다. 안전 지도는 교통량을 안전 신호로 쓰지 않았습니다. 교통량은 보행자 수와 차량 위험을 동시에 키워 방향을 단정할 수 없기 때문입니다. 추천 이유는 LLM이 아니라 규칙 기반 템플릿으로 생성해 결과를 재현 가능하게 했고, Mapbox 토큰이 없는 운영 환경에서는 가짜 경로 대신 503을 반환합니다.

Implementation & validation구현과 검증

User traces and map data are noisy, so data-quality fixes shipped as migrations: GPS cleaning, deduplication constraints on route events and track points, visited-POI de-duplication and geography expression indexes. Community reports are never applied by votes alone and need admin approval before touching official data. Release work also covered the Mapbox 3.0 alpha migration, Kakao/Naver/Google login, FCM push and account deletion.사용자 기록과 지도 데이터는 오차가 큽니다. GPS 정제, 구간 중복 제거 제약, 방문 POI 중복 방지, 지리 표현식 인덱스 등 데이터 품질 문제를 마이그레이션 단위로 하나씩 해결했습니다. 제보 데이터는 투표만으로 반영하지 않고 운영자 승인 후 공식 데이터에 반영하도록 검토 단계를 두었고, Mapbox 3.0 알파 버전 전환과 소셜 로그인(카카오·네이버·구글), FCM 푸시, 계정 삭제 같은 출시 요건도 처리했습니다.

Outcome결과

Delivered the app and API: six recommendation strategies, course building with a 3D preview, off-route alerts, safety and accessibility layers, community reports, and trip records. The backend runs on Railway with PostGIS and Redis, with 46 Alembic migrations, 79 backend test files and CI. Android release readiness (Google Play policy matrix, deploy runbook, bug ledger) is documented.추천(6가지 전략)·코스 만들기와 3D 미리보기·경로 이탈 알림·안전/접근성 지도·참여형 제보·기록과 회고까지 갖춘 앱과 API를 구현했습니다. 백엔드는 Railway(PostGIS, Redis)에서 운영하며 Alembic 마이그레이션 46개, 백엔드 테스트 파일 79개, CI가 있습니다. Android 출시 점검(Google Play 정책, 배포 런북, 버그 대장)을 문서화했습니다.

Lessons & next step배운 점과 다음 단계

향후 개선 방향(제안): 추천 점수 가중치는 설정으로 분리했지만 아직 실사용 데이터로 검증하지 않았습니다. 추천 경로를 실제로 따라 걸은 비율, 이탈률, 재방문 경로 선택률을 측정해 가중치를 조정하고, 추천 이유를 사용자에게 보여 주는 방식이 신뢰를 높이는지 확인합니다.향후 개선 방향(제안): 추천 점수 가중치는 설정으로 분리했지만 아직 실사용 데이터로 검증하지 않았습니다. 추천 경로를 실제로 따라 걸은 비율, 이탈률, 재방문 경로 선택률을 측정해 가중치를 조정하고, 추천 이유를 사용자에게 보여 주는 방식이 신뢰를 높이는지 확인합니다.

Verified evidence확인 가능한 근거

The repository is private; the on-device demo below shows Home, 3D route guidance, the off-route alert, Courses, Records and Profile. No user-count or recommendation-accuracy figures were measured, so none are claimed.저장소는 비공개이며, 아래 실기기 시연 영상에서 홈, 3D 경로 안내, 경로 이탈 알림, 코스, 기록, 프로필을 확인할 수 있습니다. 사용자 수나 추천 정확도 같은 성과 수치는 측정하지 않아 제시하지 않습니다.