Agent skill · marketing growth · jeremylongshore

groq-data-handling

Use when you need to keep PII out of Groq API calls, filter model responses, audit-log conversations, or track token cost and usage for a Groq integration. Implements prompt sanitization, PII redaction, response filtering, and usage tracking. Trigger with phrases like "groq data", "groq PII", "groq GDPR", "groq data retention", "groq privacy", "groq compliance".

Why this skill is useful

Provides specific implementation patterns for PII handling and usage tracking in Groq API calls that the AI wouldn't reliably generate on its own.

What it needs

Requires groq-sdk, node installed locally. Requires groq account access. About 3k tokens when loaded. Last updated 2026-08-07. 2,604 stars on the source repository.

What this skill does

Groq Data Handling Overview Manage data flowing through Groq's inference API. This skill wires a privacy pipeline around the Groq SDK: sanitize prompts before they are sent, filter responses after they return, redact PII, hash-log an audit trail, and track token usage and cost. Key fact: Groq does not use API data for model training (Groq Privacy Policy). Prerequisites Node.js project with the groq-sdk package installed (npm i groq-sdk). A Groq API key exported as GROQAPIKEY. The SDK reads it automatically from the environment — new Groq() needs no explicit argument. Never hardcode the key; keep it in an untracked .env or your secret manager. Node's built-in crypto module (for the audit hash) — no install needed. Instructions The pipeline layers in four stages; drop simple add-ons (moderation, cost reporting) on top. Each snippet below is the skeleton — the full, copy-ready code for every stage is in references/implementation.md. 1. Sanitize input — run a PII rule table over every message before it leaves your process, flagging which categories were caught: 2. Wrap the completion call — call safeCompletion(...) instead of the raw groq.chat.completions.create, so input and response both pass the sanitizer. 3. Track usage — trackUsage(model, completion.usage, sessionId) records token counts and estimated cost per call using a per-model price table. 4. Audit — auditedCompletion(...) ties it together and logs a SHA-256 hash of the prompt (never the prompt text) so the audit trail carries no sensitive content. For content moderation via Llama Guard and a daily cost report, see references/examples.md. Groq data policy Groq does not train on API request/response data. Prompts and completions are processed and discarded. Groq may temporarily log requests for abuse prevention. For enterprise: contact Groq for DPA and SOC 2 compliance details. …

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills jeremylongshore/groq-data-handling

View the source on GitHub

Browse the @skills marketplace