record Models-are-stateless insert and sentinel double-increment fix in agent learnings
Adds a Learnings entry for the 2026-04-30 slide-10 insert: documents the styled-HTML approach chosen (no PNG asset existed for this dialog), the slide-12 caption-strip pattern reuse, and a postmortem for the sentinel-replacement collision where pre-resolving ##S10## to "11" before running the n=11..48 loop double-incremented old-slide-10 to "12". Adds two forward-looking rules: (1) use distinct sentinel prefixes or single-pass resolution when mixing pre-resolved and loop-resolved slides, and (2) check raw file content for literal apostrophes vs HTML entities when pattern-matching comment strings. Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -149,3 +149,4 @@ _Findings from previous executions are recorded here. Add new entries as bullet
|
||||
- **2026-04-30 inline `<!-- SLIDE N: ... -->` comment-drift state**: the deck inherited heavy drift from the GDG fork (19 of 22 banners were misaligned; only SLIDE 1, SLIDE 9, SLIDE 10 happened to be correct). All 19 were repaired in the colleague-intro removal pass, and the deck is now in a clean state where every `<!-- SLIDE N: ... -->` comment matches its `data-slide="N"` value. **Rule**: future insert/delete/renumber operations MUST fix these comments in the same pass to keep the file readable for manual navigation — do not let the drift re-accumulate. Treat `data-slide` as source of truth, comment as the narrative aid.
|
||||
- **2026-04-30 slide-1 H1 rename to "Claude Code Best Practice"**: completed the deck-identity unification. Slide-1 H1 was originally "Agentic Engineering in the CLI" (preserved on 2026-04-30 during the initial rename on the theory that it was the *topic* of the talk, not the *deck name*). User explicitly corrected that judgment — they want every slide-1 surface to read as the same identity. Slide-1 H1 is now "Claude Code Best Practice" (matching `<title>`, GitHub repo `claude-code-best-practice`, and the badge URL). Inline H1 styling preserved exactly: `style="font-size: 3.2rem; letter-spacing: -0.02em; margin-bottom: 16px;"`. **Rule**: for any future deck-rename, update slide-1 H1 as part of the same coordinated set with `<title>`, slide-1 subtitle, and identity badges — don't treat H1 as a separate "topic" surface.
|
||||
- **2026-04-30 deck identity surfaces (final state after rename + H1 unification)**: every visible slide-1 element now points to the same identity. (1) `<title>` = "Claude Code Best Practice"; (2) Slide-1 HTML banner comment = "SLIDE 1: Claude Code Best Practice — Title"; (3) Slide-1 H1 = "Claude Code Best Practice"; (4) Slide-1 subtitle = "Practical patterns for [Claude logo] Claude Code"; (5) GitHub badge = `github.com/shanraisshan/claude-code-best-practice`; (6) favicon = `claude-jumping.svg`. **Known echo (feature, not bug)**: subtitle's "Claude Code" repeats text from the H1 — this is the normal "[Brand] Best Practices / Practical patterns for [Brand]" pattern (e.g. "React Best Practices / Practical patterns for React") and should NOT be auto-fixed unless the user explicitly asks. Only differentiate if the user requests it (e.g. subtitle could become "Practical patterns for agentic CLI workflows" or similar).
|
||||
- **2026-04-30 "Models are stateless" slide inserted at position 10 (48 → 49 slides)**: new slide drawn as styled-HTML-divs (no PNG asset exists for this diagram). Approach mirrors slide-12 conventions — centered block with generous whitespace, caption strip below with bold headline + accent-color subtitle. Dialog rendered as two CSS bubble columns (User = blue left-aligned; Model = purple right-aligned; error response = pink). A dashed amber divider with "new session — context wiped" label separates the two turn-pairs to visualize the statelessness. No new CSS classes introduced — all layout done via inline styles matching the surrounding slides. Sentinel-replacement bug encountered: resolving `##SN10##` → `"11"` before the bulk n=11..48 loop caused old-slide-10 to be double-incremented to `"12"` — fixed by a targeted string replacement of the affected div. **Rule for future inserts**: when using sentinel-replace for a mix of pre-resolved and loop-resolved slides, either (a) use a distinct sentinel prefix that won't match the loop range, or (b) resolve ALL sentinels in a single final pass after all placeholders are set. The `<!-- SLIDE N: ... -->` comment for the orphaned old-slide-11 banner ("Limitations") had the literal apostrophe `we're` not the HTML entity `’` — check raw file content when pattern-matching comment strings, don't trust the HTML-encoded form. Slides 10 onwards have no `data-level` (they are pre-section content); the new slide follows this convention. Gemini mentions on slides now at positions 11 and 12 (previously 10 and 11) — still illustrative, still intentional.
|
||||
|
||||
Reference in New Issue
Block a user