Skip to content

Rebase adaptive topN changes onto latest master and retrigger Actions#35

Merged
yanyiwu merged 2 commits intomasterfrom
copilot/rebase-latest-code
Mar 23, 2026
Merged

Rebase adaptive topN changes onto latest master and retrigger Actions#35
yanyiwu merged 2 commits intomasterfrom
copilot/rebase-latest-code

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 13, 2026

This updates the adaptive topN work from PR #32 onto the current master so it can be evaluated against the latest repository state. The branch carries the same feature changes on top of the updated base and retriggers the existing GitHub Actions workflow.

  • Rebase onto current base

  • Feature payload preserved

    • Adds Simhasher::getTopN(text) to recommend keyword counts from document length
    • Adds make(text, v64) overload to use the adaptive recommendation automatically
    • Keeps the README guidance and unit coverage for the adaptive path
  • Actions retrigger

    • Pushes the rebased change set on top of the latest base to generate a fresh workflow run against current CI configuration
Simhasher shash(DICT_PATH, HMM_PATH, IDF_PATH, STOP_WORDS_PATH);

uint64_t simhashValue;
shash.make(text, simhashValue);  // adaptive topN

size_t topN = Simhasher::getTopN(text);
shash.make(text, topN, simhashValue);  // explicit recommended topN

💬 Send tasks to Copilot coding agent from Slack and Teams to turn conversations into code. Copilot posts an update in your thread when it's finished.

Co-authored-by: yanyiwu <2162645+yanyiwu@users.noreply.github.com>
Copilot AI changed the title [WIP] Rebase latest code and trigger actions Rebase adaptive topN changes onto latest master and retrigger Actions Mar 13, 2026
Copilot AI requested a review from yanyiwu March 13, 2026 09:39
@yanyiwu yanyiwu marked this pull request as ready for review March 23, 2026 14:49
@yanyiwu yanyiwu merged commit e46fdec into master Mar 23, 2026
@yanyiwu yanyiwu deleted the copilot/rebase-latest-code branch March 23, 2026 14:50
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 0d6faa2d61

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +137 to +139
bool make(const string& text, uint64_t& v64) const
{
return make(text, getTopN(text), v64);
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Avoid a two-argument overload that collides with size_t

On the repo's supported Linux/macOS targets, size_t and uint64_t are the same underlying type, so this new Simhasher::make(const string&, uint64_t&) overload also accepts a size_t lvalue. That turns calls like size_t topN = Simhasher::getTopN(text); shash.make(text, topN); from a compile-time error into a silent runtime bug that overwrites topN with the hash value. Because this is a public header, that source-compatibility change is easy for downstream callers to trip over when refactoring toward the new adaptive API.

Useful? React with 👍 / 👎.

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