Skip to content
Snippets Groups Projects
This project is mirrored from https://github.com/aurelio-labs/semantic-router. Pull mirroring updated .
  1. Feb 23, 2024
  2. Feb 16, 2024
  3. Feb 15, 2024
  4. Feb 14, 2024
  5. Feb 13, 2024
    • James Briggs's avatar
      lint · 66a7c794
      James Briggs authored
      66a7c794
    • James Briggs's avatar
      fix tests · b9a4f2c4
      James Briggs authored
      b9a4f2c4
    • James Briggs's avatar
      fix tests and code · cbf7e977
      James Briggs authored
      cbf7e977
    • Siraj R Aizlewood's avatar
      New PyTests · f7f07676
      Siraj R Aizlewood authored
      And some improvements where we make sure that temp files are definitely deleted after use.
      f7f07676
    • Siraj R Aizlewood's avatar
      b7721f50
    • Siraj R Aizlewood's avatar
      Linting. · 59600647
      Siraj R Aizlewood authored
      59600647
    • Siraj R Aizlewood's avatar
      Bug Fix Saving JSON/YAML of Layer Config · 8d2de77e
      Siraj R Aizlewood authored
      Saving Layer Configs as JSON or YAML config files by representing the LayerConfig object as a dict and then turning into JSON/YAML wasn't working.
      
      See issue here: https://github.com/aurelio-labs/semantic-router/issues/144
      
      The issue was that, by attempting this, we were attempting to serialize all objects included in the Layer, including Routes, and the LLMs that those Routes use.
      
      In the case of the above issue, the LLM was a Cohere one, which included a Client as one of its attributes, and this Client is not serializable.
      
      So, instead of attempting to represent the entire LLM object a dict, to then be converted into JSON/YAML, we only keep key information about the LLM:
      
      'module': self.llm.__module__,
      'class': self.llm.__class__.__name__,
      'model': self.llm.name
      
      This is what's saved in route.py, and then sent to layer.py to be serialized (in LayerConfig.to_file()).
      
      Then, when it comes time to load from the file via LayerConfig.from_file, the LLM is re-initialized dynamically.
      8d2de77e
  6. Feb 12, 2024
  7. Feb 11, 2024
Loading