Skip to content

Cache base score for parsing#1151

Merged
tushuhei merged 1 commit intogoogle:mainfrom
shuofengzhang:optimize-base-score
Mar 4, 2026
Merged

Cache base score for parsing#1151
tushuhei merged 1 commit intogoogle:mainfrom
shuofengzhang:optimize-base-score

Conversation

@shuofengzhang
Copy link
Copy Markdown
Contributor

What changed

  • Cache the model base score on parser initialization to avoid recomputing it for every parse call.

Why

  • Parsing already relies on a constant derived from the model; caching it reduces repeated work while keeping behavior identical.

Testing

  • ./.venv/bin/pytest

@google-cla
Copy link
Copy Markdown

google-cla Bot commented Mar 3, 2026

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@tushuhei
Copy link
Copy Markdown
Member

tushuhei commented Mar 4, 2026

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

Thank you for your pull request. Please sign a CLA from the URL above.

@shuofengzhang
Copy link
Copy Markdown
Contributor Author

shuofengzhang commented Mar 4, 2026 via email

@tushuhei tushuhei merged commit 92caa35 into google:main Mar 4, 2026
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants