Upgrade notebook to gemini 3.6 flash - #165
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates the Jupyter notebook for automated contract risk and compliance review to utilize newer Gemini models, while refining the BigQuery SQL queries and Plotly visualizations. The review feedback identifies a critical bug where querying the data column directly on an Object Table with SIMPLE metadata will fail, suggesting the use of READ_FILE(uri) instead. Additionally, the feedback points out an inconsistency in the configured Gemini model version compared to the markdown documentation, and recommends fully qualifying the connection_id with the PROJECT_ID in the AI.GENERATE function for better robustness.
| "MODEL_ID = \"gemini_3_6_flash\" # @param {type:\"string\"}\n", | ||
| "MODEL_VERSION = \"gemini-3.6-flash\" # @param {type:\"string\"}\n", | ||
| "CONNECTION_CLOUD_RESOURCE_ID = \"cloud-resource-connection\" # @param {type:\"string\"}\n", |
There was a problem hiding this comment.
There is an inconsistency between the model version specified in the configuration parameters (gemini-3.6-flash) and the model version mentioned in the markdown cells (which refer to gemini-3.7-flash in sections 2, 3, and the setup instructions). Please ensure the model version is consistent throughout the notebook.
| " '- Risk Rating: ', COALESCE(CAST(t.RiskScore AS STRING), 'N/A'), '/10\\\\n\\\\n',\n", | ||
| " '**Full Contract Text:**\\\\n', COALESCE(CAST(t.data AS STRING), 'N/A')\n", | ||
| " ),\n", | ||
| " connection_id => '{REGION}.{CONNECTION_CLOUD_RESOURCE_ID}',\n", |
There was a problem hiding this comment.
No description provided.