Free and open source · Any model, cloud or local

Your medical research team,
on your desktop

A lead agent and four specialists (pharmacist, clinical research, evidence synthesis and genetics) search PubMed, trial registries and genetic databases, quote what the sources report, and write cited answers or full papers. No account, no analytics.

Watch the 2-minute film

Version 1.3.0 · free and open source · Apple Silicon, with Windows and Linux built from source

Tauri v2 React 18 Rust Backend TypeScript Strict Ollama Support

In medical research, two things matter more than anything else: where your data goes and whether you can trust the source.

HashCerebrum is built around both.

Built on HashCortX by Seif Hashish

The film

See it in action

Two minutes of the real app: a clinical question goes in, specialists search the literature, and the answer comes back as a typeset paper with every claim cited. Then the memory it builds on your own computer, and how it learns over time.

2:04
It plays right here, and nothing from YouTube loads until you press play.

One Mega-Mind

Ask Anything, One Mind

Brain classifies every request and routes it internally — a chat, a quick cited lookup, a memory recall, an evidence review, a full manuscript, a graded drug-interaction check, or a gene–disease association report — no tab to pick. Force a focus with a slash command (/paper, /genetics, /interactions or /drugs, /search, /rag, /mini, /deep) or let the classifier decide.

⌘1 Brain

The Mega-Mind Workspace

Team chat alongside a live 3D brain (or a 2D pipeline view in Lite mode). Handles chat, lookups, memory recall, evidence reviews, full papers, drug-interaction grading, and genetics scoring — all from one composer. Toggles: Memory, Library, Smart RAG, and Brain Mini for free / small models.

⌘2 Memory

Semantic Knowledge Store

Cited findings searched by meaning, plotted on a real labelled 3-axis (PC1/PC2/PC3) vector map with k-means clusters. Import your own PDFs into it, and a Project / Library scope toggle browses the whole cross-project corpus. One-click Prune.

⌘3 Peer Review

Upload & Critique

Upload any PDF or send a Brain manuscript to a 4-agent critique swarm with a live document editor — resilient on free-tier rate limits and always returns at least a partial review. Export the review as PDF or Markdown.

/interactions Intent

Clinical-Pharmacy Checker

Grades each drug pair A–X (none → contraindicated) with mechanism, effect, and management. Biases toward the more serious grade when evidence is thin. Verifies every drug against RxNorm and treats drug-label (openFDA) records as authoritative.

/genetics Intent

Gene-Expert Checker

Enter a gene variant and a disease to get an association-confidence score — computed in code, never by the model — plus a cited correlation report from GWAS Catalog, ClinVar and literature (queried by gene symbol / rsID). Clarifies the query first if a gene or disease is missing. Gene-agnostic; runs keyless and on local models.

The Swarm

Five Agents, Mapped to Brain Regions

A lead agent and four specialists, each bound to a region of a live 3D anatomical brain. As the team works, those regions light up, so you can watch the research happen. Each agent can run on its own model, picked from the model menu in the title bar. A toolbar toggle swaps the 3D brain for a 2D pipeline view whose steps match the task (lookup, paper, drug-interaction or genetics check); Lite mode uses it automatically on low-end hardware, with no loss of research features.

Agent Brain Region Domain
Lead agent (HashCerebrum) Frontal lobe Plans the question, picks the specialists, writes the cited answer
Evidence Synthesis Hippocampus PubMed · Europe PMC · OpenAlex · Semantic Scholar · Crossref — literature reviews, epidemiology, prevention, plus DOI citation & journal enrichment
Clinical Research Parietal lobe ClinicalTrials.gov — cohorts, trial outcomes, statistics, effect sizes
Pharmacist Basal ganglia RxNorm · openFDA — drugs, dosing, adverse effects, and drug pairs graded A to X by the interaction checker
Genetics Cerebellum GWAS Catalog · ClinVar · HGNC — gene–disease associations, scored 0 to 100 by the gene checker

Features

Built for Real Research

Every feature is grounded in the actual workflow of medical research — from evidence retrieval to manuscript compilation to peer review.

01

Hallucination-Gated Paper Pipeline

The model is not allowed to write a claim it cannot prove. Every research turn queries PubMed, Europe PMC, OpenAlex, ClinicalTrials.gov, openFDA, RxNorm, Semantic Scholar, Crossref and — for genetics — GWAS Catalog and ClinVar in parallel. Retrieved records are extracted into a structured evidence table with study design, population, outcomes, and effect values.

02

Claim Ledger & Validation Gate

A claim ledger maps each finding to a source marker [S#] and grades its evidence strength. The manuscript compiler writes from approved ledger entries only. A validation gate flags any unresolved citation, unsupported statistic, or thin section, and a deterministic honesty pass strips fabricated appraisals, statistically impossible results, and invented record counts before export — the document is sanitized, never silently withheld.

03

4-Agent Peer Review Swarm

Orchestrator (score 1–10, methodology, conclusions), Originality (unsupported claims, attribution gaps), Vocabulary (precision improvements), and Statistics (reporting completeness, power analysis). Export the finished review to PDF or Markdown.

04

Live Document Editor

After review, Fix Problems opens a contenteditable document editor. Each agent's suggestions are mapped back to exact passages with colour-coded marks. Every suggestion shows a before/after diff with Accept, Skip, and Get Fix buttons. Every accepted change is undoable.

05

On-Device Semantic Memory

A bundled MedEmbed-small model (Apache-2.0) runs entirely on-device in a Web Worker. Retrieval is semantic (vector similarity) fused with lexical search via Reciprocal Rank Fusion. A real 3-axis PCA vector map with genuine k-means clusters visualises your knowledge.

06

22 Providers and Ollama, Your Choice per Agent

Pick each agent's model from the model menu in the title bar. Failover hands a failing call to the next provider so one key is never burned into rate limits. Among them: OpenAI, Anthropic, Google Gemini, Groq, OpenRouter, Mistral, DeepSeek, Moonshot, Cerebras, SambaNova, NVIDIA, MiniMax, xAI, Together AI, Fireworks AI, DeepInfra, and Ollama (local).

07

Provenance You Can Verify

Every privileged action — each outbound request, every database contacted, every model call — is appended to a tamper-evident, hash-chained audit log, stored in plain text on your machine and readable from Settings. It's a receipt for every answer: see exactly which sources produced a result, and one-click Verify proves the chain was never altered.

08

Safety Guardrails

Unsafe requests are stopped before they reach the swarm. Self-harm questions get a compassionate crisis response, not a dose; requests to harm people or critical infrastructure are refused even when reframed as a "drill". Jailbreaks, prompt-injection hidden in pasted evidence, and attempts to extract the model or system prompt are caught at the gate.

09

Runs on Any Machine

Eight themes including a light Parchment reading mode with carefully tuned contrast, and a no-GPU Lite mode that swaps the 3D brain for a lightweight 2D pipeline view — full speed on low-RAM or GPU-less hardware, with auto-detection. Every research feature stays intact.

The Process

Every Answer, Step by Step

A research turn is a disciplined pipeline, not a single prompt. The lead agent routes your question, specialists retrieve source-grounded evidence, claims are graded, the manuscript is written from approved entries only, and a validation gate checks every citation before anything is exported.

Research pipeline Route & plan
  1. Route & plandecompose the question into sub-queries Queued
  2. Retrieve evidencequery PubMed, Europe PMC, ClinicalTrials.gov… Queued
  3. Extract & grade claimsbuild the claim ledger with [S#] markers Queued
  4. Draft manuscriptwrite cited sections from approved claims Queued
  5. QA & validatecheck citations, statistics, and depth Queued
  6. Finaliseexport-ready, source-grounded paper Queued
0% source-grounded & validated

Agentic Learning Memory

A RAG That Actually Learns

Most retrieval is stateless — it forgets every search. HashCerebrum's memory closes the loop: every run teaches it, and what it learns reshapes the next answer. The learning is fully deterministic, stays on your machine, and works the same with a local Ollama model or any cloud model.

Runs fully local·Deterministic·Any model
self-learning memory · what it learns feeds the next run 1 Retrieve 10 trusted sources 2 Learn beliefs · reliability · graph 3 Re-rank learned priors 4 Recall what it believes 5 Study fills its own gaps what it learns feeds the next run 1 Retrieve 10 trusted sources 2 Learn beliefs · reliability · graph 3 Re-rank learned priors 4 Recall what it believes 5 Study fills its own gaps
01

Learned-prior ranking

Source reliability, corroborated beliefs, and knowledge-graph centrality re-weight every future retrieval. The more it researches a topic, the sharper it ranks the evidence.

02

Autonomous study

Between runs it drains its own gap queue — quietly fetching trusted literature for the concepts it couldn't cover — so the next question on that topic finds it already prepared.

03

Recalled beliefs

Before answering, it tells the model what memory already holds — and flags what is contested — so it corroborates or challenges prior conclusions instead of starting from a blank slate.

04

Learns from you

Pruning a finding teaches it: the source and the beliefs it supported are demoted; undoing reinforces them. Your curation is the reward signal — human-in-the-loop, on your machine.

05

Consensus over time

It buckets the evidence by year and narrates how the consensus shifted — "positive in 2014, reversed by 2022" — something a stateless retriever can never tell you.

06

Structured-field retrieval

Effect sizes are read from labelled Results sections and ClinicalTrials.gov posted results — each hazard ratio bound to its own CI, p-value, and outcome, never scraped from prose or recombined across studies.

Privacy

Your Data Stays Yours

HashCerebrum is a single-user desktop app with no server component. The web layer is sandboxed and physically cannot reach the internet; only the Rust core can, and only to a fixed, audited allowlist of destinations.

Data Storage Location External Transfer
Projects, chat history, saved findings (memory) Local app storage on your device Never
Retrieved-evidence cache, audit log Local SQLite in the app data dir Never
Provider API keys The app's own data folder on your device, protected by your user account. Not encrypted at rest Never logged or cached
Generated papers / PDFs Saved to the folder you choose in the native save dialog Only if you export them
Your question + retrieved evidence Sent only to the one LLM provider you configure Yes — to that provider, unless you use a local model
No telemetry, no accounts, no tracking. There is no analytics SDK, no crash reporter, no update check, no sign-up, and no cloud sync anywhere in the codebase. Point it at a local Ollama model and the app makes zero external calls at all — including the three small models that search, re-rank and fact-check.

Security

Guarded by Rust

The renderer never makes an outbound HTTP request. Every call — medical databases and LLM providers alike — is a Tauri IPC call into Rust, then runs through a layered guard.

Renderer  ─IPC─▶  security::guard::check()
                  ├── denylist  (cloud-metadata, RFC1918, link-local + ULA IPv6)
                  ├── allowlist (ALLOWED_HOSTS — 36 approved hosts + loopback)
                  ├── rate limiter (per-host token bucket)
                  └── audit log (hash-chained, SQLite, verifiable)
                ─────▶  reqwest  ─────▶  external host
Renderer ─IPC─▶ guard::check()
 ├─ denylist
 │    cloud-metadata, RFC1918,
 │    link-local + ULA IPv6
 ├─ allowlist
 │    36 approved hosts + loopback
 ├─ rate limiter
 │    per-host token bucket
 └─ audit log
      hash-chained, SQLite, verifiable
 ──▶ reqwest ──▶ external host
Defense in Depth
CSP Shield
Renderer locked down. connect-src 'self' blob: blocks all direct outbound HTTP.
Tauri IPC Bridge
Every network call is a typed command. No raw fetch from the frontend.
security::guard
Rust-side gatekeeper. Parses host as IP, validates against RFC1918 & cloud metadata denylist.
Network Filter
Allowlist of 36 approved hosts + loopback. Redirects are not followed, and names are resolved by the guard so a listed name cannot point at a private address.
Audit & Rate Limit
Per-host token bucket + SHA-256 hash-chained log. Tamper with one entry, break the chain.
Request Gate
Renderer IPC Call
denylist::is_blocked?
Block
cloud-metadata · RFC1918 · link-local
policy::host_allowed?
Block
36 hosts + loopback only
localhost port check
11434 for Ollama; LAN ok for ollama provider only
ratelimit::acquire
per-host token bucket — PubMed 3/s · OpenAlex 10/s
audit::append
hash-chained SQLite entry before reqwest fires
reqwest → external host
Guarantee Implementation
No renderer-to-internet HTTP CSP connect-src 'self' blob: — all external calls are Tauri commands
SSRF protection Hosts parsed as IP addresses and matched against real RFC1918 / CGNAT / IPv6-ULA ranges + cloud-metadata denylist
Bounded response bodies Streaming 50 MB cap — replies without Content-Length cannot exhaust memory
LLM header injection prevention Rust-side allowlist — only accept, content-type, authorization, x-api-key, x-goog-api-key, http-referer, x-title, anthropic-*, openai-*
Tamper-evident audit trail SHA-256 hash chain; each entry commits seq ‖ prev_hash ‖ ts ‖ category ‖ subject ‖ action ‖ data_hash
API keys never logged Headers forwarded to reqwest, never written to audit log or cache; URL userinfo stripped
Path traversal + TOCTOU symlink_metadata → canonicalize → same_file check; hardlinks rejected
PDF magic-byte validation %PDF header check before lopdf parser is invoked

Tech Stack

Engineered for Performance

1,269 Vitest unit tests. 85 cargo tests. Strict TypeScript with noUncheckedIndexedAccess. Every layer is typed, tested, and compile-time constrained.

Desktop Shell

Tauri v2 — Rust core with WebKit frontend. Native performance, native security.

Rust WebKit Tauri v2

Rust Backend

Async networking, SQLite persistence, PDF generation, and embedded Typst typesetting — all in-process.

tokio reqwest rusqlite lopdf typst

Frontend

Vite 8 · React 18 · TypeScript 5 with strict mode and noUncheckedIndexedAccess.

Vite React 18 TypeScript

3D Workspace

React Three Fiber with post-processing effects for the live anatomical brain model.

R3F three.js drei

PDF Typesetting

Embedded Typst engine runs fully offline in-process — no sidecar, no network, no font downloads. Fallback to jsPDF with embedded DejaVu Unicode.

Typst typst-assets jsPDF DejaVu

Embeddings

MedEmbed-small runs entirely on-device via transformers.js (ONNX/WASM) in a Web Worker. Nothing is downloaded at runtime. No text leaves the machine.

ONNX WASM MedEmbed Web Worker

Testing

Determinism where it matters. Every decision that has to be trustworthy — how a citation is renumbered, when a fabricated statistic is stripped, which intent a request maps to, whether a host may reach the network — is a pure function with a unit test, not a behaviour left to the model. That is what lets the app enforce "no invented facts". Two surfaces: fast TypeScript tests over the pipeline & safety logic, and Rust tests over the guarded network / security / storage core — and every push must pass all of them.

Frontend VITEST · UNIT 1,269 Swarm & pipeline intent routing · claim ledger · export gate Citation integrity renumber [S#]→[n] · drop dangling Honesty guard fabricated stats · overclaim · CI↔p Backend CARGO · RUST 85 Security guard host allowlist · SSRF denylist Network core capped reads · per-host rate limiter Storage & provenance key store · SQLite · hash-chained audit CI · every push must pass
1,269Vitest Unit Tests
85Cargo Tests
5Strict TS Config
0Telemetry

The Architect

SH

Dr. Seif Hashish

Founder & Chief Architect

A clinical pharmacist and AI expert, Dr. Seif Hashish sits at the rare intersection of biomedical science and deep-learning research.

NGU University — Class of 2025 Clinical Pharmacy

Also by the Architect

Part of a Local-First Family

Three apps from Dr. Seif Hashish, one principle — your data never leaves your machine. HashCerebrum is built on the HashCortX core, and its usage is measured, honestly, by HashMeterAi.

Download

Version 1.3.0,
free and open source

Download the disk image, open it, and drag HashCerebrum to Applications. The build carries no paid signing certificate, so macOS refuses it the first time: right-click the app, choose Open, then Open again. If it still refuses, run this once in Terminal and then open it normally.

xattr -dr com.apple.quarantine /Applications/HashCerebrum.app

Windows and Linux are built from source with Node and Rust; the steps are in the README. Every release is published with the checksum of its disk image, so you can prove your copy is the one that was published.

Open Source

Free, Open, and
Always Private

HashCerebrum is licensed under AGPL-3.0. The source is open, the architecture is documented, and the audit log is yours to read. Build it yourself, audit it yourself, run it yourself.

Terms of Use

Not a Medical Device

For research and education only. Not a medical device, no FDA/EMA approval, not intended to diagnose, treat, or prevent any condition. Not for users under 18. By using this software you represent that you are of legal age and have sufficient training to evaluate its outputs. LLMs can hallucinate — always verify independently.

Consult a Professional

Never disregard professional medical advice or delay seeking it because of something you read or generated here. Always consult your physician, pharmacist, or qualified healthcare provider for questions about a medical condition, medication, or treatment.

No Warranties

Provided "as is" without warranties of any kind. As open-source software it has not undergone professional clinical validation or heavy-load testing. Authors have no obligation to provide updates, support, or bug fixes. You are responsible for your own data backups.

No Liability

To the fullest extent permitted by law, the authors are not liable for damages, wrong results, data-privacy issues, or data loss arising from your use. You agree to indemnify the authors from any claims arising from your use, modification, or distribution of the software.

Data & Third Parties

HashCerebrum is software, not a HIPAA-covered entity or GDPR controller. Your data stays on your device; you are responsible for its security. Retrieved evidence comes from public databases and LLM providers — we do not control, guarantee, or endorse their accuracy. References to drugs or treatments do not constitute endorsement.

License

Licensed under GNU AGPL-3.0-or-later. You may use, modify, and distribute the software under those terms. You are responsible for any modifications you make. Third-party trademarks belong to their owners. Your generated manuscripts remain your intellectual property.

By using HashCerebrum, you acknowledge these terms. If you do not agree, please do not use the software.