diff --git a/frontend/rust-lib/flowy-database2/src/manager.rs b/frontend/rust-lib/flowy-database2/src/manager.rs index 21858ad201..77d9a477bc 100644 --- a/frontend/rust-lib/flowy-database2/src/manager.rs +++ b/frontend/rust-lib/flowy-database2/src/manager.rs @@ -424,15 +424,19 @@ impl DatabaseManager { if let Some(row) = database.get_row(&view_id, &row_id) { let fields = database.get_fields(&view_id, None); for field in fields { - if let Some(cell) = row.cells.get(&field.id) { - summary_row_content.insert(field.name.clone(), stringify_cell(cell, &field)); + // When summarizing a row, skip the content in the "AI summary" cell; it does not need to + // be summarized. + if field.id != field_id { + if let Some(cell) = row.cells.get(&field.id) { + summary_row_content.insert(field.name.clone(), stringify_cell(cell, &field)); + } } } } // Call the cloud service to summarize the row. trace!( - "[AI]: summarize row:{}, content:{:?}", + "[AI]:summarize row:{}, content:{:?}", row_id, summary_row_content );