aurelio-labs/semantic-router

Routes saved, but encoder_name is not what I expected

Closed this issue · 2 comments

in my code:
encoder = OpenAIEncoder( name="text-embedding-3-small", score_threshold=0.5, dimensions=1536 ) encoder = OpenAIEncoder() rl = RouteLayer(encoder=encoder, routes=routes)
then I save it
rl.to_json("testsave.json")

but then in the json file...
"encoder_name": "text-embedding-ada-002",

I was expecting the encoder name to be saved as text-embedding-3-small

o poop, I just realized I had encoder defined twice, so of course it fell back to the default ada v2. Sorry. Closing.

as a side note: maybe "text-embedding-3-small" should be the new default, considering the price/quality improvements.