






















暂无文章
This is the 11th article in the Crazyrouter Claude Code series. This article focuses on “Claude Code with Crazyrouter Series 11: Chapter 8: Prompt Optimization Techniques,” with an emphasis on Chapter 8: Prompt Optimization Techniques, 8.1 How to Clearly Express Requirements, and specific, explicit instructions.
Unified integration approach: Claude Code / Anthropic native clients use
ANTHROPIC_BASE_URL=https://cn.crazyrouter.com; OpenAI-compatible SDKs, HTTP requests, and frontend/backend applications usebase_url=https://cn.crazyrouter.com/v1.
/v1/v1/... issue caused by an incorrect Base URL.When communicating with Claude Code, clearly expressing your requirements is the key to getting high-quality responses. Learning how to ask effectively helps the AI better understand your intent and provide more accurate answers.
Use specific, explicit instructions:
Vague wording (not recommended):
Specific wording (recommended):
Provide enough information so the AI can understand what you need:
Incomplete information (not recommended):
Complete information (recommended):
Tell the AI clearly what output format you want:
Unclear format (not recommended):
Clear format (recommended):
Provide relevant background information to help the AI understand the scenario:
No background information (not recommended):
With background information (recommended):
Explain how the content will be used so the AI can adjust the wording:
No use-case description (not recommended):
With use-case description (recommended):
Describe the audience for the content so the AI can adjust the tone and style:
No audience description (not recommended):
With audience description (recommended):
Provide reference examples so the AI can understand what you expect:
No example (not recommended):
With an example (recommended):
Provide a format example so the AI can output content according to your requirements:
No format example (not recommended):
With a format example (recommended):
Provide style examples so the AI can imitate a specific expression style:
No style example (not recommended):
With a style example (recommended):
For complex tasks, ask step by step:
All-in-one request (not recommended):
Step-by-step request (recommended):
If the first result is not satisfactory, iterate and improve it:
First request:
Improved request:
Ask for multiple versions and choose the best one:
Single version (not recommended):
Multiple versions (recommended):
Compare the effects of vague wording and clear wording:
Scenario: You need to write a meeting notice
Vague wording:
Possible AI response:
Clear wording:
AI response:
Compare the effect of including or omitting context:
Scenario: You need to reply to a customer email
No context:
Possible AI response:
With context:
AI response:
Now, try asking Claude Code questions in a clear way!
Prompt templates can help you get high-quality responses quickly. Below are some commonly used prompt templates. You can adapt them to your actual needs.
You:
Claude:
You:
Claude:
Now, try using these templates to complete your tasks quickly!
With a few techniques and methods, you can significantly improve the output quality of Claude Code and make the results better match your expectations.
Start with a simple prompt:
You:
Claude:
Based on the AI's feedback, provide more information:
You:
Claude:
If you are still not satisfied with the result, keep refining it:
You:
Claude:
Clearly tell the AI what format you want:
You:
Claude:
Provide a format example so the AI outputs the result according to your requirements:
You:
Claude:
Ask the AI to provide output in multiple formats:
You:
Claude:
Provide specific feedback and tell the AI what needs improvement:
You:
Claude:
If the AI's response contains an error, point it out directly:
You:
Claude:
If you are not satisfied with the result, you can ask it to regenerate:
You:
Claude:
State the word count requirement clearly:
You:
Claude:
State the style requirements clearly:
You:
Claude:
State the content requirements clearly:
You:
Claude:
This shows how to improve copy quality through iteration:
First attempt:
Second optimization:
Third optimization:
Fourth optimization:
This shows how to adjust the output format:
Original output:
Adjust to table format:
Adjust to a table with percentage share:
Now, try using these techniques to improve the output quality of Claude Code!
/v1 usageIf you're ready to connect Claude Code, domestic models, or your own applications to Crazyrouter through a unified setup, follow this sequence:
https://cn.crazyrouter.com; OpenAI-compatible SDKs use: https://cn.crazyrouter.com/v1./v1 was added to the Base URL.When you need to evaluate model costs or choose different models, first check the Crazyrouter pricing and models page, then add your commonly used models to the Token whitelist.
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。