-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OpenRouter: Prompt Transforms #630
Comments
/### Related issues #369: "You are a helpful AI assistant" : r/LocalLLaMA### DetailsSimilarity score: 0.88 - [ ] ["You are a helpful AI assistant" : r/LocalLLaMA](https://www.reddit.com/r/LocalLLaMA/comments/18j59g1/you_are_a_helpful_ai_assistant/?share_id=g_M0-7C_zvS88BCd6M_sI&utm_content=1&utm_medium=android_app&utm_name=androidcss&utm_source=share&utm_term=1)"You are a helpful AI assistant" Discussion Don't say "don't": this confuses them, which makes sense when you understand how they "think". They do their best to string concepts together, but they simply generate the next word in the sequence from the context available. Saying "don't" will put everything following that word into the equation for the following words. This can cause it to use the words and concepts you're telling it not to. (system prompts) Here is some context for the conversation: (Paste in relevant info such as web pages, documentation, etc, as well as bits of the convo you want to keep in context. When you hit the context limit, you can restart the chat and continue with the same context). "You are a helpful AI assistant" : this is the demo system prompt to just get agreeable answers from any model. The issue with this is, once again, how they "think". The models can't conceptualize what is helpful beyond agreeing with and encouraging you. This kind of statement can lead to them making up data and concepts in order to agree with you. This is extra fun because you may not realize the problem until you discover for yourself the falacy of your own logic. Then pass the list to your assistant you intend to chat with with something like "you can confidently answer in these subjects that you are an expert in: (the list). The point of this ^ is to limit its responses to what it actually knows, but make it confidentially answer with the information it's sure about. This has been incredibly useful in my cases, but absolutely check their work. Suggested labels{ "key": "sparse-computation", "value": "Optimizing large language models using sparse computation techniques" }#418: openchat/openchat-3.5-1210 · Hugging Face### DetailsSimilarity score: 0.88 - [ ] [openchat/openchat-3.5-1210 · Hugging Face](https://huggingface.co/openchat/openchat-3.5-1210#conversation-templates)Using the OpenChat ModelWe highly recommend installing the OpenChat package and using the OpenChat OpenAI-compatible API server for an optimal experience. The server is optimized for high-throughput deployment using vLLM and can run on a consumer GPU with 24GB RAM.
Online DeploymentIf you want to deploy the server as an online service, use the following options:
For security purposes, we recommend using an HTTPS gateway in front of the server. Mathematical Reasoning ModeThe OpenChat model also supports mathematical reasoning mode. To use this mode, include
Conversation TemplatesWe provide several pre-built conversation templates to help you get started.
Suggested labels{ "label": "chat-templates", "description": "Pre-defined conversation structures for specific modes of interaction." }#484: Docs | OpenRouter### DetailsSimilarity score: 0.87 - [ ] [Docs | OpenRouter](https://openrouter.ai/docs#models)Always Assist with Care, Respect, and Truth: Secure and Useful Responses OnlyThe future will bring us hundreds of language models and dozens of providers for each. How will you choose the best? OpenRouter: Find the Lowest Price Across Dozens of Providers
Standardized API: No Need to Change Your Code
Evals are Flawed: Compare Models by Usage and Purpose
Four Key Principles to Ensure Fairness and Positivity
Keep the wording exact. Only edit formatting. Include the entire content. Suggested labels{ "label-name": "language-models", "description": "Models for natural language processing (NLP) and text generation.", "confidence": 95.97 }#443: jcmccormick/runtts: Shell tool to prompt ollama and whisper cli programs### DetailsSimilarity score: 0.87 - [ ] [jcmccormick/runtts: Shell tool to prompt ollama and whisper cli programs](https://github.com/jcmccormick/runtts)RunTTSPOSIX-compliant shell utility for working with local LLM + voice models Requirements
To use your desired models with Ollama and TTS, configure them and note their model names as you would use with Install
AboutThis tool is a mashup of the whisper, tts, and ollama CLIs to provide a local utility for interacting with AI models. RunTTS keeps track of a running context as you continue prompting it, and when needed, conversations can be saved for later prompting. Due to the variability of situations where models can be run, RunTTS utilizes streaming responses to produce audio clips as soon as newline-delimited content is ready. Furthermore, it will handle markdown style triple-backtick blocks, setting them aside to not be read aloud, but can be viewed as received. Suggested labels{ "label-name": "AI-tools", "description": "Tools for working with AI models in a local environment", "confidence": 84.96 }#485: Docs | OpenRouter### DetailsSimilarity score: 0.86 - [ ] [Docs | OpenRouter](https://openrouter.ai/docs#models)Title: Docs | OpenRouterDescription: The future will bring us hundreds of language models and dozens of providers for each. How will you choose the best? Benefit from the race to the bottom. OpenRouter finds the lowest price for each model across dozens of providers. You can also let users pay for their own models via OAuth PKCE. Standardized API. No need to change your code when switching between models or providers. The best models will be used the most. Evals are flawed. Instead, compare models by how often they're used, and soon, for which purposes. Chat with multiple at once in the Playground. URL: https://openrouter.ai/docs#models Key Features
OpenRouter is the future of language model selection and usage. Benefit from a wide range of models and providers, while ensuring the best models are used the most. Suggested labels{ "label-name": "language-models", "description": "Information about language models and providers", "repo": "openrouter.ai", "confidence": 96.2 } |
Docs | OpenRouter
Description:
Prompt Transforms
OpenRouter has a simple rule for choosing between sending a prompt and sending a list of ChatML messages:
Choose messages if you want to have OpenRouter apply a recommended instruct template to your prompt, depending on which model serves your request. Available instruct modes include:
Choose prompt if you want to send a custom prompt to the model. This is useful if you want to use a custom instruct template or maintain full control over the prompt submitted to the model.
To help with prompts that exceed the maximum context size of a model, OpenRouter supports a custom parameter called transforms:
The transforms param is an array of strings that tell OpenRouter to apply a series of transformations to the prompt before sending it to the model. Transformations are applied in-order. Available transforms are:
Note: All OpenRouter models default to using middle-out, unless you exclude this transform by e.g. setting transforms: [] in the request body.
More information
Suggested labels
{'label-name': 'prompt-transformations', 'label-description': 'Descriptions of transformations applied to prompts in OpenRouter for AI models', 'gh-repo': 'openrouter/ai-docs', 'confidence': 52.95}
The text was updated successfully, but these errors were encountered: