Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 9 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,10 @@ bash setup.sh
- Codex: `examples/codex_mcp_config.json`
- Claude Desktop: `examples/claude_desktop_config.json`
- macOS/Linux: `*_unix.json` variants

Set:
- `UNITY_DOCS_MCP_ROOT` to your local clone path
- `UNITY_DOCS_MCP_HOST=127.0.0.1`
- `UNITY_DOCS_MCP_PORT=8765`
- Replace the `command` value with the absolute path to your local `start_server` script.
- Windows example: `C:\\projects\\UnityRAG\\start_server.bat`
- macOS/Linux example: `/home/you/UnityRAG/start_server.sh`
- No env vars are required for the default onboarding flow.

3. Restart your agent and run a prompt:
- "How do I schedule an `IJobParallelFor` with batch size?"
Expand Down Expand Up @@ -77,6 +76,11 @@ Notes:
- In `CUDA` mode, setup scripts enforce CUDA torch and fail if no working CUDA runtime is detected.
- In `CPU-only` mode, setup configures `index.vector: none` and skips vector dependencies.

Optional advanced overrides:
- `UNITY_DOCS_MCP_ROOT`
- `UNITY_DOCS_MCP_HOST`
- `UNITY_DOCS_MCP_PORT`

## Commands

```bash
Expand Down
13 changes: 4 additions & 9 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,20 +86,15 @@ These require local Unity raw docs under `data/unity/<version>/raw/UnityDocument
- Link extraction ignores external and anchor-only links; internal links are normalized to doc_ids for related lookups.

## Codex/Claude MCP wiring (HTTP server, auto-started)
- Add a server entry pointing to the HTTP launcher inside the venv. Example (Windows):
- Use `start_server` as the command and set it to an absolute path. Example (Windows):
```json
{
"servers": {
"unity-docs": {
"command": ".\\.venv\\Scripts\\unitydocs-mcp-http.exe",
"args": [],
"env": {
"UNITY_DOCS_MCP_ROOT": "C:\\projects\\UnityRAG",
"UNITY_DOCS_MCP_HOST": "127.0.0.1",
"UNITY_DOCS_MCP_PORT": "8765"
}
"command": "C:\\projects\\UnityRAG\\start_server.bat",
"args": []
}
}
}
```
Alternatively, you can point to `start_server.bat` or `start_server.sh` if you want a visible console window. Adjust the `UNITY_DOCS_MCP_ROOT` path to your clone; with this env the server finds `config.yaml` and data without changing the working directory. Codex/Claude will auto-start the MCP server and connect over HTTP at `http://127.0.0.1:8765/mcp`.
macOS/Linux equivalent command: `/path/to/UnityRAG/start_server.sh`. This default flow does not require manually setting `UNITY_DOCS_MCP_ROOT`, `UNITY_DOCS_MCP_HOST`, or `UNITY_DOCS_MCP_PORT`. Use those env vars only if you need custom overrides.
9 changes: 2 additions & 7 deletions examples/claude_desktop_config.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
{
"mcpServers": {
"unity-docs": {
"command": "start_server.bat",
"args": [],
"env": {
"UNITY_DOCS_MCP_ROOT": "C:\\projects\\UnityRAG",
"UNITY_DOCS_MCP_HOST": "127.0.0.1",
"UNITY_DOCS_MCP_PORT": "8765"
}
"command": "C:\\path\\to\\UnityRAG\\start_server.bat",
"args": []
}
}
}
11 changes: 3 additions & 8 deletions examples/claude_desktop_config_unix.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
{
{
"mcpServers": {
"unity-docs": {
"command": "./start_server.sh",
"args": [],
"env": {
"UNITY_DOCS_MCP_ROOT": "/path/to/UnityRAG",
"UNITY_DOCS_MCP_HOST": "127.0.0.1",
"UNITY_DOCS_MCP_PORT": "8765"
}
"command": "/path/to/UnityRAG/start_server.sh",
"args": []
}
}
}
9 changes: 2 additions & 7 deletions examples/codex_mcp_config.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
{
"servers": {
"unity-docs": {
"command": "start_server.bat",
"args": [],
"env": {
"UNITY_DOCS_MCP_ROOT": "C:\\projects\\UnityRAG",
"UNITY_DOCS_MCP_HOST": "127.0.0.1",
"UNITY_DOCS_MCP_PORT": "8765"
}
"command": "C:\\path\\to\\UnityRAG\\start_server.bat",
"args": []
}
}
}
11 changes: 3 additions & 8 deletions examples/codex_mcp_config_unix.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
{
{
"servers": {
"unity-docs": {
"command": "./start_server.sh",
"args": [],
"env": {
"UNITY_DOCS_MCP_ROOT": "/path/to/UnityRAG",
"UNITY_DOCS_MCP_HOST": "127.0.0.1",
"UNITY_DOCS_MCP_PORT": "8765"
}
"command": "/path/to/UnityRAG/start_server.sh",
"args": []
}
}
}