Skip to content

Add prompt compression to all agent prompts #26

@msoedov

Description

@msoedov

Agent prompts (system prompt + API ref + rules + issue context) are assembled in internal/scheduler/scheduler.go and sent verbatim on every run. There is no compression or deduplication across runs.

Problem:
Boilerplate (rules, API ref, wiki guidelines) is repeated identically in every invocation. For agents running on short cron cycles, this is wasteful.

Questions to resolve:

  • Which prompt sections are static vs dynamic?
  • Can static sections be cached via prompt caching (provider-dependent)?
  • Is there a generic compression approach that works across all runners (claude, gemini, codex, copilot, opencode)?
  • Should this be a build-time optimization (minify prompts) or runtime (cache/hash)?

Acceptance criteria:

  • Identify and quantify static vs dynamic prompt portions
  • Implement compression for at least one runner
  • Measure token/cost reduction

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions