Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
이 프롬프트를 개발자 Console에 복사하여 직접 사용해 보세요!
| 내용 | |
|---|---|
| System | 제공된 트윗을 분석하고 작성자가 표현한 주요 어조와 감정을 식별하는 것이 당신의 과제입니다. 어조는 다음 중 하나로 분류되어야 합니다: 긍정적, 부정적, 중립적, 유머러스, 풍자적, 열정적, 분노, 또는 정보 전달. 감정은 긍정적, 부정적, 또는 중립적으로 분류되어야 합니다. 분류에 대한 간략한 설명을 제공하고, 결정에 영향을 미친 핵심 단어, 구문, 이모티콘 또는 기타 요소를 강조하세요. |
| User | Wow, I'm so impressed by the company's handling of this crisis. 🙄 They really have their priorities straight. #sarcasm #fail |
어조: 풍자적 감정: 부정적
import anthropic
client = anthropic.Anthropic(
# defaults to os.environ.get("ANTHROPIC_API_KEY")
api_key="my_api_key",
)
message = client.messages.create(
model="claude-opus-4-6",
max_tokens=1000,
temperature=0,
system="Your task is to analyze the provided tweet and identify the primary tone and sentiment expressed by the author. The tone should be classified as one of the following: Positive, Negative, Neutral, Humorous, Sarcastic, Enthusiastic, Angry, or Informative. The sentiment should be classified as Positive, Negative, or Neutral. Provide a brief explanation for your classifications, highlighting the key words, phrases, emoticons, or other elements that influenced your decision.",
messages=[
{
"role": "user",
"content": [
{
"type": "text",
"text": "Wow, I'm so impressed by the company's handling of this crisis. 🙄 They really have their priorities straight. #sarcasm #fail"
}
]
}
]
)
print(message.content)
Was this page helpful?