@firebase/ai 2.10.0-canary.742e17a8e → 2.10.0-canary.bfb9accdc
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ai-public.d.ts +85 -3
- package/dist/ai.d.ts +85 -3
- package/dist/esm/index.esm.js +43 -6
- package/dist/esm/index.esm.js.map +1 -1
- package/dist/esm/src/api.d.ts +10 -2
- package/dist/esm/src/models/generative-model.d.ts +5 -0
- package/dist/esm/src/models/imagen-model.d.ts +5 -0
- package/dist/esm/src/models/template-imagen-model.d.ts +4 -1
- package/dist/esm/src/requests/imagen-image-format.d.ts +5 -0
- package/dist/esm/src/types/imagen/requests.d.ts +45 -0
- package/dist/esm/src/types/imagen/responses.d.ts +16 -0
- package/dist/index.cjs.js +43 -6
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.node.cjs.js +43 -6
- package/dist/index.node.cjs.js.map +1 -1
- package/dist/index.node.mjs +43 -6
- package/dist/index.node.mjs.map +1 -1
- package/dist/src/api.d.ts +10 -2
- package/dist/src/models/generative-model.d.ts +5 -0
- package/dist/src/models/imagen-model.d.ts +5 -0
- package/dist/src/models/template-imagen-model.d.ts +4 -1
- package/dist/src/requests/imagen-image-format.d.ts +5 -0
- package/dist/src/types/imagen/requests.d.ts +45 -0
- package/dist/src/types/imagen/responses.d.ts +16 -0
- package/package.json +8 -8
package/dist/ai-public.d.ts
CHANGED
|
@@ -1077,6 +1077,11 @@ export declare function getGenerativeModel(ai: AI, modelParams: ModelParams | Hy
|
|
|
1077
1077
|
*
|
|
1078
1078
|
* Only Imagen 3 models (named `imagen-3.0-*`) are supported.
|
|
1079
1079
|
*
|
|
1080
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1081
|
+
* early as June 2026. As a replacement, you can
|
|
1082
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1083
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1084
|
+
*
|
|
1080
1085
|
* @param ai - An {@link AI} instance.
|
|
1081
1086
|
* @param modelParams - Parameters to use when making Imagen requests.
|
|
1082
1087
|
* @param requestOptions - Additional options to use when making requests.
|
|
@@ -1117,10 +1122,13 @@ export declare function getTemplateGenerativeModel(ai: AI, requestOptions?: Requ
|
|
|
1117
1122
|
* Returns a {@link TemplateImagenModel} class for executing server-side
|
|
1118
1123
|
* Imagen templates.
|
|
1119
1124
|
*
|
|
1125
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1126
|
+
* early as June 2026. As a replacement, you can
|
|
1127
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1128
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1129
|
+
*
|
|
1120
1130
|
* @param ai - An {@link AI} instance.
|
|
1121
1131
|
* @param requestOptions - Additional options to use when making requests.
|
|
1122
|
-
*
|
|
1123
|
-
* @beta
|
|
1124
1132
|
*/
|
|
1125
1133
|
export declare function getTemplateImagenModel(ai: AI, requestOptions?: RequestOptions): TemplateImagenModel;
|
|
1126
1134
|
|
|
@@ -1424,6 +1432,11 @@ export declare interface HybridParams {
|
|
|
1424
1432
|
* See the {@link http://firebase.google.com/docs/vertex-ai/generate-images | documentation }
|
|
1425
1433
|
* for more details and examples of the supported aspect ratios.
|
|
1426
1434
|
*
|
|
1435
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1436
|
+
* early as June 2026. As a replacement, you can
|
|
1437
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1438
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1439
|
+
*
|
|
1427
1440
|
* @public
|
|
1428
1441
|
*/
|
|
1429
1442
|
export declare const ImagenAspectRatio: {
|
|
@@ -1458,6 +1471,11 @@ export declare const ImagenAspectRatio: {
|
|
|
1458
1471
|
* See the {@link http://firebase.google.com/docs/vertex-ai/generate-images | documentation }
|
|
1459
1472
|
* for more details and examples of the supported aspect ratios.
|
|
1460
1473
|
*
|
|
1474
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1475
|
+
* early as June 2026. As a replacement, you can
|
|
1476
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1477
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1478
|
+
*
|
|
1461
1479
|
* @public
|
|
1462
1480
|
*/
|
|
1463
1481
|
export declare type ImagenAspectRatio = (typeof ImagenAspectRatio)[keyof typeof ImagenAspectRatio];
|
|
@@ -1466,6 +1484,12 @@ export declare type ImagenAspectRatio = (typeof ImagenAspectRatio)[keyof typeof
|
|
|
1466
1484
|
* An image generated by Imagen, stored in a Cloud Storage for Firebase bucket.
|
|
1467
1485
|
*
|
|
1468
1486
|
* This feature is not available yet.
|
|
1487
|
+
*
|
|
1488
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1489
|
+
* early as June 2026. As a replacement, you can
|
|
1490
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1491
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1492
|
+
*
|
|
1469
1493
|
* @public
|
|
1470
1494
|
*/
|
|
1471
1495
|
export declare interface ImagenGCSImage {
|
|
@@ -1489,6 +1513,11 @@ export declare interface ImagenGCSImage {
|
|
|
1489
1513
|
* See the {@link http://firebase.google.com/docs/vertex-ai/generate-images-imagen | documentation} for
|
|
1490
1514
|
* more details.
|
|
1491
1515
|
*
|
|
1516
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1517
|
+
* early as June 2026. As a replacement, you can
|
|
1518
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1519
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1520
|
+
*
|
|
1492
1521
|
* @public
|
|
1493
1522
|
*/
|
|
1494
1523
|
export declare interface ImagenGenerationConfig {
|
|
@@ -1541,6 +1570,11 @@ export declare interface ImagenGenerationConfig {
|
|
|
1541
1570
|
/**
|
|
1542
1571
|
* The response from a request to generate images with Imagen.
|
|
1543
1572
|
*
|
|
1573
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1574
|
+
* early as June 2026. As a replacement, you can
|
|
1575
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1576
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1577
|
+
*
|
|
1544
1578
|
* @public
|
|
1545
1579
|
*/
|
|
1546
1580
|
export declare interface ImagenGenerationResponse<T extends ImagenInlineImage | ImagenGCSImage> {
|
|
@@ -1596,6 +1630,11 @@ export declare interface ImagenGenerationResponse<T extends ImagenInlineImage |
|
|
|
1596
1630
|
* }
|
|
1597
1631
|
* ```
|
|
1598
1632
|
*
|
|
1633
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1634
|
+
* early as June 2026. As a replacement, you can
|
|
1635
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1636
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1637
|
+
*
|
|
1599
1638
|
* @public
|
|
1600
1639
|
*/
|
|
1601
1640
|
export declare class ImagenImageFormat {
|
|
@@ -1646,6 +1685,11 @@ export declare class ImagenImageFormat {
|
|
|
1646
1685
|
/**
|
|
1647
1686
|
* An image generated by Imagen, represented as inline data.
|
|
1648
1687
|
*
|
|
1688
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1689
|
+
* early as June 2026. As a replacement, you can
|
|
1690
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1691
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1692
|
+
*
|
|
1649
1693
|
* @public
|
|
1650
1694
|
*/
|
|
1651
1695
|
export declare interface ImagenInlineImage {
|
|
@@ -1681,6 +1725,11 @@ export declare interface ImagenInlineImage {
|
|
|
1681
1725
|
* }
|
|
1682
1726
|
* ```
|
|
1683
1727
|
*
|
|
1728
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1729
|
+
* early as June 2026. As a replacement, you can
|
|
1730
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1731
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1732
|
+
*
|
|
1684
1733
|
* @public
|
|
1685
1734
|
*/
|
|
1686
1735
|
export declare class ImagenModel extends AIModel {
|
|
@@ -1729,6 +1778,11 @@ export declare class ImagenModel extends AIModel {
|
|
|
1729
1778
|
/**
|
|
1730
1779
|
* Parameters for configuring an {@link ImagenModel}.
|
|
1731
1780
|
*
|
|
1781
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1782
|
+
* early as June 2026. As a replacement, you can
|
|
1783
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1784
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1785
|
+
*
|
|
1732
1786
|
* @public
|
|
1733
1787
|
*/
|
|
1734
1788
|
export declare interface ImagenModelParams {
|
|
@@ -1758,6 +1812,11 @@ export declare interface ImagenModelParams {
|
|
|
1758
1812
|
* See the <a href="http://firebase.google.com/docs/vertex-ai/generate-images">personGeneration</a>
|
|
1759
1813
|
* documentation for more details.
|
|
1760
1814
|
*
|
|
1815
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1816
|
+
* early as June 2026. As a replacement, you can
|
|
1817
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1818
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1819
|
+
*
|
|
1761
1820
|
* @public
|
|
1762
1821
|
*/
|
|
1763
1822
|
export declare const ImagenPersonFilterLevel: {
|
|
@@ -1789,6 +1848,11 @@ export declare const ImagenPersonFilterLevel: {
|
|
|
1789
1848
|
* See the <a href="http://firebase.google.com/docs/vertex-ai/generate-images">personGeneration</a>
|
|
1790
1849
|
* documentation for more details.
|
|
1791
1850
|
*
|
|
1851
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1852
|
+
* early as June 2026. As a replacement, you can
|
|
1853
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1854
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1855
|
+
*
|
|
1792
1856
|
* @public
|
|
1793
1857
|
*/
|
|
1794
1858
|
export declare type ImagenPersonFilterLevel = (typeof ImagenPersonFilterLevel)[keyof typeof ImagenPersonFilterLevel];
|
|
@@ -1803,6 +1867,11 @@ export declare type ImagenPersonFilterLevel = (typeof ImagenPersonFilterLevel)[k
|
|
|
1803
1867
|
* and the {@link https://cloud.google.com/vertex-ai/generative-ai/docs/image/responsible-ai-imagen#safety-filters | Responsible AI and usage guidelines}
|
|
1804
1868
|
* for more details.
|
|
1805
1869
|
*
|
|
1870
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1871
|
+
* early as June 2026. As a replacement, you can
|
|
1872
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1873
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1874
|
+
*
|
|
1806
1875
|
* @public
|
|
1807
1876
|
*/
|
|
1808
1877
|
export declare const ImagenSafetyFilterLevel: {
|
|
@@ -1837,6 +1906,11 @@ export declare const ImagenSafetyFilterLevel: {
|
|
|
1837
1906
|
* and the {@link https://cloud.google.com/vertex-ai/generative-ai/docs/image/responsible-ai-imagen#safety-filters | Responsible AI and usage guidelines}
|
|
1838
1907
|
* for more details.
|
|
1839
1908
|
*
|
|
1909
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1910
|
+
* early as June 2026. As a replacement, you can
|
|
1911
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1912
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1913
|
+
*
|
|
1840
1914
|
* @public
|
|
1841
1915
|
*/
|
|
1842
1916
|
export declare type ImagenSafetyFilterLevel = (typeof ImagenSafetyFilterLevel)[keyof typeof ImagenSafetyFilterLevel];
|
|
@@ -1847,6 +1921,11 @@ export declare type ImagenSafetyFilterLevel = (typeof ImagenSafetyFilterLevel)[k
|
|
|
1847
1921
|
* See the {@link http://firebase.google.com/docs/vertex-ai/generate-images | documentation }
|
|
1848
1922
|
* for more details.
|
|
1849
1923
|
*
|
|
1924
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1925
|
+
* early as June 2026. As a replacement, you can
|
|
1926
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1927
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1928
|
+
*
|
|
1850
1929
|
* @public
|
|
1851
1930
|
*/
|
|
1852
1931
|
export declare interface ImagenSafetySettings {
|
|
@@ -3084,7 +3163,10 @@ export declare class TemplateGenerativeModel {
|
|
|
3084
3163
|
*
|
|
3085
3164
|
* This class should only be instantiated with {@link getTemplateImagenModel}.
|
|
3086
3165
|
*
|
|
3087
|
-
* @
|
|
3166
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
3167
|
+
* early as June 2026. As a replacement, you can
|
|
3168
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
3169
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
3088
3170
|
*/
|
|
3089
3171
|
export declare class TemplateImagenModel {
|
|
3090
3172
|
/* Excluded from this release type: _apiSettings */
|
package/dist/ai.d.ts
CHANGED
|
@@ -1162,6 +1162,11 @@ export declare function getGenerativeModel(ai: AI, modelParams: ModelParams | Hy
|
|
|
1162
1162
|
*
|
|
1163
1163
|
* Only Imagen 3 models (named `imagen-3.0-*`) are supported.
|
|
1164
1164
|
*
|
|
1165
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1166
|
+
* early as June 2026. As a replacement, you can
|
|
1167
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1168
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1169
|
+
*
|
|
1165
1170
|
* @param ai - An {@link AI} instance.
|
|
1166
1171
|
* @param modelParams - Parameters to use when making Imagen requests.
|
|
1167
1172
|
* @param requestOptions - Additional options to use when making requests.
|
|
@@ -1202,10 +1207,13 @@ export declare function getTemplateGenerativeModel(ai: AI, requestOptions?: Requ
|
|
|
1202
1207
|
* Returns a {@link TemplateImagenModel} class for executing server-side
|
|
1203
1208
|
* Imagen templates.
|
|
1204
1209
|
*
|
|
1210
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1211
|
+
* early as June 2026. As a replacement, you can
|
|
1212
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1213
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1214
|
+
*
|
|
1205
1215
|
* @param ai - An {@link AI} instance.
|
|
1206
1216
|
* @param requestOptions - Additional options to use when making requests.
|
|
1207
|
-
*
|
|
1208
|
-
* @beta
|
|
1209
1217
|
*/
|
|
1210
1218
|
export declare function getTemplateImagenModel(ai: AI, requestOptions?: RequestOptions): TemplateImagenModel;
|
|
1211
1219
|
|
|
@@ -1550,6 +1558,11 @@ export declare interface HybridParams {
|
|
|
1550
1558
|
* See the {@link http://firebase.google.com/docs/vertex-ai/generate-images | documentation }
|
|
1551
1559
|
* for more details and examples of the supported aspect ratios.
|
|
1552
1560
|
*
|
|
1561
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1562
|
+
* early as June 2026. As a replacement, you can
|
|
1563
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1564
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1565
|
+
*
|
|
1553
1566
|
* @public
|
|
1554
1567
|
*/
|
|
1555
1568
|
export declare const ImagenAspectRatio: {
|
|
@@ -1584,6 +1597,11 @@ export declare const ImagenAspectRatio: {
|
|
|
1584
1597
|
* See the {@link http://firebase.google.com/docs/vertex-ai/generate-images | documentation }
|
|
1585
1598
|
* for more details and examples of the supported aspect ratios.
|
|
1586
1599
|
*
|
|
1600
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1601
|
+
* early as June 2026. As a replacement, you can
|
|
1602
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1603
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1604
|
+
*
|
|
1587
1605
|
* @public
|
|
1588
1606
|
*/
|
|
1589
1607
|
export declare type ImagenAspectRatio = (typeof ImagenAspectRatio)[keyof typeof ImagenAspectRatio];
|
|
@@ -1592,6 +1610,12 @@ export declare type ImagenAspectRatio = (typeof ImagenAspectRatio)[keyof typeof
|
|
|
1592
1610
|
* An image generated by Imagen, stored in a Cloud Storage for Firebase bucket.
|
|
1593
1611
|
*
|
|
1594
1612
|
* This feature is not available yet.
|
|
1613
|
+
*
|
|
1614
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1615
|
+
* early as June 2026. As a replacement, you can
|
|
1616
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1617
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1618
|
+
*
|
|
1595
1619
|
* @public
|
|
1596
1620
|
*/
|
|
1597
1621
|
export declare interface ImagenGCSImage {
|
|
@@ -1615,6 +1639,11 @@ export declare interface ImagenGCSImage {
|
|
|
1615
1639
|
* See the {@link http://firebase.google.com/docs/vertex-ai/generate-images-imagen | documentation} for
|
|
1616
1640
|
* more details.
|
|
1617
1641
|
*
|
|
1642
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1643
|
+
* early as June 2026. As a replacement, you can
|
|
1644
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1645
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1646
|
+
*
|
|
1618
1647
|
* @public
|
|
1619
1648
|
*/
|
|
1620
1649
|
export declare interface ImagenGenerationConfig {
|
|
@@ -1667,6 +1696,11 @@ export declare interface ImagenGenerationConfig {
|
|
|
1667
1696
|
/**
|
|
1668
1697
|
* The response from a request to generate images with Imagen.
|
|
1669
1698
|
*
|
|
1699
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1700
|
+
* early as June 2026. As a replacement, you can
|
|
1701
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1702
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1703
|
+
*
|
|
1670
1704
|
* @public
|
|
1671
1705
|
*/
|
|
1672
1706
|
export declare interface ImagenGenerationResponse<T extends ImagenInlineImage | ImagenGCSImage> {
|
|
@@ -1722,6 +1756,11 @@ export declare interface ImagenGenerationResponse<T extends ImagenInlineImage |
|
|
|
1722
1756
|
* }
|
|
1723
1757
|
* ```
|
|
1724
1758
|
*
|
|
1759
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1760
|
+
* early as June 2026. As a replacement, you can
|
|
1761
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1762
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1763
|
+
*
|
|
1725
1764
|
* @public
|
|
1726
1765
|
*/
|
|
1727
1766
|
export declare class ImagenImageFormat {
|
|
@@ -1772,6 +1811,11 @@ export declare class ImagenImageFormat {
|
|
|
1772
1811
|
/**
|
|
1773
1812
|
* An image generated by Imagen, represented as inline data.
|
|
1774
1813
|
*
|
|
1814
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1815
|
+
* early as June 2026. As a replacement, you can
|
|
1816
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1817
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1818
|
+
*
|
|
1775
1819
|
* @public
|
|
1776
1820
|
*/
|
|
1777
1821
|
export declare interface ImagenInlineImage {
|
|
@@ -1807,6 +1851,11 @@ export declare interface ImagenInlineImage {
|
|
|
1807
1851
|
* }
|
|
1808
1852
|
* ```
|
|
1809
1853
|
*
|
|
1854
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1855
|
+
* early as June 2026. As a replacement, you can
|
|
1856
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1857
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1858
|
+
*
|
|
1810
1859
|
* @public
|
|
1811
1860
|
*/
|
|
1812
1861
|
export declare class ImagenModel extends AIModel {
|
|
@@ -1874,6 +1923,11 @@ export declare class ImagenModel extends AIModel {
|
|
|
1874
1923
|
/**
|
|
1875
1924
|
* Parameters for configuring an {@link ImagenModel}.
|
|
1876
1925
|
*
|
|
1926
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1927
|
+
* early as June 2026. As a replacement, you can
|
|
1928
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1929
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1930
|
+
*
|
|
1877
1931
|
* @public
|
|
1878
1932
|
*/
|
|
1879
1933
|
export declare interface ImagenModelParams {
|
|
@@ -1903,6 +1957,11 @@ export declare interface ImagenModelParams {
|
|
|
1903
1957
|
* See the <a href="http://firebase.google.com/docs/vertex-ai/generate-images">personGeneration</a>
|
|
1904
1958
|
* documentation for more details.
|
|
1905
1959
|
*
|
|
1960
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1961
|
+
* early as June 2026. As a replacement, you can
|
|
1962
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1963
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
1964
|
+
*
|
|
1906
1965
|
* @public
|
|
1907
1966
|
*/
|
|
1908
1967
|
export declare const ImagenPersonFilterLevel: {
|
|
@@ -1934,6 +1993,11 @@ export declare const ImagenPersonFilterLevel: {
|
|
|
1934
1993
|
* See the <a href="http://firebase.google.com/docs/vertex-ai/generate-images">personGeneration</a>
|
|
1935
1994
|
* documentation for more details.
|
|
1936
1995
|
*
|
|
1996
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
1997
|
+
* early as June 2026. As a replacement, you can
|
|
1998
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
1999
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
2000
|
+
*
|
|
1937
2001
|
* @public
|
|
1938
2002
|
*/
|
|
1939
2003
|
export declare type ImagenPersonFilterLevel = (typeof ImagenPersonFilterLevel)[keyof typeof ImagenPersonFilterLevel];
|
|
@@ -1948,6 +2012,11 @@ export declare type ImagenPersonFilterLevel = (typeof ImagenPersonFilterLevel)[k
|
|
|
1948
2012
|
* and the {@link https://cloud.google.com/vertex-ai/generative-ai/docs/image/responsible-ai-imagen#safety-filters | Responsible AI and usage guidelines}
|
|
1949
2013
|
* for more details.
|
|
1950
2014
|
*
|
|
2015
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
2016
|
+
* early as June 2026. As a replacement, you can
|
|
2017
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
2018
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
2019
|
+
*
|
|
1951
2020
|
* @public
|
|
1952
2021
|
*/
|
|
1953
2022
|
export declare const ImagenSafetyFilterLevel: {
|
|
@@ -1982,6 +2051,11 @@ export declare const ImagenSafetyFilterLevel: {
|
|
|
1982
2051
|
* and the {@link https://cloud.google.com/vertex-ai/generative-ai/docs/image/responsible-ai-imagen#safety-filters | Responsible AI and usage guidelines}
|
|
1983
2052
|
* for more details.
|
|
1984
2053
|
*
|
|
2054
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
2055
|
+
* early as June 2026. As a replacement, you can
|
|
2056
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
2057
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
2058
|
+
*
|
|
1985
2059
|
* @public
|
|
1986
2060
|
*/
|
|
1987
2061
|
export declare type ImagenSafetyFilterLevel = (typeof ImagenSafetyFilterLevel)[keyof typeof ImagenSafetyFilterLevel];
|
|
@@ -1992,6 +2066,11 @@ export declare type ImagenSafetyFilterLevel = (typeof ImagenSafetyFilterLevel)[k
|
|
|
1992
2066
|
* See the {@link http://firebase.google.com/docs/vertex-ai/generate-images | documentation }
|
|
1993
2067
|
* for more details.
|
|
1994
2068
|
*
|
|
2069
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
2070
|
+
* early as June 2026. As a replacement, you can
|
|
2071
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
2072
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
2073
|
+
*
|
|
1995
2074
|
* @public
|
|
1996
2075
|
*/
|
|
1997
2076
|
export declare interface ImagenSafetySettings {
|
|
@@ -3259,7 +3338,10 @@ export declare class TemplateGenerativeModel {
|
|
|
3259
3338
|
*
|
|
3260
3339
|
* This class should only be instantiated with {@link getTemplateImagenModel}.
|
|
3261
3340
|
*
|
|
3262
|
-
* @
|
|
3341
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
3342
|
+
* early as June 2026. As a replacement, you can
|
|
3343
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
3344
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
3263
3345
|
*/
|
|
3264
3346
|
export declare class TemplateImagenModel {
|
|
3265
3347
|
/**
|
package/dist/esm/index.esm.js
CHANGED
|
@@ -4,7 +4,7 @@ import { FirebaseError, Deferred, getModularInstance } from '@firebase/util';
|
|
|
4
4
|
import { Logger } from '@firebase/logger';
|
|
5
5
|
|
|
6
6
|
var name = "@firebase/ai";
|
|
7
|
-
var version = "2.10.0-canary.
|
|
7
|
+
var version = "2.10.0-canary.bfb9accdc";
|
|
8
8
|
|
|
9
9
|
/**
|
|
10
10
|
* @license
|
|
@@ -605,6 +605,11 @@ const SchemaType = {
|
|
|
605
605
|
* and the {@link https://cloud.google.com/vertex-ai/generative-ai/docs/image/responsible-ai-imagen#safety-filters | Responsible AI and usage guidelines}
|
|
606
606
|
* for more details.
|
|
607
607
|
*
|
|
608
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
609
|
+
* early as June 2026. As a replacement, you can
|
|
610
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
611
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
612
|
+
*
|
|
608
613
|
* @public
|
|
609
614
|
*/
|
|
610
615
|
const ImagenSafetyFilterLevel = {
|
|
@@ -634,6 +639,11 @@ const ImagenSafetyFilterLevel = {
|
|
|
634
639
|
* See the <a href="http://firebase.google.com/docs/vertex-ai/generate-images">personGeneration</a>
|
|
635
640
|
* documentation for more details.
|
|
636
641
|
*
|
|
642
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
643
|
+
* early as June 2026. As a replacement, you can
|
|
644
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
645
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
646
|
+
*
|
|
637
647
|
* @public
|
|
638
648
|
*/
|
|
639
649
|
const ImagenPersonFilterLevel = {
|
|
@@ -667,6 +677,11 @@ const ImagenPersonFilterLevel = {
|
|
|
667
677
|
* See the {@link http://firebase.google.com/docs/vertex-ai/generate-images | documentation }
|
|
668
678
|
* for more details and examples of the supported aspect ratios.
|
|
669
679
|
*
|
|
680
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
681
|
+
* early as June 2026. As a replacement, you can
|
|
682
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
683
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
684
|
+
*
|
|
670
685
|
* @public
|
|
671
686
|
*/
|
|
672
687
|
const ImagenAspectRatio = {
|
|
@@ -3142,8 +3157,9 @@ function validateGenerationConfig(generationConfig) {
|
|
|
3142
3157
|
}
|
|
3143
3158
|
if ((generationConfig.responseSchema != null ||
|
|
3144
3159
|
generationConfig.responseJsonSchema != null) &&
|
|
3145
|
-
generationConfig.responseMimeType) {
|
|
3146
|
-
throw new AIError(AIErrorCode.UNSUPPORTED, `responseMimeType must be set
|
|
3160
|
+
generationConfig.responseMimeType !== 'application/json') {
|
|
3161
|
+
throw new AIError(AIErrorCode.UNSUPPORTED, `responseMimeType must be set to "application/json" if` +
|
|
3162
|
+
` responseSchema or responseJsonSchema are set.`);
|
|
3147
3163
|
}
|
|
3148
3164
|
}
|
|
3149
3165
|
|
|
@@ -3575,6 +3591,11 @@ class LiveGenerativeModel extends AIModel {
|
|
|
3575
3591
|
* }
|
|
3576
3592
|
* ```
|
|
3577
3593
|
*
|
|
3594
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
3595
|
+
* early as June 2026. As a replacement, you can
|
|
3596
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
3597
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
3598
|
+
*
|
|
3578
3599
|
* @public
|
|
3579
3600
|
*/
|
|
3580
3601
|
class ImagenModel extends AIModel {
|
|
@@ -3906,7 +3927,10 @@ class TemplateGenerativeModel {
|
|
|
3906
3927
|
*
|
|
3907
3928
|
* This class should only be instantiated with {@link getTemplateImagenModel}.
|
|
3908
3929
|
*
|
|
3909
|
-
* @
|
|
3930
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
3931
|
+
* early as June 2026. As a replacement, you can
|
|
3932
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
3933
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
3910
3934
|
*/
|
|
3911
3935
|
class TemplateImagenModel {
|
|
3912
3936
|
/**
|
|
@@ -4215,6 +4239,11 @@ class AnyOfSchema extends Schema {
|
|
|
4215
4239
|
* }
|
|
4216
4240
|
* ```
|
|
4217
4241
|
*
|
|
4242
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
4243
|
+
* early as June 2026. As a replacement, you can
|
|
4244
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
4245
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
4246
|
+
*
|
|
4218
4247
|
* @public
|
|
4219
4248
|
*/
|
|
4220
4249
|
class ImagenImageFormat {
|
|
@@ -4715,6 +4744,11 @@ function getGenerativeModel(ai, modelParams, requestOptions) {
|
|
|
4715
4744
|
*
|
|
4716
4745
|
* Only Imagen 3 models (named `imagen-3.0-*`) are supported.
|
|
4717
4746
|
*
|
|
4747
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
4748
|
+
* early as June 2026. As a replacement, you can
|
|
4749
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
4750
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
4751
|
+
*
|
|
4718
4752
|
* @param ai - An {@link AI} instance.
|
|
4719
4753
|
* @param modelParams - Parameters to use when making Imagen requests.
|
|
4720
4754
|
* @param requestOptions - Additional options to use when making requests.
|
|
@@ -4765,10 +4799,13 @@ function getTemplateGenerativeModel(ai, requestOptions) {
|
|
|
4765
4799
|
* Returns a {@link TemplateImagenModel} class for executing server-side
|
|
4766
4800
|
* Imagen templates.
|
|
4767
4801
|
*
|
|
4802
|
+
* @deprecated All Imagen models are deprecated and will shut down as
|
|
4803
|
+
* early as June 2026. As a replacement, you can
|
|
4804
|
+
* {@link https://firebase.google.com/docs/ai-logic/imagen-models-migration |
|
|
4805
|
+
* migrate your apps to use Gemini Image models (the "Nano Banana" models)}.
|
|
4806
|
+
*
|
|
4768
4807
|
* @param ai - An {@link AI} instance.
|
|
4769
4808
|
* @param requestOptions - Additional options to use when making requests.
|
|
4770
|
-
*
|
|
4771
|
-
* @beta
|
|
4772
4809
|
*/
|
|
4773
4810
|
function getTemplateImagenModel(ai, requestOptions) {
|
|
4774
4811
|
return new TemplateImagenModel(ai, requestOptions);
|