)]}'
{
  "commit": "fd15b03ecc227957b752429bf5b7c56c0f139f1e",
  "tree": "417451c057c4702b287f4427a16dd3a194ff35ed",
  "parents": [
    "3256138ecc57de2666df704909a371919ff6fbfd"
  ],
  "author": {
    "name": "Tim Saucer",
    "email": "timsaucer@gmail.com",
    "time": "Mon Jun 15 14:01:13 2026 -0400"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Mon Jun 15 14:01:13 2026 -0400"
  },
  "message": "feat: expose array_compact, array_normalize, cosine_distance, inner_product (#1567)\n\n* feat: expose array_compact, array_normalize, cosine_distance, inner_product\n\nAdds Python bindings for four scalar functions from\ndatafusion::functions_nested::expr_fn that were not previously surfaced:\n\n- array_compact / list_compact: drop NULLs from an array.\n- array_normalize / list_normalize: L2-normalize a numeric array.\n- cosine_distance: 1 - cosine_similarity(a, b).\n- inner_product: dot product of two numeric arrays.\n\nImplementation routes each through the existing array_fn! macro in\ncrates/core/src/functions.rs, mirroring the other functions_nested\nwrappers. Python wrappers in python/datafusion/functions.py follow the\nestablished pattern with doctest examples; list_* aliases use the\none-line + See Also form per project convention.\n\nCo-Authored-By: Claude Opus 4.7 (1M context) \u003cnoreply@anthropic.com\u003e\n\n* docs: clarify array_normalize and cosine_distance docstrings\n\nExpand both docstrings with plain-English definitions, worked examples,\nranges, use cases, and behavior on edge cases (zero vector → NULL,\nlength-mismatched inputs fail). Adds a zero-vector example to\narray_normalize and an orthogonal-vector example to cosine_distance.\nUpdates the list_normalize alias summary to match.\n\nCo-Authored-By: Claude \u003cnoreply@anthropic.com\u003e\n\n* test: add alias-equivalence and length-mismatch tests for array fns\n\nPin the contracts the doctests don\u0027t cover:\nlist_compact/list_normalize must produce the same output as their\narray_* primaries, and cosine_distance/inner_product must reject\nlength-mismatched inputs at execution time.\n\n* feat: expose dot_product alias for inner_product\n\nMatch upstream DataFusion SQL alias surface (inner_product UDF\nregisters `dot_product` in its alias list). Also expand\n`inner_product` docstring with NULL/length-mismatch behavior to\nmatch peer distance fns added in this PR.\n\nCo-Authored-By: Claude Opus 4.7 \u003cnoreply@anthropic.com\u003e\n\n* test: fold dot_product alias check into parametrized test\n\nGeneralize test_array_function_aliases to accept multi-column data so\nthe dot_product/inner_product alias case fits, dropping the standalone\ntest_dot_product_alias_matches_inner_product.\n\nCo-Authored-By: Claude Opus 4.8 (1M context) \u003cnoreply@anthropic.com\u003e\n\n---------\n\nCo-authored-by: Claude Opus 4.7 (1M context) \u003cnoreply@anthropic.com\u003e",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "395d5ebfd20d4fca1efd9935c40212624857437d",
      "old_mode": 33188,
      "old_path": "crates/core/src/functions.rs",
      "new_id": "a56873c582dc00aafe2dd10afb0c9ec07f035071",
      "new_mode": 33188,
      "new_path": "crates/core/src/functions.rs"
    },
    {
      "type": "modify",
      "old_id": "9158a71468768f9836f1ff3188a542b798ae9422",
      "old_mode": 33188,
      "old_path": "python/datafusion/functions.py",
      "new_id": "4e08fa1d95efe29255dcc72497804a8821b4df2b",
      "new_mode": 33188,
      "new_path": "python/datafusion/functions.py"
    },
    {
      "type": "modify",
      "old_id": "d2abe47412e9c604d0ec2a7eee60c762722ad289",
      "old_mode": 33188,
      "old_path": "python/tests/test_functions.py",
      "new_id": "b02cdf6dbaeafd80000e37347bb80810235890fe",
      "new_mode": 33188,
      "new_path": "python/tests/test_functions.py"
    }
  ]
}
