Commit Graph

5 Commits

Author SHA1 Message Date
Claude 3902597418
Implement core backend in Go (item 2 of the build order)
Ports the Python prototype (backend/) to the actual chosen stack --
Gin + gorilla/websocket + GORM, same DB schema (models.go mirrors
backend/app/models.py), same endpoints (signup, message send,
WebSocket relay). backend/ stays as a reference prototype, not
removed.

Verified with go test: signup, duplicate-invite-code rejection (409),
404 on an unknown conversation, and WebSocket broadcast delivery all
pass -- the same cases the Python version was checked against.

Push notifications, AI service integration, and multi-device sync
are not in this commit -- see core-backend/README.md.
2026-07-30 01:42:48 +00:00
Claude 9a5358d0b1
Start Phase 1 backend skeleton (item 2 of the build order)
FastAPI app with invite-code signup, message send/relay over
WebSocket, and the DB schema from roadmap.md Phase 1 §2.1 (users,
contacts, conversations, messages, twin_settings, whitelist_rules,
escalation_logs). Defaults to SQLite for local dev, PostgreSQL in
prod per tech-design.md §8.

Verified end-to-end with TestClient: signup, duplicate-invite-code
rejection (409), message persistence, 404 on an unknown conversation,
and WebSocket broadcast delivery all behave as expected.

Push notifications and the AI pipeline integration (item 3) are not
in this commit -- see backend/README.md and roadmap.md's checklist.
2026-07-30 00:57:57 +00:00
Claude bb720f0178
Add rule-based escalation gate before any LLM call
escalation_filter.py implements tech-design.md §3's first step as an
actual hard gate, not just a system-prompt instruction: money,
appointment-confirmation, and emotional content stop generate_draft.py
before it ever calls Gemini. Self-test 10/10; measured a 0.93% trigger
rate against 82,305 real corpus utterances (mostly factual price
mentions, not personal money requests -- noted as an upper bound, not
a real-usage estimate).
2026-07-29 08:56:12 +00:00
Cursor Agent 3b9a4fcd76
Add root .env template for GEMINI_API_KEY
Provide .env.example, ignore local .env, and teach generate_draft.py to
load the repo-root .env so PoC #1 can use Gemini without exporting keys
in the shell every time.

Co-authored-by: okuma <o0kuma@users.noreply.github.com>
2026-07-29 08:37:29 +00:00
Claude 699ba68f49
Add PoC #1 base-corpus preprocessing pipeline
Consolidates the AI-Hub "한국어 SNS 멀티턴 대화" TL/VL zip parts into
clean train/val JSONL (142,575 dialogues), with a QA cross-check
against the raw TS/VS source. Script and docs only -- the dataset
itself stays out of git per .gitignore, both for size and because
AI-Hub's terms restrict redistribution.
2026-07-29 08:00:31 +00:00