Commit 21cdd42
* docs: add spec for data transformation CEL functions (#14)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* docs: add implementation plan for data transformation CEL functions (#14)
12-task plan: macro tests, string/type/collection/JSON/time functions,
obj() construction, docs updates, and example workflows.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* test(cel): add coverage for built-in map/filter/exists/all macros
* feat(cel): add toLower, toUpper, trim string functions
Registers custom string member overloads via cel.Lib and wires them
into NewEvaluator through a central customFunctions() registration point.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* feat(cel): add replace and split string functions
* feat(cel): add parseInt, parseFloat, toString type coercion functions
* feat(cel): add obj() map construction function
* feat(cel): add default() null coalescing and flatten() functions
* feat(cel): add jsonEncode and jsonDecode functions
* feat(cel): add timestamp and formatTimestamp date/time functions
* docs: add custom CEL functions and macros to expressions reference (#14)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* feat: add data transformation and AI enrichment example workflows (#14)
* docs: add data transformation patterns guide (#14)
Covers three patterns — CEL-only structural transforms, AI-powered semantic
transforms, and hybrid workflows that combine both. Includes a decision guide
and a quick-reference table of all available CEL extension functions.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* fix: address CodeRabbit review — null handling, date formats, docs, tests (#14)
- default(): fall through to rhs when lhs is null (types.NullValue)
- parseTimestamp(): try RFC3339Nano, bare ISO date, US date, and named-month formats before erroring
- expressions.md: remove undeclared `now` variable from two examples
- data-transformations.md: add missing exists_one row to list-macros table
- data-transform-api-to-db.yaml: simplify to single-user fetch+insert (fixes broken batch param shape)
- functions_test.go: add null/fallback tests for default(), edge-case tests for flatten(), and new format tests for parseTimestamp()
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* fix: address PR #21 review — non-strict default, jsonDecode precision, docs accuracy
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* fix: address PR #21 review round 3 — test coverage, trailing JSON, docs accuracy
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* fix: address PR #21 review round 4 — EOF trailing check, docs, plan cleanup
- jsonDecode: replace dec.More() with dec.Decode(&trailing) EOF check
to catch all trailing data (e.g., "{}]", "1}")
- Add trailing_bracket and trailing_brace regression tests
- Update parseTimestamp description in data-transformations.md to list
all accepted formats
- Plan: rename TestFunc_Timestamp to TestFunc_ParseTimestamp, add
golangci-lint to final validation checklist
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* fix: address PR #21 review round 5 — precision, flatten, plan accuracy
- normalizeJSONNumbers: only use float64 for decimals/exponents, preserve
overflow integers as strings to avoid silent precision loss
- flatten: initialize result as make([]any, 0) so empty lists return
non-nil empty slice
- Add large_integer_preserved test for jsonDecode
- Plan: remove dead split() variable, replace variadic obj() with
fixed-arity overloads, add jsonDecode EOF check, fix timestamp refs
- data-transformations.md: note obj() 5-pair limit
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* fix(plan): correct test selector to TestFunc_ParseTimestamp
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* chore: remove force-added superpowers docs from tracking
These internal process docs (specs, plans) are already in .gitignore
but were force-added during development. Files remain on disk but are
no longer tracked by git.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* 📝 CodeRabbit Chat: Add generated unit tests
---------
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
1 parent db71d00 commit 21cdd42
10 files changed
Lines changed: 2095 additions & 1157 deletions
File tree
- docs/superpowers
- plans
- specs
- examples
- internal/cel
- site/src/content/docs
- concepts
- getting-started
Lines changed: 0 additions & 981 deletions
This file was deleted.
Lines changed: 0 additions & 174 deletions
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
31 | | - | |
| 31 | + | |
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
36 | | - | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
37 | 40 | | |
38 | 41 | | |
39 | 42 | | |
| |||
0 commit comments