Skip to main content

write_prerequisites

Function write_prerequisites 

Source
async fn write_prerequisites(
    conn: &mut PgConnection,
    app_config: &ApplicationConfiguration,
    course_id: Uuid,
    prerequisites: Vec<EditCoursePrerequisite>,
    embeddings: &TextEmbeddings,
) -> ModelResult<()>
Expand description

Saves the course’s prerequisites as listed, deleting the ones left out. Only new and changed prerequisites get new embeddings, taken from embeddings where it has them.