@sellable/mcp 0.1.335 → 0.1.337

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -474,6 +474,35 @@ export declare const allTools: ({
474
474
  required: string[];
475
475
  additionalProperties: boolean;
476
476
  };
477
+ } | {
478
+ name: string;
479
+ description: string;
480
+ inputSchema: {
481
+ type: string;
482
+ properties: {
483
+ intent: {
484
+ type: string;
485
+ enum: string[];
486
+ description: string;
487
+ };
488
+ campaignId: {
489
+ type: string;
490
+ description: string;
491
+ };
492
+ tableId: {
493
+ type: string;
494
+ description: string;
495
+ };
496
+ limit: {
497
+ type: string;
498
+ minimum: number;
499
+ maximum: number;
500
+ description: string;
501
+ };
502
+ };
503
+ required: string[];
504
+ additionalProperties: boolean;
505
+ };
477
506
  } | {
478
507
  name: string;
479
508
  description: string;
@@ -631,6 +660,82 @@ export declare const allTools: ({
631
660
  additionalProperties: boolean;
632
661
  required?: undefined;
633
662
  };
663
+ } | {
664
+ name: string;
665
+ description: string;
666
+ inputSchema: {
667
+ type: string;
668
+ properties: {
669
+ mode: {
670
+ type: string;
671
+ enum: string[];
672
+ default: string;
673
+ description: string;
674
+ };
675
+ intent: {
676
+ type: string;
677
+ enum: string[];
678
+ description: string;
679
+ };
680
+ campaignIds: {
681
+ type: string;
682
+ items: {
683
+ type: string;
684
+ };
685
+ maxItems: number;
686
+ description: string;
687
+ };
688
+ tableIds: {
689
+ type: string;
690
+ items: {
691
+ type: string;
692
+ };
693
+ maxItems: number;
694
+ description: string;
695
+ };
696
+ sendWindowDays: {
697
+ type: string;
698
+ minimum: number;
699
+ maximum: number;
700
+ description: string;
701
+ };
702
+ targetDates: {
703
+ type: string;
704
+ items: {
705
+ type: string;
706
+ };
707
+ maxItems: number;
708
+ description: string;
709
+ };
710
+ targetScheduledSends: {
711
+ type: string;
712
+ minimum: number;
713
+ maximum: number;
714
+ description: string;
715
+ };
716
+ approvalMode: {
717
+ type: string;
718
+ enum: string[];
719
+ description: string;
720
+ };
721
+ yolo: {
722
+ type: string;
723
+ description: string;
724
+ };
725
+ planRevision: {
726
+ type: string;
727
+ description: string;
728
+ };
729
+ actionIds: {
730
+ type: string;
731
+ items: {
732
+ type: string;
733
+ };
734
+ description: string;
735
+ };
736
+ };
737
+ additionalProperties: boolean;
738
+ };
634
739
  } | {
635
740
  name: string;
636
741
  description: string;
@@ -690,6 +795,8 @@ export declare const allTools: ({
690
795
  templateRevision?: undefined;
691
796
  timeoutMs?: undefined;
692
797
  intervalMs?: undefined;
798
+ rowIds?: undefined;
799
+ enrichCellIds?: undefined;
693
800
  templateMarkdown?: undefined;
694
801
  approvedMessageTemplate?: undefined;
695
802
  };
@@ -745,6 +852,8 @@ export declare const allTools: ({
745
852
  templateRevision?: undefined;
746
853
  timeoutMs?: undefined;
747
854
  intervalMs?: undefined;
855
+ rowIds?: undefined;
856
+ enrichCellIds?: undefined;
748
857
  templateMarkdown?: undefined;
749
858
  approvedMessageTemplate?: undefined;
750
859
  };
@@ -804,6 +913,8 @@ export declare const allTools: ({
804
913
  templateRevision?: undefined;
805
914
  timeoutMs?: undefined;
806
915
  intervalMs?: undefined;
916
+ rowIds?: undefined;
917
+ enrichCellIds?: undefined;
807
918
  templateMarkdown?: undefined;
808
919
  approvedMessageTemplate?: undefined;
809
920
  };
@@ -843,12 +954,52 @@ export declare const allTools: ({
843
954
  limit?: undefined;
844
955
  forceRerun?: undefined;
845
956
  reason?: undefined;
957
+ rowIds?: undefined;
958
+ enrichCellIds?: undefined;
846
959
  templateMarkdown?: undefined;
847
960
  approvedMessageTemplate?: undefined;
848
961
  };
849
962
  additionalProperties: boolean;
850
963
  required?: undefined;
851
964
  };
965
+ } | {
966
+ name: string;
967
+ description: string;
968
+ inputSchema: {
969
+ type: string;
970
+ properties: {
971
+ tableId: {
972
+ type: string;
973
+ };
974
+ rowIds: {
975
+ type: string;
976
+ items: {
977
+ type: string;
978
+ };
979
+ };
980
+ enrichCellIds: {
981
+ type: string;
982
+ items: {
983
+ type: string;
984
+ };
985
+ };
986
+ campaignId?: undefined;
987
+ columnRole?: undefined;
988
+ rowSelector?: undefined;
989
+ limit?: undefined;
990
+ forceRerun?: undefined;
991
+ reason?: undefined;
992
+ minPassedCount?: undefined;
993
+ minGeneratedMessages?: undefined;
994
+ templateRevision?: undefined;
995
+ timeoutMs?: undefined;
996
+ intervalMs?: undefined;
997
+ templateMarkdown?: undefined;
998
+ approvedMessageTemplate?: undefined;
999
+ };
1000
+ required: string[];
1001
+ additionalProperties: boolean;
1002
+ };
852
1003
  } | {
853
1004
  name: string;
854
1005
  description: string;
@@ -899,6 +1050,8 @@ export declare const allTools: ({
899
1050
  templateRevision?: undefined;
900
1051
  timeoutMs?: undefined;
901
1052
  intervalMs?: undefined;
1053
+ rowIds?: undefined;
1054
+ enrichCellIds?: undefined;
902
1055
  };
903
1056
  required: string[];
904
1057
  additionalProperties: boolean;
@@ -2,9 +2,11 @@ import { authToolDefinitions } from "./auth.js";
2
2
  import { blueprintCommitToolDefinitions } from "./blueprint-commit.js";
3
3
  import { bootstrapToolDefinitions } from "./bootstrap.js";
4
4
  import { campaignAbTestToolDefinitions } from "./campaign-ab-test.js";
5
+ import { campaignFillRoutingToolDefinitions } from "./campaign-fill-routing.js";
5
6
  import { campaignHorizonFillToolDefinitions } from "./campaign-horizon-fill.js";
6
7
  import { campaignMessagePreparationToolDefinitions } from "./campaign-message-preparation.js";
7
8
  import { campaignProcessingToolDefinitions } from "./campaign-processing.js";
9
+ import { refillCampaignSendsToolDefinitions } from "./refill-campaign-sends.js";
8
10
  import { campaignToolDefinitions } from "./campaigns.js";
9
11
  import { cellToolDefinitions } from "./cells.js";
10
12
  import { startCliLoginToolDef, waitForCliLoginToolDef } from "./cli-login.js";
@@ -43,6 +45,8 @@ import { workspaceToolDefinitions } from "./workspaces.js";
43
45
  export const allTools = [
44
46
  ...campaignToolDefinitions,
45
47
  ...campaignAbTestToolDefinitions,
48
+ ...campaignFillRoutingToolDefinitions,
49
+ ...refillCampaignSendsToolDefinitions,
46
50
  ...campaignHorizonFillToolDefinitions,
47
51
  ...campaignMessagePreparationToolDefinitions,
48
52
  ...campaignProcessingToolDefinitions,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sellable/mcp",
3
- "version": "0.1.335",
3
+ "version": "0.1.337",
4
4
  "type": "module",
5
5
  "description": "Sellable MCP server for Claude Code and Codex campaign workflows",
6
6
  "main": "dist/index.js",
@@ -44,8 +44,11 @@ allowed-tools:
44
44
  - mcp__sellable__save_rubrics
45
45
  - mcp__sellable__get_campaign_table_schema
46
46
  - mcp__sellable__select_campaign_cells
47
+ - mcp__sellable__record_campaign_review_batch
47
48
  - mcp__sellable__queue_campaign_cells
48
49
  - mcp__sellable__wait_for_campaign_processing
50
+ - mcp__sellable__refill_campaign_sends
51
+ - mcp__sellable__resolve_campaign_fill_route
49
52
  - mcp__sellable__fill_campaign_horizon
50
53
  - mcp__sellable__start_campaign_message_preparation
51
54
  - mcp__sellable__get_campaign_message_preparation_status
@@ -105,37 +108,54 @@ most one direct `enrich_with_prospeo` sample when row evidence is too thin.
105
108
  After filter approval, the browser should move to Filter Leads with
106
109
  `currentStep: "apply-icp-rubric"` and show template waiting/approval copy until
107
110
  the template is approved.
111
+ If the bounded filter run later returns `0/N` passes, do not immediately find
112
+ new leads. Load `references/sample-validation-loop.md`, run the zero-pass
113
+ rule-relaxability audit, then choose exactly one recovery: revise saved
114
+ rubrics, record a fresh same-source review batch, or change lead source. Change
115
+ source only when safe relaxation and same-source sampling would still fail or
116
+ would pass bad-fit rows.
108
117
  The default path stays the existing first campaign-table execution slice:
109
118
  review the normal `reviewBatchLimit:15`, approve reviewed draft rows, then move
110
- to Settings/sequence/final greenlight. Only call
111
- `fill_campaign_horizon` for explicit source-cleanup horizon-fill requests, such
112
- as "fill sends from Signal Discovery but not John Cutler posts." Run
113
- `fill_campaign_horizon({ action:"audit", ... })` first, then apply with the
114
- returned `stateRevision`. It imports/prepares at most 300 eligible non-excluded
115
- source rows in the first pass, caps prep batches at 100, skips existing rows
116
- from excluded post/author sources, and does not launch the campaign. If the
117
- user only asks for generic extra sends with no source cleanup, use
118
- `start_campaign_message_preparation` when the user explicitly asks for more
119
- prepared messages, a send count, or language like "fill up/load sends for these
120
- senders." Treat those requests as capacity-fill preparation: calculate the
121
- bounded target from sender capacity when needed, then let the preparation job
122
- queue pending `Enrich Prospect` cells, wait for ICP/rubric and Generate Message
123
- cells to cascade, and mark ready or approve only the target cohort. Do not
124
- count `checkedRows` as enriched rows; it is only the table cursor. Use
119
+ to Settings/sequence/final greenlight. For any plain post-mint fill request
120
+ such as "fill campaigns", "fill up", "refill sends", "max out sends", or
121
+ "load sends", first call `refill_campaign_sends({ mode:"plan", intent:"plain" })`.
122
+ If the user did not include `--yolo`, report the plan and stop. If the user did
123
+ include `--yolo`, call plan first, inspect blockers, then call
124
+ `refill_campaign_sends({ mode:"apply", yolo:true, planRevision, actionIds })`
125
+ using only the selected immutable action IDs from the fresh plan. Plain fill is
126
+ not an alias for `fill_campaign_horizon` or campaign creation. Keep
127
+ `resolve_campaign_fill_route`, `fill_campaign_horizon`, and
128
+ `start_campaign_message_preparation` as fallback/lower-level diagnostics only
129
+ when `refill_campaign_sends` is unavailable or when the refill command itself
130
+ returns an evergreen subplan. `fill_campaign_horizon` is evergreen-only and
131
+ must not be used for regular campaign refill. When more leads are needed, the
132
+ plan must recommend same-campaign source-ladder replenishment; do not create
133
+ warm-post-engager side campaigns, on-demand campaigns, or unrelated campaigns.
134
+ If fallback `resolve_campaign_fill_route` returns `route:"ask_create"`, ask
135
+ whether to create a normal campaign or evergreen campaigns; campaign creation is
136
+ never the default response to plain fill.
137
+ Treat active fills as capacity-fill preparation: calculate the bounded target
138
+ from sender capacity when needed, then let the preparation job queue pending
139
+ `Enrich Prospect` cells, wait for ICP/rubric and Generate Message cells to
140
+ cascade, and mark ready or approve only the target cohort. Do not count
141
+ `checkedRows` as enriched rows; it is only the table cursor. Use
125
142
  `progress.enrichedRows`, `progress.needsEnrichRows`, `activeCellCount`,
126
- `preparedMessages`, `approvedRows`, target, estimated row budget remaining, and
127
- `stopReason` to explain progress. If the user says "prepare/generate X
128
- messages", set `targetPreparedMessages:X`, omit `maxRowsToCheck`, and keep
143
+ `preparedMessages`, `approvedRows`, active preparation jobs, sender-health
144
+ blockers, target, estimated row budget remaining, and `stopReason` to explain
145
+ progress. If the user says "prepare/generate X messages", set
146
+ `targetPreparedMessages:X`, omit `maxRowsToCheck`, and keep
129
147
  `approvalMode:"mark_ready"`. The backend calibrates on at least 100 actually
130
148
  enriched rows, estimates the row budget from observed rubric/pass yield, caps
131
149
  `maxRowsToCheck` at 300, then continues in batches capped at 100 newly checked
132
150
  rows. It will not pull another row batch while the current checked batch still
133
151
  has queueable or active cells. If the user says "approve X messages", use
134
152
  `approvalMode:"approve"` but still do not launch. If the user says "schedule X
135
- sends" or asks to fill sender sends, use `approvalMode:"approve"` to approve
136
- exactly the bounded X-message cohort during preparation, then continue through
137
- sender, sequence, and final launch greenlight; the launch path must verify that
138
- bounded cohort and must not broad approve-all.
153
+ sends" or asks to fill sender sends, use `approvalMode:"approve"` only when
154
+ the user explicitly asked for approval, approve exactly the bounded X-message
155
+ cohort during preparation, then re-read scheduled counts; if scheduler-owned
156
+ cells are not present, report prepared/approved/ready awaiting scheduler
157
+ instead of success. Final launch remains a separate explicit user greenlight
158
+ and must verify that bounded cohort and must not broad approve-all.
139
159
  When approving reviewed draft rows in the campaign table, resolve the actual
140
160
  visible `Approved` cells with `select_campaign_cells({ columnRole: "approved",
141
161
  rowSelector: { type: "rowIds", rowIds } })` and `update_cell` those returned
@@ -1085,7 +1105,11 @@ updates.
1085
1105
  rubrics and Message Drafting runs.
1086
1106
  After rubrics save, keep Filter Rules visible for approval; after approval,
1087
1107
  move to Filter Leads with `currentStep: "apply-icp-rubric"` and wait there
1088
- while Message Drafting finishes or the template is approved.
1108
+ while Message Drafting finishes or the template is approved. After template
1109
+ approval and bounded scoring, a `0/N` pass result must run the
1110
+ sample-validation zero-pass rule-relaxability audit before any lead-source
1111
+ revision; the three allowed recoveries are rubric revision, fresh
1112
+ same-source sample, or source revision.
1089
1113
  If filters are skipped, launch Message Drafting before moving to
1090
1114
  Messages/message review; updating `currentStep` to `messages` is not proof
1091
1115
  that the background worker started. Queue the bounded campaign-table