taru-mcp 0.1.4 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -6,18 +6,86 @@ Zero dependencies. Pure Node.js. Works with any MCP client.
6
6
 
7
7
  ## Quick Setup
8
8
 
9
+ ### macOS / Linux
10
+
9
11
  ```bash
10
12
  curl -fsSL https://raw.githubusercontent.com/arupa-inc/taru-mcp/main/setup.sh | bash
11
13
  ```
12
14
 
15
+ ### Windows (PowerShell)
16
+
17
+ ```powershell
18
+ irm https://raw.githubusercontent.com/arupa-inc/taru-mcp/main/setup.ps1 | iex
19
+ ```
20
+
13
21
  The script will ask you:
14
22
  1. **Project folder name** — creates the workspace directory
15
23
  2. **AI client** — Claude Code, Codex, or both
16
- 3. **API token** — optional, can add later
24
+ 3. **Workspace token** — taru workspace token (`xxv_...`). Can be entered later if you don't have it yet.
17
25
 
18
26
  It handles `npm init`, `taru-mcp` installation, agent file (`CLAUDE.md` / `AGENTS.md`) setup, and MCP registration automatically.
19
27
 
20
- Get your API token from the taru web console: **Settings > API Key**.
28
+ Get your workspace token from the taru web console: **Settings > API Key**.
29
+
30
+ ## Manual Setup
31
+
32
+ If the setup script doesn't work, follow these steps:
33
+
34
+ ### 1. Install
35
+
36
+ ```bash
37
+ mkdir my-project && cd my-project
38
+ npm init -y
39
+ npm install taru-mcp
40
+ ```
41
+
42
+ ### 2. Copy agent instructions
43
+
44
+ ```bash
45
+ # For Claude Code
46
+ cp node_modules/taru-mcp/samples/CLAUDE.md ./CLAUDE.md
47
+
48
+ # For Codex
49
+ cp node_modules/taru-mcp/samples/AGENTS.md ./AGENTS.md
50
+ ```
51
+
52
+ ### 3. Register MCP server
53
+
54
+ ```bash
55
+ # Claude Code
56
+ claude mcp add taru -- npx taru-mcp --url https://taru-api.arupa.io --token xxv_your_token
57
+
58
+ # Codex
59
+ codex mcp add taru -- npx taru-mcp --url https://taru-api.arupa.io --token xxv_your_token
60
+ ```
61
+
62
+ ### 4. Or configure MCP manually
63
+
64
+ If `claude mcp add` doesn't work, create `.mcp.json` in your project root:
65
+
66
+ ```json
67
+ {
68
+ "mcpServers": {
69
+ "taru": {
70
+ "command": "npx",
71
+ "args": ["taru-mcp", "--url", "https://taru-api.arupa.io", "--token", "xxv_your_token"]
72
+ }
73
+ }
74
+ }
75
+ ```
76
+
77
+ For Claude Code global config (`~/.claude.json`):
78
+
79
+ ```json
80
+ {
81
+ "mcpServers": {
82
+ "taru": {
83
+ "command": "npx",
84
+ "args": ["taru-mcp", "--url", "https://taru-api.arupa.io", "--token", "xxv_your_token"]
85
+ }
86
+ }
87
+ }
88
+ ```
21
89
 
22
90
  ## Tools
23
91
 
@@ -30,8 +98,6 @@ Once connected, these MCP tools are available to the AI:
30
98
  | `store_document` | Store a document or opinion with auto-conflict detection |
31
99
  | `list_documents` | List all documents in the workspace |
32
100
  | `list_conflicts` | View pending knowledge conflicts |
33
- | `web_search` | Search the web via DuckDuckGo |
34
- | `web_fetch` | Fetch and extract text from a URL |
35
101
  | `rebalance` | Merge similar keywords, clean up orphan nodes |
36
102
 
37
103
  ## How it works
package/bin/taru-mcp.mjs CHANGED
@@ -39,7 +39,9 @@ Examples:
39
39
  }
40
40
 
41
41
  url = url.replace(/\/+$/, "");
42
- const endpoint = `${url}/mcp/${workspaceId}`;
42
+ // If workspace ID was explicitly provided, use the scoped endpoint; otherwise use token-based auto endpoint
43
+ const hasExplicitWorkspace = args.some(a => a === "--workspace-id" || a === "-w") || env.TARU_WORKSPACE_ID;
44
+ const endpoint = hasExplicitWorkspace ? `${url}/mcp/${workspaceId}` : `${url}/mcp`;
43
45
  const isHttps = endpoint.startsWith("https://");
44
46
 
45
47
  stderr.write(`[taru-mcp] endpoint: ${endpoint}\n`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "taru-mcp",
3
- "version": "0.1.4",
3
+ "version": "0.1.5",
4
4
  "description": "MCP server for taru knowledge graph — connect Claude Code or Codex to your team's shared brain",
5
5
  "bin": {
6
6
  "taru-mcp": "./bin/taru-mcp.mjs"
package/samples/AGENTS.md CHANGED
@@ -9,8 +9,6 @@ You have access to the taru MCP server — a research knowledge graph with tempo
9
9
  - store_document: Store extracted knowledge (handles embedding + graph)
10
10
  - list_documents: List all documents with status and confidence
11
11
  - list_conflicts: View pending knowledge conflicts
12
- - web_search: Search the web (DuckDuckGo)
13
- - web_fetch: Fetch text content from a URL
14
12
  - rebalance: Clean up the knowledge graph (merge keywords, remove orphans)
15
13
 
16
14
  ### Rules
package/samples/CLAUDE.md CHANGED
@@ -9,8 +9,6 @@ You have access to the taru MCP server — a research knowledge graph with tempo
9
9
  - store_document: Store extracted knowledge (handles embedding + graph)
10
10
  - list_documents: List all documents with status and confidence
11
11
  - list_conflicts: View pending knowledge conflicts
12
- - web_search: Search the web (DuckDuckGo)
13
- - web_fetch: Fetch text content from a URL
14
12
  - rebalance: Clean up the knowledge graph (merge keywords, remove orphans)
15
13
 
16
14
  ### Rules
package/setup.sh CHANGED
@@ -12,7 +12,7 @@ echo " 🌳 taru MCP Setup"
12
12
  echo ""
13
13
 
14
14
  # 1. Ask project folder name
15
- read -rp "Project folder name: " FOLDER
15
+ read -rp "Project folder name: " FOLDER </dev/tty
16
16
  if [ -z "$FOLDER" ]; then
17
17
  echo "Error: folder name is required"
18
18
  exit 1
@@ -33,7 +33,7 @@ echo " 1) Claude Code"
33
33
  echo " 2) Codex"
34
34
  echo " 3) Not sure (copies both CLAUDE.md and AGENTS.md)"
35
35
  echo ""
36
- read -rp "Choose [1/2/3]: " CLIENT_CHOICE
36
+ read -rp "Choose [1/2/3]: " CLIENT_CHOICE </dev/tty
37
37
 
38
38
  case "$CLIENT_CHOICE" in
39
39
  1) CLIENT="claude" ;;
@@ -43,7 +43,7 @@ esac
43
43
 
44
44
  # 3. Ask token (skippable)
45
45
  echo ""
46
- read -rp "API token (press Enter to skip): " TOKEN
46
+ read -rp "Workspace token (xxv_..., press Enter to add later): " TOKEN </dev/tty
47
47
 
48
48
  # Check npm
49
49
  if ! command -v npm &>/dev/null; then
@@ -114,7 +114,7 @@ echo ""
114
114
  echo " Project: $(pwd)"
115
115
  [ "$CLIENT" = "claude" ] || [ "$CLIENT" = "both" ] && echo " Agent file: ./CLAUDE.md"
116
116
  [ "$CLIENT" = "codex" ] || [ "$CLIENT" = "both" ] && echo " Agent file: ./AGENTS.md"
117
- [ -n "$TOKEN" ] && echo " Token: configured" || echo " Token: skipped (add later via settings)"
117
+ [ -n "$TOKEN" ] && echo " Token: configured" || echo " Token: not set yet (add via settings)"
118
118
  echo ""
119
119
  echo " Open this folder in your AI client to start growing the tree."
120
120
  echo ""