Przejdź do treści
Biblioteka skilli
AI i agenci · Automatyzacja

codex-context-guard

/codex-context-guard

Zapobiega wyczerpaniu okna kontekstu Codex w długich refaktoryzacjach, audytach, migracjach i debugowaniu z dużymi logami lub wieloma odczytami plików.

Repozytorium
agent-skills ↗
Licencja
Apache-2.0
Ostatnia zmiana repozytorium
21.10.2026

Ocena i bezpieczeństwo

100/ 100Klasa: dobry
Format25 / 25
Frontmatter z nazwą i opisem, poprawna nazwa, opis do 1024 znaków, nazwa zgodna z folderem.
Odkrywalność25 / 25
Opis mówi, kiedy użyć skilla, ma sensowną długość i jest w 3. osobie.
Treść35 / 35
Co najmniej 150 słów i do 500 linii, nagłówki, listy kroków, przykłady albo kod.
Higiena15 / 15
Bez zaślepek typu TODO, bez ścieżek Windows, z licencją.
Ryzykobrak sygnałów w skanie
Pliki w paczce
4
Skrypty
0
Komentarze HTML
0
Adresy URL w SKILL.md
0
Przestarzałość

Brak sygnałów. Repozytorium zmienione 21.10.2026, bez odwołań do wycofanych modeli i API.

Licencja

Apache-2.0, otwarta: można używać i zmieniać, z zachowaniem licencji i informacji o zmianach.

Co robi i kiedy

Zapobiega wyczerpaniu okna kontekstu Codex w długich refaktoryzacjach, audytach, migracjach i debugowaniu z dużymi logami lub wieloma odczytami plików.

Oryginalny opis (EN)

Prevent Codex context-window exhaustion during long-running refactors, repo audits, migrations, debugging sessions, or tasks with large logs, many file reads, or repeated tool output. Use when Codex context is getting high, /compact may be needed, or the user asks for context-efficient workflows.

Jak działa

  1. Goal
  2. Trigger conditions
  3. When to use
  4. When not to use
  5. Inputs to inspect
  6. Rules
  7. Workflow
  8. Commands
  9. Safety rules
  10. References
Sekcje z nagłówków SKILL.md, w oryginale · 97 linii, 497 słów
Podgląd SKILL.md
---
name: codex-context-guard
description: Prevent Codex context-window exhaustion during long-running refactors, repo audits, migrations, debugging sessions, or tasks with large logs, many file reads, or repeated tool output. Use when Codex context is getting high, /compact may be needed, or the user asks for context-efficient workflows.
license: Apache-2.0
metadata:
  internal: true
  author: stark-ai-de
  category: codex-operations
  version: "0.1.0"
---

# Codex Context Guard

## Goal

Keep a long Codex session useful by reducing unnecessary context growth, preserving decisions in a compact handoff, and choosing bounded next steps before the thread becomes hard to continue.

## Trigger conditions

- The task has many files, logs, diffs, generated outputs, or repeated tool calls.
- The user asks whether to compact, summarize, or continue in a new thread.
- The agent is about to inspect broad files without a specific need.

## When to use

- Use when context budget, log volume, or file-reading scope is becoming a risk.
- Use before compacting a long session or moving work to another thread.

## When not to use

- Do not use for short, self-contained tasks that have no context pressure.
- Do not use as a substitute for actually validating completed work.

## Inputs to inspect

- Current objective, recent user instructions, changed files, validation output, and unresolved blockers.
- Use `git status --short` and `git diff --stat` before reading large diffs.

## Rules

- Prefer targeted `rg`, `sed`, `git diff --stat`, and small file ranges over whole-file dumps.
- Keep one bounded objective active at a time.
- Store durable state in a handoff artifact when the work will outlive the current context.
- Summarize large outputs instead of pasting them back to the user.
- Tell the user when a compaction or handoff would preserve momentum.

## Workflow

1. Identify the current objective, latest decision, and next blocking question.
2. Replace broad exploration with a targeted search plan.
3. Track changed files, validation commands, and open risks in a compact note.
4. Use references only when they solve the immediate context problem.
5. When context is high, prepare a handoff and recommend `/compact` or a new thread.

## Commands

Useful low-context commands:

```bash
git diff --stat
git status --short
rg -n "pattern" path
sed -n '1,120p' path/to/file
```

## Safety rules

- Do not hide failed validation behind a summary.
- Do not discard unresolved blockers when compacting.
- Do not paste secrets or full large logs into handoff text.

## References

Read only when needed:

- `references/context-budgeting.md` for large task tactics.
- `references/handoff-template.md` when writing a handoff file.

## Scripts

No bundled scripts.

## Output format

Return:

1. Current objective
2. Context risks
3. What to keep in active context
4. What to move to a handoff
5. Recommended next bounded action

## Completion criteria

- The active objective and next action are clear.
- Large context sources have been summarized or moved to a handoff.
- Validation failures and blockers remain visible.

## Failure modes

- If context is already overloaded, stop broad reads and produce a compact state summary.
- If important evidence is missing, name the missing command or file instead of guessing.

## Recovery behavior

If the thread is already overloaded, stop broad exploration, write a compact state summary, name the most recent verified command result, and recommend continuing from the handoff.
Pliki w paczce (4)
  • SKILL.md 3 KB
  • agents/openai.yaml 1 KB
  • references/context-budgeting.md 1 KB
  • references/handoff-template.md 1 KB

Wersje

W bazie nie ma innych skilli o nazwie codex-context-guard.

Migawka bazy z 28.10.2026 · wersja paczki 8b2c17455479 (skrót SHA-256 całej paczki)

Pobrania w ostatnich 30 dniach: 0 · ranking

Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.

Podobne skille

  • 100context-budget
    Zarządza oknem kontekstu agentów AI, optymalizuje jego użycie i zapobiega przepełnieniu przy dużych bazach kodu i długich sesjach.
  • 86principle-guard-the-context-window
    Kieruje duże wyniki do pod-agentów, gdy kontekst się zapełnia, zostawiając w głównym wątku tylko streszczenia.
  • 100context-window-management
    Zarządza budżetami kontekstu LLM: priorytetyzacja, streszczanie, kompaktowanie oraz decyzja, co ładować, a co tylko wskazywać, w długich sesjach, dużych repozytoriach i zadaniach z wieloma dokumentami.
  • 90principle-guard-the-context-window
    Planuje pracę, gdy kontekst modelu się zapełnia: duże wyniki oddaje podagentom, a w głównym wątku zostawia streszczenia.
  • 100guard
    Chroni sesje Claude Code przed przepełnieniem kontekstu, uruchamiając w tle demona, który monitoruje rozmiar sesji i automatycznie ją przycina przed kompaktowaniem.
  • 100context-engineering
    Audytuje i porządkuje to, co agent kodujący ma w oknie kontekstu: pliki instrukcji, reguły, skille, subagenty, hooki i rozmowę, gdy agent ignoruje CLAUDE.md albo jakość spada w długich sesjach.

Uwagi i zgłoszenia

Wiadomość trafi do Bartosza Sokolińskiego. Adres e-mail jest potrzebny tylko do odpowiedzi. Szczegóły w polityce prywatności.