Skip to content

Reduce system prompt token overhead from skill files #26

Description

@jerelvelarde

Priority: P1 | Source: PR #21 self-review (F2)

Problem

PR #21 adds ~9,150 tokens (75% increase) to the system prompt. load_all_skills() concatenates ALL .txt files unconditionally — mechanical diagram guidance is injected even for non-mechanical queries.

  • Pre-PR skill text: ~48.9 KB (~12,200 tokens)
  • Post-PR skill text: ~85.5 KB (~21,400 tokens)

Suggested Approaches

  • Conditional skill loading — only inject mechanical-illustration-skill.txt and svg-shape-library.txt when the query involves physical/mechanical subjects
  • Trim the shape library to the 6-8 most common shapes (as the issue proposal itself suggests)
  • Establish a token budget target for total skill text

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions