AI-assisted authoring
Feed a use case,
get a deployable pipeline.
We publish a self-contained system-prompt document. Feed it + a plain-English use case to any LLM (Claude, GPT, Gemini) and the output is a ready-to-deploy pipeline JSON plus an @InvocableMethod wrapper when the use case calls for Flow Builder.
How it works
Feed the system prompt
Copy the contents of docs/05-reference/pipeline-authoring-system-prompt.md into the LLM's system message.
Describe the use case
Plain English. "When an Account is updated, summarize it into a custom field for the AE." No special syntax required.
Deploy
The output is valid JSON + valid Apex. Drop into your SFDX project and sf project deploy start.
Pipeline JSON schema
Every pipeline is a DAG. Stages wire via depends_on and {{ }} templates.
{
"id": "summarize_account",
"name": "Summarize Account",
"description": "Fetch an Account with recent cases and produce a 3-sentence summary.",
"input_schema": {
"type": "object",
"properties": { "accountId": { "type": "string" } },
"required": ["accountId"]
},
"stages": [
{
"id": "fetch",
"component_type": "soql_query",
"config": {
"query": "SELECT Id, Name, Industry FROM Account WHERE Id = :input.accountId LIMIT 1"
},
"depends_on": []
},
{
"id": "summarize",
"component_type": "llm_summarizer",
"config": {
"style": "brief",
"maxLength": 120,
"prompt": "Summarize this account in 3 sentences: {{ stages.fetch.records[0] }}"
},
"depends_on": ["fetch"]
},
{
"id": "write_summary",
"component_type": "dml_operation",
"config": {
"operation": "update",
"sobjectType": "Account",
"records": [ { "Id": "{{ input.accountId }}", "AI_Summary__c": "{{ stages.summarize.summary }}" } ]
},
"depends_on": ["summarize"]
}
],
"output_stage_id": "summarize"
} Component catalog
50+ components across three categories — every shipped type, auto-registered via FM_Component_Type__mdt.
Nodes (AI / LLM)
Operators (data movement / transform)
Flow control
Invocable Apex wrapper
When the use case needs Flow Builder or record-triggered entry, the authoring prompt emits a matching Apex class. The wrapper is always public with sharing with a List<Request> signature for bulk-safe Flow invocation.
public with sharing class SummarizeAccountInvocable {
public class Request {
@InvocableVariable(label='Account ID' required=true)
public Id accountId;
}
public class Response {
@InvocableVariable(label='Summary')
public String summary;
}
@InvocableMethod(label='AI: Summarize Account' category='FlowMason AI')
public static List<Response> invoke(List<Request> requests) {
List<Map<String, Object>> inputs = new List<Map<String, Object>>();
for (Request r : requests) {
inputs.add(new Map<String, Object>{ 'accountId' => r.accountId });
}
List<ExecutionResult> results = PipelineRunner.executeAll('summarize_account', inputs);
List<Response> responses = new List<Response>();
for (ExecutionResult result : results) {
Response resp = new Response();
resp.summary = (String) result.getOutput().get('summary');
responses.add(resp);
}
return responses;
}
} Design patterns the prompt recognizes
soql_query → llm_summarizer → dml_operation
soql_query → llm_classifier → switch → handlers
form_extractor → dml_operation
classifier + analyzer → conditional → dml_operation
rag_retriever → llm_qa
soql_query → foreach { classifier → dml_operation }
circuit_breaker (mode: buffered) → wrapped stage
parallel → combiner → llm_critic
Get the full system prompt
The complete 886-line authoring doc — every component, every pattern, worked examples, quality checklist. Ships with the managed package.
Request access