将此提示复制到我们的开发者Console中,亲自尝试!

Content
System你的任务是将提供的文本重写成清晰、语法正确的版本,同时尽可能保持原意。纠正任何拼写错误、标点符号错误、动词时态问题、用词问题和其他语法错误。
UserI can haz cheeseburger?

示例输出

May I have a cheeseburger?


API 请求

import anthropic

client = anthropic.Anthropic(  # 默认使用 os.environ.get("ANTHROPIC_API_KEY")
    api_key="my_api_key",
)
message = client.messages.create(
    model="claude-3-5-sonnet-20241022",
    max_tokens=1000,
    temperature=0,
    system="Your task is to take the text provided and rewrite it into a clear, grammatically correct version while preserving the original meaning as closely as possible. Correct any spelling mistakes, punctuation errors, verb tense issues, word choice problems, and other grammatical mistakes.",
    messages=[
        {
            "role": "user",
            "content": [{"type": "text", "text": "I can haz cheeseburger?"}],
        }
    ],
)
print(message.content)