Skip to content

feat(tok): add opt-in live secret verification and exact token counting#71

Merged
Patel230 merged 1 commit into
mainfrom
feat/tok-live-secret-verification
Jul 15, 2026
Merged

feat(tok): add opt-in live secret verification and exact token counting#71
Patel230 merged 1 commit into
mainfrom
feat/tok-live-secret-verification

Conversation

@Patel230

Copy link
Copy Markdown
Contributor

Summary

Adds opt-in live secret verification and exact token counting to tok.

Verification

  • go build ./..., go test ./... pass

DetectSecretsVerified adds TruffleHog-style live-credential verification
(GitHub, Slack, Stripe, AWS key pairs) behind an explicit opt-in call —
DetectSecrets itself is unchanged and still makes zero network calls.
CountTokensExact adds an opt-in path to get real Claude/Gemini token
counts via their count-tokens APIs, since neither publishes an offline
tokenizer; the existing cl100k_base-approximated EstimateTokens family is
unchanged, with doc comments now stating plainly that it's an
approximation for those two providers.
@Patel230
Patel230 merged commit bfbfb35 into main Jul 15, 2026
20 checks passed
@Patel230
Patel230 deleted the feat/tok-live-secret-verification branch July 15, 2026 19:02
Patel230 added a commit that referenced this pull request Jul 16, 2026
feat(tok): add opt-in live secret verification and exact token counting
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant