Blame

0f27c4 Claude (Dev) 2026-03-13 06:01:33
[mcp] Add Phase 1 progress tracking page
1
---
2
category: reference
3
tags: [dev, phase-1]
4
last_updated: 2026-03-13
5
confidence: high
6
---
7
8
# Phase 1 Progress
9
10
## Task Status
11
12
| Task | Status | Branch/Repo | Notes |
13
|------|--------|-------------|-------|
14
| P1-1 | Complete | `otterwiki` fork, `wikibot-io` branch | Lambda adapter using apig-wsgi (not Mangum — Mangum is ASGI-only, Flask is WSGI). EFS requirements documented. 325 tests pass. |
15
| P1-2 | Complete | `otterwiki-semantic-search`, merged to `main` | FAISS backend + Bedrock embedding adapter. ChromaDB still default. 56 tests pass. |
16
| P1-3 | Complete | `wikibot-io`, merged to `main` | Otterwiki on Lambda with EFS. URL: `https://jj75wak0pj.execute-api.us-east-1.amazonaws.com`. Cold start ~3.1s, warm 5-600ms. |
17
| P1-4 | Complete | `wikibot-io`, merged to `main` | REST API plugin on Lambda. 20 integration tests pass. Plugin loaded via explicit import (entry points stripped in build). |
18
| P1-5 | In progress | `wikibot-io`, `feat/P1-5-mcp-lambda` | Full MCP server replacing P0-7 PoC. |
19
| P1-6 | In progress | `wikibot-io`, `feat/P1-6-semantic-search-lambda` | FAISS + Bedrock on Lambda with VPC endpoint. |
20
| P1-7 | Complete | `wikibot-io`, merged to `main` | Custom domain `dev.wikibot.io` with ACM TLS. Single API Gateway, path-based routing. |
21
| P1-8 | Not started | — | E2E test. Blocked on P1-5, P1-6. |
22
23
## Architecture Decisions
24
25
### apig-wsgi instead of Mangum (P1-1 / P1-3)
26
Mangum v0.15+ is ASGI-only. Otterwiki is Flask/WSGI. Switched to `apig-wsgi` which directly adapts WSGI apps for API Gateway v2 events.
27
28
### Zip package + Lambda layer instead of Docker (P1-3)
29
Docker daemon not available in dev container. Zip approach: `pip install --target` with `--platform manylinux2014_x86_64`. Package size: 73MB uncompressed / 24MB compressed. Git binary from `lambci/git-lambda2` layer.
30
31
### Single API Gateway (P1-7)
32
Consolidated MCP and otterwiki onto one API Gateway. A custom domain can only map to one API Gateway. Routes: `$default` → otterwiki, `ANY /mcp` and `ANY /mcp/{proxy+}` → MCP Lambda.
33
34
### MCP on separate Lambda, no VPC (P0-7)
35
MCP Lambda needs internet access for WorkOS JWKS endpoint. Putting it in VPC would require NAT. Since MCP doesn't need EFS, `SimpleLambdaComponent` (no VPC) is simpler and cheaper.
36
37
### Plugin loading via explicit import (P1-4)
38
Build step strips `.dist-info` directories to save space, which breaks pluggy's `load_setuptools_entrypoints()`. Workaround: `import otterwiki_api` in `lambda_init.py` triggers self-registration before the Flask app initializes.
39
40
## Endpoints
41
42
| Endpoint | Status |
43
|----------|--------|
44
| `https://dev.wikibot.io/` | Live — Otterwiki web UI |
45
| `https://dev.wikibot.io/api/v1/health` | Live — REST API |
46
| `https://dev.wikibot.io/mcp` | Live — MCP (P0-7 PoC, being replaced by P1-5) |
47
48
## Also Completed (Track B / Prerequisites)
49
50
| Task | Status | Notes |
51
|------|--------|-------|
52
| P0-7 | Complete | FastMCP + WorkOS OAuth on Lambda. 15 tests. Merged to `main`. |
53
| WorkOS config | Complete | Google, Apple, GitHub OAuth providers. API key + Client ID in Pulumi config. AuthKit domain: `appreciative-seed-37-staging.authkit.app`. DCR + CIMD enabled. |
54
| Pulumi fix | Complete | Added `PULUMI_BACKEND_URL` to `pulumi.sh` to avoid conflicts with other Pulumi backends. |