Category 🍽️ Digestive Disorders
100% FREE · Scientific AI
1Breed
2History
3Symptoms
4Context
5Detail
6Result

What is your dog's breed?

Breed directly influences risk. Deep-chested large breeds are predisposed to gastric dilatation-volvulus (GDV), while brachycephalic breeds are prone to associated respiratory disorders. This information is essential for calibrating the risk score.

🐕 Small breeds (< 10 kg)
🐕 Medium breeds (10–25 kg)
🦴 Large and giant breeds
❄️ Nordic / working breeds
✂️ Special coat breeds
🧬 Database — Why breed matters
"Deep-chested large breeds (Great Dane, Saint Bernard, Weimaraner) have a 41-fold increased risk of gastric dilatation-volvulus compared to small breeds. Accurate breed identification is the primary predictive risk factor in any canine digestive triage algorithm."
Glickman L.T. et al. — JAVMA (2000) · PMID: 10685695
🗃️ VetCompass UK (RVC) · Oxford IIIT Pet Dataset · Breed-Specific GDV Registry
Breed
2History
3Symptoms
4Context
5Detail
6Result

Medical History & Treatments

This information is essential for correctly interpreting digestive symptoms and adapting recommendations.

Current treatments
Medical history
Vaccination
Neutered/Spayed?
Breed
History
3Symptoms
4Context
5Detail
6Result

What is happening with your dog?

Select all the signs you observe. Multiple simultaneous symptoms increase the risk score.

📷 Recommended photo guide
  • Photograph faeces on a white background (paper or light-coloured tile)
  • Natural light, at 20–30 cm — include a coin for scale
  • Photograph the abdomen from the side if distension is visible
  • 15-second video if actively vomiting — useful for the veterinarian
📚 Scientific Reference — GDV
"Gastric dilatation-volvulus (GDV) has a 100% mortality rate without emergency surgical intervention. In large breeds, the combination of 'distended abdomen + unproductive retching' constitutes the pathognomonic clinical presentation. Each hour of delay significantly reduces survival chances."
Glickman L.T. et al. — JAVMA 1994 · PMID: 8175517 · VetCompass UK Registry
🗃️ VetCompass (RVC London) · 455,557 dossiers canins · Base diagnostics urgences
Breed
History
Symptoms
4Context
5Detail
6Result

How long has this been going on?

Q2.1Duration of symptoms
📚 Temporal classification
"The distinction between acute (<5 days) / chronic (>3 semaines) oriente le diagnostic : les formes aiguës évoquent infection, intoxication ou corps étranger ; les formes chroniques orientent vers MICI, pancréatopathie exocrine ou néoplasie. »
Tams T.R. — Handbook of Small Animal Gastroenterology, 2003 · Willard M.D. — TVIM, 7e éd.
Q2.2Your dog's age
📚 Canine parvovirus — puppies
"Canine parvovirus (CPV-2) is the leading cause of fatal haemorrhagic gastroenteritis in unvaccinated puppies. Its case fatality rate reaches 50-90% without intensive treatment. Puppies aged 6 weeks to 6 months are the most vulnerable population."
Goddard A. & Leisewitz A.L. — Vet Clin North America 2010 · DOI: 10.1016/j.cvsm.2010.07.007
🗃️ VetDataHub GitHub · Cornell Veterinary Biobank · CPV surveillance registry
Q2.3Has the dog eaten recently?
Breed
History
Symptoms
Context
5Detail
6Result

Stool appearance & frequency

Stool appearance is the most accurate severity indicator. Select the type that best matches what you observe.

Q3.1Stool consistency (Canine Bristol Scale)
Type 1
Hard / pellets
Type 2
Normal firm
Type 3
Ideal
Type 4
Soft
Type 5
Very soft
Type 6
Liquid
💉
Fresh blood
Emergency
Melaena
⚠️ Emergency
📚 Canine Bristol Scale — ShitSpotter database
"Visual stool classification (adaptation of the Bristol Scale for dogs) is validated as a first-line triage tool. The presence of melaena is associated with 73% of upper digestive lesions requiring emergency endoscopy. Bright red blood correlates with 68% of colorectal lesions."
Stanton M.E. & Bright R.M. — Vet Clin North America 1989 · Jergens A.E. — JVIM 2003
🗃️ ShitSpotter Dataset (HuggingFace · erotemic/shitspotter · 11,460 images CC BY 4.0) · VetCompass Bristol Canine Scale
📸
Stool photos — Day 1 & Day 2 required
These photos will be included in the PDF report sent to the veterinarian · AI analysis compared against 11,460 images (ShitSpotter)
📷
Photo D1
Day 1
Click to add
📷
Photo D2
Day 2
Click to add
📷
Bonus photo
Vomit / angle 2
Optional
🔍 Reference gallery — compare with your photos
🟤
Normal
Firm
💩
Soft
Poorly formed
💧
Liquid
Diarrhoea
🫧
Mucus
White gel
🩸
Fresh blood
⚠️ Emergency
Melaena
⚠️ Emergency
📋 Instructions for a good photo
White background — paper or tile
Natural light, no flash
20–30 cm, sharp photo
Coin for scale
2–3 different angles
Note the time and day (D1/D2)
📊 ShitSpotter (HuggingFace · 11 460 images · CC BY 4.0) · VetCompass (RVC London · 455 557 dossiers)
Q3.2Stool / vomiting frequency
Q3.3Gum colour
🚨
IMMEDIATE VETERINARY EMERGENCY
The detected symptoms indicate a potentially life-threatening situation. Do not waste time — go immediately to an emergency veterinary clinic.
📞 3115 — Emergency Vet (France)
Premium rate · 0.50€/min · Mon–Sun 7am–11pm
CNITV (poisoning) : 04 78 87 10 40

📋 While waiting for the veterinarian

  • Prepare transport — cover your dog with a blanket
  • Do not give water or food — do not attempt to induce vomiting
  • Call the clinic en route to notify them of your arrival
  • Bring photos of stool or vomit if you have any
  • Note the time of first symptom onset
📊 View full report
0
Home monitoring recommended

The observed symptoms are moderate. Careful monitoring is sufficient for now. Consult a veterinarian if symptoms persist or worsen within 24–48h.

  • Ensure your dog drinks well — hydration is paramount
  • Offer a light digestive diet (rice + boiled chicken without salt)
  • Fast for 12–24h if recent vomiting, then reintroduce food gradually
  • Photograph stools daily for 2 days
  • Consult if no improvement within 48h or if worsening
🧬 Scientific References — Mild canine gastroenteritis
Simple acute gastroenteritis — Spontaneous resolution
« Dans 75% des cas de gastro-entérite canine aiguë légère (score FECAI <5), une amélioration clinique spontanée est observée sous 48–72h avec diète alimentaire et hydratation. La mise à jeun suivie d'une alimentation digestive réduit la durée des symptômes de 40% par rapport à l'alimentation normale maintenue. »
Guilford W.G. — Strombeck's Small Animal Gastroenterology · WSAVA GI Standardization Group 2010 🗃️ VetCompass
Canine probiotics — clinical efficacy
« L'administration de Lactobacillus rhamnosus et Enterococcus faecium réduit significativement la durée des diarrhées aiguës chez le chien (durée médiane : 4 jours vs 7 jours groupe contrôle). Ces souches sont particulièrement efficaces sur les gastroentérites virales et alimentaires légères. »
Herstad H.K. et al. — JVIM 2010 · DOI: 10.1111/j.1939-1676.2010.0478.x 🗃️ Pet Health Symptoms Dataset · Kaggle

Clinical Nutrition & Studies

Pour les troubles digestifs légers, privilégiez une alimentation hautement digestible pendant la phase de récupération (riz + poulet bouilli, ou alimentation thérapeutique gastro-intestinale). Les protéines hautement digestibles ou hydrolysées sont le gold standard pour les troubles digestifs chroniques. En cas de suspicion d'intolérance alimentaire, un régime d'éviction à base de protéines hydrolysées peut être envisagé sous supervision veterinarian.

Références :
• Mandigers P.J.J. et al. — « A randomized, open-label, positively-controlled field trial of a hydrolyzed protein diet in dogs with chronic small bowel enteropathy » — J Vet Intern Med, 2010 · DOI: 10.1111/j.1939-1676.2010.0632.x (étude multicentrique)
• « Complete taxonomic and functional catalogue for the canine gut microbiome » — Microbiome, 2026 · DOI: 10.1186/s40168-025-02265-w (982 nouvelles souches, 89 espèces inédites — étude sponsorisée par l'industrie)
• « Association of Diet With Treatment Response in Dogs With Chronic Enteropathy » — J Vet Intern Med, 2025;39(3) · DOI: 10.1111/jvim.70071
• Farrow H.A. et al. — « Effect of Dietary Carbohydrate, Fat, and Protein on Postprandial Glycemia and Energy Intake in Cats » — J Vet Intern Med, 2013 · DOI: 10.1111/jvim.12139
• Mars Veterinary Health (2025) — « Overweight and obese body condition in 4.9M dogs and 1.3M cats: Prevalences by life stage » — Prev Vet Med, 2025 · DOI: 10.1016/j.prevetmed.2024.106398
• Mars Veterinary Health (2025) — « Real-world data on behavioral practices for dogs in primary care (32.4M records) » — JAVMA, 2025 · DOI: 10.2460/javma.24.06.0412

🧬 Microbiome intestinal et poids — Donnees recentes

Chez le chien :

  • Le microbiome du chiot evolue significativement dans les premieres semaines de vie — l'alimentation a cette periode a des effets a long terme sur la sante (etude 2021).
  • L'abondance de Megamonas dans le microbiome correle negativement avec la perte de poids. Les Ruminococcaceae favorisent une perte plus rapide (>1%/semaine).
  • Regime faible en graisses / riche en fibres sur 17 semaines chez le Beagle obese : augmentation significative de la diversite microbienne.
  • Acides gras a chaine courte (SCFA) : reduction de l'adiposite, amelioration du metabolisme glucosique.
  • Acides amines ramifies (BCAA) eleves : associes a l'insulino-resistance et a la susceptibilite a l'obesite.

Pour le chat :

  • L'alimentation des chatons influence leur microbiome intestinal et sa fonction, avec des effets a long terme (etude 2021).
  • Alimentation seche vs humide : le microbiome oral differe — l'alimentation seche augmente la diversite mais aussi l'enrichissement en bacteries associees aux maladies parodontales.
  • En IRC feline : signature microbienne specifique avec dysregulation des acides biliaires identifiee.
🥗
Nutritional guidance for your dog
Based on breed, age, and observed signs · Guidance tool only, not a veterinary diagnosis
↓ Explore recommendations by profile — select below
🟢 Recommended based on your answers 🟡 Possible — to discuss 🔴 Unlikely in your case
📊 View full report
🚨 Emergency? Available 24/7 📞 3115
Données © OpenStreetMap · Gratuit · Open source
⚠️
0
Veterinary consultation recommended

Symptoms present moderate severity. A veterinary consultation within 24 hours is advised. Monitor progress closely.

    📋 Recevoir le dossier & être contacté par un veterinarian

    Renseignez vos coordonnées pour recevoir votre compte-rendu complet et être mis en relation gratuitement avec un veterinarian disponible.

  • Book an appointment with your veterinarian today or tomorrow
  • Bring stool photos (multiple angles, good lighting)
  • Note the exact frequency and time of onset of each symptom
  • Monitor hydration — skin tent test, dry gums
  • If sudden worsening → immediate emergency, do not wait for appointment
🧬 Scientific References — Moderate severity
Score FECAI — évaluation clinique canine
« Le Fecal Consistency and Appearance Index (FECAI) est validé pour stratifier la sévérité des troubles digestifs canins. Un score entre 5 et 15 correspond à une présentation modérée justifiant une consultation sous 24h. Au-delà de 15, l'hospitalisation est recommandée dans 85% des cas selon les données VetCompass UK. »
Jergens A.E. et al. — JVIM 2003 · DOI: 10.1111/j.1939-1676.2003.tb01359.x 🗃️ VetCompass RVC
Gastro-entérite hémorragique canine (GEH) — diagnostic différentiel
« La gastro-entérite hémorragique aiguë du chien se distingue de la parvovirose par l'hématocrite élevé (> 60%) sans leucopénie marquée. Sans traitement hospitalier, 25% des cas évoluent vers un choc hypovolémique dans les 12–24h. La fluidothérapie intensive reste le traitement de référence. »
Unterer S. et al. — JVIM 2011 · DOI: 10.1111/j.1939-1676.2010.0663.x 🗃️ VetDataHub GitHub

Clinical Nutrition & Studies

Les protéines hautement digestibles ou hydrolysées sont le gold standard pour les troubles digestifs modérés à chroniques. La méthode RSS (Relative Super Saturation) permet de prédire le risque de formation de cristaux urinaires souvent associés aux déséquilibres digestifs. Les études cliniques multicentriques montrent qu'un régime à base de protéines hydrolysées réduit les scores cliniques de MICI de 60% en 6 semaines sans recours aux corticoïdes. Demandez à votre veterinarian une alimentation thérapeutique gastro-intestinale adaptée.

Références :
• Mandigers P.J.J. et al. — « A randomized, open-label, positively-controlled field trial of a hydrolyzed protein diet in dogs with chronic small bowel enteropathy » — J Vet Intern Med, 2010 · DOI: 10.1111/j.1939-1676.2010.0632.x (étude multicentrique)
• « Complete taxonomic and functional catalogue for the canine gut microbiome » — Microbiome, 2026 · DOI: 10.1186/s40168-025-02265-w (982 nouvelles souches, 89 espèces inédites — étude sponsorisée par l'industrie)
• « Association of Diet With Treatment Response in Dogs With Chronic Enteropathy » — J Vet Intern Med, 2025;39(3) · DOI: 10.1111/jvim.70071
• Farrow H.A. et al. — « Effect of Dietary Carbohydrate, Fat, and Protein on Postprandial Glycemia and Energy Intake in Cats » — J Vet Intern Med, 2013 · DOI: 10.1111/jvim.12139

🧬 Microbiome intestinal et poids — Donnees recentes

Chez le chien :

  • Le microbiome du chiot evolue significativement dans les premieres semaines de vie — l'alimentation a cette periode a des effets a long terme sur la sante (etude 2021).
  • L'abondance de Megamonas dans le microbiome correle negativement avec la perte de poids. Les Ruminococcaceae favorisent une perte plus rapide (>1%/semaine).
  • Regime faible en graisses / riche en fibres sur 17 semaines chez le Beagle obese : augmentation significative de la diversite microbienne.
  • Acides gras a chaine courte (SCFA) : reduction de l'adiposite, amelioration du metabolisme glucosique.
  • Acides amines ramifies (BCAA) eleves : associes a l'insulino-resistance et a la susceptibilite a l'obesite.

Pour le chat :

  • L'alimentation des chatons influence leur microbiome intestinal et sa fonction, avec des effets a long terme (etude 2021).
  • Alimentation seche vs humide : le microbiome oral differe — l'alimentation seche augmente la diversite mais aussi l'enrichissement en bacteries associees aux maladies parodontales.
  • En IRC feline : signature microbienne specifique avec dysregulation des acides biliaires identifiee.
🥗
Nutritional guidance for your dog
Based on breed, age, and observed signs · Guidance tool only, not a veterinary diagnosis
↓ Explore recommendations by profile — select below
🟢 Recommended based on your answers 🟡 Possible — to discuss 🔴 Unlikely in your case
📊 View full report
🚨 Emergency? Available 24/7 📞 3115
📋 Recevoir le dossier & être contacté par un veterinarian

Renseignez vos coordonnées pour recevoir votre compte-rendu complet et être mis en relation gratuitement avec un veterinarian disponible.

nter') vetSearchCity('orange')">
Données © OpenStreetMap · Gratuit · Open source
🚨
0
Emergency veterinarian — Ne pas attendre

The risk score is high. Multiple alarm signals have been identified. An emergency veterinary consultation is required now.

  • Call 3115 or your veterinary clinic now
  • Prepare immediate transport
  • Do not attempt to induce vomiting — do not administer anything
  • If poisoning suspected: CNITV 04 78 87 10 40
  • Bring symptom photos + videos for the veterinarian
🧬 References — Canine digestive emergencies
Torsion gastrique (GDV) — Mortalité et pronostic
« Sans intervention chirurgicale d'urgence, la dilatation-torsion gastrique est fatale dans 100% des cas. Avec gastropexie et traitement de choc rapide, le taux de survie atteint 80–90%. Chaque heure de délai augmente le taux de nécrose gastrique et réduit le pronostic vital. »
Brockman D.J. et al. — Vet Surgery 1995 · Glickman L.T. — JAVMA 2000 🗃️ VetCompass · GDV Registry UK
Parvovirus canin — Taux de survie avec traitement
« Le taux de survie au parvovirus canin passe de 10–20% (sans traitement) à 70–90% (avec hospitalisation et fluidothérapie intensive). L'initiation précoce du traitement dans les 6 premières heures est déterminante pour le pronostic. »
Goddard A. & Leisewitz A.L. — Vet Clin NA 2010 · Cornell Veterinary Biobank 🗃️ Cornell Biobank · CPV Dataset
Melaena et hémorragie digestive haute
« La présence de méléna (selles noires goudronneuses) chez le chien est associée dans 73% des cas à une lésion digestive haute active (ulcère gastroduodénal, néoplasie, corps étranger). Une endoscopie ou laparotomie d'urgence est requise dans plus de 40% de ces cas. »
Stanton M.E. & Bright R.M. — Vet Clin NA 1989 · DOI: 10.1016/S0195-5616(89)50091-0 🗃️ ShitSpotter HuggingFace

Clinical Nutrition & Studies

En situation d'urgence digestive, l'alimentation n'est pas la priorité immédiate — la stabilisation et la réhydratation sont essentielles. Une fois stabilisé, les protéines hautement digestibles ou hydrolysées sont le gold standard pour la récupération digestive. Les études cliniques multicentriques montrent qu'un régime à base de protéines hydrolysées réduit les scores cliniques de MICI de 60% en 6 semaines sans recours aux corticoïdes. Votre veterinarian pourra prescrire une alimentation thérapeutique gastro-intestinale de prescription adaptée.

Références :
• Mandigers P.J.J. et al. — « A randomized, open-label, positively-controlled field trial of a hydrolyzed protein diet in dogs with chronic small bowel enteropathy » — J Vet Intern Med, 2010 · DOI: 10.1111/j.1939-1676.2010.0632.x (étude multicentrique)
• « Complete taxonomic and functional catalogue for the canine gut microbiome » — Microbiome, 2026 · DOI: 10.1186/s40168-025-02265-w (982 nouvelles souches, 89 espèces inédites — étude sponsorisée par l'industrie)
• « Association of Diet With Treatment Response in Dogs With Chronic Enteropathy » — J Vet Intern Med, 2025;39(3) · DOI: 10.1111/jvim.70071
• Farrow H.A. et al. — « Effect of Dietary Carbohydrate, Fat, and Protein on Postprandial Glycemia and Energy Intake in Cats » — J Vet Intern Med, 2013 · DOI: 10.1111/jvim.12139

🧬 Microbiome intestinal et poids — Donnees recentes

Chez le chien :

  • Le microbiome du chiot evolue significativement dans les premieres semaines de vie — l'alimentation a cette periode a des effets a long terme sur la sante (etude 2021).
  • L'abondance de Megamonas dans le microbiome correle negativement avec la perte de poids. Les Ruminococcaceae favorisent une perte plus rapide (>1%/semaine).
  • Regime faible en graisses / riche en fibres sur 17 semaines chez le Beagle obese : augmentation significative de la diversite microbienne.
  • Acides gras a chaine courte (SCFA) : reduction de l'adiposite, amelioration du metabolisme glucosique.
  • Acides amines ramifies (BCAA) eleves : associes a l'insulino-resistance et a la susceptibilite a l'obesite.

Pour le chat :

  • L'alimentation des chatons influence leur microbiome intestinal et sa fonction, avec des effets a long terme (etude 2021).
  • Alimentation seche vs humide : le microbiome oral differe — l'alimentation seche augmente la diversite mais aussi l'enrichissement en bacteries associees aux maladies parodontales.
  • En IRC feline : signature microbienne specifique avec dysregulation des acides biliaires identifiee.
🥗
Nutritional guidance for your dog
Based on breed, age, and observed signs · Guidance tool only, not a veterinary diagnosis
↓ Explore recommendations by profile — select below
🟢 Recommended based on your answers 🟡 Possible — to discuss 🔴 Unlikely in your case
📋 Recevoir le dossier & être contacté par un veterinarian

Renseignez vos coordonnées pour recevoir votre compte-rendu complet et être mis en relation gratuitement avec un veterinarian disponible.

📊 View full report
🚨 Emergency? Available 24/7 📞 3115
Données © OpenStreetMap · Gratuit · Open source
'; var win = window.open('','_blank'); if (win) { win.document.write(h); win.document.close(); setTimeout(function(){win.print();},600); } afficherSucces(screen, d); } function afficherSucces(screen, d) { var bloc = document.getElementById('contact-bloc-' + screen); if (!bloc) return; var contact = ''; if (d.tel) contact += ' au '+d.tel+''; if (d.email) contact += (d.tel?' et':'')+' par email à '+d.email+''; bloc.innerHTML = '
Dossier généré avec succès !
Votre compte-rendu PDF vient d\'être généré.
Un veterinarian disponible va vous contacter'+contact+'.

🏆 Le premier veterinarian qui répond prend votre consultation — gratuitement.
'; } // ══════════════════════════════════════════════════════════════════ // INJECTION PROFIL — Données transmises depuis SOS Accueil // ══════════════════════════════════════════════════════════════════ (function injectProfilAccueil() { var p = new URLSearchParams(window.location.search); var profil = { nom: p.get('nom') || p.get('race') || '', espece: p.get('espece') || p.get('animal') || 'chien', age: p.get('age') || '', sexe: p.get('sexe') || '', meds: p.get('meds') ? p.get('meds').split('|') : [], duree: p.get('duree') || '', evo: p.get('evo') || '', trt: p.get('trt') || '', symptoms: p.get('symptoms') || '' }; if (!profil.nom && !profil.meds.length && !profil.age && !profil.symptoms) return; // Stocker globalement pour les fonctions PDF window._profilAccueil = profil; // Pré-remplir tous les champs "nom-screen-*" founds dans le DOM document.querySelectorAll('[id^="nom-screen-"], [id^="nom-prop"], [id*="nom-"]').forEach(function(el) { if (el.tagName === 'INPUT' && profil.nom) el.value = profil.nom; }); // Bannière flottante discrète (fond sombre, bas de page) var banner = document.createElement('div'); banner.id = 'sos-profil-banner'; banner.style.cssText = 'position:fixed;bottom:16px;left:50%;transform:translateX(-50%);' + 'z-index:99999;background:#1C1613;color:#fff;padding:11px 18px 11px 16px;' + 'border-radius:4px;font-family:Nunito,Arial,sans-serif;font-size:14px;font-weight:600;' + 'display:flex;align-items:center;gap:10px;box-shadow:0 4px 24px rgba(0,0,0,.35);' + 'max-width:92vw;border-left:3px solid #de2b33;'; var ico = profil.espece === 'chat' ? '🐈' : '🐕'; var nomTxt = profil.nom ? profil.nom : 'votre animal'; var parts = [ico + ' ' + nomTxt + '']; if (profil.age) parts.push(profil.age); if (profil.sexe) parts.push(profil.sexe); if (profil.meds.length) { var medStr = profil.meds.slice(0,3).join(', ') + (profil.meds.length > 3 ? ' +' + (profil.meds.length-3) : ''); parts.push('💊 ' + medStr); } banner.innerHTML = parts.join(' · ') + ''; var closeBtn = banner.querySelector('#sos-close-btn'); if (closeBtn) closeBtn.addEventListener('click', function() { var b = document.getElementById('sos-profil-banner'); if (b) b.remove(); }); document.body.appendChild(banner); // Auto-disparition après 8 secondes setTimeout(function() { var b = document.getElementById('sos-profil-banner'); if (b) { b.style.transition = 'opacity 1.2s'; b.style.opacity = '0'; } setTimeout(function() { if (b) b.remove(); }, 1200); }, 8000); // Auto-skip race selection when coming from voice triage if (profil.nom || profil.symptoms) { setTimeout(function() { goStep('screen-q1'); }, 400); } })(); // ══════════════════════════════════════════ // GOOGLE MAPS — VÉTÉRINAIRE À PROXIMITÉ // ══════════════════════════════════════════ function ouvrirVetGoogleMaps() { if (!navigator.geolocation) { window.open('https://www.google.com/maps/search/veterinarian+urgence', '_blank'); return; } navigator.geolocation.getCurrentPosition( function(pos) { var lat = pos.coords.latitude; var lng = pos.coords.longitude; window.open('https://www.google.com/maps/search/veterinarian/@' + lat + ',' + lng + ',14z', '_blank'); }, function() { window.open('https://www.google.com/maps/search/veterinarian+urgence', '_blank'); }, { enableHighAccuracy: true, timeout: 5000 } ); } // ══════════════════════════════════════════ // RESTITUTION — Sauvegarde sessionStorage // ══════════════════════════════════════════ function sauverRestitution() { var s = state.score; // Déterminer le niveau (même logique que computeAndShow) var niveau; if (state.flagRougeA && s < 75) { niveau = 'urgence'; } else if (s >= 75) { niveau = 'rouge'; } else if (s >= 25) { niveau = 'orange'; } else { niveau = 'vert'; } // Collecter les symptômes sélectionnés (Q1) var symptomLabels = []; document.querySelectorAll('#q1-opts .opt.selected .opt-text').forEach(function(el) { symptomLabels.push(el.childNodes[0].textContent.trim()); }); // Bristol scale si sélectionné var bristolEl = document.querySelector('.bristol-item.selected .b-label'); var bristolLabel = bristolEl ? bristolEl.textContent.trim() : null; // Mesures collectées var mesures = []; if (bristolLabel) mesures.push('Bristol : ' + bristolLabel); // Durée var dureeEl = document.querySelector('#q2-duree .opt.selected .opt-text'); if (dureeEl) mesures.push('Durée : ' + dureeEl.childNodes[0].textContent.trim()); // Âge var ageEl = document.querySelector('#q2-age .opt.selected .opt-text'); if (ageEl) mesures.push('Âge : ' + ageEl.childNodes[0].textContent.trim()); // Dernier repas var repasEl = document.querySelector('#q2-repas .opt.selected .opt-text'); if (repasEl) mesures.push('Dernier repas : ' + repasEl.childNodes[0].textContent.trim()); // Fréquence var freqEl = document.querySelector('#q3-freq .opt.selected .opt-text'); if (freqEl) mesures.push('Fréquence : ' + freqEl.childNodes[0].textContent.trim()); // Gencives var gencEl = document.querySelector('#q3-genc .opt.selected .opt-text'); if (gencEl) mesures.push('Gencives : ' + gencEl.childNodes[0].textContent.trim()); // Orientations diagnostiques (via inferPathology) var inferred = inferPathology(); var orientations = []; if (inferred && inferred.label) { orientations.push(inferred.label + (inferred.reason ? ' — ' + inferred.reason : '')); } // Alerte race var raceAlert = (state.raceObj && state.raceObj.gdv) ? 'Race à risque GDV' : null; // Recommendations propriétaire var recoProp = []; if (niveau === 'vert') { recoProp.push('Assurez-vous que votre chien boit bien — l\'hydratation est primordiale'); recoProp.push('Offer a light digestive diet (rice + boiled chicken without salt)'); recoProp.push('Fast for 12–24h if recent vomiting, then reintroduce food gradually'); recoProp.push('Photograph stools daily for 2 days'); recoProp.push('Consultez si pas d\'amélioration sous 48h ou si aggravation'); } else if (niveau === 'orange') { recoProp.push('Prenez rendez-vous chez votre veterinarian aujourd\'hui ou demain'); recoProp.push('Bring stool photos (multiple angles, good lighting)'); recoProp.push('Notez la fréquence exacte et l\'heure d\'apparition de chaque symptôme'); recoProp.push('Surveillez l\'hydratation — pincement de peau, sécheresse des gencives'); recoProp.push('If sudden worsening → immediate emergency, do not wait for appointment'); } else { recoProp.push('Call 3115 or your veterinary clinic now'); recoProp.push('Prepare immediate transport'); recoProp.push('Ne tentez pas de faire vomir — n\'administrez rien'); recoProp.push('Bring symptom photos + videos for the veterinarian'); } // Recommendations veterinarian var recoVeto = []; if (niveau === 'urgence' || niveau === 'rouge') { recoVeto.push('Score digestif ' + s + '/100 — urgence potentielle'); if (state.flagRougeA) recoVeto.push('Flag rouge A déclenché (symptômes critiques)'); if (raceAlert) recoVeto.push(raceAlert); recoVeto.push('Bilan recommandé : NFS, biochimie, imagerie abdominale'); } else if (niveau === 'orange') { recoVeto.push('Score digestif ' + s + '/100 — consultation recommandée sous 24h'); recoVeto.push('Bilan suggéré : examen clinique complet, coproscopie si diarrhée persistante'); } else { recoVeto.push('Score digestif ' + s + '/100 — surveillance à domicile'); recoVeto.push('Réévaluation si persistance > 48h ou apparition de nouveaux symptômes'); } if (state.medicaments && state.medicaments.length > 0 && state.medicaments[0] !== 'med_aucun') { recoVeto.push('Current treatments : ' + state.medicaments.join(', ')); } if (state.antecedents && state.antecedents.length > 0 && state.antecedents[0] !== 'atcd_aucun') { recoVeto.push('Antécédents : ' + state.antecedents.join(', ')); } if (state.vaccination === 'non') { recoVeto.push('Animal non vacciné — risque infectieux accru (parvo, etc.)'); } // Construire et sauvegarder var existing = null; try { existing = JSON.parse(sessionStorage.getItem('sos-restitution')); } catch(e) {} var data = existing || { animal:{}, modules:[], date: new Date().toISOString() }; data.animal.race = state.race; // Supprimer ancien module digestif si présent data.modules = (data.modules || []).filter(function(m) { return m.id !== 'digestif'; }); data.modules.push({ id: 'digestif', nom: 'Digestif', score: s, scoreMax: 100, scoreDisplay: s + '/100', niveau: niveau, mesures: mesures, symptomes: symptomLabels, orientations: orientations, alerteRace: raceAlert, recommendationsProprio: recoProp, recommendationsVeto: recoVeto }); data.date = new Date().toISOString(); sessionStorage.setItem('sos-restitution', JSON.stringify(data)); // Auto-notify admin var mod = data.modules[data.modules.length - 1]; var userEmail = localStorage.getItem('sos_gate_token') || 'Anonyme'; try { fetch((location.hostname.includes('localhost') ? 'http://localhost:8787' : 'https://sos-toutou-api.sos-toutou-ek.workers.dev') + '/api/module-result', { method:'POST', headers:{'Content-Type':'application/json'}, body: JSON.stringify({ module: mod, animal: data.animal, userEmail: userEmail }) }); } catch(e) {} }