GovCon ONE is AI capture intelligence for small federal contractors and GovCon advisors. It turns a SAM.gov opportunity into an evidence-backed bid/no-bid recommendation and a compliance-first proposal starter in minutes.
The product supports one connected pursuit workflow:
- Find or import a federal opportunity.
- Retrieve related context with Cloudflare Vectorize and Workers AI embeddings.
- Use free Gemma 4 through OpenRouter to make a cited
BID,REVIEW, orNO_BIDrecommendation. - Use Gemma 4 to create a compliance-first proposal starter.
- Store the decision in D1 and the generated artifact in R2.
Browser
│
▼
Cloudflare Worker ─── Astro marketing + app assets
│ Hono API (/api/*)
├── D1 opportunities, decisions, runs, drafts, leads
├── R2 downloadable proposal artifacts
├── Workers AI @cf/baai/bge-base-en-v1.5 embeddings
├── Vectorize semantic opportunity retrieval (768d cosine)
├── OpenRouter Gemma 4 26B A4B free analysis + drafting
└── SAM.gov optional live opportunity sync
There are no containers, origin servers, Supabase projects, Fly apps, or environment-tier configurations. Local development uses Wrangler's local D1/R2/Workers runtime; shipping uses one production Worker configuration.
Requirements: Node.js 20+ and pnpm 9.
pnpm install
cp .dev.vars.example .dev.vars
pnpm db:migrate:local
pnpm devOpen the Wrangler URL (normally http://localhost:8787). The migration includes three representative opportunities. The product remains testable without model keys: it clearly labels and uses deterministic safety fallbacks instead of fabricating AI output.
For the full AI path, set these values in .dev.vars:
OPENROUTER_API_KEY=...
SAM_API_KEY=... # optional; required only for live SAM.gov sync
ADMIN_TOKEN=... # protects sync and indexing routesThe active model defaults live in wrangler.jsonc:
- Strategic analysis and proposal drafting:
google/gemma-4-26b-a4b-it:freethrough OpenRouter. - Embeddings:
@cf/baai/bge-base-en-v1.5through the native Workers AI binding.
pnpm build # Build both Astro surfaces
pnpm check # Astro and Worker type checks
pnpm test # Domain and fallback tests
pnpm db:migrate:local # Apply D1 migrations locally
pnpm db:migrate:remote # Apply D1 migrations in Cloudflare
pnpm ship # Build and deploy the production WorkerAfter deployment, configure encrypted secrets without putting them in Git:
wrangler secret put OPENROUTER_API_KEY
wrangler secret put SAM_API_KEY
wrangler secret put ADMIN_TOKENThen index the opportunity corpus using an x-admin-token header against POST /api/opportunities/index.
| Method | Route | Purpose |
|---|---|---|
GET |
/api/health |
Binding and model configuration health |
GET |
/api/stats |
Workspace counts |
GET |
/api/decisions |
Recent bid-decision history |
GET |
/api/drafts |
Recent proposal-starter history |
GET |
/api/opportunities |
Full-text/NAICS opportunity search |
GET |
/api/opportunities/:id |
Opportunity and latest decision |
POST |
/api/opportunities/:id/analyze |
Gemma 4 bid analysis |
POST |
/api/opportunities/:id/draft |
Gemma 4 proposal starter |
GET |
/api/drafts/:id/download |
Download the R2-backed Markdown artifact |
POST |
/api/opportunities/sync |
Protected SAM.gov import |
POST |
/api/opportunities/index |
Protected Workers AI/Vectorize indexing |
pnpm build
pnpm check
pnpm test
pnpm exec wrangler deploy --dry-run- SAM.gov is the source of live public opportunity data; an API key is required by GSA.
- AI prompts explicitly prohibit inventing past performance, personnel, certifications, pricing, or solicitation facts.
- The free OpenRouter/Gemma demo route is not guaranteed to provide zero-data-retention processing. Use only public or synthetic demo data until a ZDR-capable provider is configured.
- Provider errors degrade to transparent, deterministic output so the product remains runnable.
- Generated proposal starters are working documents, not legal advice or a substitute for reading the full solicitation.