Skip to content

Commit 4a822da

Browse files
Fix three docstring inconsistencies per PR review
Three CoPilot findings on PR #116: 1. main.py docstring referenced PlaceholderSegment(name="history") but the actual field is named ``placeholder``. The code's chat-template construction uses ``placeholder=`` correctly; only the docstring narrative was wrong. A reader copy-pasting from the docstring would have hit a Pydantic ValidationError. 2. Walk-through doc's intro paragraph still said "Apollo 11 Lunar Module" after the image URL swap to the Apollo 16 "Orion" shot. The code's docstring + inline comment got updated when the URL changed but the walk-through intro was missed. 3. Sample "Reading the output" block showed an ``upload.wikimedia.org`` image URL the example explicitly warns against. Updated to the actual default ``images-assets.nasa.gov`` URL so the sample matches a real run.
1 parent 40c4ebf commit 4a822da

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

docs/examples/11-chat-with-multimodal.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
A lunar-mission Q&A assistant that maintains conversation context
44
across four turns. One mid-conversation turn includes an attached
5-
photograph (Apollo 11 Lunar Module on the lunar surface): the user
6-
asks about it, the agent processes the multimodal turn naturally
7-
without changing the chat-history shape.
5+
photograph (Apollo 16 Lunar Module "Orion" on the lunar surface):
6+
the user asks about it, the agent processes the multimodal turn
7+
naturally without changing the chat-history shape.
88

99
## Overview
1010

@@ -115,7 +115,7 @@ LLM, and updates state.
115115

116116
```
117117
=== openarmature chat-with-multimodal demo ===
118-
Image URL: https://upload.wikimedia.org/...
118+
Image URL: https://images-assets.nasa.gov/image/as16-113-18334/...
119119
Scripted turns: 4
120120
121121
--- Turn 0 ---

examples/11-chat-with-multimodal/main.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
which switches the user `ContentSegment.content` between a single
2525
text template (text-only turn) and a `[TextBlockTemplate,
2626
ImageURLBlockTemplate]` list (multimodal turn). The system segment
27-
and the `PlaceholderSegment(name="history")` slot are identical
27+
and the `PlaceholderSegment(placeholder="history")` slot are identical
2828
across both shapes; only the trailing user segment changes.
2929
- Chat history lives on state as `history: Annotated[list[Message],
3030
append]`. After each turn the node appends two messages (the new

0 commit comments

Comments
 (0)