Skip to content

Comments

chore: add float32 scalar kernel of log1p in unary function database#9452

Merged
kgryte merged 1 commit intostdlib-js:developfrom
gunjjoshi:unary-func-db-update
Dec 31, 2025
Merged

chore: add float32 scalar kernel of log1p in unary function database#9452
kgryte merged 1 commit intostdlib-js:developfrom
gunjjoshi:unary-func-db-update

Conversation

@gunjjoshi
Copy link
Member


type: pre_commit_static_analysis_report
description: Results of running static analysis checks when committing changes. report:

  • task: lint_filenames status: passed
  • task: lint_editorconfig status: passed
  • task: lint_markdown status: na
  • task: lint_package_json status: na
  • task: lint_repl_help status: na
  • task: lint_javascript_src status: na
  • task: lint_javascript_cli status: na
  • task: lint_javascript_examples status: na
  • task: lint_javascript_tests status: na
  • task: lint_javascript_benchmarks status: na
  • task: lint_python status: na
  • task: lint_r status: na
  • task: lint_c_src status: na
  • task: lint_c_examples status: na
  • task: lint_c_benchmarks status: na
  • task: lint_c_tests_fixtures status: na
  • task: lint_shell status: na
  • task: lint_typescript_declarations status: passed
  • task: lint_typescript_tests status: na
  • task: lint_license_headers status: passed ---

Resolves None.

Description

What is the purpose of this pull request?

This pull request:

Related Issues

Does this pull request have any related issues?

None.

Questions

Any questions for reviewers of this pull request?

No.

Other

Any other information relevant to this pull request? This may include screenshots, references, and/or implementation notes.

Currently, unary.json is missing the data for log1pf, which will be added by the workflow once we update unary_function_database.

Checklist

Please ensure the following tasks are completed before submitting this pull request.

AI Assistance

When authoring the changes proposed in this PR, did you use any kind of AI assistance?

  • Yes
  • No

If you answered "yes" above, how did you use AI assistance?

  • Code generation (e.g., when writing an implementation or fixing a bug)
  • Test/benchmark generation
  • Documentation (including examples)
  • Research and understanding

Disclosure

If you answered "yes" to using AI assistance, please provide a short disclosure indicating how you used AI assistance. This helps reviewers determine how much scrutiny to apply when reviewing your contribution. Example disclosures: "This PR was written primarily by Claude Code." or "I consulted ChatGPT to understand the codebase, but the proposed changes were fully authored manually by myself.".

{{TODO: add disclosure if applicable}}


@stdlib-js/reviewers

---
type: pre_commit_static_analysis_report
description: Results of running static analysis checks when committing changes.
report:
  - task: lint_filenames
    status: passed
  - task: lint_editorconfig
    status: passed
  - task: lint_markdown
    status: na
  - task: lint_package_json
    status: na
  - task: lint_repl_help
    status: na
  - task: lint_javascript_src
    status: na
  - task: lint_javascript_cli
    status: na
  - task: lint_javascript_examples
    status: na
  - task: lint_javascript_tests
    status: na
  - task: lint_javascript_benchmarks
    status: na
  - task: lint_python
    status: na
  - task: lint_r
    status: na
  - task: lint_c_src
    status: na
  - task: lint_c_examples
    status: na
  - task: lint_c_benchmarks
    status: na
  - task: lint_c_tests_fixtures
    status: na
  - task: lint_shell
    status: na
  - task: lint_typescript_declarations
    status: passed
  - task: lint_typescript_tests
    status: na
  - task: lint_license_headers
    status: passed
---
@stdlib-bot stdlib-bot added Math Issue or pull request specific to math functionality. Needs Review A pull request which needs code review. labels Dec 31, 2025
@stdlib-bot
Copy link
Contributor

Coverage Report

Package Statements Branches Functions Lines
math/special $\color{red}436/438$
$\color{green}+99.54%$
$\color{red}6/7$
$\color{green}+85.71%$
$\color{green}0/0$
$\color{green}+100.00%$
$\color{red}436/438$
$\color{green}+99.54%$

The above coverage report was generated for the changes in this PR.

@gunjjoshi
Copy link
Member Author

Maybe we can explore adding a workflow that does this automatically, i.e., when a new package is added, update the unary function database by adding an entry under the appropriate base alias, along with its dtype. This will then be picked up by our existing workflow to update unary.json.

@kgryte
Copy link
Member

kgryte commented Dec 31, 2025

@gunjjoshi Potentially. Not as simple, however, as when a new package is added. We'd need to

  1. Detect when a new package is added.
  2. Read the package.json.
  3. Determine if has required meta data.
  4. If so, determine if unary package.
  5. If yes, then potentially add.

My guess is that this is similar to our manual process now, where we need to manually add aliases to the package's parent namespace. In this instance, in addition to lib/index.js, we need to add to the appropriate database file.

At a minimum, we could have a workflow/cron which regularly checks whether packages are missing from a corresponding function database.

@kgryte kgryte removed the Needs Review A pull request which needs code review. label Dec 31, 2025
Copy link
Member

@kgryte kgryte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks for the follow-up, @gunjjoshi!

@kgryte kgryte merged commit bba26d6 into stdlib-js:develop Dec 31, 2025
50 checks passed
@kgryte kgryte deleted the unary-func-db-update branch December 31, 2025 08:44
@gunjjoshi
Copy link
Member Author

Thanks for sharing the whole outline, @kgryte. I'll work on making the workflow, to regularly check if packages are missing from a corresponding database.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Math Issue or pull request specific to math functionality.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants