three.ws Tutor

io.github.nirholas由 GitHub 帳號 nirholas 發布v0.1.2更新於 Oct 24, 2026

Read a Pay-As-You-Learn tutoring session's itemized tab and close it for an attested invoice.

已驗證STDIO僅桌面效率與工作流金融

概覽

AI 產生的概覽

讀取 three.ws「按需付費學習」輔導工作階段的逐項帳單,並可關閉工作階段以產生具證明的發票。

可以做什麼
  • 依工作階段 ID 讀取逐項即時帳單:每題的明細項目(題目、難度、token 數、費用)、狀態與累計總額
  • 關閉工作階段以完成結算,回傳逐項總額與 SHA-256 證明,並鎖定後續計費
適用情境
當你使用 three.ws 的按需付費輔導工作階段,想讓助理查看目前已計費的內容,或結束工作階段並取得具證明的發票時使用。
執行需求
需要 Node.js 20 或更新版本,透過 npx 或本機安裝執行。需要能連線 three.ws API,可用 THREE_WS_BASE(預設 THREE_WS_TIMEOUT_MS(預設 20000)設定。不需 API 金鑰或簽章者,工作階段以不透明的工作階段 ID 識別。
安裝前請注意
close_session 會改變狀態,把工作階段從開啟改為關閉並鎖定後續計費,呼叫前請確認工作階段 ID。工具本身免費且不轉移資金,但帳單反映的是在別處計費的按題費用。工作階段資料會傳送到所設定的 THREE_WS_BASE 端點,請只指向你信任的部署。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 three.ws Tutor,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

[three.ws]

@three-ws/tutor-mcp

Manage a Pay-As-You-Learn tutoring session from any AI agent — read its itemized running tab and close it for an attested invoice.

[npm] [license] [node] [MCP Registry] [three.ws]


A Model Context Protocol server that exposes the three.ws Pay-As-You-Learn tutor ledger over stdio. Read a tutoring session's itemized tab — one line item per answered question, with per-item cost and a running total — and close the session to seal an attested invoice.

The tutor bills per answered question; this server's tools are free. Viewing the running tab and closing the session never charge the learner — a learner must never pay to see what they owe or to end the session. Sessions are addressed by an opaque sessionId, so no API key and no signer are required — point THREE_WS_BASE at a deployment and go.

Install

bash
npm install @three-ws/tutor-mcp

Or run with npx (no install):

bash
npx @three-ws/tutor-mcp

Quick start

Claude Code, one line:

bash
claude mcp add tutor -- npx -y @three-ws/tutor-mcp

Claude Desktop / Cursor (claude_desktop_config.json or mcp.json):

json
{	"mcpServers": {		"tutor": {			"command": "npx",			"args": ["-y", "@three-ws/tutor-mcp"]		}	}}

Inspect the surface with the MCP Inspector:

bash
npx -y @modelcontextprotocol/inspector npx @three-ws/tutor-mcp

Tools

ToolTypeWhat it does
load_sessionreadRead a session's itemized running tab by sessionId — line items (question, level, tokens, cost), status, and running total.
close_sessionwriteFinalize a session and return its attested invoice — seals the ledger with a SHA-256 attestation and locks further billing.

Both tools are free and move no funds: the per-question answers are the paid action (handled elsewhere). load_session reads live data — the tab grows as questions are billed, so it is not idempotent. close_session mutates state (open → closed) but is itself idempotent: re-closing returns the same itemized total.

Input parameters

load_session — sessionId (required, ≤100 chars).

close_session — sessionId (required, ≤100 chars).

Example

jsonc
// load_session> { "sessionId": "learn-abc123" }{  "ok": true,  "sessionId": "learn-abc123",  "status": "open",  "createdAt": "2026-06-24T03:40:00.000Z",  "questionCount": 2,  "lineItems": [    { "n": 1, "question": "What is a Solana PDA?", "level": "intro", "outputTokens": 180, "costAtomics": 10000, "costUsd": "0.010000", "at": "2026-06-24T03:41:00.000Z" },    { "n": 2, "question": "How do CPIs work?", "level": "intro", "outputTokens": 220, "costAtomics": 10000, "costUsd": "0.010000", "at": "2026-06-24T03:42:00.000Z" }  ],  "totalAtomics": 20000,  "totalUsd": "0.020000"}
jsonc
// close_session> { "sessionId": "learn-abc123" }{  "ok": true,  "sessionId": "learn-abc123",  "createdAt": "2026-06-24T03:40:00.000Z",  "closedAt": "2026-06-24T03:45:00.000Z",  "questionCount": 2,  "lineItems": [ /* same itemized line items */ ],  "totalAtomics": 20000,  "totalUsd": "0.020000",  "attestation": "sha256:…"}

A sessionId with no stored history returns an empty open session (questionCount: 0) rather than an error — an honest "nothing billed yet", not a failure.

Requirements

  • Node.js >= 20.
  • Network access to https://three.ws (or your own THREE_WS_BASE).

Environment variables

VariableRequiredDefault
THREE_WS_BASEnohttps://three.ws
THREE_WS_TIMEOUT_MSno20000

Links


Part of the three.ws SDK suite — 3D AI agents, on-chain identity, and agent payments.
Website · Changelog · GitHub

來源:packages/tutor-mcp/README.md,提交 c8f2cde

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

2
  1. v0.1.2最新Oct 10, 2026
  2. v0.1.1Sep 16, 2026

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分