Techniques··4 min read

How to Feed Reference Documents into System Prompts

Best practices for including reference material in system prompts and custom instructions without bloating every request.

System prompts are paid every turn

Whatever you put in the system prompt is sent with every message. A 5,000-token style guide costs 5,000 tokens per turn, so compression pays off fast.

Label and compress

Convert source material with the Markdown Converter, compress it with the Context Compressor while preserving product names and key terms, then confirm the size in the Token Counter.

Structure it

Use a clear layout:

  • Role and goal (2 to 3 sentences)
  • Rules and constraints
  • Reference section wrapped in clear markers
  • Output format

Try it free in your browser

  • Context Compressor — Reduce token usage with compression strategies tuned for LLMs.
  • Markdown Converter — Paste HTML, DOCX, or webpage text and get tidy Markdown.
  • Token Counter — Live token, character, and context-window meter for any prompt. Uses official tiktoken encoders.

Tools mentioned

Frequently asked

Does the system prompt count toward tokens?

Yes, on every request. A bloated system prompt multiplies cost across a conversation.

Where should long documents go?

In retrieval or knowledge files, with only essentials in the system prompt.

Keep reading