vlog
← 返回全部教程

Guide · Tech

Getting Started with Claude: Three Doors and a Four-Step Habit

Guide · George Pólya, How to Solve It~7 min read

The first time you open Claude, you will probably make the same mistake almost everyone makes: you treat it like a wish-granting machine. You type "build me a website" or "fix my essay," get back something vague, and quietly decide the tool is overrated. The tool is fine. The ask wasn't. This guide gets you past that first wall. By the end you will have signed in through whichever of Claude's three doors fits your task, run a real first session, and picked up a four-step habit — borrowed from a 1945 math book — that turns a flat answer into one you can actually use.

Difficulty · BeginnerTime · ~18 minPrereq · a computer online + one real task

Before you start

  1. Work out what you actually want — then pick the door

    Before you type anything, answer the question George Pólya put at the top of his problem-solving method: what is the unknown? Not "I want help with my code" but "I want this function to stop crashing when the input is empty." A blurry ask earns a blurry answer; a sharp one gives Claude something to aim at. Once the task is clear, the door more or less picks itself, because Claude has three and they suit different work. claude.ai is a chat in your browser — best for questions, writing, research, thinking out loud. Claude Code is a coding partner that lives in your terminal and can read and edit the files in a project. The API is for when you want Claude inside software you are building yourself. Match the door to the task, and the rest of this guide is just walking the path you chose.

    Try this

    Write your task as one sentence before you start: "I want Claude to ___." If you can't finish that sentence, you aren't ready to prompt yet — you are still figuring out the problem, which is Pólya's first step and the one people skip most.

  2. Door one — claude.ai, nothing to install

    Open claude.ai in your browser and sign in with email, Google, or your work account. You land in a chat box, and that is the whole interface — type your task, press enter, done. The one choice worth understanding early is the model. Claude comes in tiers: Opus is the most capable for hard, multi-step work; Sonnet balances speed and capability for everyday tasks; Haiku is the fastest for simple, quick jobs. The default is a sensible starting point, so leave it there until an answer feels shallow, then reach for Opus. A free tier lets you start; paid plans raise the limits when you outgrow them.

  3. Door two — Claude Code, invite it into your terminal

    Claude Code is Claude as a command-line coding partner: point it at a project folder and it reads your files, runs commands, and edits code while you watch and approve. Install it one of two ways, then launch it from inside any project:

    # Option A — native installer (recommended, no Node needed)
    curl -fsSL https://claude.ai/install.sh | bash
    
    # Option B — via npm (needs Node.js 18+)
    npm install -g @anthropic-ai/claude-code
    
    # then, inside any project folder:
    claude

    The first time you run claude it opens your browser to sign in to your Anthropic account — there is no key to paste. After that you are in a session: ask it to explain a file, hunt a bug, or make a change, and it proposes edits you approve before they land. Start read-only — "walk me through what this project does" — before you let it touch anything.

  4. Door three — the API, put Claude inside your own program

    The API is for builders: your own code sends text to Claude and gets text back, so you can wire it into an app, a script, or a data pipeline. Three small steps get you a first reply:

    # 1. install the SDK
    pip install anthropic
    
    # 2. make a key at platform.claude.com → API keys → Create Key
    #    (copy it once — you won't see it again), then:
    export ANTHROPIC_API_KEY="sk-ant-..."
    
    # 3. your first call
    import anthropic
    client = anthropic.Anthropic()
    msg = client.messages.create(
        model="claude-opus-4-8",
        max_tokens=1024,
        messages=[{"role": "user", "content": "In one sentence, what is an API?"}],
    )
    print(msg.content[0].text)
    Watch out

    Keep the key out of your code and in an environment variable, the way the example does. It can spend real money, so treat it like a password — never paste it into a file you might commit or share.

  5. Whatever door you took, prompt like you're solving a problem

    This step decides whether Claude feels useful or disappointing, and it is the same behind all three doors. Pólya's four steps for solving a math problem map almost exactly onto briefing an AI. Understand: say what you actually want and why — "rewrite this for a non-technical reader" beats "improve this." Plan: hand over the context Claude can't see — the audience, the constraints, the file, an example of what good looks like — and for anything big, ask for an outline before the full answer. Carry it out: let it do the work, then read what came back instead of pasting it straight on. Look back: if it's off, don't restart with the same vague prompt — tell it exactly what was wrong and ask again. The single biggest upgrade for a beginner is the Plan step: most weak answers come from a prompt that assumed Claude could see what only you can see.

  6. Look back — don't take the answer on faith

    The last step is the one beginners skip and experienced users never do. Claude can be confidently wrong: it will state a fake statistic, invent a citation, or describe a function that doesn't exist, all in the same fluent voice it uses when it's right. So read its output as a strong first draft, not a verdict. Check anything that matters — a number, a name, a line of code — against a source you trust, or ask Claude to show its reasoning and its sources so you can see the seams. Run the code before you ship it. None of this is distrust of the tool; it is how you work with a fast, occasionally overconfident collaborator — gratefully, and with your eyes open.

    Common mistake

    The name for a confident fabrication is a "hallucination," and no model is free of them. The fix isn't a cleverer prompt — it's the habit of verifying. For a fact, ask "what's your source?" and check it. For code, run it. For anything high-stakes, keep the final judgment yours.

One pass, end to end. Say you want to turn a messy spreadsheet of survey replies into a short summary. You open claude.ai, because this is a one-off thinking task, not a codebase. You write the task as a sentence — "summarize the top three complaints in this feedback" — and paste the actual data, plus what "top" means to you (most frequent? angriest?). Claude returns three themes; you read them and notice it merged two you'd keep apart, so you say so. The second answer is right. Then you spot-check two of the quotes against the file before the summary goes in front of anyone. Four steps, five minutes, and a result you'd stand behind.

BRIEF CLAUDE LIKE YOU'RE SOLVING A PROBLEM ① Understandwhat's the unknown? ② Planhand over context ③ Carry outlet it work, then read ④ Look backverify what matters Your taskone sentence An answeryou can trust not happy? go again one pass throughloop back with feedback
Brief Claude like you're solving a problem: state the task in one sentence, hand over the context Claude can't see, let it work and read the result, then look back and verify. If it's off, loop back with specific feedback rather than restarting. Framework: George Pólya, How to Solve It. An independent beginner's guide, not official Anthropic material.

Check your work

The one line to keep

Treat Claude as a problem-solving partner, not a wish machine: state the problem, hand over the context, then look back and verify — only then is the answer one you can trust.

The four-step frame — understand, plan, carry it out, look back — is George Pólya's, from How to Solve It (1945); the "make it concrete and give it context" habit borrows from the Heath brothers' Made to Stick. The Claude specifics (claude.ai for chat, Claude Code in the terminal, the API at platform.claude.com) and the model tiers (Opus, Sonnet, Haiku) are from Anthropic's own documentation, current as of June 2026; product details change, so treat the official docs as the source of truth. This is an independent beginner's guide, not official Anthropic material. © vlog.bluecatbot.com 2026.

教程 · 技术

Claude 入门:三道门,加一个解题四步法

教程 · 波利亚《怎样解题》约 6 分钟

第一次打开 Claude,你大概会犯几乎所有人都犯的那个错:把它当许愿机。你丢一句"帮我做个网站""帮我改改这篇文章",拿回一坨泛泛的东西,然后默默判定这工具被高估了。工具没问题,是那句话有问题。这篇就带你越过这第一道墙。读完,你会从最适合你任务的那道门进去(Claude 有三道),跑通一次真正的对话,并学会一个借自一本 1945 年数学书的四步习惯,把一个平庸的答案变成你真能用的答案。

难度 · 入门时长 · 约18分钟前置 · 一台能上网的电脑 + 一件真实任务

开始之前

  1. 先弄清你到底要它干什么——再选门

    动手打字之前,先回答波利亚摆在解题法第一位的那个问题:未知量是什么?不是"我代码想要点帮助",而是"我要这个函数在输入为空时别再崩了"。含糊的提问换来含糊的答案;清晰的提问才给了 Claude 一个能瞄准的靶子。任务一旦清楚,门基本就自己选好了,因为 Claude 有三道,各管不同的活。claude.ai 是浏览器里的对话——最适合提问、写作、查资料、把想法说出来理一理。Claude Code 是住在你终端里的编程搭档,能读、能改一个项目里的文件。API 则是当你想把 Claude 嵌进自己正在做的软件里。把门和任务对上,这篇剩下的内容就只是走你选好的那条路。

    实操提示

    开始前,把任务写成一句话:"我要 Claude 替我把 ___ 做成。"如果这句话补不全,那你还没到该写提示词的时候——你还在弄清问题本身,而这恰是波利亚的第一步,也是最常被跳过的一步。

  2. 第一道门·claude.ai:零安装,打开就能聊

    在浏览器打开 claude.ai,用邮箱、Google 或工作账号登录。进去就是一个对话框,整个界面就这么多——输入任务、回车,完事。值得早点搞懂的唯一一个选择是模型。Claude 分几档:Opus 最强,应付困难的、多步骤的活;Sonnet 在速度和聪明之间取平衡,适合日常任务;Haiku 最快,干简单、要得急的小事。默认那档是个稳妥的起点,先留着,直到某个答案让你觉得太浅,再换上 Opus。有免费档可以起步;用量长大了,付费方案能把上限抬高。

  3. 第二道门·Claude Code:把它请进终端

    Claude Code 是命令行里的 Claude 编程搭档:把它指向一个项目文件夹,它就能读你的文件、跑命令、改代码,而你在旁边看着、点头同意。两种装法任选一种,然后在任意项目里启动它:

    # 方式 A——原生安装脚本(推荐,不需要 Node)
    curl -fsSL https://claude.ai/install.sh | bash
    
    # 方式 B——走 npm(需要 Node.js 18+)
    npm install -g @anthropic-ai/claude-code
    
    # 然后,在任意项目文件夹里:
    claude

    第一次跑 claude,它会打开浏览器让你登录 Anthropic 账号,不用粘贴任何密钥。之后你就进了一个会话:让它讲讲某个文件、抓个 bug、改一处代码,它会先把改动方案摆出来,等你同意了才落地。先从只读开始——比如"带我过一遍这个项目是干嘛的"——再放手让它动东西。

  4. 第三道门·API:把 Claude 嵌进你自己的程序

    API 是给开发者的:你自己的代码把文本发给 Claude,再拿回文本,于是你能把它接进一个应用、一段脚本、一条数据流水线。三个小步骤就能拿到第一条回复:

    # 1. 装 SDK
    pip install anthropic
    
    # 2. 去 platform.claude.com → API keys → Create Key 建一把密钥
    #    (只显示一次,当场复制好),然后:
    export ANTHROPIC_API_KEY="sk-ant-..."
    
    # 3. 你的第一次调用
    import anthropic
    client = anthropic.Anthropic()
    msg = client.messages.create(
        model="claude-opus-4-8",
        max_tokens=1024,
        messages=[{"role": "user", "content": "用一句话说说,API 是什么?"}],
    )
    print(msg.content[0].text)
    常见错误

    像示例那样,把密钥放进环境变量、别写进代码里。它能花你的真金白银,所以当密码看待——绝不要粘进一个你可能提交或分享出去的文件。

  5. 不管进的哪道门,都要像解题一样写提示词

    这一步决定了 Claude 到底好用还是让你失望,而且三道门背后是同一套。波利亚解数学题的四步,几乎能原样套到"给 AI 交代任务"上。弄清问题:说清楚你到底要什么、为什么要——"把这段改写得让外行也看懂"远胜过"把它改好点"。拟定计划:把 Claude 看不见的上下文交给它——读者是谁、有哪些限制、那个文件、一个"好答案长什么样"的范例——大任务还要先让它给个提纲,再出全文。执行:让它干,干完先读一遍,别原样贴出去。回顾:不对劲就别拿同一句含糊提示重来——告诉它具体哪儿错了,再问一遍。对新手而言,单项收益最大的就是"拟定计划"这一步:大多数差答案,都出在那句假设了 Claude 看得见只有你才看得见的东西的提示词上。

  6. 回顾:别把答案当圣旨

    最后这一步,新手会跳过,老手从不跳。Claude 可能一本正经地错:它会说出一个假数据、编一条不存在的引用、描述一个根本没有的函数,而且用的是它说对时一模一样的流利口吻。所以把它的输出当成一份很强的初稿,而不是定论。凡是要紧的——一个数字、一个名字、一行代码——都去你信得过的来源那里对一对,或者让 Claude 把它的推理和出处亮出来,好让你看清接缝。代码上线前先跑一遍。这一切都不是不信任这工具,而是你该怎么用一个敏捷、快速、偶尔过于自信的协作者——心怀感激,同时睁着自己的眼。

    常见错误

    这种"自信的胡编"有个名字叫"幻觉",没有哪个模型能完全免疫。解药不是更聪明的提示词,而是养成核实的习惯。对事实,问一句"你的出处是什么?"再去查。对代码,跑一遍。凡是高风险的事,最后那一锤定音留给你自己。

把整套走一遍。假设你要把一张乱糟糟的问卷回复表,变成一段简短总结。你打开 claude.ai——因为这是个一次性的动脑任务,不是一个代码库。你把任务写成一句话——"把这些反馈里最突出的三条抱怨总结出来"——再把真实数据贴进去,外加你心里"最突出"是什么意思(最频繁?还是火气最大?)。Claude 给回三个主题;你读完发现它把两个你想分开的并到了一起,于是你指出来。第二版就对了。然后在把总结拿给别人看之前,你拿其中两条引述跟原表对一对。四步,五分钟,一个你拿得出手的结果。

像解题一样给 Claude 交代任务 ① 弄清问题未知量是什么? ② 拟定计划交出上下文 ③ 执行让它做,再读一遍 ④ 回顾验证,别全信 你的任务一句话 靠得住的答案 不满意?带反馈再来 一次走完带反馈再来一轮
像解题一样给 Claude 交代任务:用一句话说清任务,把 Claude 看不见的上下文交出去,让它做、再读结果,然后回顾验证。不对劲就带着具体反馈回到上一步,而不是从头再来。框架:波利亚《怎样解题》。本图为独立入门教程,非 Anthropic 官方材料。

完成验证

核心句

把 Claude 当解题伙伴,不是许愿机:说清问题、交足上下文、再回头验证——四步走完,答案才靠得住。

"弄清问题、拟定计划、执行、回顾"这套四步框架取自波利亚《怎样解题》(1945);"讲具体、给上下文"的习惯借自希思兄弟《粘住》。文中 Claude 的具体信息(claude.ai 用于对话、Claude Code 在终端里、API 在 platform.claude.com)与模型分档(Opus、Sonnet、Haiku)来自 Anthropic 官方文档,截至 2026 年 6 月;产品细节会变,请以官方文档为准。本文为独立的入门教程,非 Anthropic 官方材料。© vlog.bluecatbot.com 2026。

ガイド · テック

Claude 入門:三つの扉と、問題解決の4ステップ

ガイド · ポリア『いかにして問題をとくか』約 8 分

はじめて Claude を開くと、たいていの人と同じ間違いをするだろう。願いをかなえる機械のように扱ってしまうのだ。「ウェブサイトを作って」「この文章を直して」と打ち込み、ぼんやりした答えが返ってきて、この道具は過大評価だと静かに結論づける。道具に問題はない。頼み方に問題があったのだ。このガイドは、その最初の壁を越えさせる。読み終えるころには、あなたの用事に合った扉——Claude には三つある——から入り、最初の対話を実際に動かし、そして1945年の数学書から借りた4ステップの習慣を身につけている。平凡な答えを、本当に使える答えに変える習慣だ。

難易度 · 入門所要 · 約18分前提 · ネットにつながる PC + 本物の用事ひとつ

始める前に

  1. まず何をさせたいのかをはっきりさせ、それから扉を選ぶ

    何かを打ち込む前に、ポリアが問題解決法の冒頭に置いた問いに答える。未知のものは何か?「コードを手伝ってほしい」ではなく「入力が空のときに、この関数が落ちないようにしたい」だ。あいまいな頼みはあいまいな答えを招き、はっきりした頼みは Claude に狙う的を与える。用事がはっきりすれば、扉はほぼ自分で決まる。Claude には三つあり、それぞれ別の仕事を受け持つからだ。claude.ai はブラウザの中の対話——質問、執筆、調べもの、考えを声に出して整理するのに向く。Claude Code はターミナルに住むコーディングの相棒で、プロジェクトのファイルを読み、編集できる。API は、自分で作っているソフトウェアの中に Claude を組み込みたいときのものだ。扉と用事を合わせれば、このガイドの残りは選んだ道を歩くだけになる。

    実践のヒント

    始める前に、用事を一文で書く。「Claude に ___ をやり遂げてほしい」。この一文を埋められないなら、まだプロンプトを書く段階ではない——まだ問題そのものを見極めている途中で、それこそポリアの第一歩であり、最も飛ばされがちな一歩だ。

  2. 第一の扉·claude.ai:インストール不要、開けばすぐ話せる

    ブラウザで claude.ai を開き、メール、Google、または仕事用アカウントでサインインする。入るとそこは対話ボックスで、画面はそれがすべて——用事を打ち、エンターを押す、それで終わりだ。早めに理解しておく価値のある唯一の選択がモデルだ。Claude にはいくつかの段階がある。Opus は最も賢く、難しい多段階の仕事をこなす。Sonnet は速さと賢さのつり合いがよく、日常の用事に向く。Haiku は最も速く、単純で急ぎの小仕事に向く。既定の段階は無難な出発点だから、答えが浅いと感じるまではそのままにし、感じたら Opus に切り替える。無料の段階で始められ、使う量が増えれば有料プランが上限を引き上げてくれる。

  3. 第二の扉·Claude Code:ターミナルに招き入れる

    Claude Code はコマンドラインの Claude、コーディングの相棒だ。プロジェクトのフォルダに向けると、ファイルを読み、コマンドを走らせ、コードを編集する——あなたが横で見て、承認しながら。次の二つの方法のどちらかで入れ、それから任意のプロジェクトの中で起動する。

    # 方法 A——ネイティブの導入スクリプト(推奨、Node 不要)
    curl -fsSL https://claude.ai/install.sh | bash
    
    # 方法 B——npm で(Node.js 18 以降が必要)
    npm install -g @anthropic-ai/claude-code
    
    # そのあと、任意のプロジェクトフォルダの中で:
    claude

    初めて claude を走らせると、ブラウザが開いて Anthropic アカウントへのサインインを求める——貼り付ける鍵はいらない。そのあとはセッションの中だ。あるファイルの説明、バグ探し、ある箇所の変更を頼むと、編集案をまず示し、あなたが承認してから反映する。まずは読むだけ——「このプロジェクトが何をするか案内して」——から始め、それから手を触れさせよう。

  4. 第三の扉·API:自分のプログラムの中に Claude を置く

    API は作り手のためのものだ。自分のコードがテキストを Claude に送り、テキストを受け取る。だからアプリ、スクリプト、データの流れに組み込める。三つの小さな手順で、最初の返事が手に入る。

    # 1. SDK を入れる
    pip install anthropic
    
    # 2. platform.claude.com → API keys → Create Key で鍵を作る
    #    (表示は一度きり、その場でコピー)、そして:
    export ANTHROPIC_API_KEY="sk-ant-..."
    
    # 3. 最初の呼び出し
    import anthropic
    client = anthropic.Anthropic()
    msg = client.messages.create(
        model="claude-opus-4-8",
        max_tokens=1024,
        messages=[{"role": "user", "content": "API とは何か、一文で。"}],
    )
    print(msg.content[0].text)
    よくある間違い

    例のように、鍵はコードに書かず環境変数に入れる。これは本物のお金を使えるので、パスワードと同じに扱うこと——コミットや共有をしかねないファイルには、決して貼らない。

  5. どの扉から入っても、問題を解くようにプロンプトを書く

    このステップが、Claude を役立つと感じるか期待外れと感じるかを決める。しかも三つの扉の裏は同じ仕組みだ。ポリアの数学の問題を解く4ステップは、AI への指示出しにほぼそのまま重なる。問題を理解する:何を本当に望むのか、なぜかを言う——「専門外の読者向けに書き直して」は「よくして」に勝る。計画を立てる:Claude に見えない文脈を渡す——読者は誰か、どんな制約があるか、その(対象の)ファイル、よい答えの見本——そして大きな用事なら、全文の前にまず構成を出させる。実行する:やらせ、できたものをそのまま貼らずにまず読む。振り返る:外していたら、同じあいまいなプロンプトでやり直さない——どこがどう違ったかを具体的に伝え、もう一度頼む。初心者にとって伸びしろが最大なのは「計画を立てる」だ。弱い答えの多くは、自分にしか見えないものを Claude も見えると思い込んだプロンプトから生まれる。

  6. 振り返る:答えを鵜呑みにしない

    最後のこのステップを、初心者は飛ばし、慣れた人は決して飛ばさない。Claude は自信たっぷりに間違えることがある——偽の統計を述べ、ありもしない出典をでっち上げ、存在しない関数を説明する。しかも、正しいときと寸分違わぬ流暢な口調で。だからその出力は、結論ではなく、よくできた下書きとして読む。大事なものは何であれ——数字、名前、一行のコード——信頼できる出典に当てて確かめるか、Claude に推論と出典を示させ、継ぎ目が見えるようにする。コードは世に出す前に走らせる。これは道具を信じないということではない。素早く、鋭く、ときに自信過剰な協力者をどう使うか、ということだ——感謝しつつ、自分の目は開けたまま。

    よくある間違い

    この「自信に満ちた作り話」には名前があり、「ハルシネーション」と呼ぶ。どのモデルもこれから完全には逃れられない。直し方は、より賢いプロンプトではなく、確かめる習慣だ。事実なら「出典は?」と問い、当たって確かめる。コードなら走らせる。賭け金の高いことは、最後の判断を自分の手に残す。

ひと通り、最初から最後まで。乱雑なアンケート回答の表を、短い要約に変えたいとしよう。あなたは claude.ai を開く——これはコードベースではなく、一回きりの考える用事だからだ。用事を一文で書く——「このフィードバックで最も目立つ不満を三つ要約して」——そして実際のデータを貼り、「最も目立つ」が自分にとって何か(最も多い?最も怒っている?)も添える。Claude は三つのテーマを返す。読んでみると、分けておきたかった二つを一つにまとめていたので、そう伝える。二度目の答えは正しい。それから要約を誰かに見せる前に、引用のうち二つを元の表に当てて確かめる。四ステップ、五分、そして胸を張れる結果だ。

問題を解くように Claude に指示する ① 理解する未知のものは? ② 計画文脈を渡す ③ 実行やらせて、読む ④ 振り返る確かめる あなたの用事一文で 信頼できる答え 不満なら、戻ってもう一度 ひと通りフィードバックして戻る
問題を解くように Claude に指示する:用事を一文で言い、Claude に見えない文脈を渡し、やらせて結果を読み、振り返って確かめる。外れていたら最初からやり直さず、具体的な指摘を添えて前のステップへ戻る。枠組み:ポリア『いかにして問題をとくか』。独立した入門ガイドであり、Anthropic 公式の資料ではない。

仕上がりチェック

覚えておく一文

Claude は願いをかなえる機械ではなく、問題を解く相棒として使う。問題を言い、文脈を渡し、そして振り返って確かめる——四つを終えて初めて、答えは信頼できる。

「理解する・計画を立てる・実行する・振り返る」という4ステップの枠組みは、ポリア『いかにして問題をとくか』(1945)による。「具体的にし、文脈を渡す」習慣はヒース兄弟『アイデアのちから』から借りた。本文の Claude の具体情報(対話は claude.ai、Claude Code はターミナルの中、API は platform.claude.com)とモデルの段階(Opus、Sonnet、Haiku)は Anthropic 公式ドキュメントによるもので、2026年6月時点。製品の詳細は変わるので、公式ドキュメントを正とすること。本稿は独立した入門ガイドであり、Anthropic 公式の資料ではない。© vlog.bluecatbot.com 2026。