Add token-count badge to README#71
Conversation
Greptile SummaryThis PR adds a single token-count badge to the README header, sourced from the
Confidence Score: 4/5Documentation-only README change; no application code is affected and the change is safe to merge as-is. The only changes are to a single README line. The badge renders through shields.io as a proxy, so no user data is directly exposed to the third-party service. The two minor observations — missing link wrapper and external service availability — do not affect runtime behavior of the project itself. README.md — the badge line warrants a quick look for the missing link and the decision about accepting an external service dependency. Important Files Changed
Sequence Diagram%%{init: {'theme': 'neutral'}}%%
sequenceDiagram
participant Browser as GitHub/Browser
participant Shields as shields.io
participant GitTokens as gittokens.rsamf.com
Browser->>Shields: "GET /endpoint?url=https://gittokens.rsamf.com/badge/..."
Shields->>GitTokens: GET /badge/JCodesMore/ai-website-cloner-template
GitTokens-->>Shields: JSON badge data (label, message, color)
Shields-->>Browser: Rendered SVG badge image
%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%%
sequenceDiagram
participant Browser as GitHub/Browser
participant Shields as shields.io
participant GitTokens as gittokens.rsamf.com
Browser->>Shields: "GET /endpoint?url=https://gittokens.rsamf.com/badge/..."
Shields->>GitTokens: GET /badge/JCodesMore/ai-website-cloner-template
GitTokens-->>Shields: JSON badge data (label, message, color)
Shields-->>Browser: Rendered SVG badge image
Reviews (1): Last reviewed commit: "docs: add token-count badge to README" | Re-trigger Greptile |
| # AI Website Cloner Template | ||
|
|
||
| <a href="https://github.com/JCodesMore/ai-website-cloner-template/blob/master/LICENSE"><img src="https://img.shields.io/badge/license-MIT-blue" alt="MIT License" /></a> <a href="https://github.com/JCodesMore/ai-website-cloner-template/stargazers"><img src="https://img.shields.io/github/stars/JCodesMore/ai-website-cloner-template?style=flat" alt="Stars" /></a> <a href="https://discord.gg/hrTSX5yTpB"><img src="https://img.shields.io/discord/1400896964597383279?label=discord" alt="Discord" /></a> | ||
| <a href="https://github.com/JCodesMore/ai-website-cloner-template/blob/master/LICENSE"><img src="https://img.shields.io/badge/license-MIT-blue" alt="MIT License" /></a> <a href="https://github.com/JCodesMore/ai-website-cloner-template/stargazers"><img src="https://img.shields.io/github/stars/JCodesMore/ai-website-cloner-template?style=flat" alt="Stars" /></a> <a href="https://discord.gg/hrTSX5yTpB"><img src="https://img.shields.io/discord/1400896964597383279?label=discord" alt="Discord" /></a> <img src="https://img.shields.io/endpoint?url=https://gittokens.rsamf.com/badge/JCodesMore/ai-website-cloner-template" alt="tokens" /> |
There was a problem hiding this comment.
Badge lacks a link, inconsistent with other badges
The new token badge is the only one in the row not wrapped in an <a> tag — the license, stars, and Discord badges all link to a relevant destination. Wrapping it in <a href="https://gittokens.rsamf.com">...</a> would keep the row consistent and give curious visitors somewhere to go.
Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
| # AI Website Cloner Template | ||
|
|
||
| <a href="https://github.com/JCodesMore/ai-website-cloner-template/blob/master/LICENSE"><img src="https://img.shields.io/badge/license-MIT-blue" alt="MIT License" /></a> <a href="https://github.com/JCodesMore/ai-website-cloner-template/stargazers"><img src="https://img.shields.io/github/stars/JCodesMore/ai-website-cloner-template?style=flat" alt="Stars" /></a> <a href="https://discord.gg/hrTSX5yTpB"><img src="https://img.shields.io/discord/1400896964597383279?label=discord" alt="Discord" /></a> | ||
| <a href="https://github.com/JCodesMore/ai-website-cloner-template/blob/master/LICENSE"><img src="https://img.shields.io/badge/license-MIT-blue" alt="MIT License" /></a> <a href="https://github.com/JCodesMore/ai-website-cloner-template/stargazers"><img src="https://img.shields.io/github/stars/JCodesMore/ai-website-cloner-template?style=flat" alt="Stars" /></a> <a href="https://discord.gg/hrTSX5yTpB"><img src="https://img.shields.io/discord/1400896964597383279?label=discord" alt="Discord" /></a> <img src="https://img.shields.io/endpoint?url=https://gittokens.rsamf.com/badge/JCodesMore/ai-website-cloner-template" alt="tokens" /> |
There was a problem hiding this comment.
External service dependency with no fallback
The badge pulls live data from gittokens.rsamf.com via shields.io's endpoint proxy. If the service becomes unavailable or the URL format changes, the badge will show a broken/error state on every page load of the README. Since this is a community-maintained open-source service run by the PR author rather than an established provider, the repo maintainers should be comfortable accepting that availability dependency. Consider whether a static pre-computed badge (e.g. https://img.shields.io/badge/tokens-~Xk-blue) would serve the use case with less fragility.
Hi! This PR adds one line to the README: a badge showing an estimate of how many LLM tokens this repo weighs. Since this project is the kind of thing people load into an LLM's context window, the number seemed genuinely useful to surface.
Preview:
Full disclosure: I built the free, open-source service behind the badge (https://github.com/rsamf/gittokens), and I'm proposing it to a small, hand-picked set of repos where it seems like a good fit. If it isn't a fit here, please just close this, and I won't resubmit.