Add view-tracking pixels to README and notebooks#22
Conversation
Adds the 1x1 analytics view pixel (same pattern RAG_Techniques already uses) to the README and to all 22 notebooks, pointing at this repo's own views tracker (prompt-eng-tracker). Previously the repo had only click links (routed through the RAG tracker) and no view pixel, so README/notebook page views were never recorded. Each notebook gets a unique notebook= slug using the existing -- hierarchy convention. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
📝 WalkthroughWalkthroughThis PR adds embedded analytics tracking images across the repository's educational documentation. A tracker image is inserted into README.md and appended to all 22 Jupyter notebooks in ChangesPrompt Engineering Tracker Analytics Integration
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~5 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 Ruff (0.15.15)all_prompt_engineering_techniques/prompt-formatting-structure.ipynbUnexpected end of JSON input all_prompt_engineering_techniques/negative-prompting.ipynbUnexpected end of JSON input all_prompt_engineering_techniques/basic-prompt-structures.ipynbUnexpected end of JSON input
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 4
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@all_prompt_engineering_techniques/instruction-engineering-notebook.ipynb`:
- Around line 452-457: The notebook currently embeds a remote tracking pixel via
the markdown image URL
("https://europe-west1-prompt-eng-views-tracker.cloudfunctions.net/prompt-eng-tracker?notebook=all-prompt-engineering-techniques--instruction-engineering-notebook")
which issues third-party requests on render; add a visible privacy disclosure
directly above that markdown cell describing what metadata may be collected and
why, and gate the pixel behind explicit consent (e.g., replace the direct image
with a consent button or toggle that, when enabled by the user, loads the
external image), or proxy/replace the external call so no third‑party request
fires without consent; ensure the disclosure is prominent, includes an opt-out,
and that the image URL is not requested until consent is granted.
In `@all_prompt_engineering_techniques/prompt-security-and-safety.ipynb`:
- Around line 417-422: The notebook contains a passive tracking pixel embedded
as the markdown image reference
"";
replace or augment this with a visible privacy disclosure and an opt-out/opt-in
mechanism: add a short markdown notice above the image explaining what metadata
the pixel collects and why, provide a documented opt-out option (e.g.,
remove/replace the image URL or toggle to disable tracking) and link to
documentation that records the opt-out procedure, and ensure the image is not
requested automatically without explicit consent (e.g., remove the image tag or
conditionally render it after consent) so the pixel cannot fire on notebook
render.
In `@README.md`:
- Line 384: Add a short privacy disclosure immediately adjacent to the README
pixel line (the image URL containing
"https://europe-west1-prompt-eng-views-tracker.cloudfunctions.net/prompt-eng-tracker?notebook=main-readme")
explaining that the remote endpoint receives a passive view ping (e.g.,
timestamp, viewer IP/referrer/agent or a basic view count), the purpose
(aggregate README view metrics), and how to avoid it (disable remote image
loading, block that domain, or remove the image line). Place this as a one- or
two-sentence "Privacy" note next to the existing image tag so readers see it
where the tracking pixel is embedded.
- Line 384: The tracker image tag currently has empty alt text; update the image
markdown to include a concise, descriptive alt attribute (e.g., "Prompt
engineering views tracker") so it passes accessibility linting—locate the image
markdown line containing the tracker URL and replace the empty alt (the ![]
part) with meaningful alt text inside the brackets.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: e4ffc3d6-89b7-4f72-b15a-dab7bb890d50
📒 Files selected for processing (23)
README.mdall_prompt_engineering_techniques/ambiguity-clarity.ipynball_prompt_engineering_techniques/basic-prompt-structures.ipynball_prompt_engineering_techniques/constrained-guided-generation.ipynball_prompt_engineering_techniques/cot-prompting.ipynball_prompt_engineering_techniques/ethical-prompt-engineering.ipynball_prompt_engineering_techniques/evaluating-prompt-effectiveness.ipynball_prompt_engineering_techniques/few-shot-learning.ipynball_prompt_engineering_techniques/instruction-engineering-notebook.ipynball_prompt_engineering_techniques/intro-prompt-engineering-lesson.ipynball_prompt_engineering_techniques/multilingual-prompting.ipynball_prompt_engineering_techniques/negative-prompting.ipynball_prompt_engineering_techniques/prompt-chaining-sequencing.ipynball_prompt_engineering_techniques/prompt-formatting-structure.ipynball_prompt_engineering_techniques/prompt-length-complexity-management.ipynball_prompt_engineering_techniques/prompt-optimization-techniques.ipynball_prompt_engineering_techniques/prompt-security-and-safety.ipynball_prompt_engineering_techniques/prompt-templates-variables-jinja2.ipynball_prompt_engineering_techniques/role-prompting.ipynball_prompt_engineering_techniques/self-consistency.ipynball_prompt_engineering_techniques/specific-task-prompts.ipynball_prompt_engineering_techniques/task-decomposition-prompts.ipynball_prompt_engineering_techniques/zero-shot-prompting.ipynb
| { | ||
| "cell_type": "markdown", | ||
| "metadata": {}, | ||
| "source": [ | ||
| "" | ||
| ] |
There was a problem hiding this comment.
Add explicit tracking disclosure/consent before embedding remote view pixels.
Line 456 introduces a third-party tracking request on notebook render, which can collect visitor metadata (e.g., IP/user-agent/referrer) without an explicit notice. Please add a visible privacy disclosure (and ideally an opt-out mechanism) where these pixels are introduced, or gate tracking behind explicit consent.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@all_prompt_engineering_techniques/instruction-engineering-notebook.ipynb`
around lines 452 - 457, The notebook currently embeds a remote tracking pixel
via the markdown image URL
("https://europe-west1-prompt-eng-views-tracker.cloudfunctions.net/prompt-eng-tracker?notebook=all-prompt-engineering-techniques--instruction-engineering-notebook")
which issues third-party requests on render; add a visible privacy disclosure
directly above that markdown cell describing what metadata may be collected and
why, and gate the pixel behind explicit consent (e.g., replace the direct image
with a consent button or toggle that, when enabled by the user, loads the
external image), or proxy/replace the external call so no third‑party request
fires without consent; ensure the disclosure is prominent, includes an opt-out,
and that the image URL is not requested until consent is granted.
| { | ||
| "cell_type": "markdown", | ||
| "metadata": {}, | ||
| "source": [ | ||
| "" | ||
| ] |
There was a problem hiding this comment.
Add explicit disclosure/consent for passive tracking pixels.
This hidden pixel causes automatic outbound requests on notebook render and can collect user metadata (e.g., IP/UA/referrer) without an in-repo disclosure or opt-out path. Please add a visible privacy notice and documented opt-out before rollout.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@all_prompt_engineering_techniques/prompt-security-and-safety.ipynb` around
lines 417 - 422, The notebook contains a passive tracking pixel embedded as the
markdown image reference
"";
replace or augment this with a visible privacy disclosure and an opt-out/opt-in
mechanism: add a short markdown notice above the image explaining what metadata
the pixel collects and why, provide a documented opt-out option (e.g.,
remove/replace the image URL or toggle to disable tracking) and link to
documentation that records the opt-out procedure, and ensure the image is not
requested automatically without explicit consent (e.g., remove the image tag or
conditionally render it after consent) so the pixel cannot fire on notebook
render.
|
|
||
| Keywords: Prompt Engineering, AI, Machine Learning, Natural Language Processing, LLM, Language Models, NLP, Conversational AI, Zero-Shot Learning, Few-Shot Learning, Chain of Thought | ||
|
|
||
|  |
There was a problem hiding this comment.
Add explicit tracking disclosure for the README view pixel.
Line 384 introduces passive analytics collection from a remote endpoint. Please add a short privacy notice in the README (what is collected, purpose, and how users can avoid it) so this is transparent and compliant with common OSS privacy expectations.
🧰 Tools
🪛 markdownlint-cli2 (0.22.1)
[warning] 384-384: Images should have alternate text (alt text)
(MD045, no-alt-text)
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@README.md` at line 384, Add a short privacy disclosure immediately adjacent
to the README pixel line (the image URL containing
"https://europe-west1-prompt-eng-views-tracker.cloudfunctions.net/prompt-eng-tracker?notebook=main-readme")
explaining that the remote endpoint receives a passive view ping (e.g.,
timestamp, viewer IP/referrer/agent or a basic view count), the purpose
(aggregate README view metrics), and how to avoid it (disable remote image
loading, block that domain, or remove the image line). Place this as a one- or
two-sentence "Privacy" note next to the existing image tag so readers see it
where the tracking pixel is embedded.
Provide alt text for the tracker image.
Line 384 uses an image with empty alt text; this fails markdown accessibility linting and is easy to fix.
Proposed fix
-
+📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
|  | |
|  |
🧰 Tools
🪛 markdownlint-cli2 (0.22.1)
[warning] 384-384: Images should have alternate text (alt text)
(MD045, no-alt-text)
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@README.md` at line 384, The tracker image tag currently has empty alt text;
update the image markdown to include a concise, descriptive alt attribute (e.g.,
"Prompt engineering views tracker") so it passes accessibility linting—locate
the image markdown line containing the tracker URL and replace the empty alt
(the ![] part) with meaningful alt text inside the brackets.
Source: Linters/SAST tools
What
Adds the 1x1 analytics view pixel to the README and to all 22 notebooks, pointing at this repo's own views tracker (
prompt-eng-tracker).Why
This repo currently records 0 views. It had only click links (routed through the RAG_Techniques tracker) and no view pixel, so README and notebook page views were never counted, unlike RAG_Techniques, which carries the same pixel.
Details
?notebook=main-readme).?notebook=<slug>using the existing--hierarchy convention.🤖 Generated with Claude Code
Summary by CodeRabbit