DevOps guide

Prompt compression in CI/CD

Your CI/CD pipeline already checks for code quality, test coverage, and security vulnerabilities. Add token cost checks to catch prompt bloat before it reaches production.

By Arjun Shah - Creator of SuperCompress - Updated 2026-07-03

GitHub Action integration

# .github/workflows/token-check.yml
name: Token cost check
on:
  pull_request:
    paths: ["prompts/**", "**/*.py", "**/*.ts"]

jobs:
  check-tokens:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - name: Check prompt costs
        uses: arjunkshah/supercompress/.github/actions/supercompress-compress@main
        with:
          context: prompts/long_context.txt
          query: "Summarize this context."
          pr-comment: "true"

What CI checks prevent token waste

Frequently asked questions

Can I use this with GitLab CI?

Yes. The SuperCompress CLI works in any CI. Run `supercompress check` in your GitLab pipeline.

Does it work with pre-commit hooks?

Yes. Use the SuperCompress CLI in a pre-commit hook to catch bloat before commit.

Try it yourself

Paste your long prompt into the playground, ask a question, and see what SuperCompress keeps and removes. Free, no signup needed.

Open the Playground Embed the badge