How To: Upload Evaluation Key
Overview of the Process
import lattica_common.app_api as agent_app
# Notice your query token expires in 30 days
query_token = "the_query_token_you_got_using_the_generate_user_token"
# user_data is a tuple of:
# (serialized_context, serialized_secret_key, serialized_homseq)
# which you need for encrypting the query and querying the model
user_data = agent_app.user.query_offline_phase(query_token)
import { LatticaQueryClient } from 'lattica-query-client';
const client = new LatticaQueryClient('your-jwt-query-token');
// Uploaded the EK
const initialized = await client.init();
if (!initialized) {
console.error('Initialization failed: The EK was not successfully uploaded.');
throw new Error('EK upload failed.');
}
console.log('EK uploaded successfully.');Parameters
Last updated