clinical-text-search-elk — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited clinical-text-search-elk (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
A pile of notes nobody can search has no value. This skill stands up a production-style search index for clinical text using the ELK/OpenSearch stack, tuned for medical language (synonyms, abbreviations, negation-aware filtering) and offering both keyword (BM25) and semantic (vector kNN) retrieval. It doubles as the retrieval layer for RAG and downstream NLP.
text fields with a custom analyzer; keyword fields forfacets (specialty, encounter_type, ICD-10); dense_vector for embeddings.
HTN ↔ hypertension), abbreviation expansion, and clinical stop-words.
sentence-transformer model) and fuse scores (RRF) for better recall on paraphrases.
from elasticsearch import Elasticsearch
es = Elasticsearch("http://localhost:9200")
es.indices.create(index="clinical_notes", body={
"settings": {"analysis": {
"filter": {"med_syn": {"type": "synonym", "synonyms": [
"mi, myocardial infarction", "htn, hypertension", "t2dm, type 2 diabetes"]}},
"analyzer": {"clinical": {"tokenizer": "standard",
"filter": ["lowercase", "med_syn"]}}}},
"mappings": {"properties": {
"note_text": {"type": "text", "analyzer": "clinical"},
"specialty": {"type": "keyword"},
"service_date": {"type": "date"},
"embedding": {"type": "dense_vector", "dims": 384, "index": True, "similarity": "cosine"}}}})
# Hybrid query: BM25 + kNN
es.search(index="clinical_notes", body={
"query": {"bool": {"must": {"match": {"note_text": "chest pain rule out MI"}},
"filter": {"term": {"specialty": "cardiology"}}}},
"knn": {"field": "embedding", "query_vector": qvec, "k": 10, "num_candidates": 100}})Measure retrieval with precision@k, recall@k, MRR, and nDCG against a labeled query set. A/B the synonym pack and the BM25-vs-hybrid configuration (use ab-testing-healthcare for the rollout). Monitor zero-result and long-tail queries in Kibana to grow the synonym list.
clinical_notes index + reusable mapping/analyzer JSON.synonyms.txt curated medical synonym/abbreviation pack.retrieval_eval.md P@k / nDCG by configuration.Tuned for clinical vocabulary and the operational reality of PHI access control and audit logging. Retrieval feeds clinical-text-summarization and RAG assistants; the same stack covers data-platform log search. Use OpenSearch as the Apache-2.0 drop-in where ELK licensing matters.
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.