NAME

MCP::Server::KnowledgeStore::Command::rebuild_vectors - Rebuild the TF-IDF vectors used by search tools

VERSION

version 0.001

SYNOPSIS

./bin/mcp-ks rebuild_vectors
./bin/mcp-ks rebuild_vectors --kind=memory
./bin/mcp-ks rebuild_vectors --all

DESCRIPTION

Rebuilds the TF-IDF vectors used by the search_* tools.

This command:

  • Clears existing vector cache

  • Computes corpus-wide IDF from all latest revisions

  • Computes and stores TF-IDF vectors for each latest revision

Only LATEST REVISIONS (those referenced by entries.head_id) are processed. Historical revisions are ignored.

Run this after initial deployment, or whenever you want to refresh the vector cache (e.g., after importing a large amount of data).

NAME

MCP::Server::KnowledgeStore::Command::rebuild_vectors - Rebuild TF-IDF vectors for hybrid search

OPTIONS

--kind=KIND

Rebuild vectors only for the specified kind. Can be 'memory', 'skill', or 'spec'. Default: rebuilds all kinds.

--all

Rebuild vectors for all kinds (memory, skill, spec). This is the default.

SEE ALSO

MCP::Server::KnowledgeStore::Store, MCP::Server::KnowledgeStore::TermWeight

AUTHOR

Wesley Schwengle <waterkip@cpan.org>

COPYRIGHT AND LICENSE

This software is Copyright (c) 2026 by Wesley Schwengle.

This is free software, licensed under:

The (three-clause) BSD License