@synap-core/workspace-templates 0.35.0 → 0.37.0
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.
- package/README.md +1 -0
- package/dist/{define-DHDi8C33.d.ts → define-YL-hIPcn.d.ts} +10 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.js +319 -10
- package/dist/index.js.map +1 -1
- package/dist/wire.d.ts +1 -1
- package/package.json +1 -1
- package/src/brand-library.yaml +17 -1
- package/src/crm-health.template.test.ts +82 -0
- package/src/crm-messages-cadence.template.test.ts +39 -0
- package/src/crm-rules-guidance.template.test.ts +156 -0
- package/src/crm.yaml +324 -20
- package/src/lifecycle-declarations.test.ts +6 -1
- package/src/templates.ts +319 -10
- package/src/types.ts +5 -0
package/src/crm.yaml
CHANGED
|
@@ -700,6 +700,92 @@ profiles:
|
|
|
700
700
|
valueType: string
|
|
701
701
|
inputType: textarea
|
|
702
702
|
|
|
703
|
+
# ── Outreach angle: one row of "By kind of lead" (design b199a3a4, 8 Nov 2026) ─
|
|
704
|
+
# What to lead with, depending on the lead: IF the lead is X (a condition in
|
|
705
|
+
# words, optionally an audience it was found for and an offer it is about),
|
|
706
|
+
# lead with an angle, put an offer forward, show a proof, avoid something,
|
|
707
|
+
# in a tone, on a channel. The rows are ORDERED (`order`): the drafters take
|
|
708
|
+
# the first row whose condition fits the lead, else the last one, so the
|
|
709
|
+
# catch-all row ("Anything else") carries the highest order.
|
|
710
|
+
# A RULE, not an output: the CRM drafters ("Draft a first message", "Follow
|
|
711
|
+
# up on leads in outreach", "Personalized Outreach") declare
|
|
712
|
+
# `guidance: kind:outreach-angle`, and every run renders the CURRENT rows into
|
|
713
|
+
# the AI's instructions (backend#924: only rows whose status category is
|
|
714
|
+
# done render). So `current` is a person's call (trust (a)): an agent writes
|
|
715
|
+
# a draft, a person makes it current. A new version of a row is a new row in
|
|
716
|
+
# draft that `revises` the current one (entityLinks below); making it current
|
|
717
|
+
# and retiring the old one is the person's act, and the retired chain is the
|
|
718
|
+
# row's history. The fields render in this order; `order` and the status do
|
|
719
|
+
# not. The CRM's Brand & communication page reads and writes these rows.
|
|
720
|
+
- slug: outreach-angle
|
|
721
|
+
displayName: Outreach angle
|
|
722
|
+
icon: compass
|
|
723
|
+
color: violet
|
|
724
|
+
description: "One row of \"By kind of lead\": if the lead is X, lead with this angle, offer, proof, tone and channel. The first row that fits the lead wins; a person makes a row current."
|
|
725
|
+
# The ONE lifecycle (work model L1): every option's category.
|
|
726
|
+
lifecycle:
|
|
727
|
+
property: angle-status
|
|
728
|
+
options:
|
|
729
|
+
- { key: draft, category: open }
|
|
730
|
+
- { key: current, category: done, humanOnly: true }
|
|
731
|
+
- { key: retired, category: lost, humanOnly: true }
|
|
732
|
+
properties:
|
|
733
|
+
- slug: angle-status
|
|
734
|
+
label: Status
|
|
735
|
+
valueType: string
|
|
736
|
+
inputType: select
|
|
737
|
+
enumValues: [draft, current, retired]
|
|
738
|
+
constraints: { defaultValue: draft }
|
|
739
|
+
# The match: the condition in words, plus the audience it was found for
|
|
740
|
+
# and the offer it is about, when they apply.
|
|
741
|
+
- slug: angle-if
|
|
742
|
+
label: If the lead
|
|
743
|
+
valueType: string
|
|
744
|
+
inputType: textarea
|
|
745
|
+
placeholder: e.g. Posted a small automation project on Codeur or Malt
|
|
746
|
+
- slug: angle-audience
|
|
747
|
+
label: Audience
|
|
748
|
+
valueType: entity_id
|
|
749
|
+
targetProfileSlug: audience
|
|
750
|
+
inputType: entity_select
|
|
751
|
+
- slug: angle-about-offer
|
|
752
|
+
label: About the offer
|
|
753
|
+
valueType: entity_id
|
|
754
|
+
targetProfileSlug: offer
|
|
755
|
+
inputType: entity_select
|
|
756
|
+
- slug: angle-lead-with
|
|
757
|
+
label: Lead with
|
|
758
|
+
valueType: string
|
|
759
|
+
inputType: textarea
|
|
760
|
+
- slug: angle-offer
|
|
761
|
+
label: Offer
|
|
762
|
+
valueType: string
|
|
763
|
+
inputType: textarea
|
|
764
|
+
placeholder: e.g. Fixed small set-up, tool costs listed apart
|
|
765
|
+
- slug: angle-proof
|
|
766
|
+
label: Proof
|
|
767
|
+
valueType: string
|
|
768
|
+
inputType: textarea
|
|
769
|
+
- slug: angle-avoid
|
|
770
|
+
label: Avoid
|
|
771
|
+
valueType: string
|
|
772
|
+
inputType: textarea
|
|
773
|
+
- slug: angle-tone
|
|
774
|
+
label: Tone
|
|
775
|
+
valueType: string
|
|
776
|
+
inputType: text
|
|
777
|
+
- slug: angle-channel
|
|
778
|
+
label: Channel
|
|
779
|
+
valueType: string
|
|
780
|
+
inputType: text
|
|
781
|
+
placeholder: e.g. LinkedIn, else email
|
|
782
|
+
# The row's place: the first row that fits wins (the pod's renderer
|
|
783
|
+
# sorts by the property named exactly `order`).
|
|
784
|
+
- slug: order
|
|
785
|
+
label: Order
|
|
786
|
+
valueType: number
|
|
787
|
+
inputType: number
|
|
788
|
+
|
|
703
789
|
# `linked_to_deal` is the GENERIC counterparty edge and stays the SSOT for "who
|
|
704
790
|
# is on this deal" — the handoff flow's `find-party` node reads exactly it and
|
|
705
791
|
# requires exactly one match, so nothing below may replace it.
|
|
@@ -789,6 +875,12 @@ entityLinks:
|
|
|
789
875
|
targetProfileSlug: audience
|
|
790
876
|
type: targets
|
|
791
877
|
label: Targets
|
|
878
|
+
# A new version of a "By kind of lead" row is a draft that `revises` the
|
|
879
|
+
# current one (design b199a3a4): the retired chain is the row's history.
|
|
880
|
+
- sourceProfileSlug: outreach-angle
|
|
881
|
+
targetProfileSlug: outreach-angle
|
|
882
|
+
type: revises
|
|
883
|
+
label: Revises
|
|
792
884
|
|
|
793
885
|
# Views folded from Outreach & Comms (2026-10-23). The CRM's own surface is the
|
|
794
886
|
# website (layout.primarySurface); these are the workbench lenses on the same
|
|
@@ -834,6 +926,21 @@ views:
|
|
|
834
926
|
config:
|
|
835
927
|
groupByField: status
|
|
836
928
|
cardFields: [channel, touchType, sentDate]
|
|
929
|
+
# Health: the sales dashboard of the CRM space, a bento whose tiles are HTML
|
|
930
|
+
# cells an AI proposes and a person approves (design b199a3a4 Question 2,
|
|
931
|
+
# option A). It starts empty: each tile lands through "Propose a Health
|
|
932
|
+
# cell" (cell/define with placeOn = this view, backend#926), and the CRM
|
|
933
|
+
# app and the desktop draw the same view. A bento without a profile is not a
|
|
934
|
+
# profile dashboard. Note: a template update does not add a bento view to a
|
|
935
|
+
# space that already exists (the reconcile defers bento views); a fresh
|
|
936
|
+
# install gets it.
|
|
937
|
+
- name: Health
|
|
938
|
+
slug: health
|
|
939
|
+
type: bento
|
|
940
|
+
description: The health of your sales at a glance, one tile per question you asked, each one approved by you.
|
|
941
|
+
config:
|
|
942
|
+
layout: bento
|
|
943
|
+
blocks: []
|
|
837
944
|
|
|
838
945
|
onboarding:
|
|
839
946
|
goal: >
|
|
@@ -1425,11 +1532,11 @@ playbooks:
|
|
|
1425
1532
|
them; ignored, draft by email instead when they have an email address.
|
|
1426
1533
|
While the draft waits for them to connect, set the lead's nextAction to
|
|
1427
1534
|
"Wait for <name> to accept the LinkedIn request" and its nextActionAt 7
|
|
1428
|
-
days later. An email message needs none of this.
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1535
|
+
days later. An email message needs none of this.
|
|
1536
|
+
RULES: follow the rules this process follows, in order: Voice, then By
|
|
1537
|
+
kind of lead (the first row that fits the lead; a given campaign's angle
|
|
1538
|
+
comes first). A rule shown as not available is left out: say so. Draft
|
|
1539
|
+
one message only: a person reviews
|
|
1433
1540
|
it in the channel, edits it if needed and approves it. NEXT ACTION:
|
|
1434
1541
|
set the lead's nextAction to "Send the first message to <name> on
|
|
1435
1542
|
LinkedIn" ("Send the first message to <name> by email" on email),
|
|
@@ -1464,6 +1571,16 @@ playbooks:
|
|
|
1464
1571
|
- { name: channel, type: choice, label: Channel, options: [linkedin, email], defaultValue: linkedin }
|
|
1465
1572
|
executor: is-agent
|
|
1466
1573
|
status: active
|
|
1574
|
+
# The rules it writes by (design b199a3a4, backend#924): every run renders
|
|
1575
|
+
# the CURRENT, person-approved versions under "Rules this playbook
|
|
1576
|
+
# follows", in this order. The style lines this goal held (personal, cites
|
|
1577
|
+
# the signal, short, the person's language, French with vous, one useful
|
|
1578
|
+
# next step, never pressure) seed the Voice now, through "Propose my rules
|
|
1579
|
+
# from my sent messages"; DRAFT RULES and CADENCE stay here: they are
|
|
1580
|
+
# process. Foundation's positioning joins once its kind has a lifecycle.
|
|
1581
|
+
guidance:
|
|
1582
|
+
- { ref: "kind:brand-voice-guide", label: Voice, where: { voice-context: [general, outreach] } }
|
|
1583
|
+
- { ref: "kind:outreach-angle", label: By kind of lead }
|
|
1467
1584
|
grants: [entity.create]
|
|
1468
1585
|
stages:
|
|
1469
1586
|
- key: draft
|
|
@@ -1484,8 +1601,10 @@ playbooks:
|
|
|
1484
1601
|
- key: first-message-no-capture
|
|
1485
1602
|
statement: No tool's own send verb was called, no outreach touch, note or task holds the message, no record was made with synap_capture, and a decider created for a company lead carries only the person's own fields, never the company's website, domain or email.
|
|
1486
1603
|
check: { kind: judge }
|
|
1487
|
-
|
|
1488
|
-
|
|
1604
|
+
# The style it is judged by is the rules it follows (guidance), not
|
|
1605
|
+
# lines of this goal (design b199a3a4).
|
|
1606
|
+
- key: first-message-rules
|
|
1607
|
+
statement: The message follows the rules this process follows, as its instructions showed them (the approved Voice, then the first By kind of lead row that fits the lead, or the campaign's angle when one was given).
|
|
1489
1608
|
check: { kind: judge }
|
|
1490
1609
|
- key: first-message-not-rescored
|
|
1491
1610
|
statement: The lead's icpScore, buyingSignal and scoredAt are unchanged, and its stage was not moved.
|
|
@@ -1722,10 +1841,10 @@ playbooks:
|
|
|
1722
1841
|
only when the lead's next action date is today or past and no
|
|
1723
1842
|
proposed message to it is still waiting, draft the next message, to
|
|
1724
1843
|
the lead (for a company, the person who decides there) and in the
|
|
1725
|
-
angle of the lead's outreach campaign: follow its value proposition
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1844
|
+
angle of the lead's outreach campaign: follow its value proposition and
|
|
1845
|
+
call to action. With no campaign and no By kind of lead row that fits,
|
|
1846
|
+
ask the person which campaign. Draft at most two follow-ups per lead: a
|
|
1847
|
+
lead
|
|
1729
1848
|
already sent two follow-ups gets no draft, never a third follow-up;
|
|
1730
1849
|
when its last date passes in silence, propose moving it to nurturing
|
|
1731
1850
|
through the status door, with its expected status. DRAFT RULES: each
|
|
@@ -1757,8 +1876,12 @@ playbooks:
|
|
|
1757
1876
|
them; ignored, draft by email instead when they have an email address.
|
|
1758
1877
|
While the draft waits for them to connect, set the lead's nextAction to
|
|
1759
1878
|
"Wait for <name> to accept the LinkedIn request" and its nextActionAt 7
|
|
1760
|
-
days later. An email message needs none of this.
|
|
1761
|
-
|
|
1879
|
+
days later. An email message needs none of this.
|
|
1880
|
+
RULES: follow the rules this process follows, in order: Voice, then By
|
|
1881
|
+
kind of lead (the first row that fits the lead; a given campaign's angle
|
|
1882
|
+
comes first). A rule shown as not available is left out: say so. For
|
|
1883
|
+
each draft, set the
|
|
1884
|
+
lead's `nextAction` to send it (e.g. "Send the drafted message to
|
|
1762
1885
|
Ana on LinkedIn") and `nextActionAt` to today. The person reviews each
|
|
1763
1886
|
proposed message in its channel, edits it if needed and approves it;
|
|
1764
1887
|
the agent never sends. CADENCE: when a message is sent (a person
|
|
@@ -1787,6 +1910,16 @@ playbooks:
|
|
|
1787
1910
|
- { on: manual, mode: propose }
|
|
1788
1911
|
executor: is-agent
|
|
1789
1912
|
status: active
|
|
1913
|
+
# The rules it writes by (design b199a3a4, backend#924): every run renders
|
|
1914
|
+
# the CURRENT, person-approved versions under "Rules this playbook
|
|
1915
|
+
# follows", in this order. The style lines this goal held (personal, cites
|
|
1916
|
+
# the signal, short, the person's language, French with vous, one useful
|
|
1917
|
+
# next step, never pressure) seed the Voice now, through "Propose my rules
|
|
1918
|
+
# from my sent messages"; DRAFT RULES and CADENCE stay here: they are
|
|
1919
|
+
# process. Foundation's positioning joins once its kind has a lifecycle.
|
|
1920
|
+
guidance:
|
|
1921
|
+
- { ref: "kind:brand-voice-guide", label: Voice, where: { voice-context: [general, outreach] } }
|
|
1922
|
+
- { ref: "kind:outreach-angle", label: By kind of lead }
|
|
1790
1923
|
expectedOutputs:
|
|
1791
1924
|
# Proposed messages on the people's channels (see "Draft a first message").
|
|
1792
1925
|
- { kind: messaging, label: Proposed follow-ups, relationToSubject: none }
|
|
@@ -1800,7 +1933,7 @@ playbooks:
|
|
|
1800
1933
|
statement: Each draft reflects what was already sent to that lead and any reply, read from its channels.
|
|
1801
1934
|
check: { kind: judge }
|
|
1802
1935
|
- key: followup-angle
|
|
1803
|
-
statement: Each draft follows the angle of the lead's outreach campaign and its call to action.
|
|
1936
|
+
statement: Each draft follows the angle of the lead's outreach campaign and its call to action, or, with no campaign, the first By kind of lead row that fits the lead, and the approved Voice.
|
|
1804
1937
|
check: { kind: judge }
|
|
1805
1938
|
- key: followup-no-draft-after-reply
|
|
1806
1939
|
statement: No message is drafted for a lead who replied (its reply is summarised and a next step proposed, no deal opened), nor a third follow-up for a lead already sent two.
|
|
@@ -1839,13 +1972,13 @@ playbooks:
|
|
|
1839
1972
|
goalTemplate: >-
|
|
1840
1973
|
Run this outreach campaign ({campaign}) on {channel}; each stage moves
|
|
1841
1974
|
its status. If its type is not outreach, stop and say so. PREPARE: write
|
|
1842
|
-
the target audience, the value proposition and the call to action
|
|
1975
|
+
the target audience, the value proposition and the call to action (from
|
|
1976
|
+
the By kind of lead row that fits the audience, when one does). Pick
|
|
1843
1977
|
the people to reach from the pod (and public sources when the pod has
|
|
1844
1978
|
too few), resolving each one before creating anything, link each as a
|
|
1845
1979
|
member of the campaign with the lead role (lead source cold-outreach
|
|
1846
1980
|
when it has none), and for each draft one first message to that person
|
|
1847
|
-
in this campaign's angle
|
|
1848
|
-
any past message — never a generic template. DRAFT RULES: each draft is
|
|
1981
|
+
in this campaign's angle. DRAFT RULES: each draft is
|
|
1849
1982
|
one proposed message in the channel of the person it is written to,
|
|
1850
1983
|
filed through the pod's send door: run messaging.send with to = that
|
|
1851
1984
|
person's entity id (for a company lead, its decider: when that person
|
|
@@ -1874,7 +2007,11 @@ playbooks:
|
|
|
1874
2007
|
them; ignored, draft by email instead when they have an email address.
|
|
1875
2008
|
While the draft waits for them to connect, set the lead's nextAction to
|
|
1876
2009
|
"Wait for <name> to accept the LinkedIn request" and its nextActionAt 7
|
|
1877
|
-
days later. An email message needs none of this.
|
|
2010
|
+
days later. An email message needs none of this.
|
|
2011
|
+
RULES: follow the rules this process follows, in order: Voice, then By
|
|
2012
|
+
kind of lead (the first row that fits the lead; a given campaign's angle
|
|
2013
|
+
comes first). A rule shown as not available is left out: say so. START:
|
|
2014
|
+
a person approves the audience, the offer and
|
|
1878
2015
|
the list,
|
|
1879
2016
|
then reviews each proposed message in its channel and approves it;
|
|
1880
2017
|
nothing goes out before they approve it, and the agent never sends.
|
|
@@ -1910,6 +2047,16 @@ playbooks:
|
|
|
1910
2047
|
- { name: channel, type: choice, label: Channel, options: [linkedin, email], defaultValue: linkedin }
|
|
1911
2048
|
executor: is-agent
|
|
1912
2049
|
status: active
|
|
2050
|
+
# The rules it writes by (design b199a3a4, backend#924): every run renders
|
|
2051
|
+
# the CURRENT, person-approved versions under "Rules this playbook
|
|
2052
|
+
# follows", in this order. The style lines this goal held (personal, cites
|
|
2053
|
+
# the signal, short, the person's language, French with vous, one useful
|
|
2054
|
+
# next step, never pressure) seed the Voice now, through "Propose my rules
|
|
2055
|
+
# from my sent messages"; DRAFT RULES and CADENCE stay here: they are
|
|
2056
|
+
# process. Foundation's positioning joins once its kind has a lifecycle.
|
|
2057
|
+
guidance:
|
|
2058
|
+
- { ref: "kind:brand-voice-guide", label: Voice, where: { voice-context: [general, outreach] } }
|
|
2059
|
+
- { ref: "kind:outreach-angle", label: By kind of lead }
|
|
1913
2060
|
requiredIntents: [find_people, enrich_entity]
|
|
1914
2061
|
grants: [entity.create]
|
|
1915
2062
|
expectedOutputs:
|
|
@@ -1925,8 +2072,8 @@ playbooks:
|
|
|
1925
2072
|
- key: outreach-offer
|
|
1926
2073
|
statement: The target audience, value proposition and call to action are written on the campaign.
|
|
1927
2074
|
check: { kind: judge }
|
|
1928
|
-
- key: outreach-
|
|
1929
|
-
statement: Every drafted message
|
|
2075
|
+
- key: outreach-rules
|
|
2076
|
+
statement: Every drafted message follows the rules this process follows, as its instructions showed them (the approved Voice, in this campaign's angle).
|
|
1930
2077
|
check: { kind: judge }
|
|
1931
2078
|
- key: start
|
|
1932
2079
|
name: Person approves the list
|
|
@@ -2117,6 +2264,163 @@ playbooks:
|
|
|
2117
2264
|
statement: The lead records the date and the channel the estimate was sent on.
|
|
2118
2265
|
check: { kind: judge }
|
|
2119
2266
|
|
|
2267
|
+
# ── Propose my rules from my sent messages — the first rules ────────────
|
|
2268
|
+
# Design b199a3a4 Question 1, slice 2 (8 Nov 2026). The drafters write by
|
|
2269
|
+
# their `guidance` (Voice, By kind of lead) and no longer carry style lines
|
|
2270
|
+
# in their goals. This process seeds those rules as DRAFTS: from the lines
|
|
2271
|
+
# the drafters' goals held until now (quoted below, word for word the seed)
|
|
2272
|
+
# and from the messages the person actually sent. It writes drafts only,
|
|
2273
|
+
# never a current version: `approved` (voice) and `current` (angle) are
|
|
2274
|
+
# humanOnly, so a person makes each one current, on the CRM's Brand &
|
|
2275
|
+
# communication page or in the pod. A draft of something that already has a
|
|
2276
|
+
# current version is a NEW record that `revises` it, never an edit of it.
|
|
2277
|
+
# No subject and no activator: the person starts it, as "Propose a Health
|
|
2278
|
+
# cell". grants entity.create: it creates the draft records.
|
|
2279
|
+
- name: Propose my rules from my sent messages
|
|
2280
|
+
description: Propose the first rules your drafts follow, the voice (say, don't say) and what to lead with by kind of lead, from the rules your drafters held until now and the messages you sent; they stay drafts until you make them current.
|
|
2281
|
+
goalTemplate: >-
|
|
2282
|
+
Propose the rules the CRM drafters write by, as drafts for a person to
|
|
2283
|
+
make current. READ: the current and draft voice guides
|
|
2284
|
+
(synap_get_entities profileSlug brand-voice-guide) and By kind of lead
|
|
2285
|
+
rows (profileSlug outreach-angle), the audiences and offers, and the
|
|
2286
|
+
messages already sent: for the leads with a lastContactedAt, newest
|
|
2287
|
+
first, at most 20, their channels (synap_get_channel, mode person) and
|
|
2288
|
+
the outbound messages they show. SEED: the drafters' rules until now,
|
|
2289
|
+
word for word: "Its message is personal: it cites the buying signal and
|
|
2290
|
+
what it showed, or a past exchange, never a generic template; short; in
|
|
2291
|
+
the person's language, French by default, and in French it says vous.
|
|
2292
|
+
It offers one useful next step, never pressure." VOICE: one voice
|
|
2293
|
+
guide, context outreach, status draft, in the Brand Library space: its
|
|
2294
|
+
Do lines (what to say) and Don't lines (what never to say), one per
|
|
2295
|
+
line, start from the seed and add only what at least two sent messages
|
|
2296
|
+
show; Source IDs lists the messages' channel or entity ids. BY KIND OF
|
|
2297
|
+
LEAD: one row per kind of lead the sent messages show, status draft:
|
|
2298
|
+
If the lead (the condition in words), its audience and offer when one
|
|
2299
|
+
fits, Lead with, Offer, Proof, Avoid, Tone, Channel and an order, the
|
|
2300
|
+
most specific first; end with an "Anything else" row with the highest
|
|
2301
|
+
order. Never invent a proof: leave it empty and say so. When a current
|
|
2302
|
+
version exists, the draft is a new record that revises it (a revises
|
|
2303
|
+
edge to it) and says what changed; never edit or retire a current one.
|
|
2304
|
+
DRAFTS ONLY: never set a voice guide to approved or deprecated, nor a
|
|
2305
|
+
row to current or retired; a person does, on the Brand and
|
|
2306
|
+
communication page. With fewer than three sent messages, propose the
|
|
2307
|
+
voice from the seed alone and one "Anything else" row, and say so.
|
|
2308
|
+
FINISH: list each draft with the messages it came from.
|
|
2309
|
+
executor: is-agent
|
|
2310
|
+
status: active
|
|
2311
|
+
grants: [entity.create]
|
|
2312
|
+
expectedOutputs:
|
|
2313
|
+
- { kind: brand-voice-guide, label: Draft outreach voice, relationToSubject: none }
|
|
2314
|
+
- { kind: outreach-angle, label: "Draft \"By kind of lead\" rows", relationToSubject: none }
|
|
2315
|
+
stages:
|
|
2316
|
+
- key: draft
|
|
2317
|
+
name: Propose the drafts
|
|
2318
|
+
category: started
|
|
2319
|
+
goal: Read the current rules, the audiences and offers and the sent messages; write one draft outreach voice guide from the seed and the messages, and one draft By kind of lead row per kind of lead, ending with an "Anything else" row.
|
|
2320
|
+
criteria:
|
|
2321
|
+
- key: rules-drafts-only
|
|
2322
|
+
statement: Every voice guide and By kind of lead row this run wrote is a draft (voice status draft, angle status draft), and no approved voice guide or current row was edited, approved or retired.
|
|
2323
|
+
check: { kind: judge }
|
|
2324
|
+
- key: rules-seeded
|
|
2325
|
+
statement: The draft voice holds the seed lines (cite the signal or a past exchange, never a generic template, short, the person's language, French by default with vous, one useful next step, never pressure) as Do and Don't lines, plus only what at least two sent messages show.
|
|
2326
|
+
check: { kind: judge }
|
|
2327
|
+
- key: rules-rows-sourced
|
|
2328
|
+
statement: Each By kind of lead row names the sent messages it came from, has an order, and the last one is an "Anything else" row; no proof is invented.
|
|
2329
|
+
check: { kind: judge }
|
|
2330
|
+
- key: review
|
|
2331
|
+
name: Person makes them current
|
|
2332
|
+
category: completed
|
|
2333
|
+
goal: The person reads the drafts, edits them if needed and makes each one current (a voice guide approved, a row current) on the Brand and communication page or in the pod, or drops it.
|
|
2334
|
+
gate: { kind: human }
|
|
2335
|
+
onFail: { toStage: draft }
|
|
2336
|
+
|
|
2337
|
+
# ── Propose a Health cell — one tile of the Health view ─────────────────
|
|
2338
|
+
# Design b199a3a4 Question 2, slice 5. The person asks a question of their
|
|
2339
|
+
# sales ("reply rate by audience, weekly"); the AI writes ONE HTML cell that
|
|
2340
|
+
# answers it and files it with synap_create_cell, contentKind widget and
|
|
2341
|
+
# placeOn = the Health view: approving the proposal defines the cell and
|
|
2342
|
+
# puts its tile on Health in one act (backend#926). Governed: an agent's
|
|
2343
|
+
# cell/define is always a proposal, and the person approves it in the CRM
|
|
2344
|
+
# ("Add to Health") or in the pod.
|
|
2345
|
+
# The cell reads pod data only through the cell bridge (window.synap.query
|
|
2346
|
+
# with the ops of @synap-core/types/cell-bridge read-ops.ts); the host stamps
|
|
2347
|
+
# the space. The bridge has no message op yet (design slice 7), so a number
|
|
2348
|
+
# it cannot read is baked into the page as a snapshot with its date.
|
|
2349
|
+
# executor external-agent: the run needs synap_create_cell with placeOn and
|
|
2350
|
+
# contentKind, which only the MCP door carries today; Synap AI's own
|
|
2351
|
+
# create_cell (synap-intelligence-service creative-loop-tools.ts) sends
|
|
2352
|
+
# neither, so its cell would land nowhere. Switch to is-agent once it does.
|
|
2353
|
+
# No grants: the run uses pod reads and the cells door, no tool or skill.
|
|
2354
|
+
- name: Propose a Health cell
|
|
2355
|
+
description: Answer one question about your sales with a tile on the Health dashboard; the AI writes the tile and you approve it before it shows. Run by one of your agents for now (Synap AI cannot place a tile yet).
|
|
2356
|
+
goalTemplate: >-
|
|
2357
|
+
Propose one Health tile that answers: {question}. FIND THE VIEW: in the
|
|
2358
|
+
CRM space, the bento view named Health (synap_list_views with the
|
|
2359
|
+
space's workspaceId, type bento). When the space has none, stop and say
|
|
2360
|
+
so: never create another dashboard. READ FIRST: what already sits on
|
|
2361
|
+
Health (its config.blocks: each widget tile names a cell by widgetType)
|
|
2362
|
+
and the space's cells (synap_list_widgets); when a tile already answers
|
|
2363
|
+
the question, say which one and stop. DATA: decide where each number
|
|
2364
|
+
comes from. A cell reads the pod ONLY through the cell bridge, at
|
|
2365
|
+
render time: window.synap.query(op, params), with an op of the bridge
|
|
2366
|
+
table (entities.list, entities.get, views.list, profiles.list,
|
|
2367
|
+
lifecycle.board, lifecycle.throughput, attention.needsYou,
|
|
2368
|
+
attention.count, sessions.list, lifecycle.home, lifecycle.moving,
|
|
2369
|
+
documents.get, lens.page) and only that op's params; the host stamps
|
|
2370
|
+
the space, so never put a workspaceId, a token, a pod URL or a fetch in
|
|
2371
|
+
the page. What the bridge reads stays live: query it in the page, never
|
|
2372
|
+
paste its rows. What it cannot read yet (messages, replies, sends: the
|
|
2373
|
+
bridge has no message op) you read now with your own tools
|
|
2374
|
+
(synap_get_channel, synap_get_entities) and write into the page as a
|
|
2375
|
+
snapshot, with the date it was taken shown on the tile (for example "au 8 novembre")
|
|
2376
|
+
and how it was counted. Never invent a number: a figure you cannot
|
|
2377
|
+
source is left out and the tile says what is missing. THE PAGE: one
|
|
2378
|
+
self-contained HTML page, inline script and style only (no CDN, no
|
|
2379
|
+
remote font or image: the frame's CSP refuses them), that answers the
|
|
2380
|
+
question in one glance (a number, a short table or a small chart), in
|
|
2381
|
+
the person's language (French by default), readable in light and dark,
|
|
2382
|
+
and that shows an error, never an empty tile, when a query fails. FILE
|
|
2383
|
+
IT: synap_create_cell with name = a short title of the question,
|
|
2384
|
+
rendererSource = the page, workspaceId = the CRM space (never pod-wide:
|
|
2385
|
+
the CRM app reads only its space's cells), contentKind widget, placeOn
|
|
2386
|
+
= {viewId: the Health view's id}, and reasoning = the question in the
|
|
2387
|
+
person's words. It comes back proposed: that is success, never retry
|
|
2388
|
+
it; the person approves it in the CRM or the pod, which defines the
|
|
2389
|
+
cell and puts its tile on Health in one act. One cell per run.
|
|
2390
|
+
# No activator: a run is started by the person (the CRM's "Ask for a
|
|
2391
|
+
# tile"), and an activator fires on a subject this process has none of.
|
|
2392
|
+
params:
|
|
2393
|
+
- { name: question, type: text, label: What should the tile answer?, required: true }
|
|
2394
|
+
executor: external-agent
|
|
2395
|
+
status: active
|
|
2396
|
+
stages:
|
|
2397
|
+
- key: draft
|
|
2398
|
+
name: Write the tile
|
|
2399
|
+
category: started
|
|
2400
|
+
goal: Find the Health view, check no tile already answers the question, write one self-contained HTML page that answers it (live through the cell bridge, a dated snapshot for what the bridge cannot read), and file it with synap_create_cell, contentKind widget, workspaceId the CRM space and placeOn the Health view.
|
|
2401
|
+
expectedOutputs:
|
|
2402
|
+
# The proposed cell: a `cell/define` proposal carrying the page and
|
|
2403
|
+
# its placement. It writes no edge to a subject (the run has none).
|
|
2404
|
+
- { kind: cell, label: Proposed Health tile, relationToSubject: none }
|
|
2405
|
+
criteria:
|
|
2406
|
+
# Judges: no core or catalog verb reads a session's proposals and
|
|
2407
|
+
# answers {passed}, so the pod has no exact check for these yet.
|
|
2408
|
+
- key: health-cell-placed
|
|
2409
|
+
statement: One cell/define proposal was filed through synap_create_cell with contentKind widget, workspaceId the CRM space and placeOn the Health view's id, and no other dashboard or view was created.
|
|
2410
|
+
check: { kind: judge }
|
|
2411
|
+
- key: health-cell-bridge-only
|
|
2412
|
+
statement: The page reads pod data only through window.synap.query with ops of the cell bridge table, and holds no token, pod URL, workspaceId, fetch or remote script, style, font or image.
|
|
2413
|
+
check: { kind: judge }
|
|
2414
|
+
- key: health-cell-sourced
|
|
2415
|
+
statement: Every number the page shows is either queried live through the bridge or a snapshot shown with the date it was taken and how it was counted; no number is invented.
|
|
2416
|
+
check: { kind: judge }
|
|
2417
|
+
- key: approve
|
|
2418
|
+
name: You approve the tile
|
|
2419
|
+
category: completed
|
|
2420
|
+
goal: The person previews the proposed tile and approves it (the cell is defined and its tile placed on Health) or rejects it.
|
|
2421
|
+
gate: { kind: human }
|
|
2422
|
+
onFail: { toStage: draft }
|
|
2423
|
+
|
|
2120
2424
|
# The lead requirement keeps "Qualify a lead" out of plain person/company
|
|
2121
2425
|
# records (rendered by CRM and Browser through the shared entity-action runner).
|
|
2122
2426
|
actionPlacements:
|
|
@@ -161,10 +161,13 @@ describe("lifecycle declarations — coverage (derived from the playbooks)", ()
|
|
|
161
161
|
* this ledger makes any change to one a deliberate, reviewed edit. Founder
|
|
162
162
|
* decisions among them: ui-design.approved (design review, DESIGN-DEV-XP-PLAN
|
|
163
163
|
* P6, 2026-10-12), outreach-touch.sent (a person sends, 2026-10-20),
|
|
164
|
-
* devplane_feature.cancelled / devplane_story.dropped (homes, 2026-10-13)
|
|
164
|
+
* devplane_feature.cancelled / devplane_story.dropped (homes, 2026-10-13),
|
|
165
|
+
* brand-voice-guide.approved and outreach-angle.current / retired (rules a
|
|
166
|
+
* playbook renders into the AI's instructions, design b199a3a4, 8 Nov 2026).
|
|
165
167
|
*/
|
|
166
168
|
const HUMAN_ONLY = [
|
|
167
169
|
"brand-library:brand-asset.deprecated",
|
|
170
|
+
"brand-library:brand-voice-guide.approved",
|
|
168
171
|
"brand-library:brand-voice-guide.deprecated",
|
|
169
172
|
"brand-library:content-guideline.deprecated",
|
|
170
173
|
"builder-workspace:devplane_feature.cancelled",
|
|
@@ -181,6 +184,8 @@ describe("lifecycle declarations — coverage (derived from the playbooks)", ()
|
|
|
181
184
|
"crm:campaign.cancelled",
|
|
182
185
|
"crm:campaign.paused",
|
|
183
186
|
"crm:deal.lost",
|
|
187
|
+
"crm:outreach-angle.current",
|
|
188
|
+
"crm:outreach-angle.retired",
|
|
184
189
|
"crm:outreach-touch.replaced",
|
|
185
190
|
"crm:outreach-touch.sent",
|
|
186
191
|
"finance:expense.reimbursed",
|