Download the .md file or copy the text below.
# SailScan: every outside service Checked 2026-10-21 against the latest code on GitHub (origin/master) and the Railway setting names (names only, no secrets). "(not confirmed)" means I could not prove it from the repo or settings. ## The live scan, step by step A live scan is a customer photo sent to the server (POST /api/analyze). 1. Phone app (Expo build, Apple/Google store app) sends the photo to the SailScan server on **Railway**. 2. The server (**Railway**, Node) cleans up the photo and fixes its rotation. 3. The server calls the model service (**Railway**, Python, CPU only). It finds the stripes and the foot-down direction. The model files are fetched from **Cloudflare R2** when the service boots. 4. At the same time, for landscape photos only: **Cloudflare "clef"** says which side the mast is on. It gets 3 seconds, then we skip it and use our own rule. 5. The server sends the lines to **RunPod serverless SAM 3** (SAILSCAN account) to tidy them. Time limit is 120 seconds (the setting says so). If it fails, the scan still returns the model's lines. 6. The server does the math (draft, twist, camber) itself. No outside service. 7. The photo and result are saved to **Cloudflare R2**. Overlay picture and a rough location (from the IP address) are made afterward, not blocking the reply. 8. Errors go to **error tracking** (Sentry code, pointed at GlitchTip, see below). The reply goes back to the phone. Not in a live scan: email, Tesseract, Expo/EAS, GitHub, Hugging Face. ## Live scan services | Service | What it does for us | Part of app | In every live scan? | Account / owner | Cost basis | |---|---|---|---|---|---| | Railway, service `boats` (Node server) | Runs the main SailScan server and its API. Has a small disk volume (4.9 GB) for the database. Public address boats-production.up.railway.app | live scan, mobile app, web apps | Yes | Railway project `boats`, workspace "Nate McGuire's Projects" | Not stated in repo (not confirmed) | | Railway, service `inference` (Python model service, CPU) | Runs the stripe-finding model (YOLO plus RF-DETR "ensemble" mode). Runs on CPU, no graphics card. | live scan | Yes | Same Railway project | Not stated in repo (not confirmed) | | Cloudflare R2 (file storage) | Stores every photo, label, overlay picture, and the model weight files. Bucket `sailscan-labels`. | live scan, web apps, training | Yes (photo save); model service reads weights at boot | Cloudflare token is in Railway settings; which Cloudflare account owns the bucket: (not confirmed). Repo says bucket access is limited to Railway's IP. | Not stated in repo (not confirmed) | | Cloudflare Workers AI "clef" (mast finder) | A hosted vision model that says which side of the photo the mast is on. Helps decide which edge is the luff (front edge). | live scan | No. Landscape photos only, 3 second cap. Fails open (scan never blocked). | Alex's Cloudflare account (7f8e...). Confirmed 2026-10-21: it stopped at the free daily limit and came back when Alex turned on Workers Paid. | Workers Paid plan, $5/month, plus about $0.0003 per scan | | RunPod serverless, SAM 3 (SAILSCAN account) | Rented GPU that runs SAM 3 (a "segment anything" image model) to refine the stripe lines. | live scan | Yes when it is switched on. It is on in production (SAM3_PRODUCTION_ENABLED=1). | RunPod account SAILSCAN (alex@sailscanapp...) per team notes. Not in repo (not confirmed in code). | Not stated in repo for serverless. An older doc says the always-on test GPU was $0.44/hr, about $150/mo. | | Tesseract OCR (tesseract.js) | Reads numbers off photos of boat instrument screens (wind speed, etc.). Runs inside our own server. No outside call. | mobile app, web apps (instrument photo) | No. Only when someone reads an instrument photo. | Open source (Apache 2.0). No account. | Free | | ip-api.com | Looks up the city/region from a scan's IP address. Free public lookup. | live scan, after the reply | Runs after the reply on each saved scan with an IP | No account (not confirmed whether paid) | Free tier (not confirmed) | ## Websites and web apps (hosting) | Service | What it does for us | Part of app | Account / owner | |---|---|---|---| | Cloudflare Pages: `sailscan-label` | Hosts label.sailscanapp.com. The tool for labeling and reviewing photos, training, admin. | web apps | Alex's Cloudflare, ID 7f8e... (in CLAUDE.md deploy command) | | Cloudflare Pages: `sailscan-scanner` | Hosts the customer desktop web app (scanner.sailscanapp.com). Match to project name: (not confirmed) | web apps | Account (not confirmed) | | Cloudflare Pages: `sailscanapp` | Hosts the sailscanapp.com marketing site. | web apps | Alex's Cloudflare ([email protected]), ID 7f8e... | | Cloudflare Pages previews (other project names such as `sailscan-proof`, `sam-edges`) | One-off review pages for Alex. | web apps | Alex's Cloudflare (mostly; not confirmed each) | | Cloudflare Worker `sailscan-legal` (alexhigby100.workers.dev) | Serves the privacy policy page the App Store links to. | build & release (store listing) | Alex's Cloudflare | | Google Fonts | Fonts for the labeler and desktop pages. | web apps | Public, no account | Domain/DNS registrar for sailscanapp.com: (not confirmed). ## Email | Service | What it does | Notes | |---|---|---| | Resend | Sends sign-up approvals, password resets and alerts (including an alert when SAM 3 is down). Main sender. | API key is in Railway. Account owner: (not confirmed). | | Amazon SES | Backup sender if Resend is not set. Code is there. | Settings exist on Railway (AWS_KEY, AWS_SECRET, AWS_REGION). Whether it is actually used: (not confirmed). | ## Error tracking and monitoring | Service | What it does | Notes | |---|---|---| | GlitchTip (self-hosted on Railway: glitchtip-web-production-d37c) | Collects crash and error reports. Uses the Sentry code libraries. | The phone app code points at GlitchTip. The server's reporting address is a Railway setting (SENTRY_DSN) and I did not read its value, so which tracker the server reports to: (not confirmed). | | Sentry libraries (@sentry/node, @sentry/react-native) | The code inside our server and app that sends the reports. | Software only. A paid Sentry account: (not confirmed). | | Railway logs and deploy list | Basic server health and logs. | Part of Railway | Analytics (Google Analytics, Mixpanel, etc.): none found in the app, labeler, or desktop code. Not in repo (not confirmed beyond the code search). ## Mobile app: build and release | Service | What it does | Account / owner | |---|---|---| | Expo (framework) and EAS (Expo's cloud build service) | Builds the iPhone and Android apps (eas.json). Release notes say builds may also be done locally. | Expo account owner: (not confirmed) | | Apple App Store Connect / TestFlight | iPhone app listing, test builds, review. | App moved to Sail Scan LLC team N5H73D2WDR (per team notes). Public iPhone version is 1.0.5. | | Google Play Console | Android app listing. Package com.sailscan.app. | Public Android version is 1.0.4 (per CLAUDE.md). | | Fastlane | Script tool that uploads builds, text and screenshots to Apple and Google. Config is in fastlane/. | Software only | | GitHub (natemcguire) | Holds the code. Also hosts private model/container images at ghcr.io/natemcguire/ (see training). | GitHub user natemcguire | Phone features that use Apple/Google services: camera, location (GPS), push notification library installed (expo-notifications). Which push service is actually used: (not confirmed). ## Training and model work (not in live scans) | Service | What it does | Account / owner | Cost basis | |---|---|---|---| | RunPod, ALEXGMAIL account | Rented GPUs for training and test runs (default RunPod key in team notes). Also RunPod pods for SAM 3 fine-tuning. | RunPod ALEXGMAIL (alexhigby100@gmail), per team notes | Not stated in repo (not confirmed) | | GitHub Container Registry (ghcr.io/natemcguire) | Stores the private container images RunPod pulls (SAM 3 training and the SAM 3 serverless image). | GitHub natemcguire | Free/private tier (not confirmed) | | Hugging Face | Downloads open model weights: SAM 3 / 3.1 (via the SailScan / Alex Higby account) and DINOv3 for experiments (Nate's account). | SailScan account for SAM 3; Nate's for some experiments | Free | | Ultralytics and PyTorch (open-source software) | Model code used for training and in the model service. Software only, no outside call. Note: Ultralytics licence (AGPL) is an open question in team notes. | n/a | Free | | Railway, service `inference-preview` / PREVIEW_INFERENCE_URL (sailscan-preview-production) | A second model service used to preview new models before they go live. | Same Railway project (service name: not confirmed) | Not stated | | Railway staging (boats-staging) | Test copy of the server. | Same Railway project | Not stated | ## Retired or never adopted | Service | Status | |---|---| | Anthropic (Claude) and Google Gemini LLM keys | Retired. The product no longer calls any AI chat model. Old test scripts for orientation still mention Gemini, OpenAI and xAI. They are one-off tools, not used by the product. | | The archive partner | Training data source, ended 2026-10-02. Harvester deleted, never to run again. Photos kept in a private backup. | | OpenCV stripe detector | Deleted in July 2026. It did not work. The trained model is the only stripe source. (OpenCV is still used inside the model service as a plain image library.) | | Roboflow | Tested in a probe on 2026-10-03, not used (per team notes; no Roboflow call in the product code). | | Old Pages-based rating site (`sailscan-rating`) | Deleted 2026-10-02. | | Custom camera module | Deleted 2026-08-16. Now uses Expo's camera. | ## Items I could not confirm - Which Cloudflare account owns the R2 bucket, the `sailscan-scanner` Pages project, and the clef login. - Whether the server reports errors to GlitchTip or Sentry (the setting value was not read). - Whether Amazon SES is actually used, and who owns the Resend account. - Expo/EAS account owner; push notification service in use. - Domain registrar and DNS host for sailscanapp.com. - Dollar costs for Railway, R2, RunPod serverless and email (not stated in repo). - Whether the ip-api.com call is the free tier.