6 ms·
Show HN: GlycemicGPT – Open-source AI-powered diabetes management
I'm a Type 1 diabetic and software engineer. Last year I went months between endocrinologists with no clinician reviewing my data. I'm an engineer, so I built the tool I needed — and now I'm open sourcing it.
GlycemicGPT is a self-hosted platform that connects continuous glucose monitors, insulin pumps, and existing Nightscout instances to an AI analysis layer running on your own infrastructure.
Data sources:
Dexcom G7 (cloud API)
Tandem t:slim X2 and Mobi pumps (direct BLE)
Nightscout (point it at your existing instance and you're running in minutes)
What the AI layer does:
Daily briefs summarizing overnight and 24-hour patterns
Meal response analysis
Conversational chat with RAG-backed clinical knowledge
Predictive alerting with configurable thresholds and caregiver escalation
Important: this is monitoring and analysis only. GlycemicGPT does not deliver insulin, does not control your pump, and is not a closed-loop system. It reads your data and gives you insight on top of it. Your clinical decisions stay between you and your care team.
Architecture:
Self-hosted via Docker or K8S — the GlycemicGPT stack runs entirely on your hardware
BYOAI — bring your own AI provider. Use Ollama for fully local operation (no data leaves your hardware), or point it at Claude, OpenAI, or any OpenAI-compatible endpoint if you prefer a hosted model. Data flows directly from your instance to the provider you choose; nothing is routed through any centralized service operated by the project.
GPL-3.0, no subscriptions, no vendor lock-in
Stack:
Backend API: FastAPI, Python 3.12, PostgreSQL 16, Redis 7
Web Dashboard: Next.js 15, React 19, Tailwind CSS, shadcn/ui
AI Sidecar: TypeScript, Express, multi-provider proxy
Android App: Kotlin, Jetpack Compose, BLE
Wear OS: Kotlin, Wear Compose, Watch Face Push API
Plugin SDK: Kotlin interfaces, capability-based, sandboxed
Looking for contributors — especially folks with BLE/Android experience or anyone in the diabetes tech space. Plugin SDK is documented if you want to add support for new devices.
GitHub: https://github.com/GlycemicGPT/GlycemicGPT https://github.com/GlycemicGPT/GlycemicGPT
- fnands 5mo agoThe alerts system and sharing with caregivers is a solved problem already (e.g. Dexcom's Follow, Abbot's LibreLinkUp). Do you find the analytics actually helps? I.e. a lot of this will depend on what you ate and whether or not you logged it?
- surgicalcoder 5mo agoI'm a T1D who has an insulin pump looping with AndroidAPS and NightScout, what does this give you that Nightscout and Autotune doesn't give you? And how do you deal with AI hallucinations?
- pimeys 5mo agoI think the only thing that could be made better is tuning the I:C/ISF/Basal values automatically. And ISF is already handled by DynamicISF, while not perfect it reduces the variables you have to tweak. Otherwise, when tuned correctly, oref1 et.al. provide amazing results and are safe. Hard to understand where I would use LLMs in this.
- surgicalcoder 5mo agoYou sort of have that - not automatically though, but you can run autotune against nightscout and get a report of where things need to be adjusted. I run oref1 with DyanmicISF, and just run autotune every few months just to tweak values. I genuinely don't see where I would use an LLM in this process.
- pimeys 5mo agoI agree. For us, who are really good with software and all that, AndroidAPS is really good when you can easily learn how to use it. Not that great for non-technical people. But it saved my life at least. Edit: thanks for reminding me about Autotune. I used the azure app ages ago, but it's now integrated in AndroidAPS behind a secret setting.
- ingridstanquini 5mo ago[flagged]
- jlengelbrecht 5mo ago[flagged]
- jlengelbrecht 5mo ago
- xyzal 5mo agoThis is THE ONE domain where you would want to use classical machine learning and not unreliable LLMs. Unless you want to kill yourself, that is.
- stingraycharles 5mo agoYes, language has nothing to do with it and is complete overkill. Probably something like SVM for warnings. Unless the whole purpose is just daily reports.
- axegon_ 5mo ago"This will all end in tears, I just know it" Marvin
- mhovd 5mo agoThe risk to benefits ratio of introducing a language model to interpret so clear signals is nowhere near justified. Monitoring and analytics is important, but it is a solved problem. A language model will only be able to hallucinate about the relationship between meals and glycemic response. At best it does no harm, at worst it can directly misinform.
- pimeys 5mo agoYep. The oref1 algorithm is amazing and proven to make diabetic's quality of life better, AND SAFE. I don't understand why would you need to add AI to that mix. But I will check this algo out. Maybe it has some interesting bits.
- AnthonBerg 5mo agoMy experience is completely the opposite, of using LLMs to pattern match and cast diagnostic nets. Is your perspective based on, say, opinionated principle?, or experience? The benefits are enormous. The risks; What risks? No diabetic with baseline adult competence is going to drive their insulin-delivery vehicle off a cliff because some app said so.
- pferde 5mo agoI think you're being too optimistic about your fellow humans' judgement. "Death by GPS" is a quite common occurrence: https://www.sciencedirect.com/science/article/abs/pii/S135503062300028X https://www.sciencedirect.com/science/article/abs/pii/S13550...
- AnthonBerg 5mo agoType 1 diabetes with the sensors and pump technology that this software being presented here fits to is not Everyman Joe stuff. Someone who can set this up and get this going is already burdened with the kind of analysis that the app can assist with.
- pu_pe 5mo agoRisks: Changing parameters on the insulin pump because the LLM said so Neglecting to seek actual medical advice believing a LLM replaces it Misunderstanding medical complexity (ie a prescription due to medical history not available to the LLM)
- tornadofart 5mo agoI'm a T1D and tbh it's not that hard to manage, I just wouldn't need that. But for kids or the elderly, I see a use case. The hardest to learn was that an unhealthy lifestyle resulted in a diabetes that was harder to manage. Too much carbs, not enough exercise, etc. After adjusting my lifestyle, it became quite easy. The most pain, in my experience, comes from the discrepancy between the CGM - measured value and the prick-test value, even when accounting for time lag. I've used several CGMs and they've all been wildly off sometimes. I have a few T1D acquaintances who relied on their CGM alone and have significantly improved their HbA1c after accounting for that. Maybe that information is useful to you.
- jevogel 5mo agoLook into Eversense 355 (implantable), it has so much better accuracy for my wife than the Libre and Dexcom CGMs she has tried.
- M0r13n 5mo ago> But for kids or the elderly, I see a use case. These are exactly the kinds of people who should NOT base their diabetes management on the "suggestions" of LLMs! There is the real risk that such users lack the competence or judgement to critically assess the convincing-sounding output of an LLM.
- pimeys 5mo agoI don't know, Dexcom G7 is accurate enough. I do random tests from finger and it's about there a bit off but close. The previous versions were wildly off if you're having a hyperglycemia, and also G7 doesn't peak as high as measured from a finger. But in that level you already have ketones in your blood, and insulin resistance, and a bit extra insulin from the pump will not drop you to hypo.
- tornadofart 5mo agoDexcom G7 has had inaccuracies for me. A standardized product meets non-standardized living beings, I guess.
- foo-bar-baz529 5mo agoWhat’s the limit on badges in a README
- andai 5mo agoLife imitates comedy...
- Jasssss 5mo ago[flagged]
- AnthonBerg 5mo agoWent through pregnancy with the mother having recently-diagnosed T1 diabetes – just barely not killed by grave neglect on behalf of healthcare due to how badly they missed the diagnosis to begin with. On your work: this is legit it is appreciated Hats off, I salute this, thank you
- emsign 5mo agoFDA approved?
- jlengelbrecht 5mo agoNo but the project has undergone an in depth evaluation from Open Collective prior to being accepted for fiscal hosting. Additionally I am in contact with an Attorney who is reviewing the projects stance. The project as it is right now is aims to not cross any boundaries that would make it a medical device. The platform does not control insulin or make dosing recommendations. It's still in early alpha but I have made my position clear. The platform serves as a tool to help you understand your data and help you have better discussions with your medical provider.
- maleldil 5mo agoI'm just happy to see a GPL project.
- vsaravind007 5mo agoLooks interesting, being a Whoop user for the last few years, I have seen for myself that their AI Coach/AI based suggestions are a hit or miss 3 out of 10 times, slightly concerned about how accurate this will. Not a diabetic patient, but I do monitor my levels with a CGM from time to time, will definitely check it out!
- hombre_fatal 5mo agoThe issue with Whoop’s AI is that there isn’t much data, and the data doesn’t have much prescriptive power, so it can’t really suggest anything useful. Recovery and Strain scores are made up, and even resting heart rate doesn’t tell you anything prescriptive for the day. The data available to the LLM in OP’s app is the polar opposite. It’s all actíonable and real, so I bet it can draw more useful insights than Whoop reminding you that you didn’t exercise all week.
- MassiveOwl 5mo agoI've done this with the Libre 2 sensor. I added Gemini to it. It gets like 2 weeks of readings at once, and the user can "chat to their data". I added a meals tool as well, where the user can photo their meal, and the ai estimates the impact on the readings. It's so helpful to offload some the thinking about the condition to ai, all these people moaning about 'muh safety' don't get it. T1D suffers have to think about it all day all the time. A person doesn't have their own blood glucose data in their head.
- darkhorse13 5mo agoThis is quite possibly a horrible idea. Personal anecdote: ChatGPT once read a blood work report value as 40, when the actual report said 4.
- mexicocitinluez 5mo agoSo, I'm in the medical field building an EMR and LLMs have obviously been a really important topic in the industry the last few years. We're still not even sure that giving LLM-assisted suggestions TO ACTUAL DOCTORS AND CLINICIANS will be helpful let alone to the patient themselves. It's breaking the golden rule of these tools which is to have someone with enough knowledge to verify the accuracy of the data it spits out. Patient's famously don't. Hell, even the actual staff don't really understand or know how these tools work (or the ways in which you can/can't trust them).
- throwatdem12311 5mo agoI mean this in the nicest way possible. But if someone dies because this thing hallucinates their reporting - would you feel any sense of culpability? “GPL says no warranty” “People need to double check LLM output” “You’re holding it wrong” I really don’t know if we, collectively as a civilization, should be willing to accept this kind of hand-waving when it comes to creating things like this. Sure, tools make mistakes or people misinterpret reports without the help of LLMs - but LLMs are just on a whole other level where the mistakes are just part of how these things work from a fundamental level. I don’t even trust AI scribes at my doctors office to transcribe my appointment due to errors. There is no way in hell I would ever use something like this that could just straight up lie about something that kills me if I get it wrong.
- sexylinux 5mo agoYou know that current AI systems are not reliable and produce errors? How do you protect your life and the life of others using your software against potential lethal errors?
- peppetv4 5mo agoReally nice of you to share this, well done! About the risks, managing type 1 diabetes is exhausting, and most people will still sanitycheck the output alongside the hundreds of treatment decisions they make every day. That doesn’t change the fact that tools like this can nudge you to notice and look into patterns or things that needs attention.
- Diti 5mo agoTools like this can also display false low glucose figures, leading you to reduce your slow-acting insulin and skipping fast-acting insulin. A day later, you start feeling nauseous (ketoacidosis), and you’re in danger of death. I’ll keep using the manual glucose meters (like you advised), and would personally stay the fuck away from any transformer-based LLM to report medical data.
- M0r13n 5mo agoI don't think that LLMs are trustworthy companions in managing a complex metabolic disease like diabetes - especially if you deviate (ever so slightly) from the norm (very lean, very active, strict diet, etc.)! I'm a T1D myself and like to experiment with ChatGPT (or Opus). My experiences are mixed LLMs are overly cautious when it comes to correcting with insulin. They regularly advise against correcting before going to bed, even if this means that my blood glucose remains above 140 mg/dl for the whole night. I am following a low to medium carb diet (<100g a day). ChatGPT always nudges me to consume more carbohydrates, even though I have a TIR of 90% (70-150 mg/dl). Why would I change my diet if it currently works very well for me? Still, most LLMs seem to favor carbs for some reason. I am using Fiasp as my fast acting insulin. Typically, I inject around 1 to 4 IUs of Fiasp. Its glucose-lowering effect typically lasts for roughly 2-3 hours. Therefore, I know that it is safe to re-inject after three hours without risking insulin stacking. But ChatGPT regularly advises against that and wants me to wait another 1-2 hours. I am not against automating diabetes management. In fact, I really appreciate projects that help with that. But I don't consider LLMs to be helpful in this regard. Their combination of training data bias, liability aversion, lack of context, and one-size-fits-all thinking disqualifies them from such tasks.
- nahsra 5mo agoI understand this instinct, but I can see the appeal of capabilities that are well within the limits of a well-designed agentic system. Imagine asking such a system, "look at my postprandial response to dosing for the past week and make ratio suggestions for breakfast, lunch, and dinner." This is genuinely helpful, saves time, and well within the reasoning limits. You could spot check if you like. Is it worth setting up such an assistant for the value you'd get out of it? I guess that's on the user and how many similar use cases exist.
- M0r13n 5mo ago> look at my postprandial response to dosing for the past week and make ratio suggestions for breakfast, lunch, and dinner I'm not so sure about that. A patient absolutely must critically evaluate the LLM's suggestions. A naive user risks severe complications. A user with that kind of competence, however, doesn't need an LLM for such trivial adjustments - they're obvious
- Kryscekk 5mo agoAs a urologist who built and runs his own clinic management software, I'd encourage thinking about this question early: what does the system do when the LLM refuses to answer, returns malformed JSON, or hallucinates a glycemic value? In medical contexts, a 'silent failure' (system continues despite bad data) is much worse than a noisy failure (system stops and asks the user). The 'happy path' for an LLM-powered medical tool is usually well-designed. The failure paths are where the project lives or dies. Curious how you handle that.
- jlengelbrecht 5mo ago[flagged]
- jlengelbrecht 5mo agoThank you. Really appreciate this feedback. I am actually already thinking about this. Hallucinations need to be clearly called out which is important. This is on the project's roadmap for me to address. There needs to be a way for users to clearly say "This is wrong. you need to reevaluate" In terms of alerting this is where we drift from what the LLM does and what the platform does. The platform already ingests data and stores it in the RAG system which provides the AI context but AI is the component that used for chatting about your data and providing you daily briefs. Alerting lives on the platform side so the AI may use it when we start implementing pattern detection to alert diabetics and care takers with questions such as "I see your glucose is rising. Did you eat and not bolus?" but for actual glucose events that fire during hyper or hypo events this is hard coded in the platform itself.
- Jinyibruceli 5mo ago[flagged]
- vrc 5mo agoDoes it prompt logging? For example, when I was trying to monitor my BG after diagnosis, I tried to log my meals to correlate later, but 1) would forget and 2) wouldn’t have the energy to time align the stats. So a tool that even saw changes in BG and shot me a text or message (did you eat/exercise do something @ [time]?) and used the LLM or something else to capture and enrich the metadata. Paired with boring things like med reminders (I just realized I forgot my metformin while typing this) and giving me an easy visualizer with these meta points would be useful. If I’m tracking sleep on a device etc. As others have said, the analysis might be risky. I don’t want to trust interpretation to anyone but myself (bear my own risk) or my clinician. But just remembering to capture the data and making it easily time alignable and possible augmentable in the future would be useful.
- jlengelbrecht 5mo agoYes this is actually on the roadmap. The project does not do this today as its still in alapha but what you are describing is exactly what i am building toward. Specifically behavior analysis where the AI notices changes in your blood glucose and asks you follow up questions to help you understand what you might have missed. I have had early adopters of the project specifically ask for this.
- hereme888 5mo agoInteresting. I can see the utility if you're going to see a nurse practitioner. But if your physician doesn't pull the actual charts for your device and visually inspect them.... try finding someone else.
- UomoNeroNero 5mo agoI truly appreciate your work (and I’ll absolutely take a look at it). But let me say one thing: I’ve been diabetic for more than 20 years. Ten years of management with finger pricks, three measurements a day, and insulin pens (thinking about it now, it feels completely insane that anyone could imagine managing this madness in such a primitive way). Then came years of CGM systems (I’m on my third one now, with different types of sensors, but that’s not the point). I tinkered, automated, hacked things. But in the end I came to one conclusion: you need a competent specialist (someone who also understands that we tend to be a bit tech-obsessed) who, besides listening to you, actually imposes a strategy. We are the ones who need to adapt to the mainstream approach so we can speak the same language and have methods that are compatible with “everyone else.” No doctor will ever fully understand your custom system, and meanwhile the key to proper management is not in what you built. Precise carb counting (without cheating yourself), correct boluses given at the right times, marking exercise, boredom and repetition, and being lucid about the effects of changes (agreed upon beforehand!) to CGM settings — changes that should only be made when you’re certain you’ve been a “good and precise patient.” I’m saying this from the perspective of my own devastated situation. I now have an HbA1c of 5.8, but only after 20 years of smashing my head against the wall (and suffering incredible damage, many mistakes, and the classic “I’ve figured it all out myself” approach). Stay strong.
- limack0 5mo ago[flagged]