Agent skill

Groq Multi Env Setup

by jeremylongshore in jeremylongshore/tons-of-skills-marketplace

A skill your agent uses when you need Groq to behave differently across dev, staging, and production — cheap fast models and verbose logs in dev, the production model and hardened retries everywhere…

MITAuto-check: notesBackend & APIs

Install Groq Multi Env Setup

skills CLI
$ npx skills add jeremylongshore/tons-of-skills-marketplace --skill groq-multi-env-setup -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install jeremylongshore/tons-of-skills-marketplace groq-multi-env-setup --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/jeremylongshore/tons-of-skills-marketplace.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/.curated/groq-multi-env-setup .claude/skills/groq-multi-env-setup && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
groq-multi-env-setup
GitHub stars
2.8k
Token cost
~1.7k tokens
SKILL.md length
541 words
Files
3 (incl. references)
Skills in repo
3,342
Repo updated
First seen
Licence
MIT

At a glance

A skill your agent uses when you need Groq to behave differently across dev, staging, and production — cheap fast models and verbose logs in dev, the production model and hardened retries everywhere…

  • Works in 6 steps: Build the config module… → Wire an environment-aware service… → Source secrets per platform. Dev reads a… → …
  • You need Groq to behave differently across dev
  • SKILL.md covers Overview, Prerequisites, Environment Strategy and Instructions, plus 5 more sections
  • Calls npx and npm; needs GROQ_API_KEY

What it does

Groq Multi Env Setup is an agent skill from jeremylongshore/tons-of-skills-marketplace. Use when you need Groq to behave differently across dev, staging, and production — cheap fast models and verbose logs in dev, the production model and hardened retries everywhere else, with per-environment API keys. Configure environment-specific model selection, rate limits, and secrets. Trigger with phrases like "groq environments", "groq staging", "groq dev prod", "groq environment setup", "groq multi-env", "groq config by env".

Its SKILL.md is about 1.7k tokens, which your agent loads only when the skill is triggered. The skill folder holds 3 other files, including reference files (for example `references/implementation.md` and `references/secrets-and-deployment.md`). Compatibility notes: Designed for Claude Code

It sits in Backend & APIs, covering Rate limiting. The repository describes itself as: Model-agnostic agent-skills platform with a harness-free canonical layer, verified adapters, and the ccpi package manager. Explore at tonsofskills.com. The licence is MIT.

When your agent uses it

  • You need Groq to behave differently across dev
  • Production — cheap fast models and verbose logs in dev
  • The production model and hardened retries everywhere else
  • With per-environment API keys

Example prompts

  • “groq environments”
  • “groq staging”
  • “groq dev prod”
  • “/groq-multi-env-setup”

Requirements

  • Node.js
  • Docker
  • A credential in GROQ_API_KEY
  • Compatibility (from SKILL.md): Designed for Claude Code
  • Pre-approved tools (allowed-tools): Read, Write, Edit, Bash(aws:*), Bash(gcloud:*), Bash(vault:*)

Workflow steps

6 steps, taken from the first numbered list in SKILL.md.

  1. Build the config module (config/groq.ts). One configs record keyed by
  2. Wire an environment-aware service (services/groq-service.ts) that reads
  3. Source secrets per platform. Dev reads a git-ignored .env.local; staging
  4. Deploy with Docker Compose profiles so each environment injects its own
  5. Verify each environment with scripts/verify-groq-env.ts, which prints the
  6. Inspect rate limits per key via the x-ratelimit-* response headers — see

What it can do on your machine

Read from SKILL.md and the folder at commit cfae287. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Read
    • Write
    • Edit
    • Bash(aws:*)
    • Bash(gcloud:*)
    • Bash(vault:*)

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • npx
    • npm

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Links to these hosts (documentation or services it may open):

    • console.groq.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names these keys or tokens, usually read from environment variables:

    • GROQ_API_KEY

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

  • Compatibility

    Designed for Claude Code

    From compatibility in the SKILL.md frontmatter.

Context cost

Groq Multi Env Setup loads about 1.7k tokens when it runs, and up to ~3.5k if it reads all its reference files. Until then it costs about 114 tokens; SKILL.md has 541 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~114
When it runs · the whole SKILL.md, loaded when a task matches
~1.7k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~3.5k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check: notes

The automated check noted patterns worth knowing about, such as sudo or a known installer.

  • NoteMentions a .env fileSKILL.md:39
    | Development | `.env.local` | `llama-3.1-8b-instant` | 1 | Verbose |
  • NoteMentions a .env fileSKILL.md:74
    per platform.** Dev reads a git-ignored `.env.local`; staging
  • NoteMentions a .env fileSKILL.md:111
    I_KEY not set` | Missing env var | Check .env.local (dev) or secret manager (prod) |

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from jeremylongshore/tons-of-skills-marketplace at commit cfae287, republished under its MIT licence (© jeremylongshore). 541 words, ~1,728 tokens.

Download SKILL.mdSave it as .claude/skills/groq-multi-env-setup/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.
name
groq-multi-env-setup
description
Use when you need Groq to behave differently across dev, staging, and production — cheap fast models and verbose logs in dev, the production model and hardened retries everywhere else, with per-environment API keys. Configure environment-specific model selection, rate limits, and secrets. Trigger with phrases like "groq environments", "groq staging", "groq dev prod", "groq environment setup", "groq multi-env", "groq config by env".
allowed-tools
Read, Write, Edit, Bash(aws:*), Bash(gcloud:*), Bash(vault:*)
compatibility
Designed for Claude Code
version
1.11.0
license
MIT
author
Jeremy Longshore <jeremy@intentsolutions.io>
tags
saas, groq, deployment, api, llm

Groq Multi-Environment Setup

Overview

Configure Groq API access across development, staging, and production with the right model, rate limit strategy, and secret management per environment. Key insight: use llama-3.1-8b-instant in development (cheapest, fastest), match production model in staging, and harden production with retries and fallbacks.

Prerequisites

  • A Groq account with API keys from console.groq.com/keys — ideally a separate key (or organization) per environment.
  • Node project with the groq-sdk package installed (npm install groq-sdk).
  • NODE_ENV set per environment (development / staging / production).
  • A secret store for staging/production keys: GitHub Actions secrets, AWS Secrets Manager, GCP Secret Manager, or HashiCorp Vault.

Environment Strategy

EnvironmentAPI Key SourceDefault ModelRetryLogging
Development.env.localllama-3.1-8b-instant1Verbose
StagingCI/CD secretsllama-3.3-70b-versatile3Standard
ProductionSecret managerllama-3.3-70b-versatile5Structured

Instructions

The full, copy-paste implementation lives in the reference files — this section is the map. Read the implementation walkthrough for the code module, service wrapper, and verify script, and secrets & deployment for per-platform key management, Docker Compose profiles, and rate-limit inspection.

  1. Build the config module (config/groq.ts). One configs record keyed by environment resolves model, token budget, retries, timeout, and logging, then validates that a key is present with an environment-specific error message. The essential skeleton:

    typescript
    const configs: Record<string, GroqEnvConfig> = {
      development: { model: "llama-3.1-8b-instant", maxRetries: 1, logRequests: true, /* ... */ },
      staging:     { model: "llama-3.3-70b-versatile", maxRetries: 3, logRequests: false, /* ... */ },
      production:  { model: "llama-3.3-70b-versatile", maxRetries: 5, logRequests: false, /* ... */ },
    };
    export function getGroqConfig(): GroqEnvConfig {
      return configs[process.env.NODE_ENV || "development"] || configs.development;
    }

    See implementation.md § Step 1 for the full module including key validation and the memoized getGroqClient().

  2. Wire an environment-aware service (services/groq-service.ts) that reads the resolved config, logs only when logRequests is on, and surfaces the retry-after header on 429. Full code in implementation.md § Step 2.

  3. Source secrets per platform. Dev reads a git-ignored .env.local; staging uses CI/CD secrets; production pulls from a secret manager. Commands for GitHub Actions, AWS, GCP, and Vault are in secrets-and-deployment.md § Step 3.

  4. Deploy with Docker Compose profiles so each environment injects its own key (env var for dev/staging, external Docker secret for prod). See secrets-and-deployment.md § Step 4.

  5. Verify each environment with scripts/verify-groq-env.ts, which prints the resolved model/retries and does a live round-trip. Full script in implementation.md § Step 5.

  6. Inspect rate limits per key via the x-ratelimit-* response headers — see secrets-and-deployment.md § Step 6.

Show full SKILL.md (200 more words)Show less

Output

After setup, each environment resolves its own Groq configuration and the verify script confirms a live connection. Expected output from verify-groq-env.ts in production:

text
Environment: production
Model: llama-3.3-70b-versatile
Max retries: 5
API key prefix: gsk_AbCd...
Connection: OK (312ms)
Model response: OK

You end with: a config/groq.ts that selects model/retries/logging by NODE_ENV, a service wrapper that logs verbosely only in dev, per-environment keys sourced from the right secret store, and Docker Compose profiles that never leak a production key into the process environment.

Error Handling

IssueCauseSolution
GROQ_API_KEY not setMissing env varCheck .env.local (dev) or secret manager (prod)
Wrong model in envConfig mismatchVerify with verify-groq-env.ts script
Rate limited in devFree tier limitsUse llama-3.1-8b-instant with low max_tokens
Staging/prod key in devKey leak riskUse separate Groq organizations per environment

Examples

Resolve the config for the current environment:

typescript
import { getGroqConfig } from "./config/groq";

const config = getGroqConfig();      // picks dev/staging/prod by NODE_ENV
console.log(config.model);           // "llama-3.1-8b-instant" in dev

Complete a chat with the environment default model:

typescript
import { complete } from "./services/groq-service";

const answer = await complete([{ role: "user", content: "Summarize in one line." }]);

Verify production before a deploy:

bash
NODE_ENV=production GROQ_API_KEY_PROD=gsk_... npx tsx scripts/verify-groq-env.ts

Full, runnable versions of every snippet are in implementation.md and secrets-and-deployment.md.

Resources

Next Steps

For deployment configuration, see the groq-deploy-integration skill, which builds on this environment strategy to wire CI/CD deploy pipelines and health checks.

© jeremylongshore, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 2 other files (references) in skills/.curated/groq-multi-env-setup of jeremylongshore/tons-of-skills-marketplace.

  • SKILL.md
  • references/implementation.md
  • references/secrets-and-deployment.md

Open the folder on GitHubat commit cfae287

Compare with similar skills

Groq Multi Env Setup next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Groq Multi Env Setup compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Groq Multi Env Setup this skilljeremylongshore/tons-of-skills-marketplace2.8k—~1.7kAutomated safety check: NotesMIT
Rate Limit Managementgrandamenium/cortextos101—~1.2kAutomated safety check: PassMIT
System Design Building BlocksHoangNguyen0403/agent-skills-standard572—~970Automated safety check: PassMIT
Provider API Call Dedupmondoohq/mql412—~7.7kAutomated safety check: PassCustom licence
LLM Gatewaysickn33/agentic-awesome-skills47k1 repos~2.1kAutomated safety check: PassMIT
Sap Btp Service Managersecondsky/sap-skills462—~4.3kAutomated safety check: NotesGPL-3.0

Similar skills

  • Rate Limit Management

    grandamenium/cortextos

    Framework protocol for responding to Claude Max API usage thresholds.

    101 GitHub stars~1.2k tokensUpdated 18 days ago
    Backend & APIsAuto-check passed
  • System Design Building Blocks

    HoangNguyen0403/agent-skills-standard

    Select infrastructure components by the constraint each removes: load balancers, caches and invalidation, queues and pub/sub, CDN, API gateway, rate limiting, consistent hashing.

    572 GitHub stars~970 tokensUpdated yesterday
    Backend & APIsAuto-check passed
  • A skill your agent uses when a provider scan is slow, times out, or trips rate limits (429, throttling, Retry-After), when the same request URL appears many times in a debug log, when an asset's…

    412 GitHub stars~7.7k tokensUpdated yesterday
    DevOps & CloudAuto-check passed
  • LLM Gateway

    sickn33/agentic-awesome-skills

    Deploy an API gateway for LLM traffic with load balancing, rate limiting, key management, semantic caching, fallback routing, and cost tracking.

    47k GitHub starsUsed in 1 repo~2.1k tokens
    Backend & APIsAuto-check passed
  • Sap Btp Service Manager

    secondsky/sap-skills

    This skill provides comprehensive knowledge for SAP Service Manager on SAP Business Technology Platform (BTP).

    462 GitHub stars~4.3k tokensUpdated 5 days ago
    Backend & APIsAuto-check: notes
  • Official

    Guide for using the Grafana MCP to monitor and diagnose the capture service (rust/capture) in production.

    40k GitHub stars~5k tokensUpdated today
    DevOps & CloudAuto-check passed

More from jeremylongshore/tons-of-skills-marketplace

All 3,342 skills in this repo
  • Performing Security Code Review

    jeremylongshore/tons-of-skills-marketplace

    Execute this skill enables AI assistant to conduct a security-focused code review using the security-agent plugin.

    2.8k GitHub starsUsed in 2 repos~1.3k tokens
    Auto-check: notes
  • Adapting Transfer Learning Models

    jeremylongshore/tons-of-skills-marketplace

    Build this skill automates the adaptation of pre-trained machine learning models using transfer learning techniques.

    2.8k GitHub stars~1.1k tokensUpdated yesterday
    Auto-check passed
  • Agent Context Loader

    jeremylongshore/tons-of-skills-marketplace

    Execute proactive auto-loading: automatically detects and loads agents.md files.

    2.8k GitHub stars~1.1k tokensUpdated yesterday
    Auto-check passed
  • Aggregating Performance Metrics

    jeremylongshore/tons-of-skills-marketplace

    Aggregate and centralize performance metrics from applications, systems, databases, caches, and services.

    2.8k GitHub stars~1.2k tokensUpdated yesterday
    Auto-check passed
  • Analyzing Capacity Planning

    jeremylongshore/tons-of-skills-marketplace

    Execute this skill enables AI assistant to analyze capacity requirements and plan for future growth.

    2.8k GitHub stars~947 tokensUpdated yesterday
    Auto-check passed
  • Analyzing Database Indexes

    jeremylongshore/tons-of-skills-marketplace

    Process use when you need to work with database indexing. An agent skill from jeremylongshore/tons-of-skills-marketplace.

    2.8k GitHub stars~2k tokensUpdated yesterday
    Auto-check passed

Questions about Groq Multi Env Setup

What does Groq Multi Env Setup do?

A skill your agent uses when you need Groq to behave differently across dev, staging, and production — cheap fast models and verbose logs in dev, the production model and hardened retries everywhere…. Groq Multi Env Setup is an agent skill from jeremylongshore/tons-of-skills-marketplace. Use when you need Groq to behave differently across dev, staging, and production — cheap fast models and verbose logs in dev, the production model and hardened retries everywhere else, with per-environment API keys.

When should I use Groq Multi Env Setup?

Groq Multi Env Setup fits situations like: you need Groq to behave differently across dev; production — cheap fast models and verbose logs in dev; the production model and hardened retries everywhere else; with per-environment API keys.

How do I install Groq Multi Env Setup in Claude Code?

Run `npx skills add jeremylongshore/tons-of-skills-marketplace --skill groq-multi-env-setup -a claude-code`. Or copy the skill folder (skills/.curated/groq-multi-env-setup in jeremylongshore/tons-of-skills-marketplace) into .claude/skills/groq-multi-env-setup in your project. Claude Code loads it when a task matches its description.

How do I install Groq Multi Env Setup in Codex?

Run `npx skills add jeremylongshore/tons-of-skills-marketplace --skill groq-multi-env-setup -a codex`. Or copy the skill folder (skills/.curated/groq-multi-env-setup in jeremylongshore/tons-of-skills-marketplace) into .agents/skills/groq-multi-env-setup in your project. Codex loads it when a task matches its description.

Can I use Groq Multi Env Setup in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add jeremylongshore/tons-of-skills-marketplace --skill groq-multi-env-setup -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/groq-multi-env-setup, .gemini/skills/groq-multi-env-setup, .github/skills/groq-multi-env-setup and .opencode/skills/groq-multi-env-setup in your project.

What does Groq Multi Env Setup need to run?

Going by SKILL.md and its folder, Groq Multi Env Setup needs the command-line tools its instructions call (npx and npm) and credentials named GROQ_API_KEY. Our summary lists: Node.js; Docker; A credential in GROQ_API_KEY. Its frontmatter pre-approves these tools: Read, Write, Edit, Bash(aws:*), Bash(gcloud:*), Bash(vault:*). Compatibility (from SKILL.md): Designed for Claude Code.

Does Groq Multi Env Setup access the network?

SKILL.md names 1 domain. As links in the text: console.groq.com. This is read from the text; nothing was executed.

Is Groq Multi Env Setup safe to install?

Our automated static check of SKILL.md found notes only (mentions a .env file), nothing it rates as a warning. It is not a guarantee. Review the folder before installing.

What licence does Groq Multi Env Setup use?

Groq Multi Env Setup is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Groq Multi Env Setup use?

About 1.7k tokens (SKILL.md is roughly 6.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 1.8k tokens, read only when the agent opens those files.

What are the alternatives to Groq Multi Env Setup?

Skills that share tags, products or a category with Groq Multi Env Setup: Rate Limit Management (grandamenium/cortextos, 101 stars), System Design Building Blocks (HoangNguyen0403/agent-skills-standard, 572 stars), Provider API Call Dedup (mondoohq/mql, 412 stars) and LLM Gateway (sickn33/agentic-awesome-skills, 47k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Groq Multi Env Setup?

jeremylongshore (a GitHub user) maintains it in jeremylongshore/tons-of-skills-marketplace, which has 2,827 GitHub stars. The repository holds 3,342 skills in this directory. The repository was last updated on October 10, 2026.

Source: jeremylongshore/tons-of-skills-marketplace on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.