Skip to content

Commit c9b6da8

Browse files
committed
feat!(ai): Remove GroundingAttribution
BREAKING CHANGE
1 parent 5871fd6 commit c9b6da8

File tree

7 files changed

+5
-107
lines changed

7 files changed

+5
-107
lines changed

.changeset/slimy-mirrors-nail.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@firebase/ai': major
3+
---
4+
5+
Remove GroundingAttribution

common/api-review/ai.api.md

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -485,22 +485,8 @@ export interface GoogleAIGenerateContentResponse {
485485
usageMetadata?: UsageMetadata;
486486
}
487487

488-
// @public @deprecated (undocumented)
489-
export interface GroundingAttribution {
490-
// (undocumented)
491-
confidenceScore?: number;
492-
// (undocumented)
493-
retrievedContext?: RetrievedContextAttribution;
494-
// (undocumented)
495-
segment: Segment;
496-
// (undocumented)
497-
web?: WebAttribution;
498-
}
499-
500488
// @public
501489
export interface GroundingMetadata {
502-
// @deprecated (undocumented)
503-
groundingAttributions: GroundingAttribution[];
504490
// (undocumented)
505491
retrievalQueries?: string[];
506492
// (undocumented)

docs-devsite/_toc.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,6 @@ toc:
7676
path: /docs/reference/js/ai.generativemodel.md
7777
- title: GoogleAIBackend
7878
path: /docs/reference/js/ai.googleaibackend.md
79-
- title: GroundingAttribution
80-
path: /docs/reference/js/ai.groundingattribution.md
8179
- title: GroundingMetadata
8280
path: /docs/reference/js/ai.groundingmetadata.md
8381
- title: ImagenGCSImage

docs-devsite/ai.groundingattribution.md

Lines changed: 0 additions & 62 deletions
This file was deleted.

docs-devsite/ai.groundingmetadata.md

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -22,22 +22,9 @@ export interface GroundingMetadata
2222

2323
| Property | Type | Description |
2424
| --- | --- | --- |
25-
| [groundingAttributions](./ai.groundingmetadata.md#groundingmetadatagroundingattributions) | [GroundingAttribution](./ai.groundingattribution.md#groundingattribution_interface)<!-- -->\[\] | |
2625
| [retrievalQueries](./ai.groundingmetadata.md#groundingmetadataretrievalqueries) | string\[\] | |
2726
| [webSearchQueries](./ai.groundingmetadata.md#groundingmetadatawebsearchqueries) | string\[\] | |
2827

29-
## GroundingMetadata.groundingAttributions
30-
31-
> Warning: This API is now obsolete.
32-
>
33-
>
34-
35-
<b>Signature:</b>
36-
37-
```typescript
38-
groundingAttributions: GroundingAttribution[];
39-
```
40-
4128
## GroundingMetadata.retrievalQueries
4229

4330
<b>Signature:</b>

docs-devsite/ai.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,6 @@ The Firebase AI Web SDK.
9595
| [GenerateContentStreamResult](./ai.generatecontentstreamresult.md#generatecontentstreamresult_interface) | Result object returned from [GenerativeModel.generateContentStream()](./ai.generativemodel.md#generativemodelgeneratecontentstream) call. Iterate over <code>stream</code> to get chunks as they come in and/or use the <code>response</code> promise to get the aggregated response when the stream is done. |
9696
| [GenerationConfig](./ai.generationconfig.md#generationconfig_interface) | Config options for content-related requests |
9797
| [GenerativeContentBlob](./ai.generativecontentblob.md#generativecontentblob_interface) | Interface for sending an image. |
98-
| [GroundingAttribution](./ai.groundingattribution.md#groundingattribution_interface) | |
9998
| [GroundingMetadata](./ai.groundingmetadata.md#groundingmetadata_interface) | Metadata returned to client when grounding is enabled. |
10099
| [ImagenGCSImage](./ai.imagengcsimage.md#imagengcsimage_interface) | An image generated by Imagen, stored in a Cloud Storage for Firebase bucket.<!-- -->This feature is not available yet. |
101100
| [ImagenGenerationConfig](./ai.imagengenerationconfig.md#imagengenerationconfig_interface) | <b><i>(Public Preview)</i></b> Configuration options for generating images with Imagen.<!-- -->See the [documentation](http://firebase.google.com/docs/vertex-ai/generate-images-imagen) for more details. |

packages/ai/src/types/responses.ts

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -177,21 +177,6 @@ export interface Citation {
177177
export interface GroundingMetadata {
178178
webSearchQueries?: string[];
179179
retrievalQueries?: string[];
180-
/**
181-
* @deprecated
182-
*/
183-
groundingAttributions: GroundingAttribution[];
184-
}
185-
186-
/**
187-
* @deprecated
188-
* @public
189-
*/
190-
export interface GroundingAttribution {
191-
segment: Segment;
192-
confidenceScore?: number;
193-
web?: WebAttribution;
194-
retrievedContext?: RetrievedContextAttribution;
195180
}
196181

197182
/**

0 commit comments

Comments
 (0)