Inject flattened `model` / `usage_*` columns for assistant rows. Values come from `message.model` and `message.usage.*`. A column is only added when the source value exists and the key is not already present at the top level of the record (existing JSON keys always win).
(json: &JsonValue, map: &mut BTreeMap<String, Value>)
| 357 | /// added when the source value exists and the key is not already present at |
| 358 | /// the top level of the record (existing JSON keys always win). |
| 359 | fn flatten_usage_columns(json: &JsonValue, map: &mut BTreeMap<String, Value>) { |
| 360 | for (key, value) in flattened_usage_fields(json) { |
| 361 | if !map.contains_key(key) { |
| 362 | map.insert(key.to_string(), json_value_to_glue_value(value)); |
| 363 | } |
| 364 | } |
| 365 | } |
| 366 | |
| 367 | /// Convert a todo JSON object to a DataRow |
| 368 | fn todo_json_to_data_row( |
no test coverage detected