PRD
PRD
Last updated 5/24/2026
Colony — Progressive Product Requirements Document
PRD Metadata
| Field | Value |
|---|---|
| Product Name | Colony |
| Tagline | The Command Interface for the ZoomProp GTM Agentic Stack |
| Repository | midwestco/colony |
| PRD Version | v1.0 |
| Spec Reference | docs/ZP_GTM_Agentic_Stack_Draft_V1.pdf |
| Architecture Reference | docs/architecture.md |
| Phase 1 Plan | docs/phase-1.md, docs/phase1/action_plans/ |
| Phase 2 Plan | docs/phase2/action_plans/ |
| Primary Stack | Next.js 16 · React 19 · Cloud SQL Postgres 16 · pgvector · Inngest · Clerk · GCP Cloud Run |
| Infrastructure-as-Code | Terraform (infrastructure/gcp/) via hashicorp/google 7.29.0 and hashicorp/google-beta 7.29.0 |
| Test Coverage | 38 spec files across Phase 1 (Markdown specs) and Phase 2 (TypeScript specs) |
| Status | Active Development — Phase 2 in progress |
v0.1 Spark — Problem & Outcomes
Problem Statement
ZoomProp's go-to-market motion is fragmented across disconnected point solutions: a CRM that doesn't talk to the outbound tool, a recording platform whose signals never reach the pipeline, content that is produced without attribution to revenue, and onboarding assets that are assembled manually after every closed deal. Founders and GTM leads spend three to four hours per day context-switching between these surfaces — Pipedrive, a LinkedIn outreach tool, a meeting recorder, a content calendar, and a spreadsheet — instead of executing. There is no single source of truth, no memory layer that accumulates institutional knowledge, and no way to command the entire GTM stack in plain English.
The deeper problem: the raw capability to automate every stage of the GTM loop (prospect discovery, qualification, personalised outreach, meeting intelligence, post-call nurture, content production, onboarding, and analytics) already exists in the form of LLMs and specialist APIs, but it is not orchestrated into a coherent product. Each capability lives in a silo, requires separate configuration, and produces output that no other tool can consume.
Desired Outcomes
| ID | Outcome | Measurable Signal |
|---|---|---|
| OUT-001 | Founders spend < 30 minutes per day on GTM administration | Daily active session duration on /overview drops below 30 min while pipeline throughput stays constant |
| OUT-002 | Time-to-first-outreach for a new ICP segment drops from days to < 2 hours | Median elapsed time from "find prospects" command to first message sent |
| OUT-003 | Every meeting signal is captured and routed to the correct CRM field without manual entry | Zero unlinked Gemini Meet Notes in Google Drive after 30 days |
| OUT-004 | Closed-Won triggers an 8-asset Deployment Kit within one business day | Onboarding agent success rate ≥ 95% measured via deployment_kits table completion |
| OUT-005 | Daily brief lands in inbox every morning, providing a complete operational picture | Brief delivery rate ≥ 99% measured via Resend event logs |
| OUT-006 | Knowledge Core accumulates ≥ 10 domains of institutional GTM knowledge available via pgvector retrieval | Retrieval hit rate (cosine similarity ≥ 0.82) on benchmark query set |
Constraints
- Single-tenant per deployment at Phase 1. Clerk organizations map 1:1 to a Colony deployment; multi-org switching is hardened in Phase 2 (
docs/phase2/action_plans/27_org_switcher_hardening.md). - GCP-only infrastructure. Cloud Run, Cloud SQL (
colony-39989:…:colony), Cloud Storage (gs://colony-assets), GCP Secret Manager, and KMS are the mandated primitives. No AWS or Azure resources. - Human-in-the-loop approval gates are non-negotiable. Every outbound message and every prospect candidate batch must pass through an approval queue before being sent. Circuit breakers enforce per-org send limits (
docs/phase1/action_plans/22_circuit_breakers.md,docs/phase2/action_plans/11_circuit_breakers_phase2.md). - No cold start on LLM calls without context. Every message, content piece, and brief must pull exemplars from the Knowledge Core via pgvector before generation.
- RBAC is enforced at the API layer. Three Clerk roles gate every action; the GitHub Actions workflow
.github/workflows/rbac-check.ymlruns on every PR. - Two-tier secret architecture is fixed. Platform-level secrets live in GCP Secret Manager; per-org credentials (Pipedrive, Unipile, etc.) live in the KMS-encrypted
api_keystable (Colony Vault).
v0.2 Market Definition — ICP & Segments
Ideal Customer Profile
Colony is built first and specifically for the ZoomProp GTM team — a PropTech founder-led organisation running a high-velocity B2B outbound motion targeting institutional real estate buyers, fund analysts, and property operators. The generalised ICP, should Colony be productised beyond ZoomProp, is a seed-to-Series-A B2B SaaS or PropTech company with 2–10 people on the GTM team, an existing Pipedrive CRM, and a need to run personalised outbound at volume without hiring an SDR team.
Segment Table
| Segment | Description | Signal Indicators | Priority |
|---|---|---|---|
| SEG-001: PropTech Founders | Founding team members owning GTM at a PropTech startup; running outbound to fund analysts, asset managers, and property operators | Pipedrive user, LinkedIn outreach, Gemini Meet Notes in Drive | P0 — primary ZoomProp user |
| SEG-002: GTM Leads at Vertical SaaS | VP Sales or Head of GTM at a 10–50 person B2B SaaS with a defined ICP, existing CRM, and content team of one | Uses Pipedrive or HubSpot, has a content calendar, records all sales calls | P1 — near-term expansion |
| SEG-003: Revenue Operations | RevOps practitioners who need a unified data layer and automated daily brief to manage pipeline health across multiple AEs | Heavy Pipedrive bi-sync usage, pipeline analytics consumer | P2 — Phase 2 enablement |
| SEG-004: Healthcare SaaS GTM | Specifically called out in docs/phase2/action_plans/22_healthcare_icp_signal_extraction.md as a vertical with bespoke ICP signal extraction requirements | Regulated industry, compliance-sensitive outreach, specialised qualification criteria | P2 — vertical extension |
"Not For"
- Enterprise sales organisations with existing Salesforce deployments and dedicated RevOps teams of 5+. Colony does not integrate with Salesforce and does not attempt to replace a mature CRM stack.
- Outbound agencies managing multiple client accounts. Colony's per-org Clerk architecture and vault model are not designed for an agency reseller model.
- Consumer or B2C businesses. Every agent, prompt, and ICP-scoring heuristic in Colony is calibrated for B2B deal cycles.
- Teams unwilling to maintain human approval gates. Colony's design philosophy requires founder review of outbound messages; fully autonomous send is not supported and is blocked by circuit breakers.
v0.3 Commercial Model — Pricing & Positioning
Positioning
Colony is not a CRM. It is not an outbound sequencer. It is not a meeting recorder. It is the command plane that makes all three — and six other GTM workflows — work as a single system. The competitive frame is: "What if your entire GTM stack had one interface, one memory layer, and one agent brain?" The product is positioned as infrastructure for founder-led GTM, not a SaaS tool with a features checklist.
Monetisation
At the current stage, Colony is an internal platform for ZoomProp with no external pricing. The commercial model described here applies to the productisation path.
| Tier | Description | Pricing Basis |
|---|---|---|
| Foundation | Single Clerk org, all Phase 1 agents, unlimited Knowledge Core, up to 500 prospects/month, 2 active sequences | Per-org seat licence, monthly |
| Growth | Adds Phase 2 discovery orchestrator, multi-channel sequences, mailbox rotation, Gmail + Calendar integration, Notion KC sync, CSV import | Per-org + usage-based on prospect discovery volume |
| Enterprise | Custom vertical ICP signal extraction (healthcare module), multi-org switcher, dedicated Cloud Run service, CMEK at rest | Custom contract, dedicated GCP project |
Moat Thesis
Colony's durable differentiation is the Knowledge Core — a pgvector-backed, 10-domain institutional memory that compounds with every message sent, every recording ingested, and every case study produced. Competitors can replicate the outbound sequencer or the chat interface. They cannot replicate 12–24 months of accumulated GTM signals, winning message exemplars, ICP qualification history, and post-call insights that are embedded into every generation call Colony makes. The moat is the data flywheel, not the feature set.
A secondary moat is the two-tier secret architecture and per-org circuit breaker model, which allows Colony to safely hand the keys of a production GTM stack to a non-technical founder without risk of runaway sends or credential exposure. This compliance posture will matter increasingly as email deliverability regulations tighten (docs/phase2/action_plans/19_email_deliverability_and_warmup.md).
v0.4 User Journeys
UJ-001: Daily GTM Command — Morning Brief to First Action
Actor: Founder / GTM Lead (Clerk role: owner)
Entry Point: Email inbox (Resend delivery) or /overview route
Trigger: Scheduled daily brief job fires each morning
- Founder opens the daily brief email. It contains: pipeline today (deals by stage), alerts (deals at risk, HOT reply queue depth), yesterday's output (messages sent, content published, recordings processed).
- Founder navigates to
/overview. The GTM Orchestrator chat interface is pre-loaded with the same brief as context. - Founder types: "There are two HOT replies in the queue — draft responses and get them ready for my review."
- The orchestrator streams a multi-turn tool loop: fetches HOT reply queue → retrieves conversation history from
api_keys-vaulted Unipile → pulls message exemplars from Knowledge Core via pgvector → generates two personalised replies. - Replies surface in the approval queue. Founder reviews, edits one, approves both.
- Unipile sends messages. Circuit breaker decrements the per-org daily send counter.
Success Metric: Full loop completes in < 8 minutes from brief open.
UJ-002: Prospect Discovery Campaign
Actor: Founder (Clerk role: owner)
Entry Point: /overview chat interface
Trigger: Founder identifies a new ICP segment to target
- Founder types: "Find 20 European fund analysts at firms with AUM > €500M and draft signal-led outreach for each."
- GTM Orchestrator dispatches the Campaign Orchestrator via Inngest event.
- Campaign Orchestrator fans out to the Prospect Agent, which queries: Pipedrive LeadBooster scraper (
docs/phase2/action_plans/02_pipedrive_leadbooster_scraper.md), Google Places (docs/phase2/action_plans/03_google_places_integration.md), SerpAPI (docs/phase2/action_plans/04_serpapi_integration.md), Unipile LinkedIn search (docs/phase2/action_plans/06_unipile_search_extension.md), and public data adapters (docs/phase2/action_plans/05_public_data_adapters.md). - The Matching Algorithm (
docs/phase2/action_plans/08_matching_algorithm.md) scores each candidate against the ICP definition. Anti-ICP hard pre-filter (docs/phase2/action_plans/16_anti_icp_hard_prefilter.md) eliminates disqualifying signals before scoring. - Candidates surface in the Candidate Approval Queue (
docs/phase2/action_plans/09_candidate_approval_queue.md). Founder reviews the shortlist; rejects 3, approves 17. - Approved candidates are passed to the Qualification Agent, which enriches each with LinkedIn activity signals, company news (SerpAPI), and any existing CRM history.
- Message Generator Agent selects the
signal-ledangle (one of 5: signal, pain, referral, pattern-break, insight) and generates personalised messages for each contact, pulling exemplars from Knowledge Core. - Messages enter the approval queue. Founder batch-approves. Outbound Sequence Engine enrols each contact into a T1 sequence.
Success Metric: 17 approved, personalised messages queued for send within 90 minutes of the initial command.
UJ-003: Recording Intelligence — Meeting to CRM
Actor: System (automated), reviewed by GTM Lead Entry Point: Google Drive folder watched by Recording Intelligence Agent Trigger: Gemini Meet Notes file appears in the configured Drive folder
- A new meeting recording summary is written to Google Drive by Gemini Meet Notes.
- The Recording Intelligence Agent (
docs/phase1/action_plans/14_recording_intelligence_agent.md) detects the new file. - Agent extracts structured signals: deal stage indicators, objections raised, next steps committed, stakeholder sentiment, buying signals.
- Signals are written to the corresponding Pipedrive deal fields via bi-sync. The deal's ICP score is recalculated.
- Extracted insights are embedded and upserted into the Knowledge Core (domain:
recording_signals). - Post-Call Agent (
docs/phase1/action_plans/15_post_call_agent.md) generates a follow-up email draft, a humanised post-call summary (docs/phase2/action_plans/18_humanized_post_call_writer.md), and updates the deal's next-step task in Pipedrive. - The draft follow-up appears in the approval queue for the GTM Lead.
Success Metric: Zero manual CRM updates required after a recorded meeting. Signal-to-CRM latency < 15 minutes.
UJ-004: Closed-Won → Deployment Kit Generation
Actor: System (automated), reviewed by Founder
Entry Point: Pipedrive deal stage change to "Closed-Won" (bi-sync event)
Trigger: deal.stage_changed event consumed by Inngest
- Bi-sync detects the stage change and fires an Inngest event.
- Onboarding Agent (
docs/phase1/action_plans/17_onboarding_agent.md) receives the event. - Agent reads the full deal record, contact history, and meeting recordings from the Knowledge Core.
- Agent generates 8 assets: pitch deck, one-pager, case-study shortlist, pricing reference, rollout calendar, stakeholder map, risk register, KPI dashboard.
- Assets are stored in GCS (
gs://colony-assets) with CMEK encryption and signed URLs. - A
deployment_kitrecord is written to Postgres linking all 8 asset URLs to the deal. - Founder receives a Resend email with links to all 8 assets and a summary of the onboarding recommended path.
Success Metric: All 8 assets generated and delivered within 4 hours of Closed-Won.
UJ-005: Content Pipeline — Pillar to Pipeline Attribution
Actor: Content Agent (automated), reviewed by GTM Lead
Entry Point: Scheduled Inngest job or manual command via /overview
Trigger: Weekly content cadence or explicit "create content" command
- Content Agent (
docs/phase1/action_plans/16_content_agent.md) selects the active content pillar from the 6-pillar framework. - Agent retrieves relevant exemplars from Knowledge Core (domain:
content_exemplars) and recent pipeline signals (deal stage distribution, common objections from recording signals). - Agent drafts the content piece (LinkedIn post, newsletter section, or case study draft) with pipeline-influence hooks embedded.
- Draft appears in the approval queue. GTM Lead reviews, edits, approves.
- On approval, content is published via the configured channel. Attribution metadata is written to the
content_piecestable, linking the piece to the active deals it influences. - Analytics Agent tracks downstream pipeline movement correlated with content publish date.
Success Metric: Every published content piece has an attribution record in content_pieces. Pipeline influence is visible in the daily brief within 48 hours.
UJ-006: Knowledge Core — Curation and Retrieval
Actor: Founder / GTM Lead (Clerk role: owner or member)
Entry Point: Knowledge Core Editor (docs/phase1/action_plans/24_knowledge_core_editor.md)
Trigger: Manual curation or automated ingestion from recording/content agents
- GTM Lead opens the Knowledge Core editor surface.
- Lead reviews recently auto-ingested entries (from recording signals, approved messages, published content) across 10 domains.
- Lead promotes a winning message variant to "exemplar" status, adding a tag and a quality note.
- The entry is re-embedded with
pgvector(1536-dimension OpenAI embeddings) and upserted. - All subsequent Message Generator calls for the relevant ICP segment retrieve this exemplar as a top-k result (cosine similarity retrieval).
Success Metric: Exemplar retrieval hit rate ≥ 82% on a monthly benchmark query run.
v0.5 Red Team Review
Risk Register
| ID | Risk | Category | Likelihood | Impact | Mitigation |
|---|---|---|---|---|---|
| RISK-001 | Runaway outbound sends exceed per-org daily limit due to circuit breaker misconfiguration | Operational | Medium | Critical | Per-org circuit breakers in api_keys table, enforced in Phase 1 (docs/phase1/action_plans/22_circuit_breakers.md) and extended in Phase 2 (docs/phase2/action_plans/11_circuit_breakers_phase2.md); rbac-check.yml gates config changes |
| RISK-002 | Pipedrive API rate limits cause batch discovery jobs to fail silently | Integration | High | High | Batch runner artifacts (runners/.artifacts/pipedrive-batch/) show retry logic; circuit breaker Phase 2 adds per-integration rate guard; Langfuse traces every tool call for visibility |
| RISK-003 | GCP Secret Manager credentials leak via Cloud Run environment injection | Security | Low | Critical | Two-tier secret model; per-org credentials in KMS-encrypted api_keys table, never in environment variables; Trivy scanning via .codacy/tools-configs/trivy.yaml |
| RISK-004 | pgvector index degrades retrieval quality as Knowledge Core grows beyond 100k embeddings | Performance | Medium | High | 1536-dimension index with cosine similarity; monitoring via Langfuse; benchmark suite in docs/phase1/testing/08_e2e_knowledge_core.spec.md |
| RISK-005 | Gemini Meet Notes ingestion fails for non-standard recording formats or Drive folder permission changes | Integration | High | Medium | Google Drive setup runbook (docs/phase1/runbooks/google-drive-setup.md); recording pipeline runbook (docs/phase2/runbooks/03_recording_pipeline.md); e2e spec docs/phase1/testing/06_e2e_recording_intelligence.spec.md |
| RISK-006 | Clerk RBAC bypass — a member-role user escalates to owner-level agent actions | Security | Low | Critical | RBAC enforced at API layer; dedicated CI check .github/workflows/rbac-check.yml; e2e spec docs/phase1/testing/02_e2e_auth_and_rbac.spec.md |
| RISK-007 | Email deliverability degradation causes outbound messages to land in spam | Deliverability | High | High | Email deliverability and warmup plan docs/phase2/action_plans/19_email_deliverability_and_warmup.md; mailbox rotation docs/phase2/action_plans/25_sender_mailbox_rotation.md; Resend setup runbook docs/phase1/runbooks/resend-setup.md |
| RISK-008 | Inngest durable function backlog grows unbounded during discovery orchestrator fan-out | Operational | Medium | High | Per-org concurrency limits in Inngest configuration; circuit breakers apply to agent-dispatched events; Phase 2 wave orchestration plan docs/phase2/action_plans/00a_WAVE_ORCHESTRATION.md |
| RISK-009 | Onboarding agent generates incorrect assets for wrong deal due to bi-sync race condition | Data Integrity | Low | High | Idempotency enforced via Inngest event IDs; deployment_kits table has a unique constraint on deal_id; e2e spec covers the full onboarding flow |
| RISK-010 | DR recovery gap — Cloud SQL instance unavailable; no tested restore procedure | Operational | Low | Critical | DR recovery runbook docs/phase2/runbooks/04_dr_recovery.md; Cloud SQL automated backups managed via infrastructure/gcp/cloud-sql.tf |
| RISK-011 | Anti-ICP filter over-exclusion causes valid prospects to be dropped silently | Product | Medium | Medium | Hard pre-filter logic tested in docs/phase2/testing/16_anti_icp.spec.ts; candidate queue shows rejected candidates with rejection reason for founder review |
| RISK-012 | Multi-org switcher exposes one org's data to another via session token reuse | Security | Low | Critical | Org switcher hardening plan docs/phase2/action_plans/27_org_switcher_hardening.md; e2e spec docs/phase2/testing/27_org_switcher.spec.ts; Clerk org isolation is the primary guard |
v0.6 Architecture
System Overview
Colony is a Next.js 16 / React 19 application deployed to GCP Cloud Run (infrastructure/gcp/cloud-run-runner.tf), backed by Cloud SQL Postgres 16 (infrastructure/gcp/cloud-sql.tf) with the pgvector (1536-dimension) and pgcrypto extensions initialised in infrastructure/postgres/init/02-extensions.sql. Static and generated assets are stored in GCS (gs://colony-assets, defined in infrastructure/gcp/storage.tf) with CMEK encryption and signed URL access.
Authentication and multi-tenancy are managed by Clerk, with Svix webhooks providing real-time organisation and user sync into the Postgres users and organisations tables. Three RBAC roles (owner, member, viewer) are enforced at the Next.js App Router API layer and validated in CI via .github/workflows/rbac-check.yml.
Agent execution is driven by Inngest durable functions, which provide event-sourced, retry-capable orchestration for all long-running agent workflows. The GTM Orchestrator and Campaign Orchestrator are multi-turn Inngest functions; specialist agents are dispatched as child functions.
TECH References
| ID | Component | Implementation |
|---|---|---|
| TECH-001 | Next.js App Router + SSE Streaming | Orchestrator chat at /overview; SSE used for real-time tool call streaming to the UI |
| TECH-002 | Cloud SQL Postgres 16 | infrastructure/gcp/cloud-sql.tf; instance colony-39989:…:colony; pgvector (1536) + pgcrypto extensions |
| TECH-003 | Inngest Durable Functions | Agent runtime for all specialist agents and orchestrators; event fan-out for discovery campaigns |
| TECH-004 | Clerk Auth + RBAC | Three roles; Svix webhook sync; org isolation; hardened in Phase 2 (docs/phase2/action_plans/27_org_switcher_hardening.md) |
| TECH-005 | GCP Secret Manager | Platform-level secrets: Clerk, Inngest, bootstrap LLM keys, Langfuse, Sentry; injected at gcloud run deploy time |
| TECH-006 | Colony Vault (api_keys table) | Per-org, KMS-encrypted rows; stores Pipedrive, Unipile, and other org-specific credentials |
| TECH-007 | pgvector (1536-dim) | Knowledge Core retrieval; cosine similarity; upsert on every approved message, recording signal, and content piece |
| TECH-008 | GCS (gs://colony-assets) | CMEK-encrypted asset storage; signed URLs for Deployment Kit asset delivery; defined in infrastructure/gcp/storage.tf |
| TECH-009 | Langfuse | LLM observability; traces every agent tool call; cost and latency dashboards |
| TECH-010 | Sentry | Error tracking for Next.js app and Inngest functions |
| TECH-011 | Terraform (hashicorp/google 7.29.0, hashicorp/google-beta 7.29.0) | Infrastructure-as-code; all GCP resources declared in infrastructure/gcp/ |
| TECH-012 | Playwright (GH Actions) | E2e test runner; .github/workflows/playwright-runner.yml; Phase 2 specs in docs/phase2/testing/*.spec.ts |
| TECH-013 | Codacy Static Analysis | .codacy/ config; ESLint, Semgrep, Trivy, Lizard, Revive; runs on every PR |
API Surface
| ID | Route / Event | Method | Description |
|---|---|---|---|
| API-001 | /overview | GET / SSE | GTM Orchestrator chat interface; streams tool calls and artifacts via SSE |
| API-002 | Clerk Svix webhook endpoint | POST | Receives organization.created, user.created, membership.updated events; syncs to Postgres |
| API-003 | Inngest function: gtm-orchestrator | Event | Multi-turn orchestrator; receives chat messages, dispatches specialist agents |
| API-004 | Inngest function: campaign-orchestrator | Event | Fan-out for prospect discovery; dispatches prospect, qualification, and message-gen agents |
| API-005 | Inngest function: prospect-agent | Event | Queries LeadBooster scraper, Google Places, SerpAPI, Unipile, public data adapters |
| API-006 | Inngest function: qualification-agent | Event | Enriches candidates; applies ICP scoring and anti-ICP hard pre-filter |
| API-007 | Inngest function: message-gen-agent | Event | Selects outreach angle; retrieves Knowledge Core exemplars; generates personalised messages |
| API-008 | Inngest function: recording-agent | Event | Watches Google Drive; extracts signals from Gemini Meet Notes; routes to CRM + Knowledge Core |
| API-009 | Inngest function: post-call-agent | Event | Generates humanised follow-up; creates next-step task in Pipedrive |
| API-010 | Inngest function: content-agent | Event | Pillar-aware content generation; attribution metadata write |
| API-011 | Inngest function: onboarding-agent | Event | Triggered by Closed-Won; generates 8-asset Deployment Kit; writes to GCS + Postgres |
| API-012 | Inngest function: analytics-agent | Event | Daily brief generation; pipeline analytics; delivers via Resend |
| API-013 | Approval queue API | POST/GET | Human review gate for messages, candidates, content drafts; integrates with circuit breaker check |
| API-014 | Knowledge Core editor API | POST/GET/PATCH | CRUD for Knowledge Core entries; triggers re-embedding on update |
| API-015 | Pipedrive bi-sync | Webhook/Polling | Two-way sync of deal stages, contacts, and custom fields; runbook at docs/phase1/runbooks/pipedrive-fields.md |
Database Model (Inferred)
| ID | Table | Key Columns | Notes |
|---|---|---|---|
| DBT-001 | organisations | id, clerk_org_id, name, created_at | Synced from Clerk via Svix |
| DBT-002 | users | id, clerk_user_id, org_id, role, email | Role: owner, member, viewer |
| DBT-003 | api_keys | id, org_id, provider, encrypted_key, kms_key_version | Colony Vault; KMS-encrypted per-org credentials |
| DBT-004 | prospects | id, org_id, name, company, title, icp_score, source, status, created_at | Candidate pipeline; scored by qualification agent |
| DBT-005 | sequences | id, org_id, prospect_id, tier (T1–T5), angle, status, created_at | Outbound sequence tracker |
| DBT-006 | messages | id, org_id, sequence_id, body, channel, status, sent_at, approved_by | Per-message approval and send record |
| DBT-007 | deals | id, org_id, pipedrive_id, stage (9 stages), icp_score, contact_id, synced_at | Bi-synced with Pipedrive |
| DBT-008 | recordings | id, org_id, deal_id, drive_file_id, signals_json, processed_at | Gemini Meet Notes ingestion record |
| DBT-009 | knowledge_core | id, org_id, domain, content, embedding vector(1536), tags, quality_tier, created_at | pgvector index; 10 domains |
| DBT-010 | content_pieces | id, org_id, pillar, body, channel, published_at, deal_ids[], pipeline_influence | 6-pillar attribution table |
| DBT-011 | deployment_kits | id, org_id, deal_id, assets_json, status, created_at | 8-asset onboarding kit; assets in GCS |
| DBT-012 | daily_briefs | id, org_id, date, content_json, delivered_at, resend_message_id | Brief delivery log |
| DBT-013 | approval_queue | id, org_id, type (message, candidate, content), payload_json, status, reviewed_by, reviewed_at | Unified approval surface |
| DBT-014 | circuit_breakers | id, org_id, provider, daily_limit, sent_today, last_reset_at | Per-org send limits |
| DBT-015 | contact_lists | id, org_id, name, source (csv, discovery, manual), prospect_ids[] | Phase 2; docs/phase2/action_plans/24_contact_list_builder.md |
v0.7 Build Execution
EPIC Backlog
EPIC-001: Infrastructure & Data Foundation (Phase 1, Wave 0)
Reference: docs/phase1/action_plans/01_infrastructure_and_database.md
- Provision Cloud SQL Postgres 16 via
infrastructure/gcp/cloud-sql.tf - Run
infrastructure/postgres/init/01-multiple-dbs.shand02-extensions.sqlto enable pgvector and pgcrypto - Bootstrap GCS bucket
gs://colony-assetswith CMEK (infrastructure/gcp/storage.tf) - Configure GCP Secret Manager secrets (
infrastructure/gcp/secrets.tf) - Deploy Terraform workspace (
infrastructure/gcp/main.tf); lock file at.terraform.lock.hcl - Validate Cloud Run service account IAM bindings (
infrastructure/gcp/iam-runner.tf)
EPIC-002: Auth, RBAC & Multi-Tenancy (Phase 1)
Reference: docs/phase1/action_plans/02_clerk_auth_and_rbac.md
- Integrate Clerk with Next.js App Router
- Configure Svix webhook for
organization.*anduser.*events → Postgres sync (DBT-001, DBT-002)