Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Read embeddings config during bootstrap/load and instance creation #387

Merged
merged 3 commits into from
Sep 5, 2024

Commits on Sep 4, 2024

  1. Read embeddings config during bootstrap/load and instance creation

    When CONFIG_FILES setting is not used, the caikit-nlp config values
    are not read from environment variables unless caikit has already
    imported caikit-nlp.  The code was loading the embedding config too
    soon in this case so the env vars were ignored.
    
    This commit reads the config during bootstrap and load for settings that are needed
    at bootstrap/load time and also reads config during module init for runtime settings.
    
    In addition:
    
    * bootstrap() kwargs can be used (e.g. for trust_remote_code param)
    * load() was made to work with model_path as ModuleConfig (because str is deprecated and spammy)
    * utils/env_val_to_int was removed because the caikit config handles this well
    * utils/env_val_to_bool was NOT YET removed because the caikit config does not handle this quite as well
    
    Signed-off-by: Mark Sturdevant <[email protected]>
    markstur committed Sep 4, 2024
    Configuration menu
    Copy the full SHA
    272eeb1 View commit details
    Browse the repository at this point in the history
  2. Make sure EmbeddingModule load() is not called without a model_path

    ModuleConfig should always have a model_path, but this check will
    make the error better if this gets called with an empty ModuleConfig.
    
    Signed-off-by: Mark Sturdevant <[email protected]>
    markstur committed Sep 4, 2024
    Configuration menu
    Copy the full SHA
    90e0ccb View commit details
    Browse the repository at this point in the history

Commits on Sep 5, 2024

  1. Clarify test

    Signed-off-by: Mark Sturdevant <[email protected]>
    markstur committed Sep 5, 2024
    Configuration menu
    Copy the full SHA
    8488582 View commit details
    Browse the repository at this point in the history