Skip to content

Commit 7a8ac2e

Browse files
committed
feat: add research copilot workspace
1 parent 36b198a commit 7a8ac2e

53 files changed

Lines changed: 4775 additions & 11 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.codex/config.toml

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,17 @@
33
#
44
# Trust this repository in Codex so this file is loaded (project MCP is for trusted projects only).
55
#
6-
# Neon: set NEON_API_KEY in your environment (Neon Console → API keys). Never paste tokens here.
7-
# Same variable name works across machines; pair with a gitignored .mcp.json for Cursor/Claude Code if you use Bearer there.
8-
9-
[mcp_servers.neon]
10-
url = "https://mcp.neon.tech/mcp"
11-
bearer_token_env_var = "NEON_API_KEY"
6+
# Keep external MCPs opt-in here. Active project-scoped MCP entries are initialized when
7+
# Codex starts in this trusted repo, so a missing secret creates startup warnings even when
8+
# the tool is not needed.
9+
#
10+
# Neon is intentionally disabled by default. When a task actually needs Neon MCP access:
11+
# 1. Export NEON_API_KEY in the shell or app environment that launches Codex.
12+
# 2. Uncomment the block below for that session.
13+
# 3. Restart Codex so the project MCP config is reloaded.
14+
#
15+
# Never paste tokens in this file.
16+
#
17+
# [mcp_servers.neon]
18+
# url = "https://mcp.neon.tech/mcp"
19+
# bearer_token_env_var = "NEON_API_KEY"

CHANGELOG.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,21 @@
11
# Changelog
22

3+
## 2026-04-12 — Issue Created: issue-013
4+
5+
- **Type**: Feature
6+
- **Title**: PM Research Copilot — chat-first planning, orchestrated evidence, exportable insights
7+
- **App**: TBD (portfolio-level product direction; implementation path after `/explore`)
8+
- **Status**: Discovery
9+
- **Linear**: Root [**VIJ-65**](https://linear.app/vijaypmworkspace/issue/VIJ-65/issue-013-pm-research-copilot-chat-first-planning-orchestrated) · Project [**issue-013 — PM Research Copilot…**](https://linear.app/vijaypmworkspace/project/issue-013-pm-research-copilot-chat-first-planning-orchestrated-a5e43bf29c24)
10+
311
## 2026-04-10 — MoneyMirror Hotfix: Dashboard 500 on Gmail Sync users (RCA + 5-fix patch)
412

513
Post-cycle hotfix — production HTTP 500 on `GET /api/dashboard` triggered by Gmail sync introducing a `gmail_sync` statement type that Zod schema validation did not accept.
614

715
**Root cause:** `layerAFactsSchema` in `coaching-facts.ts` used `z.enum(['bank_account', 'credit_card'])``'gmail_sync'` was absent. After a Gmail sync run, `fetchDashboardLegacy` (no `statement_type` filter) would pick the most-recently-created `gmail_sync` statement. `buildLayerAFacts` then called `layerAFactsSchema.parse({ statement_type: 'gmail_sync' })`, throwing a `ZodError` caught by the route's `try/catch` and returned as HTTP 500.
816

917
**Fixes applied:**
18+
1019
1. **`coaching-facts.ts:31`** — Added `'gmail_sync'` to `layerAFactsSchema` `statement_type` enum. (crash fix)
1120
2. **`statements.ts:1`** — Added `'gmail_sync'` to the `StatementType` TypeScript union. (type correctness)
1221
3. **`dashboard-legacy.ts:50`** — Added `AND s.statement_type != 'gmail_sync'` to the `statementId=null` WHERE clause so the legacy path never selects Gmail synthetic statements. (behavior fix)

README.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ A simulated, end-to-end product development organization where specialized AI ag
66

77
> **Live:** [ai-product-os-493e.vercel.app](https://ai-product-os-493e.vercel.app/) | Built and operated with [Claude Code](https://claude.ai/code). You need Claude Code to run the slash commands.
88
>
9-
> Deploy note: `ai-product-os-493e` and `money-mirror` are separate Vercel projects. MoneyMirror production deploys from `main`; the landing app is path-gated so it should only build when `apps/landing` changes.
9+
> Deploy note: `ai-product-os-493e` is the current landing Vercel project. MoneyMirror was a separate Vercel project in earlier cycles; its legacy app code has been removed from this monorepo.
1010
1111
---
1212

@@ -40,7 +40,8 @@ A simulated, end-to-end product development organization where specialized AI ag
4040
| 006 | [ozi-reorder](apps/ozi-reorder/) | Reorder reminder experiment for dark-store baby essentials (50/50 test vs. control, 7 PostHog events) | Next.js, Neon, PostHog | Complete |
4141
| 007 | [ozi-insights](apps/ozi-insights/) | Synthetic Freshdesk support data for order reliability research (30 tickets, grounded in Play Store) | Data workspace | Explored |
4242
| 008 | [nykaa-personalisation](apps/nykaa-personalisation/) | Hyper-personalized discovery feed (affinity + intent scoring, 10 PostHog events, 5 API routes) | Next.js, Neon, PostHog | Archived |
43-
| 009 | [money-mirror](apps/money-mirror/) | AI personal finance coach — parses Indian bank + credit card PDFs, reveals perception gap, delivers consequence-first nudges. Weekly recap email. | Next.js 16, Neon Auth, Neon DB, Gemini 2.5 Flash, Resend | Live |
43+
| 009 | money-mirror | AI personal finance coach — parses Indian bank + credit card PDFs, reveals perception gap, delivers consequence-first nudges. Weekly recap email. | Next.js 16, Neon Auth, Neon DB, Gemini 2.5 Flash, Resend | Archived |
44+
| 013 | [research-copilot](apps/research-copilot/) | Chat-first PM research workspace with plan approval, visible tool orchestration, cited findings, and Markdown export. | Next.js 16, Neon Postgres, OpenRouter, PostHog | T0 |
4445
|| [landing](apps/landing/) | Framework landing page showcasing pipeline, agents, and shipped products | Next.js, Tailwind CSS | Live |
4546

4647
Each issue number maps directly across all folders: `experiments/ideas/issue-NNN.md`, `experiments/exploration/exploration-NNN.md`, `experiments/plans/plan-NNN.md`, and `experiments/results/*-NNN.md`.
@@ -132,6 +133,7 @@ If Linear is unavailable, the Linear utility command should fail explicitly. The
132133
3. **Run commands sequentially** — pass the command file from [`commands/`](commands/) to Claude Code (e.g., paste `commands/create-issue.md` content and follow it)
133134
4. **Read the knowledge base first** — every command in the pipeline reads all files in [`knowledge/`](knowledge/) before generating output to avoid repeating past mistakes
134135
5. **Track gates, not just progress** — check `project-state.md` after each command; blocked = do not proceed
136+
6. **Validate repo changes** — run `bun run validate` from the repo root before accepting agent work
135137

136138
**Default tech stack** (used across all apps):
137139

@@ -146,8 +148,8 @@ If Linear is unavailable, the Linear utility command should fail explicitly. The
146148
```bash
147149
cd apps/[project-name]
148150
cp .env.local.example .env.local # fill in your keys
149-
npm install
150-
npm run dev
151+
bun install
152+
bun run dev
151153
```
152154

153155
Each app includes a `schema.sql` (idempotent) that must be applied in your database editor before first run.

0 commit comments

Comments
 (0)