Problem / motivation
MATLAB reads a per-folder functionSignatures.json to power editor tab-completion and inline argument hints (valid name-value names, enum values, types). Two were just added:
libs/FastSense/functionSignatures.json (commit 8d7af2c)
libs/Dashboard/functionSignatures.json (commit 90d0579)
But the Tag family has none. libs/SensorThreshold/ — the core domain API users instantiate constantly (SensorTag, MonitorTag, CompositeTag, DerivedTag, StateTag, plus TagRegistry) — has no signature metadata, so the editor offers no completion for those constructors or their name-value options. (Neither do EventDetection, FastSenseCompanion, WebBridge, PlantLog, but the Tag family is the highest-traffic public API and the natural next step.)
This is a clean parity follow-up to the just-merged work.
Proposed feature
Add libs/SensorThreshold/functionSignatures.json covering the Tag-family public API, mirroring the structure of the two existing files. Cover:
- Constructors:
SensorTag(key, ...), MonitorTag(key, parent, conditionFn, ...), CompositeTag(...), DerivedTag(...), StateTag(...) — with their name-value options (e.g. Name, Units, Criticality, EventStore, MinDuration, AggregateMode, Persist, …) and enum values where applicable (e.g. AggregateMode ∈ and|or|majority|count|worst|severity|user_fn).
TagRegistry static methods (get, register, find, findByKind, loadFromStructs, …).
- Common methods worth hinting (
getXY, getXYRange, valueAt).
Rough sketch
- File:
libs/SensorThreshold/functionSignatures.json (new; no code change).
- Pattern: copy the schema/shape from
libs/FastSense/functionSignatures.json and libs/Dashboard/functionSignatures.json (same _schemaVersion + per-function inputs with name/kind/type/purpose). Use kind: "namevalue" for option pairs and type: ["choices={...}"] for enums.
- Validation: MATLAB's
validateFunctionSignaturesJSON (where available) to lint the file; otherwise load a class in the editor and confirm completion.
Value
Editor tab-completion and argument hints for the most-used public API in the project — discoverability of constructor options and valid enum values without leaving the editor. Pure DX, no runtime risk, completes the parity the two merged signature files started.
Constraints check
- Toolbox-free: ✅ a JSON metadata file read by the base MATLAB editor; no toolbox, no code.
- Backward-compatible: ✅ purely additive metadata; zero runtime behavior change; ignored by Octave (which simply doesn't read it).
- Pure MATLAB / Octave: ✅ no MEX, no deps; MATLAB-only benefit, harmless on Octave.
Effort estimate
M — mechanical but sizable: author signatures for 5 constructors + TagRegistry statics + key methods, mirroring the two existing files. Naturally extensible later to EventDetection/FastSenseCompanion/WebBridge/PlantLog.
AI-proposed via /feature-scout — needs a human product decision before implementation.
Problem / motivation
MATLAB reads a per-folder
functionSignatures.jsonto power editor tab-completion and inline argument hints (valid name-value names, enum values, types). Two were just added:libs/FastSense/functionSignatures.json(commit 8d7af2c)libs/Dashboard/functionSignatures.json(commit 90d0579)But the Tag family has none.
libs/SensorThreshold/— the core domain API users instantiate constantly (SensorTag,MonitorTag,CompositeTag,DerivedTag,StateTag, plusTagRegistry) — has no signature metadata, so the editor offers no completion for those constructors or their name-value options. (Neither doEventDetection,FastSenseCompanion,WebBridge,PlantLog, but the Tag family is the highest-traffic public API and the natural next step.)This is a clean parity follow-up to the just-merged work.
Proposed feature
Add
libs/SensorThreshold/functionSignatures.jsoncovering the Tag-family public API, mirroring the structure of the two existing files. Cover:SensorTag(key, ...),MonitorTag(key, parent, conditionFn, ...),CompositeTag(...),DerivedTag(...),StateTag(...)— with their name-value options (e.g.Name,Units,Criticality,EventStore,MinDuration,AggregateMode,Persist, …) and enum values where applicable (e.g.AggregateMode∈and|or|majority|count|worst|severity|user_fn).TagRegistrystatic methods (get,register,find,findByKind,loadFromStructs, …).getXY,getXYRange,valueAt).Rough sketch
libs/SensorThreshold/functionSignatures.json(new; no code change).libs/FastSense/functionSignatures.jsonandlibs/Dashboard/functionSignatures.json(same_schemaVersion+ per-functioninputswithname/kind/type/purpose). Usekind: "namevalue"for option pairs andtype: ["choices={...}"]for enums.validateFunctionSignaturesJSON(where available) to lint the file; otherwise load a class in the editor and confirm completion.Value
Editor tab-completion and argument hints for the most-used public API in the project — discoverability of constructor options and valid enum values without leaving the editor. Pure DX, no runtime risk, completes the parity the two merged signature files started.
Constraints check
Effort estimate
M — mechanical but sizable: author signatures for 5 constructors +
TagRegistrystatics + key methods, mirroring the two existing files. Naturally extensible later toEventDetection/FastSenseCompanion/WebBridge/PlantLog.AI-proposed via /feature-scout — needs a human product decision before implementation.