No description
| server_app | ||
| skills/mental-health-advisor | ||
| .dockerignore | ||
| .gitignore | ||
| AGENTS.md | ||
| Dockerfile | ||
| entrypoint.sh | ||
| launch_mh.sh | ||
| launch_voice.sh | ||
| opencode.jsonc | ||
| readme.md | ||
| run.sh | ||
| voice_chat.py | ||
Mental Health Research Advisor
OpenCode session:
ses_09535ec94ffe4rTjXnPNCrMRjUResume:opencode --session ses_09535ec94ffe4rTjXnPNCrMRjU
An opencode-powered mental health research assistant for laypeople in Japan. Helps find and evaluate mental health evidence without the TikTok pop-psychology, Instagram therapy advice, or AI-generated misinformation of generic web search.
This is NOT a substitute for a mental health professional. It is a research librarian.
Voice Server (Containerized)
cd /src/llm_mentalhealth
OPENROUTER_API_KEY=sk-or-v1-... DEEPSEEK_API_KEY=sk-7e31... ./run.sh up
# Access: http://localhost:8010 (or Tailscale IP http://100.93.132.70:8010)
Quick Start
cd /src/llm_mentalhealth && ./launch_mh.sh
Then ask anything about mental health. The mental-health-advisor skill auto-loads.
What It Does
| You ask | You get |
|---|---|
| "Does CBT work for depression?" | Systematic review with PMIDs, effect sizes in plain language, NNT |
| "Is my antidepressant available in Japan?" | PMDA approval check, NHI coverage, Japan-specific dosing |
| "ADHDの治療法は?" | Evidence-graded treatment review, JSPN guidelines, Japan drug formulary |
| "Is microdosing psilocybin effective?" | Honest assessment of evidence quality (early-stage, small samples) |
| "What helps with hikikomori?" | Japan-specific context, cultural factors, evidence-limited but framework provided |
Architecture
User query
│
├─ 1. KB search (DSM-5-TR, WHO mhGAP, Cochrane MH, NICE MH, Japan MH system)
│ └─ Ground-truth frameworks before any literature search
│
├─ 2. PubMed (search → fetch articles → fulltext → related articles)
│ └─ Primary biomedical evidence, MeSH-indexed, graded
│
├─ 3. Web search (domain-whitelisted only)
│ ├─ International: nimh.nih.gov, psychiatry.org, nice.org.uk, ...
│ └─ Japan: mhlw.go.jp, ncnp.go.jp, jspn.or.jp, ...
│
└─ Output: disclaimer (+ crisis resources) → PICO → evidence summary → Japan context → plain language
No TikTok. No Instagram therapy influencers. No "Big Pharma hiding the cure." No AI therapy app marketing.
Japan-Specific Coverage
- PMDA psychiatric drug approval status (Japan's formulary differs significantly)
- JSPN clinical practice guidelines (Japanese equivalent of APA/NICE)
- NHI coverage for psychiatric care and medications
- Pharmacogenomics — CYP2D6*10, CYP2C19 variants in Japanese populations affect psychiatric medication
- Cultural context — hikikomori, taijin kyofusho, karoshi/karojisatsu, mental health stigma
- Care pathways — hokensho, mental clinics, university hospital psychiatry, designated mental health physicians
- Japanese dosing — often substantially lower than Western dosing for psychiatric medications
Evidence Grading
| Tier | Type | Example |
|---|---|---|
| S | Cochrane/NICE/WHO mhGAP/APA guideline | Gold standard |
| A | Systematic review & meta-analysis | Pooled RCT analysis |
| B | Large multi-site RCT (n>200, pre-registered) | Active comparator preferred |
| C | Cohort/case-control, open-label | Correlation ≠ causation |
| D | Case series, expert opinion | Hypothesis only |
| E | Pre-prints, animal models | Not peer-reviewed |
| F | TikTok, Instagram, influencer claims | Noise |
Every response gets a grade.
Files
/src/llm_mentalhealth/
launch_mh.sh — one-command launcher
opencode.jsonc — project config
AGENTS.md — project instructions (loaded by opencode)
readme.md — this file
~/.config/opencode/skills/mental-health-advisor/
SKILL.md — the skill (auto-loads on mental health keywords)
~/content-repo/books/mental-health-reference/
dsm5-tr-criteria.md — key diagnostic frameworks
who-mhgap-guide.md — WHO Mental Health Gap Action Programme
cochrane-mental-health.md — systematic review methods for MH
nice-mh-guidelines.md — UK evidence-based guidelines (widely referenced)
japan-mental-health-system.md — care pathways, law, culture
mental-health-quick-reference.md — consolidated quick-reference
Requirements
opencodebinary- PubMed MCP (remote, already in global config)
- Tavily MCP (remote, already in global config)
kb-mcp-server(local,CONTENT_REPO=~/content-repo)
Run ./launch_mh.sh --check to verify without launching.
Crisis Resources (Japan)
If you or someone you know is in crisis:
| Resource | Contact | Language |
|---|---|---|
| Tokyo English Lifeline (TELL) | 03-5774-0992 | English |
| Inochi no Denwa | 0120-783-556 | Japanese |
| Yorisoi Hotline | 0120-279-338 | Japanese / foreign languages |
| Emergency | 119 | — |