File tree Expand file tree Collapse file tree 1 file changed +0
-25
lines changed
Expand file tree Collapse file tree 1 file changed +0
-25
lines changed Original file line number Diff line number Diff line change @@ -213,35 +213,10 @@ def mock_generate_content(
213213 if has_retrieval and (not has_rag_retrieval ) and request .contents [0 ].parts [0 ].text :
214214 grounding_metadata = gapic_content_types .GroundingMetadata (
215215 web_search_queries = [request .contents [0 ].parts [0 ].text ],
216- grounding_attributions = [
217- gapic_content_types .GroundingAttribution (
218- segment = gapic_content_types .Segment (
219- start_index = 0 ,
220- end_index = 67 ,
221- ),
222- confidence_score = 0.69857746 ,
223- web = gapic_content_types .GroundingAttribution .Web (
224- uri = "https://math.ucr.edu/home/baez/physics/General/BlueSky/blue_sky.html" ,
225- title = "Why is the sky blue? - UCR Math" ,
226- ),
227- ),
228- ],
229216 )
230217 elif has_rag_retrieval and request .contents [0 ].parts [0 ].text :
231218 grounding_metadata = gapic_content_types .GroundingMetadata (
232219 retrieval_queries = [request .contents [0 ].parts [0 ].text ],
233- grounding_attributions = [
234- gapic_content_types .GroundingAttribution (
235- retrieved_context = gapic_content_types .GroundingAttribution .RetrievedContext (
236- uri = "gs://my-bucket/my-file.pdf" ,
237- ),
238- segment = gapic_content_types .Segment (
239- start_index = 0 ,
240- end_index = 67 ,
241- ),
242- confidence_score = 0.69857746 ,
243- ),
244- ],
245220 )
246221 else :
247222 grounding_metadata = None
You can’t perform that action at this time.
0 commit comments