Maksutov Design MAKSUTOV DESIGN
v1.0.0 LatestNode.jsPGliteSupabase SQLA0–A3

Growth System

A local operating system for finding paid design work. Twelve roles research the market, write drafts and store evidence in a CRM. Nothing leaves the system: every external action needs the owner's exact approval, and release v1.0.0 has no executor at all

01 / product scope

Research is free, acting outward needs permission

12roles: orchestrator, lead, studio and job search, outreach, SEO, content, links and analytics.
7SQL migrations: workspace isolation, evidence, deduplication and approval guards.
13CRM tables, each with row-level security (RLS) enabled.
4approval levels A0–A3: from reading to legal and financial decisions.
15database triggers: timestamps, draft hash, integrity checks.
13SQL functions, including `approve_action` and `reject_action`.
3dashboard views: pipeline, approval queue, weekly funnel.
63files in the repository: prompts, policies, migrations, scripts and configs, no owner data.

02 / pipeline

From a find to a draft that waits for a human

Research first, then verification, then evidence and a score. Only then does a draft appear. If a mandatory condition is unknown, the record stays under review.

  1. Research, A0Public sources: companies, studios, jobs. Read-only.
  2. VerificationIdentity and mandatory conditions. Unknown conditions stay for manual review.
  3. Evidence and scoreEvery find keeps its sources (evidence) and a score. An outreach draft needs a score of 65 or more.
  4. CRMDeduplication and 13 opportunity stages, from `discovered` to `archived`.
  5. Draft, A1An email, application, SEO patch or article. Built only from verified CRM data.
  6. Approval packet, A2 or A3Recipient, exact text, reason, sources and expiry.
  7. Owner decisionApproval covers only the text and target shown. Editing the draft voids it.
  8. StopThere is no executor: an approved record sends and publishes nothing.

03 / roles

Twelve roles, one job each

The MVP registry runs seven roles: orchestrator, leads, studios, jobs, outreach, SEO and analytics. The other five add content and links. All start at level A1, and any external step needs A2.

orchestrator

Turns CRM state into a short work queue and hands research to specialists.

A1
lead_hunter

Finds companies that need design now or soon. Values quality and timing over list size.

A1
studio_hunter

Finds studios where a freelance or contract design partner is useful.

A1
job_hunter

Finds current roles where the portfolio can credibly compete.

A1
outreach_writer

Writes personal drafts from verified CRM evidence only. Sends nothing.

A1 → A2
seo_auditor

Builds a ranked, evidence-backed SEO backlog. Never touches production.

A1
content_researcher

Finds topics where search demand meets real expertise.

A1
content_writer

Turns approved briefs into publication-ready drafts for the site.

A1 → A2
case_builder

Improves and creates case studies from real project evidence.

A1 → A2
link_researcher

Finds legitimate mentions, links and editorial opportunities.

A1 → A2
profile_distribution

Maintains public profiles and directories that bring trust and traffic.

A1 → A2
analytics

Measures business outcomes, not vanity metrics.

A1

04 / approvals

Four approval levels: from reading to contracts

The policy lists 35 actions across the levels. A2 is approved in batches, A3 one action at a time.

A0

Read only

8 actions
  • Market and competitor research
  • Finding public jobs and studios
  • Scoring leads from public data
A1

Internal write

8 actions
  • Email and article drafts
  • CRM records from public data
  • Proposed site patches in a branch
A2

Batch approval

9 actions
  • Sending an email or message
  • Publishing an article or page
  • Job application, contact form
A3

One at a time

10 actions
  • Purchases and paid subscriptions
  • Contracts, NDAs and price commitments
  • DNS, billing, access and data deletion

Always prohibited without a new instruction: 9 items

Fake reviewsImpersonationBuying linksComment spamCAPTCHA bypassScraping private dataEvading anti-spam limitsSelling personal dataDeceptive opt-ins

What an approval request contains: 9 fields

approval_idlevelaction_typetargetreasonexact_payloadsource_evidencerisk_notesexpires_at

Approval covers only the text and target shown. Any material change needs a new approval

05 / crm & sql

A 13-table CRM: protection lives in the database

The schema targets Supabase and runs locally on PGlite. Every table belongs to a workspace, and four roles decide access: owner, admin, operator, viewer.

Workspace

workspacesworkspace_members

Who

companiespeople

What we look for

opportunitiesevidence

Actions

draftsapprovalstouchpointssuppressions

Operations

tasksagent_runsevents

001

Schema foundation

13 tables, 13 enum types and 11 indexes.

  • Companies, people and opportunities are linked, and evidence is stored separately.
  • 13 opportunity stages, from `discovered` to `archived`.
  • 7 opportunity types: direct client, studio, job, SEO, content, backlink, other.
001_core.sql ↗
002

Functions and triggers

7 SQL functions and triggers that stop an approval from surviving a text edit.

  • `compute_draft_payload_hash` hashes the draft text.
  • `invalidate_approval_on_draft_change` voids the approval if the text changes.
  • `approve_action`, `reject_action` and `is_suppressed`: the decision and the stop list.
002_functions_triggers.sql ↗
003

Row-level security

12 policies (one more arrives in 005), RLS enabled on all 13 tables.

  • Access follows workspace membership.
  • The owner, admin, operator and viewer roles differ in rights.
003_rls.sql ↗
004

Views

Three dashboard views: `v_pipeline`, `v_approval_queue`, `v_weekly_funnel`.

  • Created with `security_invoker = true`, so row-level security still applies inside them.
004_views.sql ↗
005

Approval visibility

Members see the approval queue, but only owner and admin decide, through an RPC.

  • One policy: `approvals_member_select`.
005_approval_visibility.sql ↗
006

Integrity guards

5 functions and 6 triggers: links are checked even on server-side writes, and an approval cannot be swapped.

  • Moving a record to another workspace is forbidden, and a reference into another workspace is rejected (code 23514).
  • An ordinary user cannot set a draft to `approved` or `sent`.
  • The approval payload is immutable: a change needs a new request. Default expiry is 7 days, and the stop list is checked on creation.
  • `approve_action` and `reject_action` are closed to anonymous access.
006_integrity_guards.sql ↗
007

Approval maintenance

The `refresh_approval_states` function can only retire approvals.

  • Moves them to expired and invalidated, but never creates or grants an approval.
  • Available to owner, admin and operator.
007_approval_maintenance.sql ↗

06 / run & verify

Run and verify: all local

Requires Node.js and npm. Installation creates no schedules, the daily run is disabled and external actions are switched off in the config.

npm ci --ignore-scripts
npm run setup              # empty local database
npm run runtime:init
npm run dry-run            # SQL migrations, rolled back
npm run pipeline:demo      # synthetic pipeline
npm run test:approval-preflight
npm run crm:backup         # export + restore check

npm run crm:report
npm run analytics:daily
npm run approval:maintain  # rollback by default
npm run approval:preflight
31/31SQL dry-run checks: migrations apply and roll back.
22/22pipeline checks: candidate and evidence intake.
15/15approval preflight checks.
14tables restored when the backup is verified in memory.

Tests run on a separate synthetic database. They do not prove lead freshness, legal eligibility, content quality, scheduling or production readiness

Reference schedule: 8 jobs, not installed by default

JobTimeRoleLimits
Daily work queueMon–Fri 08:15orchestratorfrom CRM state
Lead discoveryMon, Tue, Thu, Fri 08:30lead_hunterup to 30 candidates, target 8
Studio discoveryTue, Thu 09:30studio_hunterup to 20, target 6
Job discoveryMon–Fri 10:00job_hunterup to 30, target 10
Outreach draftsMon–Fri 11:30outreach_writerup to 10 drafts, then A2
SEO auditMon 09:00seo_auditorevidence-backed backlog
Daily analyticsMon–Fri 17:30analyticsdaily digest
Weekly analyticsFri 16:00analyticsfunnel, wins, losses

Timezone Europe/Berlin. This is reference design: the cron jobs are not installed, and the `GROWTH_AUTOMATION_ENABLED` flag works as a kill switch

07 / limits

What the system does not do

  • No external executor: an approved record sends and publishes nothing.
  • No live model integration: this is infrastructure for an operator, not an autopilot.
  • Tests do not check lead freshness, legal eligibility or text quality.
  • Installation creates no schedule, and the daily run is off by default.
  • The repository holds no owner CRM, keys, personal drafts, backups or list of researched companies.

08 / file map

Key files

09 / next projects