Give me ppt presentation on topic contusion

Reading File
Reading File
Reading File
Finding Sources
Searching PubMed

contusion AND treatment

Searching the Web

contusion bruises first aid when to seek medical attention Mayo Clinic

Reading File
Finding Sources
Searching Images

medical diagram soft tissue contusion bruise broken capillaries hematoma

Browsing Directory

~/

Reading Web Page

https://www.mayoclinic.org/first-aid/first-aid-bruise/basics…

Reading File
Finding Sources
Running Command

mkdir -p "/tmp/workspace/contusion-presentation/src" "/tmp/workspace/contusion-presentation/output"

Running Command

python - <<'PY' from pptx import Presentation from pptx.util import Inches, Pt from pptx.enum.shapes import MSO_SHAPE, MSO_CONNECTOR from pptx.enum.text import PP_ALIGN, MSO_ANCHOR from pptx.dml.color import RGBColor from pptx.enum.dml import MSO_THEME_COLOR from pptx.enum.text import MSO_AUTO_SIZE from pathlib import Path OUT=Path('/tmp/workspace/contusion-presentation/output/Contusion_Presentation.pptx') prs=Presentation() prs.slide_width=Inches(13.333) prs.slide_height=Inches(7.5) blank=prs.slide_layouts[6] # Palette NAVY=RGBColor(25,45,76); TEAL=RGBColor(25,131,137); SKY=RGBColor(222,244,246) INK=RGBColor(32,43,55); MUTED=RGBColor(93,105,118); WHITE=RGBColor(255,255,255) PURPLE=RGBColor(93,65,127); RED=RGBColor(178,48,65); ORANGE=RGBColor(223,126,50) YELLOW=RGBColor(242,199,73); GREEN=RGBColor(47,139,100); PALE=RGBColor(246,248,250) LINE=RGBColor(211,220,226) def shape(slide, typ, x,y,w,h, fill, line=None, radius=True): s=slide.shapes.add_shape(typ, Inches(x), Inches(y), Inches(w), Inches(h)) s.fill.solid(); s.fill.fore_color.rgb=fill s.line.color.rgb=line or fill s.line.width=Pt(0.6) return s def textbox(slide, x,y,w,h, text, size=20, color=INK, bold=False, align=PP_ALIGN.LEFT, font='Aptos', valign=MSO_ANCHOR.TOP): box=slide.shapes.add_textbox(Inches(x), Inches(y), Inches(w), Inches(h)) tf=box.text_frame; tf.clear(); tf.word_wrap=True tf.margin_left=tf.margin_right=tf.margin_top=tf.margin_bottom=0 tf.vertical_anchor=valign p=tf.paragraphs[0]; p.alignment=align r=p.add_run(); r.text=text; r.font.name=font; r.font.size=Pt(size); r.font.bold=bold; r.font.color.rgb=color return box def title(slide, kicker, heading, subtitle=None): textbox(slide,.64,.35,12,.25,kicker.upper(),10,TEAL,True) textbox(slide,.64,.68,12,0.58,heading,28,NAVY,True) if subtitle: textbox(slide,.65,1.30,12,.35,subtitle,12,MUTED) line=slide.shapes.add_connector(MSO_CONNECTOR.STRAIGHT, Inches(.65), Inches(1.75), Inches(12.68), Inches(1.75)); line.line.color.rgb=LINE; line.line.width=Pt(1) def footer(slide, n, source=None): textbox(slide,.65,7.12,10.9,.18,source or 'Educational overview - general soft-tissue contusion',8,MUTED) textbox(slide,12.3,7.08,.4,.22,str(n),9,TEAL,True,PP_ALIGN.RIGHT) def card(slide,x,y,w,h,heading,body,accent=TEAL): shape(slide,MSO_SHAPE.ROUNDED_RECTANGLE,x,y,w,h,WHITE,LINE) shape(slide,MSO_SHAPE.RECTANGLE,x,y,.10,h,accent,accent) textbox(slide,x+.28,y+.22,w-.45,.30,heading,15,NAVY,True) textbox(slide,x+.28,y+.64,w-.52,h-.80,body,12,INK) def bullets(slide,x,y,w,items,size=16,color=INK,spacing=10): box=slide.shapes.add_textbox(Inches(x),Inches(y),Inches(w),Inches(4.8)); tf=box.text_frame; tf.clear(); tf.word_wrap=True tf.margin_left=tf.margin_right=tf.margin_top=tf.margin_bottom=0 for i,item in enumerate(items): p=tf.paragraphs[0] if i==0 else tf.add_paragraph() p.text=item; p.font.name='Aptos'; p.font.size=Pt(size); p.font.color.rgb=color; p.space_after=Pt(spacing); p.level=0 # bullet xml p._p.get_or_add_pPr().insert(0, __import__('pptx').oxml.xmlchemy.OxmlElement('a:buChar')) p._p.pPr[0].set('char','•') return box # 1 s=prs.slides.add_slide(blank); shape(s,MSO_SHAPE.RECTANGLE,0,0,13.333,7.5,NAVY,NAVY) # decorative circles for x,y,d,c in [(9.7,.7,3.4,TEAL),(10.9,3.6,2.2,PURPLE),(8.9,5.45,1.3,ORANGE)]: shape(s,MSO_SHAPE.OVAL,x,y,d,d,c,c) textbox(s,.76,.72,6,.3,'TRAUMA & FIRST AID',13,RGBColor(143,223,220),True) textbox(s,.74,1.35,7.3,1.1,'CONTUSION',42,WHITE,True) textbox(s,.78,2.65,6.6,.9,'A concise presentation on bruises, assessment, first aid, and warning signs',21,RGBColor(226,236,242)) shape(s,MSO_SHAPE.ROUNDED_RECTANGLE,.78,4.05,5.8,.85,RGBColor(38,63,97),RGBColor(38,63,97)) textbox(s,1.05,4.30,5.2,.27,'General soft-tissue injury | Student presentation',14,WHITE,False) textbox(s,.78,6.70,8,.25,'Prepared for educational use | October 2026',10,RGBColor(169,191,209)) # 2 s=prs.slides.add_slide(blank); title(s,'1. Definition','What is a contusion?','Commonly called a bruise') card(s,.72,2.15,3.9,3.7,'Core definition','A contusion is a closed soft-tissue injury caused by blunt force. Small blood vessels are damaged and blood leaks into surrounding tissue, while the skin usually remains intact.',TEAL) card(s,4.74,2.15,3.9,3.7,'What you see','The trapped blood produces discoloration. It may look red, blue, purple, brown, green, or yellow as it changes during healing.',PURPLE) card(s,8.76,2.15,3.9,3.7,'What you feel','Typical features are localized pain, tenderness, swelling, and sometimes reduced movement of the nearby joint or muscle.',ORANGE) footer(s,2,'Source: Mayo Clinic, Bruise: First aid (accessed 2026)') # 3 mechanism s=prs.slides.add_slide(blank); title(s,'2. Mechanism','How a bruise develops','Blunt impact can injure vessels without breaking the skin') # skin diagram shape(s,MSO_SHAPE.ROUNDED_RECTANGLE,.85,2.15,5.2,3.95,RGBColor(255,224,205),RGBColor(221,177,156)) shape(s,MSO_SHAPE.RECTANGLE,.85,2.15,5.2,.55,RGBColor(248,201,172),RGBColor(248,201,172)) textbox(s,1.05,2.31,1.2,.18,'SKIN',10,RED,True) shape(s,MSO_SHAPE.RECTANGLE,.85,2.70,5.2,1.35,RGBColor(255,236,207),RGBColor(255,236,207)) textbox(s,1.05,3.15,2,.18,'SUBCUTANEOUS TISSUE',10,ORANGE,True) shape(s,MSO_SHAPE.RECTANGLE,.85,4.05,5.2,2.05,RGBColor(230,171,157),RGBColor(230,171,157)) textbox(s,1.05,5.35,1.2,.18,'MUSCLE',10,RED,True) # vessels and blood for x,y in [(2,3.4),(3.2,3.1),(4.2,3.55),(2.6,4.6),(4.5,4.85)]: shape(s,MSO_SHAPE.OVAL,x,y,.33,.18,RED,RED) shape(s,MSO_SHAPE.OVAL,3.0,3.55,1.15,.7,PURPLE,PURPLE) textbox(s,3.25,3.78,.65,.15,'blood',9,WHITE,True,PP_ALIGN.CENTER) # impact arrow arrow=shape(s,MSO_SHAPE.DOWN_ARROW,2.95,1.45,1.05,1.1,ORANGE,ORANGE); textbox(s,2.8,1.18,1.4,.2,'BLUNT IMPACT',10,ORANGE,True,PP_ALIGN.CENTER) # process rhs for i,(h,b,c) in enumerate([('1. Force compresses tissue','A fall, collision, blow, or sporting impact transfers energy to soft tissue.',TEAL),('2. Vessels tear','Capillaries and small veins rupture, allowing blood to escape.',RED),('3. Blood spreads locally','Extravasated blood causes discoloration and pressure-related tenderness.',PURPLE),('4. Healing begins','Cells clear blood products and the colour fades over time.',GREEN)]): y=2.0+i*1.05; shape(s,MSO_SHAPE.OVAL,7.1,y,.52,.52,c,c); textbox(s,7.25,y+.12,.2,.16,str(i+1),10,WHITE,True,PP_ALIGN.CENTER) textbox(s,7.8,y,4.6,.25,h,15,NAVY,True); textbox(s,7.8,y+.32,4.55,.35,b,11,MUTED) footer(s,3,'Source: Mayo Clinic, Bruise: First aid (accessed 2026)') #4 causes factors s=prs.slides.add_slide(blank); title(s,'3. Causes & risks','Who gets contusions and why?') card(s,.72,2.15,3.82,3.8,'Typical causes','Falls\nSports contact\nBlows or collisions\nWorkplace or household accidents',TEAL) card(s,4.76,2.15,3.82,3.8,'More visible bruising','Thin or fragile skin\nOlder age\nAreas over bone\nLighter skin makes colour easier to see',PURPLE) card(s,8.80,2.15,3.82,3.8,'Bleeding tendency','Anticoagulant or antiplatelet medicines\nPlatelet/coagulation disorders\nSome liver disorders\nFrequent unexplained bruising needs assessment',RED) footer(s,4,'Source: Parikh, Textbook of Medical Jurisprudence, “Bruises (Contusions)”; Mayo Clinic') #5 clinical features s=prs.slides.add_slide(blank); title(s,'4. Clinical features','Recognizing a simple contusion') features=[('Pain / tenderness',TEAL),('Swelling',ORANGE),('Discoloration',PURPLE),('Warmth or firmness',RED),('Reduced movement',NAVY),('Possible hematoma',GREEN)] for i,(lab,c) in enumerate(features): x=.85+(i%3)*4.13; y=2.25+(i//3)*1.72 shape(s,MSO_SHAPE.ROUNDED_RECTANGLE,x,y,3.55,1.30,PALE,LINE) shape(s,MSO_SHAPE.OVAL,x+.25,y+.31,.66,.66,c,c) textbox(s,x+1.12,y+.35,2.13,.26,lab,16,NAVY,True) text=['Local tissue sensitivity','Fluid/inflammation response','Blood under the skin','May occur early after injury','Pain or swelling can limit use','A larger localized blood collection'][i] textbox(s,x+1.12,y+.70,2.15,.28,text,10,MUTED) textbox(s,.9,6.1,11.5,.38,'Appearance alone does not reliably reveal the severity, timing, or exact site of the original impact.',14,RED,True,PP_ALIGN.CENTER) footer(s,5,'Source: Parikh, Textbook of Medical Jurisprudence, “Bruises (Contusions)”; DiMaio, Forensic Pathology') # 6 classification s=prs.slides.add_slide(blank); title(s,'5. Types','Contusions can involve different tissues') items=[('Superficial / skin','Visible bruise in subcutaneous tissue',TEAL),('Muscle','Pain, swelling, weakness, limited contraction',ORANGE),('Bone bruise','Deep pain after impact; MRI may detect marrow edema',PURPLE),('Deep organ','Brain, lung, or heart contusions are trauma emergencies',RED)] for i,(h,b,c) in enumerate(items): x=.78+i*3.13 shape(s,MSO_SHAPE.ROUNDED_RECTANGLE,x,2.15,2.82,3.75,WHITE,LINE) shape(s,MSO_SHAPE.OVAL,x+.86,2.52,1.1,1.1,c,c) textbox(s,x+.28,3.93,2.28,.36,h,16,NAVY,True,PP_ALIGN.CENTER) textbox(s,x+.30,4.46,2.22,.72,b,12,MUTED,False,PP_ALIGN.CENTER) textbox(s,.9,6.30,11.5,.35,'This presentation focuses on uncomplicated superficial and muscle contusions, not internal-organ trauma.',13,TEAL,True,PP_ALIGN.CENTER) footer(s,6,'Source: Rosen’s Emergency Medicine; Rockwood and Green’s Fractures in Adults') # 7 assessment s=prs.slides.add_slide(blank); title(s,'6. Initial assessment','A structured check after an injury') steps=[('History','What happened? When? Force and location? Medicines and bleeding history?'),('Inspect','Skin integrity, expanding bruising, deformity, color, symmetry.'),('Palpate','Tenderness, warmth, swelling, firmness, distal pulses and sensation.'),('Function','Range of motion, ability to bear weight or use the limb.'),('Consider imaging','If fracture, deep injury, severe pain, or organ trauma is suspected.')] for i,(h,b) in enumerate(steps): y=1.95+i*.88 shape(s,MSO_SHAPE.OVAL,.90,y,.54,.54,TEAL,TEAL); textbox(s,1.08,y+.14,.18,.14,str(i+1),10,WHITE,True,PP_ALIGN.CENTER) textbox(s,1.72,y+.02,2.0,.24,h,15,NAVY,True); textbox(s,3.75,y+.02,8.0,.36,b,13,INK) footer(s,7,'General clinical teaching framework. Severe trauma requires urgent professional assessment.') #8 RICE s=prs.slides.add_slide(blank); title(s,'7. Early management','Protect the injured part and control symptoms') steps=[('R','REST','Stop the activity and protect the area from further impact.',TEAL),('I','ICE','Use a cold pack wrapped in cloth for short intervals. Do not place ice directly on skin.',SKY),('C','COMPRESSION','A light elastic wrap may limit swelling. It must not cause numbness, pallor, or worsening pain.',PURPLE),('E','ELEVATION','Raise the area above heart level when practical to help reduce swelling.',GREEN)] for i,(letter,h,b,c) in enumerate(steps): x=.72+i*3.12 shape(s,MSO_SHAPE.ROUNDED_RECTANGLE,x,2.15,2.78,3.7,WHITE,LINE) shape(s,MSO_SHAPE.OVAL,x+.88,2.55,1.02,1.02,c,c) textbox(s,x+.88,2.78,1.02,.3,letter,24,NAVY if c==SKY else WHITE,True,PP_ALIGN.CENTER) textbox(s,x+.35,3.85,2.1,.3,h,16,NAVY,True,PP_ALIGN.CENTER) textbox(s,x+.30,4.35,2.2,1.0,b,12,MUTED,False,PP_ALIGN.CENTER) textbox(s,.85,6.25,11.7,.40,'For pain relief, use medicines only as appropriate for the person. Ask a clinician or pharmacist if taking blood thinners or if bleeding risk is a concern.',12,RED,True,PP_ALIGN.CENTER) footer(s,8,'Source: Mayo Clinic, Bruise: First aid (accessed 2026)') #9 red flags s=prs.slides.add_slide(blank); title(s,'8. Red flags','When a “bruise” needs medical evaluation') left=['Rapidly increasing pain or swelling','Numbness, weakness, coldness, or color change beyond the injury','Inability to bear weight or use the limb','Suspected fracture, joint injury, or a very large hematoma'] right=['Bruise after significant head, chest, or abdominal trauma','Repeated unexplained bruises or bleeding from other sites','A person taking anticoagulants with substantial bruising','Fever, worsening redness, drainage, or no improvement as expected'] shape(s,MSO_SHAPE.ROUNDED_RECTANGLE,.75,2.05,5.85,3.95,RGBColor(255,245,245),RGBColor(244,199,199)); textbox(s,1.05,2.38,4.8,.3,'Urgent assessment',19,RED,True) bullets(s,1.05,2.95,5.1,left,14,INK,12) shape(s,MSO_SHAPE.ROUNDED_RECTANGLE,6.75,2.05,5.85,3.95,RGBColor(247,249,253),LINE); textbox(s,7.05,2.38,4.8,.3,'Clinical review',19,NAVY,True) bullets(s,7.05,2.95,5.1,right,14,INK,12) footer(s,9,'Source: Mayo Clinic, Bruise: First aid; emergency assessment principles') #10 course s=prs.slides.add_slide(blank); title(s,'9. Expected course','Healing and follow-up') # timeline line=s.shapes.add_connector(MSO_CONNECTOR.STRAIGHT,Inches(1.2),Inches(3.65),Inches(12.05),Inches(3.65)); line.line.color.rgb=TEAL; line.line.width=Pt(4) stages=[('Early','Tender, swollen\nred-blue',RED),('Days later','Blue-purple\nto green-yellow',PURPLE),('Recovery','Less pain and\ncolor gradually fades',GREEN),('Review if atypical','Persistent, recurrent,\nor worsening symptoms',ORANGE)] for i,(h,b,c) in enumerate(stages): x=1.18+i*3.58; shape(s,MSO_SHAPE.OVAL,x,3.18,.92,.92,c,c) textbox(s,x-.12,2.25,1.2,.32,h,14,NAVY,True,PP_ALIGN.CENTER); textbox(s,x-.35,4.30,1.62,.6,b,12,MUTED,False,PP_ALIGN.CENTER) textbox(s,.9,5.95,11.55,.42,'Colour changes vary with depth, location, skin pigmentation, and individual healing. Do not use colour alone to accurately date an injury.',13,RED,True,PP_ALIGN.CENTER) footer(s,10,'Source: DiMaio, Forensic Pathology; Parikh, Textbook of Medical Jurisprudence') #11 prevention s=prs.slides.add_slide(blank); title(s,'10. Prevention','Reducing the risk of contusions') pre=[('At home','Clear trip hazards, improve lighting, use stable footwear.'),('In sport','Use appropriate protective equipment, warm up, and follow safe technique.'),('At work','Follow safety procedures and wear required personal protective equipment.'),('Medication safety','Know if medicines raise bleeding risk; do not stop prescribed drugs without advice.')] for i,(h,b) in enumerate(pre): x=.83+(i%2)*6.1;y=2.1+(i//2)*2.0 shape(s,MSO_SHAPE.ROUNDED_RECTANGLE,x,y,5.65,1.45,WHITE,LINE); shape(s,MSO_SHAPE.OVAL,x+.30,y+.34,.72,.72,[TEAL,ORANGE,PURPLE,GREEN][i],[TEAL,ORANGE,PURPLE,GREEN][i]) textbox(s,x+1.25,y+.28,3.9,.28,h,16,NAVY,True); textbox(s,x+1.25,y+.73,4.0,.36,b,12,MUTED) footer(s,11) #12 summary s=prs.slides.add_slide(blank); title(s,'11. Take-home messages','Contusion: the essentials') summary=[('Closed blunt injury','Skin is usually intact, but vessels beneath it are injured.'),('Assess beyond the color','Mechanism, pain, swelling, function, and neurovascular status matter.'),('Early care is supportive','Rest, protected cold application, compression when appropriate, and elevation can help.'),('Know the warning signs','Severe trauma, expanding symptoms, impaired function, or unexplained bruising needs evaluation.')] for i,(h,b) in enumerate(summary): card(s,.82+(i%2)*6.05,2.02+(i//2)*1.95,5.56,1.5,h,b,[TEAL,PURPLE,ORANGE,RED][i]) footer(s,12) #13 references s=prs.slides.add_slide(blank); title(s,'References','Selected sources') refs=[ 'Mayo Clinic. Bruise: First aid. https://www.mayoclinic.org/first-aid/first-aid-bruise/basics/art-20056663 (accessed October 2026).', 'Parikh CK. Parikh’s Textbook of Medical Jurisprudence, Forensic Medicine and Toxicology. Section: Bruises (Contusions).', 'DiMaio VJM, DiMaio D. Forensic Pathology. Section: Dating of Contusions.', 'Rosen’s Emergency Medicine: Concepts and Clinical Practice. Trauma assessment content.', 'Rockwood and Green’s Fractures in Adults, 10th ed. Pulmonary Contusion chapter, for the distinction between superficial and internal contusions.' ] bullets(s,.9,2.0,11.7,refs,14,INK,15) shape(s,MSO_SHAPE.ROUNDED_RECTANGLE,.9,5.85,11.55,.62,RGBColor(255,248,231),RGBColor(244,220,163)); textbox(s,1.15,6.06,11.05,.22,'This educational deck is not a substitute for assessment by a qualified healthcare professional.',12,RED,True,PP_ALIGN.CENTER) footer(s,13) # add notes perhaps not necessary prs.core_properties.title='Contusion: Assessment and First Aid' prs.core_properties.subject='Educational presentation' prs.core_properties.author='Orris' prs.save(OUT) print(OUT, OUT.stat().st_size) PY

Running Command

python - <<'PY' from pptx import Presentation p='/tmp/workspace/contusion-presentation/output/Contusion_Presentation.pptx' prs=Presentation(p) print('slides:', len(prs.slides)) for i, slide in enumerate(prs.slides,1): texts=[sh.text.replace('\n',' | ') for sh in slide.shapes if getattr(sh,'has_text_frame',False) and sh.text.strip()] print(f'{i}:', ' :: '.join(texts[:3])) PY python - <<'PY' from zipfile import ZipFile p='/tmp/workspace/contusion-presentation/output/Contusion_Presentation.pptx' with ZipFile(p) as z: bad=z.testzip() print('zip_valid:', bad is None) PY

Created a 13-slide PowerPoint presentation on Contusion covering definition, mechanism, causes, clinical features, assessment, RICE-based early care, red flags, prevention, and references.

Add clinical images and diagrams to the presentation

Reading File
Reading File
Searching Images

clinical photograph contusion bruise skin soft tissue injury

Searching Images

medical illustration diagram contusion bruising blood vessels under skin

Searching Images

muscle contusion ultrasound MRI medical image

Searching the Web

contusion bruise clinical image diagram public domain medical

Reading File
Reading Web Page

https://medlineplus.gov/bruises.html

Loading Image
Loading Image
Browsing Directory

~/contusion-presentation/

Generating Image

Educational medical cutaway diagram of a superficial soft-tissue contusion: unbroken skin, damaged capillaries beneath the skin, small localized blood collection, labeled skin, subcutaneous tissue, capillary rupture, and bruising. No patient, no text other than these labels.

Running Command

python /tmp/skills/shared/scripts/fetch_images.py "https://cdn.orris.care/image-gen/69ca82114c264f9b831c7e8b59a1f52c.png" "https://orthoinfo.aaos.org/contentassets/8910bd6df8094cf98d6bbbb799751f54/a00802f01.jpg" "https://orthoinfo.aaos.org/contentassets/129f16d731104d14a49ecd4a14c822a6/gettyimages-1456719242-2.jpg" "https://medlineplus.gov/images/Bruises_share.jpg" > "/tmp/workspace/contusion-presentation/assets_fetch.json"

Running Command

python - <<'PY' import json p='/tmp/workspace/contusion-presentation/assets_fetch.json' with open(p) as f: d=json.load(f) for item in d: print(item['url'], bool(item.get('base64')), item.get('error')) PY

Browsing Directory

~/

Running Command

mkdir -p "/tmp/workspace/contusion-presentation/assets"; python - <<'PY' import json,base64 from pathlib import Path items=json.load(open('/tmp/workspace/contusion-presentation/assets_fetch.json')) for i,item in enumerate(items): mime,data=item['base64'].split(',',1) ext='.png' if 'png' in mime else '.jpg' path=Path('/tmp/workspace/contusion-presentation/assets')/f'asset_{i}{ext}' path.write_bytes(base64.b64decode(data)) print(path) PY

Reading File
Reading File
Reading File
Reading File
Running Command

python - <<'PY' from PIL import Image,ImageDraw from pathlib import Path ps=list(Path('/tmp/workspace/contusion-presentation/assets').glob('*')) ims=[] for p in ps: im=Image.open(p).convert('RGB'); im.thumbnail((360,240)); ims.append((p.name,im.copy())) out=Image.new('RGB',(760,600),'white'); d=ImageDraw.Draw(out) for i,(name,im) in enumerate(ims): x=(i%2)*380+10;y=(i//2)*300+25 out.paste(im,(x,y));d.text((x,y+250),name,fill='black') out.save('/tmp/workspace/contusion-presentation/assets/contact.jpg') print('created') PY

Reading File
Generating Image

Educational medical infographic diagram showing first aid for a limb contusion in four sequential panels: resting an injured lower leg, a cloth-wrapped cold pack placed on a bruise, gentle elastic compression bandage, and leg elevated on pillows. Clean realistic clinical illustration, no text, no logos.

Running Command

python /tmp/skills/shared/scripts/fetch_images.py "https://cdn.orris.care/image-gen/c3005436c5b64d32b08fd05bf117d9c2.png" > "/tmp/workspace/contusion-presentation/rice_fetch.json" && python - <<'PY' import json,base64 from pathlib import Path item=json.load(open('/tmp/workspace/contusion-presentation/rice_fetch.json'))[0] raw=base64.b64decode(item['base64'].split(',',1)[1]) path=Path('/tmp/workspace/contusion-presentation/assets/rice_diagram.png');path.write_bytes(raw);print(path, path.stat().st_size) PY

Running Command

python - <<'PY' from PIL import Image from pathlib import Path for p in Path('/tmp/workspace/contusion-presentation/assets').glob('*'): try: im=Image.open(p) print(p.name, im.size, im.mode) except: pass from pptx import Presentation p='/tmp/workspace/contusion-presentation/output/Contusion_Presentation.pptx' prs=Presentation(p) print('existing slides',len(prs.slides)) PY

Running Command

python - <<'PY' from pptx import Presentation from pptx.util import Inches, Pt from pptx.enum.shapes import MSO_SHAPE, MSO_CONNECTOR from pptx.enum.text import PP_ALIGN, MSO_ANCHOR from pptx.dml.color import RGBColor from PIL import Image from pathlib import Path src=Path('/tmp/workspace/contusion-presentation/output/Contusion_Presentation.pptx') out=Path('/tmp/workspace/contusion-presentation/output/Contusion_Presentation_with_Clinical_Images_and_Diagrams.pptx') assets=Path('/tmp/workspace/contusion-presentation/assets') prs=Presentation(src) blank=prs.slide_layouts[6] NAVY=RGBColor(25,45,76); TEAL=RGBColor(25,131,137); INK=RGBColor(32,43,55); MUTED=RGBColor(93,105,118); WHITE=RGBColor(255,255,255); LINE=RGBColor(211,220,226); PALE=RGBColor(246,248,250); RED=RGBColor(178,48,65); ORANGE=RGBColor(223,126,50) def rect(slide,x,y,w,h,fill,line=None,typ=MSO_SHAPE.RECTANGLE): s=slide.shapes.add_shape(typ, Inches(x), Inches(y), Inches(w), Inches(h));s.fill.solid();s.fill.fore_color.rgb=fill;s.line.color.rgb=line or fill;s.line.width=Pt(.6);return s def txt(slide,x,y,w,h,text,size=18,color=INK,bold=False,align=PP_ALIGN.LEFT): b=slide.shapes.add_textbox(Inches(x),Inches(y),Inches(w),Inches(h));tf=b.text_frame;tf.clear();tf.word_wrap=True;tf.margin_left=tf.margin_right=tf.margin_top=tf.margin_bottom=0 p=tf.paragraphs[0];p.alignment=align;r=p.add_run();r.text=text;r.font.name='Aptos';r.font.size=Pt(size);r.font.bold=bold;r.font.color.rgb=color;return b def header(slide,kicker,heading,sub=''): txt(slide,.65,.35,12,.23,kicker.upper(),10,TEAL,True) txt(slide,.65,.67,12,.5,heading,28,NAVY,True) if sub: txt(slide,.66,1.30,12,.26,sub,12,MUTED) l=slide.shapes.add_connector(MSO_CONNECTOR.STRAIGHT,Inches(.65),Inches(1.72),Inches(12.67),Inches(1.72));l.line.color.rgb=LINE;l.line.width=Pt(1) def footer(slide,n,src): txt(slide,.65,7.12,11.3,.18,src,8,MUTED);txt(slide,12.28,7.08,.4,.2,str(n),9,TEAL,True,PP_ALIGN.RIGHT) def add_crop(slide,path,x,y,w,h): # Picture aspect-cropped to fill a box im=Image.open(path); iw,ih=im.size; target=w/h; ar=iw/ih pic=slide.shapes.add_picture(str(path), Inches(x), Inches(y), width=Inches(w), height=Inches(h)) if ar>target: # source wider, crop left-right crop=(1-target/ar)/2;pic.crop_left=crop;pic.crop_right=crop else: crop=(1-ar/target)/2;pic.crop_top=crop;pic.crop_bottom=crop return pic # visual slide 1 s=prs.slides.add_slide(blank); header(s,'12. Clinical images','Clinical appearance of a contusion','Appearance differs with skin tone, depth of bleeding, and time after injury') rect(s,.72,2.02,5.82,3.88,WHITE,LINE,MSO_SHAPE.ROUNDED_RECTANGLE); add_crop(s,assets/'asset_1.jpg',.88,2.18,5.5,2.75) txt(s,.95,5.18,5.35,.27,'Clinical example: localized skin discoloration',14,NAVY,True,PP_ALIGN.CENTER) txt(s,.95,5.52,5.35,.23,'A superficial contusion may be painful and swollen even when the skin is intact.',10,MUTED,False,PP_ALIGN.CENTER) rect(s,6.79,2.02,5.82,3.88,WHITE,LINE,MSO_SHAPE.ROUNDED_RECTANGLE); add_crop(s,assets/'asset_3.jpg',6.95,2.18,5.5,2.75) txt(s,7.02,5.18,5.35,.27,'Bruise image: blood beneath unbroken skin',14,NAVY,True,PP_ALIGN.CENTER) txt(s,7.02,5.52,5.35,.23,'Clinical interpretation always depends on the history, examination, and associated symptoms.',10,MUTED,False,PP_ALIGN.CENTER) footer(s,14,'Image sources: AAOS OrthoInfo, “Muscle Contusion (Bruise)”; MedlinePlus, “Bruises.”') # slide diagram s=prs.slides.add_slide(blank); header(s,'13. Diagram','Anatomy of a superficial contusion','A cutaway view of vessel injury beneath intact skin') rect(s,.72,2.0,7.35,4.5,WHITE,LINE,MSO_SHAPE.ROUNDED_RECTANGLE); add_crop(s,assets/'asset_0.jpg',.87,2.15,7.05,4.17) rect(s,8.42,2.0,4.18,4.5,PALE,LINE,MSO_SHAPE.ROUNDED_RECTANGLE) txt(s,8.75,2.35,3.5,.28,'Interpret the diagram',17,NAVY,True) points=[('Intact surface','The skin may remain unbroken.'),('Vessel damage','Blunt force can rupture small vessels.'),('Extravasation','Blood enters the surrounding soft tissue.'),('Symptoms','Local pressure and inflammation contribute to tenderness and swelling.')] for i,(a,b) in enumerate(points): y=2.92+i*.77;rect(s,8.75,y,.36,.36,[TEAL,RED,ORANGE,RGBColor(93,65,127)][i],None,MSO_SHAPE.OVAL);txt(s,9.28,y-.01,2.9,.2,a,13,NAVY,True);txt(s,9.28,y+.25,2.95,.28,b,10,MUTED) footer(s,15,'Diagram generated for this educational presentation. Clinical basis: MedlinePlus, “Bruises.”') # RICE slide s=prs.slides.add_slide(blank); header(s,'14. Diagram','Visual guide to early supportive care','Supportive first aid for an uncomplicated limb contusion') rect(s,.72,1.98,8.2,4.54,WHITE,LINE,MSO_SHAPE.ROUNDED_RECTANGLE);add_crop(s,assets/'rice_diagram.png',.88,2.14,7.88,4.2) rect(s,9.25,1.98,3.35,4.54,PALE,LINE,MSO_SHAPE.ROUNDED_RECTANGLE) txt(s,9.57,2.30,2.7,.28,'Safety reminders',17,NAVY,True) for i,t in enumerate(['Wrap cold packs in cloth.','Do not apply ice directly to skin.','Compression should be light.','Stop and seek care if pain, numbness, pallor, or swelling worsens.']): y=2.95+i*.72;rect(s,9.57,y,.25,.25,RED if i==3 else TEAL,None,MSO_SHAPE.OVAL);txt(s,9.98,y-.02,2.25,.42,t,11,INK) footer(s,16,'Diagram generated for this educational presentation. First-aid principles: AAOS OrthoInfo, “Muscle Contusion (Bruise).”') # reorder: reference slide was index 13 (id position 12). Retain visuals before final references sldIdLst=prs.slides._sldIdLst refs=sldIdLst[12] sldIdLst.remove(refs);sldIdLst.append(refs) # page number references changed to 17 needs update only footer text placed original 13, looks hack alter footer text from '13' refslide=prs.slides[-1] for sh in refslide.shapes: if getattr(sh,'has_text_frame',False) and sh.text.strip()=='13': sh.text_frame.paragraphs[0].runs[0].text='17' # add 3 visual source references to references slide for sh in refslide.shapes: if getattr(sh,'has_text_frame',False) and 'Mayo Clinic. Bruise' in sh.text: # avoid adding too much unreadable content on existing list sh.text_frame.paragraphs[0].add_run().text='' prs.core_properties.title='Contusion: Clinical Images and Diagrams' prs.save(out) print(out, out.stat().st_size, 'slides',len(prs.slides)) PY

Running Command

python - <<'PY' from pptx import Presentation p='/tmp/workspace/contusion-presentation/output/Contusion_Presentation_with_Clinical_Images_and_Diagrams.pptx' prs=Presentation(p) print('slides:',len(prs.slides)) for i,s in enumerate(prs.slides,1): texts=[sh.text.replace('\n',' | ') for sh in s.shapes if getattr(sh,'has_text_frame',False) and sh.text.strip()] pics=sum(1 for sh in s.shapes if sh.shape_type==13) print(i, 'pics=',pics, 'title=',texts[1] if len(texts)>1 else texts[0] if texts else '') PY python - <<'PY' from zipfile import ZipFile p='/tmp/workspace/contusion-presentation/output/Contusion_Presentation_with_Clinical_Images_and_Diagrams.pptx' with ZipFile(p) as z: print('zip_valid:',z.testzip() is None) PY

Running Command

python - <<'PY' from pptx import Presentation p='/tmp/workspace/contusion-presentation/output/Contusion_Presentation_with_Clinical_Images_and_Diagrams.pptx' prs=Presentation(p) for sh in prs.slides[-1].shapes: if getattr(sh,'has_text_frame',False) and sh.text.strip()=='17': for para in sh.text_frame.paragraphs: for run in para.runs: run.text='16' prs.save(p) print('saved',len(prs.slides)) PY python - <<'PY' from zipfile import ZipFile p='/tmp/workspace/contusion-presentation/output/Contusion_Presentation_with_Clinical_Images_and_Diagrams.pptx' with ZipFile(p) as z: print('zip_valid:',z.testzip() is None) PY

Added clinical images and educational diagrams to the presentation, including:
  • Clinical examples of bruising/contusion
  • Soft-tissue cutaway diagram showing vessel injury and extravasated blood
  • Visual RICE first-aid diagram
  • Source credits for the clinical images and diagrams
You can reply with a topic name or "continue" to go deeper with a fresh budget.
This is a shared conversation. Sign in to Orris to start your own chat.