--- title: NurseLex emoji: 🏛️ colorFrom: indigo colorTo: purple sdk: gradio sdk_version: "5.50.0" app_file: app.py pinned: true license: mit short_description: UK law for mental health & LD nurses tags: - nursing - legal - mental-health - nhs - uk-law - lex-api --- # 🏛️ NurseLex — UK Law for Nurses **Legal literacy for mental health & learning disability nurses** — powered by the **i.AI Lex API**, a custom UK Gov **[fine-tuned embedding model](https://huggingface.co/i-dot-ai/all-miniLM-L6-v2-UKPGA-6k-finetune)**, and Google Gemini Flash. ## What It Does NurseLex helps non-acute NHS nursing staff understand UK healthcare legislation by: 1. **Searching real UK legislation** via the i.AI Lex API (semantic search across millions of Acts and Statutory Instruments) 2. **Explaining the law in plain English** using Gemini Flash, tailored for mental health and learning disability nursing 3. **Citing the exact Act, section, and year** — zero hallucination, grounded in actual statutory text ## Key Legislation - Mental Health Act 1983 (Sections 2, 3, 5(4), 17, 117, 135, 136) - Mental Capacity Act 2005 (Capacity, Best Interests, DoLS) - Care Act 2014 (Safeguarding, Assessments, Advocacy) - Human Rights Act 1998 (Articles 5, 8) - Equality Act 2010 (Reasonable Adjustments) - Mental Health Units (Use of Force) Act 2018 - Autism Act 2009 ## Architecture ``` User Query → i.AI UKPGA Embedding Model (Semantic Search) → Local Statutory Cache → Gemini Flash → Plain English + Citations ``` All legislation data comes from the **[i.AI Lex](https://lex.lab.i.ai.gov.uk/)** bulk datasets (Crown Copyright, Open Government Licence v3.0). Semantic search capabilities are powered locally using the `i-dot-ai/all-miniLM-L6-v2-UKPGA-6k-finetune` sentence transformer, specifically trained on UK Public General Acts. ## Built By **NurseCitizenDeveloper** — NHS Registered Nurse (Learning Disabilities) building open-source AI tools for nursing. - 🌐 [AI Educator Toolkit](https://clinical-quality-intelligence.github.io/nursing-ai-toolkit/) - 🤗 [Hugging Face](https://huggingface.co/NurseCitizenDeveloper) ======= --- title: NurseLex emoji: 🏛️ colorFrom: indigo colorTo: purple sdk: gradio sdk_version: "5.50.0" app_file: app.py pinned: true license: mit short_description: UK law for mental health & LD nurses tags: - nursing - legal - mental-health - nhs - uk-law - lex-api --- # 🏛️ NurseLex — UK Law for Nurses **Legal literacy for mental health & learning disability nurses** — powered by the [i.AI Lex API](https://lex.lab.i.ai.gov.uk/) and Google Gemini Flash. ## What It Does NurseLex helps non-acute NHS nursing staff understand UK healthcare legislation by: 1. **Searching real UK legislation** via the i.AI Lex API (semantic search across millions of Acts and Statutory Instruments) 2. **Explaining the law in plain English** using Gemini Flash, tailored for mental health and learning disability nursing 3. **Citing the exact Act, section, and year** — zero hallucination, grounded in actual statutory text ## Key Legislation - Mental Health Act 1983 (Sections 2, 3, 5(4), 17, 117, 135, 136) - Mental Capacity Act 2005 (Capacity, Best Interests, DoLS) - Care Act 2014 (Safeguarding, Assessments, Advocacy) - Human Rights Act 1998 (Articles 5, 8) - Equality Act 2010 (Reasonable Adjustments) - Mental Health Units (Use of Force) Act 2018 - Autism Act 2009 ## Architecture ``` User Question → Lex API (semantic search) → Statutory Text → Gemini Flash → Plain English + Citations ``` ## Data Source All legislation data comes from the **[i.AI Lex API](https://lex.lab.i.ai.gov.uk/)** — an official UK Government service. Crown Copyright, Open Government Licence v3.0. ## Built By **NurseCitizenDeveloper** — NHS Registered Nurse (Learning Disabilities) building open-source AI tools for nursing. - 🌐 [AI Educator Toolkit](https://clinical-quality-intelligence.github.io/nursing-ai-toolkit/) - 🤗 [Hugging Face](https://huggingface.co/NurseCitizenDeveloper) >>>>>>> a4e257b16d56f80612b7c9ac6d2e7c198fef5bb6