[query] Rudimentary static evaluation of predicates #150

Open
opened 2020-08-06 16:55:46 +00:00 by gburd · 0 comments
gburd commented 2020-08-06 16:55:46 +00:00 (Migrated from github.com)

Should we see a query with an expression like [(< ?x ?y)], and it turns out that both ?x and ?y are known — by deduction from the schema, by input binding, by deduction (e.g., for a boolean-valued variable, we might also have [(!= ?y true)], which allows us to ground ?y to false) — then we have an opportunity to compute the value prior to executing the query.

This ticket covers the basics: taking a pattern like [(< 5 4)] and marking the pattern as is_known_empty.

Should we see a query with an expression like `[(< ?x ?y)]`, and it turns out that both `?x` and `?y` are known — by deduction from the schema, by input binding, by deduction (_e.g._, for a boolean-valued variable, we might also have `[(!= ?y true)]`, which allows us to `ground` `?y` to `false`) — then we have an opportunity to compute the value prior to executing the query. This ticket covers the basics: taking a pattern like `[(< 5 4)]` and marking the pattern as `is_known_empty`.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: greg/mentat#150
No description provided.