How it differs from Asker mode
| Asker mode | Semantic function | |
|---|---|---|
| Input | A natural language question | A function name + parameters |
| When the query is built | Every time you ask | Once, when the function is created |
| Runtime | Jedify interprets and generates the query | Runs the pre-built query directly |
| Result | Answer, chart, explanation | Rows of data |
The lifecycle
Discover
Check what already exists with
list_semantic_functions. Most dashboards can be built from existing functions — only create new ones when there’s a gap.Create (if needed)
Validate a question in Asker mode, then turn that result into a function with
create_semantic_function. You name the values you want to expose as parameters.What you can parameterize
When you create a function, you list the values to expose as parameters. You can parameterize values that appear in the query — for example:- A dimension you filter on (region, status, country, category)
- A date or datetime range
- A numeric threshold or range
- A list of values (an
INlist) - A boolean toggle
Parameter types
Each parameter has a type, which controls how its value is formatted into the query:| Type | Example value |
|---|---|
string | "active" |
number | 100 |
boolean | true |
date | "2025-01-01" |
datetime | "2025-01-01T00:00:00Z" |
array<string> | ["US", "Canada"] |
array<number> | [101, 102, 103] |
Naming
Function names start with an underscore and useUPPER_CASE_WITH_UNDERSCORES — for example _REVENUE_BY_PRODUCT or _CHURN_BY_REGION.
Validation
When a function is created, Jedify validates it by running it once with its default parameters:- Active — the function ran successfully and is ready to call.
- Failed validation — the function couldn’t run; it’s saved with the error but can’t be called until the issue is resolved.
Query results come back with UPPERCASE column names. Access fields as
row.TOTAL_REVENUE, not row.total_revenue. See the SDK reference for details.