You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At the moment, the AI proxy is tightly coupled to ahnlich-db. For it to truly be extensible, it would have to be able to
Return embeddings for raw inputs without having to save within DB. For this, we would have to make an extra endpoint that simply does raw input to embedding conversions and hence doesn't need the binary started with a running DB. Currently we have
let db_client = Self::build_db_client(&config).await
...
AIProxyServer{db_client:Arc::new(db_client),
...}// .. where AIProxyServer struct is structAIProxyServer{db_client:Arc<DbClient>,}
and for all queries within the handler that absolutely need it like create_store, throw up an error if db_client is None. Then a new query we can call input_to_embeddings that could look something like
enumAIQuery{InputToEmbeddings{inputs:Vec<StoreInput>,preprocess_action:PreprocessAction,model:AIModel,},
...
}enumAIServerResponse{// Vector of embeddings matching the length of Vec<StoreInput>Embeddings(Vec<Array1<f32>>),
...
}
A check to then ensure that all StoreInput's input type match the AIModel's input type is sufficient... and finally calling ModelManager::handle_request to return the StoreKey
The text was updated successfully, but these errors were encountered:
At the moment, the AI proxy is tightly coupled to ahnlich-db. For it to truly be extensible, it would have to be able to
If that is changed to
and for all queries within the handler that absolutely need it like
create_store
, throw up an error if db_client is None. Then a new query we can callinput_to_embeddings
that could look something likeA check to then ensure that all
StoreInput
's input type match theAIModel
's input type is sufficient... and finally callingModelManager::handle_request
to return the StoreKeyThe text was updated successfully, but these errors were encountered: