Comments (4)
Proposed implementation
class NonAdditiveDimensionParametersProtocol(Protocol):
name: str
window_choice: AggregationType
window_groupings: List[str]
class MeasureAggregationParametersProtocol(Protocol):
percentile: Optional[float]
use_discrete_percentile: bool
use_approximate_percentile: bool
class MeasureProtocol(Protocol):
name: str
agg: AggregationType
description: Optional[str]
create_metric: Optional[bool]
expr: Optional[str]
agg_params: Optional[MeasureAggregationParametersProtocol]
non_additive_dimension: Optional[NonAdditiveDimensionParametersProtocol]
agg_time_dimension: Optional[str]
checked_agg_time_dimension: TimeDimensionReference
reference: MeasureReference
from dbt-semantic-interfaces.
@WilliamDee can I get your 👀 on this to see if it passes the sniff test?
from dbt-semantic-interfaces.
@WilliamDee can I get your 👀 on this to see if it passes the sniff test?
@callum-mcdata This looks right! Question I had is do we necessarily need the properties being a protocol as well (ie., MeasureAggregationParametersProtocol
)? The answer to that would probably be how flexible we want to be with building these custom classes.
from dbt-semantic-interfaces.
I think @QMalcolm is probably the best person to answer this. I have no strong opinons one way or another on how we want to implement this 🤔
Additionally I've edited the proposal based on a conversation he and I had offline around whether we want default implementations for property methods. He recommended that we instead define the shape of those properties and core is free to implement them as they see fit.
from dbt-semantic-interfaces.
Related Issues (20)
- [Bug] Please support pydantic-2.x HOT 1
- [SL-1489] [Bug] The pydantic shim isn't being included in the `wheel` distributions of the package
- [SL-1491] [CI/CD] Create github action that checks the produced distributions are functional
- [SL-1507] Release 0.5.0a3
- [SL-1508] Release 0.4.3 HOT 1
- [SL-1563] [Feature] Add `meta` to Metric/SemanticModel HOT 2
- [Feature] Add cache config to saved query HOT 3
- [Feature] Add `timezone` key to time dimensions `type_params` HOT 1
- [SL-1603] Remove `create_metric` from protocol spec
- [SL-1610] [SL-1610] [Bug] Referencing entities in where filter causes an error.
- [Python 3.12] Support + test against python 3.12 in dbt-semantic-interfaces
- [Feature] Allow specifying saved query group by items with dundered syntax vs the object syntax HOT 1
- [Bug] Derived metric validation allows empty input metric set
- [Bug] Make `expr` required for derived metrics
- [Feature] Support referencing a metric in where filter HOT 1
- [Feature] Sub-daily granularity
- [Feature] Relax double underscore requirement on metrics HOT 4
- [Feature] Add `period_agg` field for cumulative metrics
- [Feature] Add `default_grain` to metric spec HOT 1
- [Bug] Inconsistency between time dimension Jinja objects for `time_granularity_name`
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dbt-semantic-interfaces.