In short. Doktor MCP classifies physicians' questions on informed consent, patient rights, medical records, confidentiality and the duty of care; it retrieves the relevant legislation from mevzuat.gov.tr and the decisions from the official search systems of the Court of Cassation and the Council of State. Only decisions with legal reasoning that can be linked to the facts make it into the pack. The result is an information pack with points for a lawyer to review; it is not a legal opinion.
- What
- MCP serverModel Context Protocol: an open standard for connecting AI assistants to external tools and data sources
- For
- Physicians and healthcare institutionsA preliminary research tool for lawyers working in health law
- Sources
- mevzuat.gov.tr, Court of Cassation, Council of StateLive official sources; no blogs, news or forums
- Status
- BetaNot a public service
- Source code
- github.com/afsozer/doktor-mcpOpen source, AGPL-3.0 license
- Package
- npmjs.com/package/doktor-mcpRuns with npx, no install needed
Why I built it
Physicians' legal questions tend to cluster around the same few topics: how much information the patient must be given, how consent should be obtained, whether a complication counts as fault, who may see the patient file. The answers lie in specific statutory provisions and high court decisions; but they often reach physicians through writing, news and forums whose sources are unclear.
Doktor MCP makes the AI assistant answer these questions with official texts only. When the assistant relies on a provision, it quotes it verbatim; when it relies on a decision, it shows the decision's citation, reasoning and outcome.
Which topics does it cover?
- Informed consent and medical intervention
- Patient rights
- Patient confidentiality and personal health data
- Records, patient files and discharge summaries
- Emergency intervention, referral and consultation
- The physician's duty of care
- Professional ethics
Health-specific legislation comes first: the Regulation on Patient Rights, the Regulation on Medical Deontology, the Law on the Practice of Medicine and Its Branches (Law No. 1219) and the Basic Law on Health Services. General rules such as the Personal Data Protection Law (KVKK) come after them as supporting sources; for example, in a patient confidentiality question the Regulation on Patient Rights is ranked before KVKK.
What is in the information pack?
- Short answer. Grounded in the sources, in conditional language.
- Legal classification. Which of these areas the question touches: criminal, compensation, disciplinary and administrative proceedings, patient rights, confidentiality and KVKK, professional ethics.
- Relevant legislation. The name of the legislation, the article number, a verbatim quotation of the provision and its link to the facts.
- Verified high court decisions. Court and chamber, date, docket and decision numbers; a summary of the facts, the legal assessment and the outcome; how the case resembles and differs from the question.
- Missing information. What needs to be learned from the physician for an assessment.
- Points for a lawyer to review.
Every legislative entry in the pack carries its document identifier in the official source and a verbatim quotation. The assistant can open a single article or decision separately without rebuilding the pack.
Which decisions go into the pack?
Finding a decision does not make it a precedent. Every decision is placed in one of five categories, and only the first goes into the pack:
- Usable as precedent: full text available, legal reasoning present, a link to the facts can be made.
- Limited value: full text available, but a weak link to the facts.
- Procedural only: no reasoning on the merits; a bare affirmation or a bare reversal.
- Citation only: the full text could not be retrieved.
- No reasoning: full text available, but it contains no legal reasoning.
Decisions left out are recorded in a separate diagnostics section together with the reasons for exclusion, so it is visible why they were not used.
Red lines
- No categorical verdict such as “there is liability” or “there is no liability”. The assessment is made in conditional language, such as “the sources point in this direction”, and with the source shown.
- No risk score (“high risk”, “low risk”) without a source.
- No instructions for urgent action; the physician is not told what to do.
- No petitions or defence submissions.
- A legal proposition that cannot be verified in an official source and rests only on the model's knowledge does not go into the pack. If a source cannot be retrieved, the pack says so plainly; the gap is not filled with a guess.
- A provision is never assumed to be “in force”; its status and last amendment date are carried separately.
- A response produced from test data is clearly marked, so that it is not mistaken for real legislation.
Where does it get its sources?
Legislation comes live from the Presidency's Legislation Information System (mevzuat.gov.tr), Court of Cassation decisions from Bedesten, the Ministry of Justice's decision search system, and Council of State decisions from the Council of State's own decision search. Because the Constitutional Court's decision database has no machine-readable interface, Constitutional Court decisions are not yet connected as a live source.
General web writing, blogs, news, forums and law firms' promotional pages are not used as sources; the articles on this site included.
Doktor MCP works independently of Emsal MCP: instead of a local corpus, it goes directly to live official sources.
What it does not do
- It gives no legal opinion. The pack is information; assessing the specific case is for the lawyer who reviews the file.
- It makes no medical assessment. It shows which legal rules an intervention is subject to, not whether it was medically correct.
- It does not yet search Constitutional Court decisions live.
- It is not a public service. It has no interface opened for direct use by physicians.
Technical details
- Language
- TypeScript, Node.jsMCP server
- Tools
- 8 MCP toolsQuestion classification, health legislation search, article retrieval, decision search, reasoned decision filter, information pack, opening a single pack item, full decision text
- Source layer
- Requests with bounded retries and backoffThe source's “retry later” signal is respected; copies of the same decision arriving from different sources are de-duplicated
- Tests
- VitestSeparate tests for source-safety rules, non-fabrication of decisions and malicious input
- Development
- Design and product decisions are mineCoding done with AI-assisted tools (Claude Code)
Installation
Doktor MCP is published on npm as the doktor-mcp package and requires Node.js 20 or later. By default it queries the official sources live. To add it to Claude Code:
claude mcp add doktor -- npx -y doktor-mcp
In Claude Desktop or another MCP client, setting the command to npx and the arguments to -y doktor-mcp is enough.
Source code
The source code is open on GitHub under the GNU Affero General Public License, version 3 (AGPL-3.0). You may use, modify and distribute it; if you offer a modified version to others over a network, you must make your modified source code available to them under the same license. Security vulnerabilities can be reported privately as described in the repository's SECURITY.md file.
This page describes version 0.59.0 as of 7 October 2026.