openrouter-context-optimization - Optimize OpenRouter Context Window Usage
Optimize context window usage for OpenRouter models to reduce cost and manage long conversations.
Tags
Updated: 2026-03-23Typical Inputs
Typical Outputs
What this skill does
- query context limits
- estimate tokens
- select model
- trim conversation
- chunk document
- process document
- cache prompt
- monitor tokens
Inputs
- OpenRouter API key
- model ID
- conversation messages
- document text
- question
Outputs
- context limit data
- token count
- selected model ID
- trimmed conversation
- document chunks
- analysis result
- synthesized response
Requirements
- OpenRouter API access
- OpenAI-compatible client
- Python environment
- internet connection
