The header linked 'Explore the docs' back to the repository itself and offered
Report Bug / Request Feature buttons pointing at issue templates that do not
exist, while the Streamlit interface — the one artefact a non-developer can
use — was never mentioned anywhere.
- Add a Try It Out section: the frontend Space, Swagger, and a curl against the
live API using the new examples/employee.json
- Surface KLEB38/OC_P5_Frontend_FUTURISYS, previously undocumented
- Drop the Best-README-Template leftovers: contributors/forks/stars/issues
badges on a solo project, and the dead issue-template links
- Supabase -> Neon across badges, architecture diagram and prose
- Point clone and project URLs at the current repository name
- Document the best-effort logging decision now that it is one
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
The deploy job had no event guard, so it also fired on pull_request runs. It
failed there by accident — checkout leaves a detached HEAD and the 'main'
refspec does not resolve — which is the only reason unreviewed code was never
shipped. Guard the event and push HEAD:main so the command no longer depends on
a local branch existing.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Merge pull request #1 from KL38/fix/resilient-logging
ALTER TABLE ... DROP CONSTRAINT was issued before to_sql() had created the
tables, so the script only ever worked on an instance that was already
populated. ALTER TABLE IF EXISTS makes the first run on a fresh database work.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Stop the log table from taking the whole API down
Every prediction route currently returns 500 when the database is unreachable,
because log_prediction() runs unguarded on the request path. The model is fine;
it is the audit trail that fails, and it drags the response down with it.
- log_prediction() is now best-effort: failures go to the application log and
the prediction is served regardless
- GET /predict/{id} genuinely needs the database (the employee record is its
input), so an outage there is reported as 503 with a message pointing at
POST /predict, instead of a bare 500
- insert_data.py read its three CSVs from hard-coded absolute paths that no
longer exist (the folder was renamed from "OC P4" to "OC_P4"); the directory
is now taken from P5_DATA_DIR, and a missing file fails with a clear message
instead of a traceback
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>