@genesislcap/foundation-ai 15.33.1 → 15.34.1
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/dts/index.d.ts +4 -0
- package/dist/dts/index.d.ts.map +1 -1
- package/dist/dts/tiers/ai-tiers.d.ts +154 -0
- package/dist/dts/tiers/ai-tiers.d.ts.map +1 -0
- package/dist/dts/tiers/build-tier-providers.d.ts +67 -0
- package/dist/dts/tiers/build-tier-providers.d.ts.map +1 -0
- package/dist/dts/utils/token-cost.d.ts +14 -0
- package/dist/dts/utils/token-cost.d.ts.map +1 -1
- package/dist/esm/index.js +7 -0
- package/dist/esm/tiers/ai-tiers.js +173 -0
- package/dist/esm/tiers/build-tier-providers.js +72 -0
- package/dist/esm/utils/token-cost.js +14 -0
- package/dist/foundation-ai.api.json +1128 -263
- package/dist/foundation-ai.d.ts +191 -0
- package/package.json +10 -10
|
@@ -378,6 +378,52 @@
|
|
|
378
378
|
"endIndex": 0
|
|
379
379
|
}
|
|
380
380
|
},
|
|
381
|
+
{
|
|
382
|
+
"kind": "Variable",
|
|
383
|
+
"canonicalReference": "@genesislcap/foundation-ai!AI_TIER_IDS:var",
|
|
384
|
+
"docComment": "/**\n * Every tier id, in ascending capability order.\n *\n * This array is the source of truth and {@link AITierId} is derived from it, so the two cannot drift: a tier exists exactly when it is listed here. That matters because the provider builders and the table's tests all loop over this array — a tier missing from it would get no provider and no test, with nothing to say so.\n *\n * @beta\n */\n",
|
|
385
|
+
"excerptTokens": [
|
|
386
|
+
{
|
|
387
|
+
"kind": "Content",
|
|
388
|
+
"text": "AI_TIER_IDS: "
|
|
389
|
+
},
|
|
390
|
+
{
|
|
391
|
+
"kind": "Content",
|
|
392
|
+
"text": "readonly [\"low\", \"high\", \"reasoning\"]"
|
|
393
|
+
}
|
|
394
|
+
],
|
|
395
|
+
"fileUrlPath": "src/tiers/ai-tiers.ts",
|
|
396
|
+
"isReadonly": true,
|
|
397
|
+
"releaseTag": "Beta",
|
|
398
|
+
"name": "AI_TIER_IDS",
|
|
399
|
+
"variableTypeTokenRange": {
|
|
400
|
+
"startIndex": 1,
|
|
401
|
+
"endIndex": 2
|
|
402
|
+
}
|
|
403
|
+
},
|
|
404
|
+
{
|
|
405
|
+
"kind": "Variable",
|
|
406
|
+
"canonicalReference": "@genesislcap/foundation-ai!AI_TIER_VENDORS:var",
|
|
407
|
+
"docComment": "/**\n * Every vendor in the table — the two the platform's proxy meters. The source of truth for {@link AITierVendor}, for the same reason as {@link AI_TIER_IDS}.\n *\n * @beta\n */\n",
|
|
408
|
+
"excerptTokens": [
|
|
409
|
+
{
|
|
410
|
+
"kind": "Content",
|
|
411
|
+
"text": "AI_TIER_VENDORS: "
|
|
412
|
+
},
|
|
413
|
+
{
|
|
414
|
+
"kind": "Content",
|
|
415
|
+
"text": "readonly [\"anthropic\", \"gemini\"]"
|
|
416
|
+
}
|
|
417
|
+
],
|
|
418
|
+
"fileUrlPath": "src/tiers/ai-tiers.ts",
|
|
419
|
+
"isReadonly": true,
|
|
420
|
+
"releaseTag": "Beta",
|
|
421
|
+
"name": "AI_TIER_VENDORS",
|
|
422
|
+
"variableTypeTokenRange": {
|
|
423
|
+
"startIndex": 1,
|
|
424
|
+
"endIndex": 2
|
|
425
|
+
}
|
|
426
|
+
},
|
|
381
427
|
{
|
|
382
428
|
"kind": "TypeAlias",
|
|
383
429
|
"canonicalReference": "@genesislcap/foundation-ai!AIConfig:type",
|
|
@@ -1416,149 +1462,108 @@
|
|
|
1416
1462
|
"extendsTokenRanges": []
|
|
1417
1463
|
},
|
|
1418
1464
|
{
|
|
1419
|
-
"kind": "
|
|
1420
|
-
"canonicalReference": "@genesislcap/foundation-ai!
|
|
1421
|
-
"docComment": "/**\n *
|
|
1465
|
+
"kind": "TypeAlias",
|
|
1466
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierId:type",
|
|
1467
|
+
"docComment": "/**\n * The tier a caller asks for, rather than a model id.\n *\n * Tier-shaped names are what let an app swap vendor (or re-bench a tier onto a newer model) without touching a single agent config — agents resolve `'high'`, not `claude-sonnet-5`. Derived from {@link AI_TIER_IDS}.\n *\n * @beta\n */\n",
|
|
1422
1468
|
"excerptTokens": [
|
|
1423
1469
|
{
|
|
1424
1470
|
"kind": "Content",
|
|
1425
|
-
"text": "
|
|
1471
|
+
"text": "export type AITierId = "
|
|
1426
1472
|
},
|
|
1427
1473
|
{
|
|
1428
1474
|
"kind": "Content",
|
|
1429
|
-
"text": "
|
|
1430
|
-
}
|
|
1431
|
-
],
|
|
1432
|
-
"fileUrlPath": "src/utils/token-cost.ts",
|
|
1433
|
-
"initializerTokenRange": {
|
|
1434
|
-
"startIndex": 1,
|
|
1435
|
-
"endIndex": 2
|
|
1436
|
-
},
|
|
1437
|
-
"isReadonly": true,
|
|
1438
|
-
"releaseTag": "Beta",
|
|
1439
|
-
"name": "ANTHROPIC_CACHE_READ_MULTIPLIER",
|
|
1440
|
-
"variableTypeTokenRange": {
|
|
1441
|
-
"startIndex": 0,
|
|
1442
|
-
"endIndex": 0
|
|
1443
|
-
}
|
|
1444
|
-
},
|
|
1445
|
-
{
|
|
1446
|
-
"kind": "Variable",
|
|
1447
|
-
"canonicalReference": "@genesislcap/foundation-ai!ANTHROPIC_CACHE_WRITE_1H_MULTIPLIER:var",
|
|
1448
|
-
"docComment": "/**\n * @beta\n */\n",
|
|
1449
|
-
"excerptTokens": [
|
|
1450
|
-
{
|
|
1451
|
-
"kind": "Content",
|
|
1452
|
-
"text": "ANTHROPIC_CACHE_WRITE_1H_MULTIPLIER = "
|
|
1475
|
+
"text": "(typeof "
|
|
1453
1476
|
},
|
|
1454
1477
|
{
|
|
1455
|
-
"kind": "
|
|
1456
|
-
"text": "
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
"fileUrlPath": "src/utils/token-cost.ts",
|
|
1460
|
-
"initializerTokenRange": {
|
|
1461
|
-
"startIndex": 1,
|
|
1462
|
-
"endIndex": 2
|
|
1463
|
-
},
|
|
1464
|
-
"isReadonly": true,
|
|
1465
|
-
"releaseTag": "Beta",
|
|
1466
|
-
"name": "ANTHROPIC_CACHE_WRITE_1H_MULTIPLIER",
|
|
1467
|
-
"variableTypeTokenRange": {
|
|
1468
|
-
"startIndex": 0,
|
|
1469
|
-
"endIndex": 0
|
|
1470
|
-
}
|
|
1471
|
-
},
|
|
1472
|
-
{
|
|
1473
|
-
"kind": "Variable",
|
|
1474
|
-
"canonicalReference": "@genesislcap/foundation-ai!ANTHROPIC_CACHE_WRITE_5M_MULTIPLIER:var",
|
|
1475
|
-
"docComment": "/**\n * @beta\n */\n",
|
|
1476
|
-
"excerptTokens": [
|
|
1478
|
+
"kind": "Reference",
|
|
1479
|
+
"text": "AI_TIER_IDS",
|
|
1480
|
+
"canonicalReference": "@genesislcap/foundation-ai!AI_TIER_IDS:var"
|
|
1481
|
+
},
|
|
1477
1482
|
{
|
|
1478
1483
|
"kind": "Content",
|
|
1479
|
-
"text": "
|
|
1484
|
+
"text": ")[number]"
|
|
1480
1485
|
},
|
|
1481
1486
|
{
|
|
1482
1487
|
"kind": "Content",
|
|
1483
|
-
"text": "
|
|
1488
|
+
"text": ";"
|
|
1484
1489
|
}
|
|
1485
1490
|
],
|
|
1486
|
-
"fileUrlPath": "src/
|
|
1487
|
-
"initializerTokenRange": {
|
|
1488
|
-
"startIndex": 1,
|
|
1489
|
-
"endIndex": 2
|
|
1490
|
-
},
|
|
1491
|
-
"isReadonly": true,
|
|
1491
|
+
"fileUrlPath": "src/tiers/ai-tiers.ts",
|
|
1492
1492
|
"releaseTag": "Beta",
|
|
1493
|
-
"name": "
|
|
1494
|
-
"
|
|
1495
|
-
"startIndex":
|
|
1496
|
-
"endIndex":
|
|
1493
|
+
"name": "AITierId",
|
|
1494
|
+
"typeTokenRange": {
|
|
1495
|
+
"startIndex": 1,
|
|
1496
|
+
"endIndex": 4
|
|
1497
1497
|
}
|
|
1498
1498
|
},
|
|
1499
1499
|
{
|
|
1500
1500
|
"kind": "Interface",
|
|
1501
|
-
"canonicalReference": "@genesislcap/foundation-ai!
|
|
1502
|
-
"docComment": "/**\n *
|
|
1501
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierOverrides:interface",
|
|
1502
|
+
"docComment": "/**\n * Per-tier overrides, shallow-merged field by field over the defaults.\n *\n * @beta\n */\n",
|
|
1503
1503
|
"excerptTokens": [
|
|
1504
1504
|
{
|
|
1505
1505
|
"kind": "Content",
|
|
1506
|
-
"text": "export interface
|
|
1507
|
-
},
|
|
1508
|
-
{
|
|
1509
|
-
"kind": "Reference",
|
|
1510
|
-
"text": "AIProviderConfig",
|
|
1511
|
-
"canonicalReference": "@genesislcap/foundation-ai!~AIProviderConfig:interface"
|
|
1512
|
-
},
|
|
1513
|
-
{
|
|
1514
|
-
"kind": "Content",
|
|
1515
|
-
"text": " "
|
|
1506
|
+
"text": "export interface AITierOverrides "
|
|
1516
1507
|
}
|
|
1517
1508
|
],
|
|
1518
|
-
"fileUrlPath": "src/
|
|
1509
|
+
"fileUrlPath": "src/tiers/ai-tiers.ts",
|
|
1519
1510
|
"releaseTag": "Beta",
|
|
1520
|
-
"name": "
|
|
1511
|
+
"name": "AITierOverrides",
|
|
1521
1512
|
"preserveMemberOrder": false,
|
|
1522
1513
|
"members": [
|
|
1523
1514
|
{
|
|
1524
1515
|
"kind": "PropertySignature",
|
|
1525
|
-
"canonicalReference": "@genesislcap/foundation-ai!
|
|
1516
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierOverrides#anthropic:member",
|
|
1526
1517
|
"docComment": "",
|
|
1527
1518
|
"excerptTokens": [
|
|
1528
1519
|
{
|
|
1529
1520
|
"kind": "Content",
|
|
1530
|
-
"text": "
|
|
1521
|
+
"text": "anthropic?: "
|
|
1522
|
+
},
|
|
1523
|
+
{
|
|
1524
|
+
"kind": "Reference",
|
|
1525
|
+
"text": "Partial",
|
|
1526
|
+
"canonicalReference": "!Partial:type"
|
|
1531
1527
|
},
|
|
1532
1528
|
{
|
|
1533
1529
|
"kind": "Content",
|
|
1534
|
-
"text": "
|
|
1530
|
+
"text": "<"
|
|
1531
|
+
},
|
|
1532
|
+
{
|
|
1533
|
+
"kind": "Reference",
|
|
1534
|
+
"text": "Record",
|
|
1535
|
+
"canonicalReference": "!Record:type"
|
|
1535
1536
|
},
|
|
1536
1537
|
{
|
|
1537
1538
|
"kind": "Content",
|
|
1538
|
-
"text": "
|
|
1539
|
-
}
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
"propertyTypeTokenRange": {
|
|
1546
|
-
"startIndex": 1,
|
|
1547
|
-
"endIndex": 2
|
|
1548
|
-
}
|
|
1549
|
-
},
|
|
1550
|
-
{
|
|
1551
|
-
"kind": "PropertySignature",
|
|
1552
|
-
"canonicalReference": "@genesislcap/foundation-ai!AnthropicAIConfig#maxTokens:member",
|
|
1553
|
-
"docComment": "/**\n * Hard cap on tokens generated per response. Anthropic's `max_tokens` is a required field on every request. Defaults to 4096.\n */\n",
|
|
1554
|
-
"excerptTokens": [
|
|
1539
|
+
"text": "<"
|
|
1540
|
+
},
|
|
1541
|
+
{
|
|
1542
|
+
"kind": "Reference",
|
|
1543
|
+
"text": "AITierId",
|
|
1544
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierId:type"
|
|
1545
|
+
},
|
|
1555
1546
|
{
|
|
1556
1547
|
"kind": "Content",
|
|
1557
|
-
"text": "
|
|
1548
|
+
"text": ", "
|
|
1549
|
+
},
|
|
1550
|
+
{
|
|
1551
|
+
"kind": "Reference",
|
|
1552
|
+
"text": "Partial",
|
|
1553
|
+
"canonicalReference": "!Partial:type"
|
|
1558
1554
|
},
|
|
1559
1555
|
{
|
|
1560
1556
|
"kind": "Content",
|
|
1561
|
-
"text": "
|
|
1557
|
+
"text": "<"
|
|
1558
|
+
},
|
|
1559
|
+
{
|
|
1560
|
+
"kind": "Reference",
|
|
1561
|
+
"text": "AnthropicTierConfig",
|
|
1562
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicTierConfig:interface"
|
|
1563
|
+
},
|
|
1564
|
+
{
|
|
1565
|
+
"kind": "Content",
|
|
1566
|
+
"text": ">>>"
|
|
1562
1567
|
},
|
|
1563
1568
|
{
|
|
1564
1569
|
"kind": "Content",
|
|
@@ -1568,25 +1573,65 @@
|
|
|
1568
1573
|
"isReadonly": false,
|
|
1569
1574
|
"isOptional": true,
|
|
1570
1575
|
"releaseTag": "Beta",
|
|
1571
|
-
"name": "
|
|
1576
|
+
"name": "anthropic",
|
|
1572
1577
|
"propertyTypeTokenRange": {
|
|
1573
1578
|
"startIndex": 1,
|
|
1574
|
-
"endIndex":
|
|
1579
|
+
"endIndex": 11
|
|
1575
1580
|
}
|
|
1576
1581
|
},
|
|
1577
1582
|
{
|
|
1578
1583
|
"kind": "PropertySignature",
|
|
1579
|
-
"canonicalReference": "@genesislcap/foundation-ai!
|
|
1580
|
-
"docComment": "
|
|
1584
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierOverrides#gemini:member",
|
|
1585
|
+
"docComment": "",
|
|
1581
1586
|
"excerptTokens": [
|
|
1582
1587
|
{
|
|
1583
1588
|
"kind": "Content",
|
|
1584
|
-
"text": "
|
|
1589
|
+
"text": "gemini?: "
|
|
1585
1590
|
},
|
|
1586
1591
|
{
|
|
1587
1592
|
"kind": "Reference",
|
|
1588
|
-
"text": "
|
|
1589
|
-
"canonicalReference": "
|
|
1593
|
+
"text": "Partial",
|
|
1594
|
+
"canonicalReference": "!Partial:type"
|
|
1595
|
+
},
|
|
1596
|
+
{
|
|
1597
|
+
"kind": "Content",
|
|
1598
|
+
"text": "<"
|
|
1599
|
+
},
|
|
1600
|
+
{
|
|
1601
|
+
"kind": "Reference",
|
|
1602
|
+
"text": "Record",
|
|
1603
|
+
"canonicalReference": "!Record:type"
|
|
1604
|
+
},
|
|
1605
|
+
{
|
|
1606
|
+
"kind": "Content",
|
|
1607
|
+
"text": "<"
|
|
1608
|
+
},
|
|
1609
|
+
{
|
|
1610
|
+
"kind": "Reference",
|
|
1611
|
+
"text": "AITierId",
|
|
1612
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierId:type"
|
|
1613
|
+
},
|
|
1614
|
+
{
|
|
1615
|
+
"kind": "Content",
|
|
1616
|
+
"text": ", "
|
|
1617
|
+
},
|
|
1618
|
+
{
|
|
1619
|
+
"kind": "Reference",
|
|
1620
|
+
"text": "Partial",
|
|
1621
|
+
"canonicalReference": "!Partial:type"
|
|
1622
|
+
},
|
|
1623
|
+
{
|
|
1624
|
+
"kind": "Content",
|
|
1625
|
+
"text": "<"
|
|
1626
|
+
},
|
|
1627
|
+
{
|
|
1628
|
+
"kind": "Reference",
|
|
1629
|
+
"text": "GeminiTierConfig",
|
|
1630
|
+
"canonicalReference": "@genesislcap/foundation-ai!GeminiTierConfig:interface"
|
|
1631
|
+
},
|
|
1632
|
+
{
|
|
1633
|
+
"kind": "Content",
|
|
1634
|
+
"text": ">>>"
|
|
1590
1635
|
},
|
|
1591
1636
|
{
|
|
1592
1637
|
"kind": "Content",
|
|
@@ -1596,24 +1641,65 @@
|
|
|
1596
1641
|
"isReadonly": false,
|
|
1597
1642
|
"isOptional": true,
|
|
1598
1643
|
"releaseTag": "Beta",
|
|
1599
|
-
"name": "
|
|
1644
|
+
"name": "gemini",
|
|
1600
1645
|
"propertyTypeTokenRange": {
|
|
1601
1646
|
"startIndex": 1,
|
|
1602
|
-
"endIndex":
|
|
1647
|
+
"endIndex": 11
|
|
1603
1648
|
}
|
|
1604
|
-
}
|
|
1649
|
+
}
|
|
1650
|
+
],
|
|
1651
|
+
"extendsTokenRanges": []
|
|
1652
|
+
},
|
|
1653
|
+
{
|
|
1654
|
+
"kind": "Interface",
|
|
1655
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITiers:interface",
|
|
1656
|
+
"docComment": "/**\n * The whole table: every tier, for every vendor.\n *\n * Total records, not partials — a tier a vendor cannot serve is not a tier, it is a gap that only shows up when an agent resolves it at runtime.\n *\n * @beta\n */\n",
|
|
1657
|
+
"excerptTokens": [
|
|
1658
|
+
{
|
|
1659
|
+
"kind": "Content",
|
|
1660
|
+
"text": "export interface AITiers "
|
|
1661
|
+
}
|
|
1662
|
+
],
|
|
1663
|
+
"fileUrlPath": "src/tiers/ai-tiers.ts",
|
|
1664
|
+
"releaseTag": "Beta",
|
|
1665
|
+
"name": "AITiers",
|
|
1666
|
+
"preserveMemberOrder": false,
|
|
1667
|
+
"members": [
|
|
1605
1668
|
{
|
|
1606
1669
|
"kind": "PropertySignature",
|
|
1607
|
-
"canonicalReference": "@genesislcap/foundation-ai!
|
|
1670
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITiers#anthropic:member",
|
|
1608
1671
|
"docComment": "",
|
|
1609
1672
|
"excerptTokens": [
|
|
1610
1673
|
{
|
|
1611
1674
|
"kind": "Content",
|
|
1612
|
-
"text": "
|
|
1675
|
+
"text": "anthropic: "
|
|
1676
|
+
},
|
|
1677
|
+
{
|
|
1678
|
+
"kind": "Reference",
|
|
1679
|
+
"text": "Record",
|
|
1680
|
+
"canonicalReference": "!Record:type"
|
|
1613
1681
|
},
|
|
1614
1682
|
{
|
|
1615
1683
|
"kind": "Content",
|
|
1616
|
-
"text": "
|
|
1684
|
+
"text": "<"
|
|
1685
|
+
},
|
|
1686
|
+
{
|
|
1687
|
+
"kind": "Reference",
|
|
1688
|
+
"text": "AITierId",
|
|
1689
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierId:type"
|
|
1690
|
+
},
|
|
1691
|
+
{
|
|
1692
|
+
"kind": "Content",
|
|
1693
|
+
"text": ", "
|
|
1694
|
+
},
|
|
1695
|
+
{
|
|
1696
|
+
"kind": "Reference",
|
|
1697
|
+
"text": "AnthropicTierConfig",
|
|
1698
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicTierConfig:interface"
|
|
1699
|
+
},
|
|
1700
|
+
{
|
|
1701
|
+
"kind": "Content",
|
|
1702
|
+
"text": ">"
|
|
1617
1703
|
},
|
|
1618
1704
|
{
|
|
1619
1705
|
"kind": "Content",
|
|
@@ -1623,31 +1709,333 @@
|
|
|
1623
1709
|
"isReadonly": false,
|
|
1624
1710
|
"isOptional": false,
|
|
1625
1711
|
"releaseTag": "Beta",
|
|
1626
|
-
"name": "
|
|
1712
|
+
"name": "anthropic",
|
|
1627
1713
|
"propertyTypeTokenRange": {
|
|
1628
1714
|
"startIndex": 1,
|
|
1629
|
-
"endIndex":
|
|
1715
|
+
"endIndex": 7
|
|
1630
1716
|
}
|
|
1631
1717
|
},
|
|
1632
1718
|
{
|
|
1633
1719
|
"kind": "PropertySignature",
|
|
1634
|
-
"canonicalReference": "@genesislcap/foundation-ai!
|
|
1720
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITiers#gemini:member",
|
|
1635
1721
|
"docComment": "",
|
|
1636
1722
|
"excerptTokens": [
|
|
1637
1723
|
{
|
|
1638
1724
|
"kind": "Content",
|
|
1639
|
-
"text": "
|
|
1725
|
+
"text": "gemini: "
|
|
1640
1726
|
},
|
|
1641
1727
|
{
|
|
1642
|
-
"kind": "
|
|
1643
|
-
"text": "
|
|
1728
|
+
"kind": "Reference",
|
|
1729
|
+
"text": "Record",
|
|
1730
|
+
"canonicalReference": "!Record:type"
|
|
1644
1731
|
},
|
|
1645
1732
|
{
|
|
1646
1733
|
"kind": "Content",
|
|
1647
|
-
"text": "
|
|
1648
|
-
}
|
|
1649
|
-
|
|
1650
|
-
|
|
1734
|
+
"text": "<"
|
|
1735
|
+
},
|
|
1736
|
+
{
|
|
1737
|
+
"kind": "Reference",
|
|
1738
|
+
"text": "AITierId",
|
|
1739
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierId:type"
|
|
1740
|
+
},
|
|
1741
|
+
{
|
|
1742
|
+
"kind": "Content",
|
|
1743
|
+
"text": ", "
|
|
1744
|
+
},
|
|
1745
|
+
{
|
|
1746
|
+
"kind": "Reference",
|
|
1747
|
+
"text": "GeminiTierConfig",
|
|
1748
|
+
"canonicalReference": "@genesislcap/foundation-ai!GeminiTierConfig:interface"
|
|
1749
|
+
},
|
|
1750
|
+
{
|
|
1751
|
+
"kind": "Content",
|
|
1752
|
+
"text": ">"
|
|
1753
|
+
},
|
|
1754
|
+
{
|
|
1755
|
+
"kind": "Content",
|
|
1756
|
+
"text": ";"
|
|
1757
|
+
}
|
|
1758
|
+
],
|
|
1759
|
+
"isReadonly": false,
|
|
1760
|
+
"isOptional": false,
|
|
1761
|
+
"releaseTag": "Beta",
|
|
1762
|
+
"name": "gemini",
|
|
1763
|
+
"propertyTypeTokenRange": {
|
|
1764
|
+
"startIndex": 1,
|
|
1765
|
+
"endIndex": 7
|
|
1766
|
+
}
|
|
1767
|
+
}
|
|
1768
|
+
],
|
|
1769
|
+
"extendsTokenRanges": []
|
|
1770
|
+
},
|
|
1771
|
+
{
|
|
1772
|
+
"kind": "TypeAlias",
|
|
1773
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierVendor:type",
|
|
1774
|
+
"docComment": "/**\n * The cloud vendors the tier table covers. Derived from {@link AI_TIER_VENDORS}.\n *\n * @beta\n */\n",
|
|
1775
|
+
"excerptTokens": [
|
|
1776
|
+
{
|
|
1777
|
+
"kind": "Content",
|
|
1778
|
+
"text": "export type AITierVendor = "
|
|
1779
|
+
},
|
|
1780
|
+
{
|
|
1781
|
+
"kind": "Content",
|
|
1782
|
+
"text": "(typeof "
|
|
1783
|
+
},
|
|
1784
|
+
{
|
|
1785
|
+
"kind": "Reference",
|
|
1786
|
+
"text": "AI_TIER_VENDORS",
|
|
1787
|
+
"canonicalReference": "@genesislcap/foundation-ai!AI_TIER_VENDORS:var"
|
|
1788
|
+
},
|
|
1789
|
+
{
|
|
1790
|
+
"kind": "Content",
|
|
1791
|
+
"text": ")[number]"
|
|
1792
|
+
},
|
|
1793
|
+
{
|
|
1794
|
+
"kind": "Content",
|
|
1795
|
+
"text": ";"
|
|
1796
|
+
}
|
|
1797
|
+
],
|
|
1798
|
+
"fileUrlPath": "src/tiers/ai-tiers.ts",
|
|
1799
|
+
"releaseTag": "Beta",
|
|
1800
|
+
"name": "AITierVendor",
|
|
1801
|
+
"typeTokenRange": {
|
|
1802
|
+
"startIndex": 1,
|
|
1803
|
+
"endIndex": 4
|
|
1804
|
+
}
|
|
1805
|
+
},
|
|
1806
|
+
{
|
|
1807
|
+
"kind": "Variable",
|
|
1808
|
+
"canonicalReference": "@genesislcap/foundation-ai!ANTHROPIC_CACHE_READ_MULTIPLIER:var",
|
|
1809
|
+
"docComment": "/**\n * Prompt-cache pricing multipliers, applied to the model's base input rate (`promptPerMillion`) — https://docs.claude.com/en/docs/build-with-claude/prompt-caching Reads bill at ~0.1× base input; writes bill by TTL — 5-minute at ~1.25× and 1-hour at 2×. Both write TTLs are reachable (`CachePolicy.ttl` is `'5m' | '1h'`), so each TTL bucket is costed from the response's per-TTL `cache_creation` breakdown rather than assuming one rate.\n *\n * @beta\n */\n",
|
|
1810
|
+
"excerptTokens": [
|
|
1811
|
+
{
|
|
1812
|
+
"kind": "Content",
|
|
1813
|
+
"text": "ANTHROPIC_CACHE_READ_MULTIPLIER = "
|
|
1814
|
+
},
|
|
1815
|
+
{
|
|
1816
|
+
"kind": "Content",
|
|
1817
|
+
"text": "0.1"
|
|
1818
|
+
}
|
|
1819
|
+
],
|
|
1820
|
+
"fileUrlPath": "src/utils/token-cost.ts",
|
|
1821
|
+
"initializerTokenRange": {
|
|
1822
|
+
"startIndex": 1,
|
|
1823
|
+
"endIndex": 2
|
|
1824
|
+
},
|
|
1825
|
+
"isReadonly": true,
|
|
1826
|
+
"releaseTag": "Beta",
|
|
1827
|
+
"name": "ANTHROPIC_CACHE_READ_MULTIPLIER",
|
|
1828
|
+
"variableTypeTokenRange": {
|
|
1829
|
+
"startIndex": 0,
|
|
1830
|
+
"endIndex": 0
|
|
1831
|
+
}
|
|
1832
|
+
},
|
|
1833
|
+
{
|
|
1834
|
+
"kind": "Variable",
|
|
1835
|
+
"canonicalReference": "@genesislcap/foundation-ai!ANTHROPIC_CACHE_WRITE_1H_MULTIPLIER:var",
|
|
1836
|
+
"docComment": "/**\n * @beta\n */\n",
|
|
1837
|
+
"excerptTokens": [
|
|
1838
|
+
{
|
|
1839
|
+
"kind": "Content",
|
|
1840
|
+
"text": "ANTHROPIC_CACHE_WRITE_1H_MULTIPLIER = "
|
|
1841
|
+
},
|
|
1842
|
+
{
|
|
1843
|
+
"kind": "Content",
|
|
1844
|
+
"text": "2"
|
|
1845
|
+
}
|
|
1846
|
+
],
|
|
1847
|
+
"fileUrlPath": "src/utils/token-cost.ts",
|
|
1848
|
+
"initializerTokenRange": {
|
|
1849
|
+
"startIndex": 1,
|
|
1850
|
+
"endIndex": 2
|
|
1851
|
+
},
|
|
1852
|
+
"isReadonly": true,
|
|
1853
|
+
"releaseTag": "Beta",
|
|
1854
|
+
"name": "ANTHROPIC_CACHE_WRITE_1H_MULTIPLIER",
|
|
1855
|
+
"variableTypeTokenRange": {
|
|
1856
|
+
"startIndex": 0,
|
|
1857
|
+
"endIndex": 0
|
|
1858
|
+
}
|
|
1859
|
+
},
|
|
1860
|
+
{
|
|
1861
|
+
"kind": "Variable",
|
|
1862
|
+
"canonicalReference": "@genesislcap/foundation-ai!ANTHROPIC_CACHE_WRITE_5M_MULTIPLIER:var",
|
|
1863
|
+
"docComment": "/**\n * @beta\n */\n",
|
|
1864
|
+
"excerptTokens": [
|
|
1865
|
+
{
|
|
1866
|
+
"kind": "Content",
|
|
1867
|
+
"text": "ANTHROPIC_CACHE_WRITE_5M_MULTIPLIER = "
|
|
1868
|
+
},
|
|
1869
|
+
{
|
|
1870
|
+
"kind": "Content",
|
|
1871
|
+
"text": "1.25"
|
|
1872
|
+
}
|
|
1873
|
+
],
|
|
1874
|
+
"fileUrlPath": "src/utils/token-cost.ts",
|
|
1875
|
+
"initializerTokenRange": {
|
|
1876
|
+
"startIndex": 1,
|
|
1877
|
+
"endIndex": 2
|
|
1878
|
+
},
|
|
1879
|
+
"isReadonly": true,
|
|
1880
|
+
"releaseTag": "Beta",
|
|
1881
|
+
"name": "ANTHROPIC_CACHE_WRITE_5M_MULTIPLIER",
|
|
1882
|
+
"variableTypeTokenRange": {
|
|
1883
|
+
"startIndex": 0,
|
|
1884
|
+
"endIndex": 0
|
|
1885
|
+
}
|
|
1886
|
+
},
|
|
1887
|
+
{
|
|
1888
|
+
"kind": "Interface",
|
|
1889
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicAIConfig:interface",
|
|
1890
|
+
"docComment": "/**\n * Anthropic server-proxy AI configuration (client calls your server; server calls Anthropic).\n *\n * @remarks\n *\n * API key stays on the server. URL defaults to `/gwf/ai-service/anthropic/chat`. When `apiKey` is provided, the transport calls `api.anthropic.com/v1/messages` directly (browser direct calls require `anthropic-dangerous-direct-browser-access: true`, which the transport sends automatically — only use this in trusted contexts).\n *\n * @beta\n */\n",
|
|
1891
|
+
"excerptTokens": [
|
|
1892
|
+
{
|
|
1893
|
+
"kind": "Content",
|
|
1894
|
+
"text": "export interface AnthropicAIConfig extends "
|
|
1895
|
+
},
|
|
1896
|
+
{
|
|
1897
|
+
"kind": "Reference",
|
|
1898
|
+
"text": "AIProviderConfig",
|
|
1899
|
+
"canonicalReference": "@genesislcap/foundation-ai!~AIProviderConfig:interface"
|
|
1900
|
+
},
|
|
1901
|
+
{
|
|
1902
|
+
"kind": "Content",
|
|
1903
|
+
"text": " "
|
|
1904
|
+
}
|
|
1905
|
+
],
|
|
1906
|
+
"fileUrlPath": "src/types/config.types.ts",
|
|
1907
|
+
"releaseTag": "Beta",
|
|
1908
|
+
"name": "AnthropicAIConfig",
|
|
1909
|
+
"preserveMemberOrder": false,
|
|
1910
|
+
"members": [
|
|
1911
|
+
{
|
|
1912
|
+
"kind": "PropertySignature",
|
|
1913
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicAIConfig#apiKey:member",
|
|
1914
|
+
"docComment": "",
|
|
1915
|
+
"excerptTokens": [
|
|
1916
|
+
{
|
|
1917
|
+
"kind": "Content",
|
|
1918
|
+
"text": "apiKey?: "
|
|
1919
|
+
},
|
|
1920
|
+
{
|
|
1921
|
+
"kind": "Content",
|
|
1922
|
+
"text": "string"
|
|
1923
|
+
},
|
|
1924
|
+
{
|
|
1925
|
+
"kind": "Content",
|
|
1926
|
+
"text": ";"
|
|
1927
|
+
}
|
|
1928
|
+
],
|
|
1929
|
+
"isReadonly": false,
|
|
1930
|
+
"isOptional": true,
|
|
1931
|
+
"releaseTag": "Beta",
|
|
1932
|
+
"name": "apiKey",
|
|
1933
|
+
"propertyTypeTokenRange": {
|
|
1934
|
+
"startIndex": 1,
|
|
1935
|
+
"endIndex": 2
|
|
1936
|
+
}
|
|
1937
|
+
},
|
|
1938
|
+
{
|
|
1939
|
+
"kind": "PropertySignature",
|
|
1940
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicAIConfig#maxTokens:member",
|
|
1941
|
+
"docComment": "/**\n * Hard cap on tokens generated per response. Anthropic's `max_tokens` is a required field on every request. Defaults to 4096.\n */\n",
|
|
1942
|
+
"excerptTokens": [
|
|
1943
|
+
{
|
|
1944
|
+
"kind": "Content",
|
|
1945
|
+
"text": "maxTokens?: "
|
|
1946
|
+
},
|
|
1947
|
+
{
|
|
1948
|
+
"kind": "Content",
|
|
1949
|
+
"text": "number"
|
|
1950
|
+
},
|
|
1951
|
+
{
|
|
1952
|
+
"kind": "Content",
|
|
1953
|
+
"text": ";"
|
|
1954
|
+
}
|
|
1955
|
+
],
|
|
1956
|
+
"isReadonly": false,
|
|
1957
|
+
"isOptional": true,
|
|
1958
|
+
"releaseTag": "Beta",
|
|
1959
|
+
"name": "maxTokens",
|
|
1960
|
+
"propertyTypeTokenRange": {
|
|
1961
|
+
"startIndex": 1,
|
|
1962
|
+
"endIndex": 2
|
|
1963
|
+
}
|
|
1964
|
+
},
|
|
1965
|
+
{
|
|
1966
|
+
"kind": "PropertySignature",
|
|
1967
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicAIConfig#model:member",
|
|
1968
|
+
"docComment": "/**\n * Defaults to `claude-haiku-4-5-20251001`. Only {@link SUPPORTED_ANTHROPIC_MODEL_IDS} are accepted at runtime.\n */\n",
|
|
1969
|
+
"excerptTokens": [
|
|
1970
|
+
{
|
|
1971
|
+
"kind": "Content",
|
|
1972
|
+
"text": "model?: "
|
|
1973
|
+
},
|
|
1974
|
+
{
|
|
1975
|
+
"kind": "Reference",
|
|
1976
|
+
"text": "AnthropicModelId",
|
|
1977
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicModelId:type"
|
|
1978
|
+
},
|
|
1979
|
+
{
|
|
1980
|
+
"kind": "Content",
|
|
1981
|
+
"text": ";"
|
|
1982
|
+
}
|
|
1983
|
+
],
|
|
1984
|
+
"isReadonly": false,
|
|
1985
|
+
"isOptional": true,
|
|
1986
|
+
"releaseTag": "Beta",
|
|
1987
|
+
"name": "model",
|
|
1988
|
+
"propertyTypeTokenRange": {
|
|
1989
|
+
"startIndex": 1,
|
|
1990
|
+
"endIndex": 2
|
|
1991
|
+
}
|
|
1992
|
+
},
|
|
1993
|
+
{
|
|
1994
|
+
"kind": "PropertySignature",
|
|
1995
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicAIConfig#providerType:member",
|
|
1996
|
+
"docComment": "",
|
|
1997
|
+
"excerptTokens": [
|
|
1998
|
+
{
|
|
1999
|
+
"kind": "Content",
|
|
2000
|
+
"text": "providerType: "
|
|
2001
|
+
},
|
|
2002
|
+
{
|
|
2003
|
+
"kind": "Content",
|
|
2004
|
+
"text": "'anthropic'"
|
|
2005
|
+
},
|
|
2006
|
+
{
|
|
2007
|
+
"kind": "Content",
|
|
2008
|
+
"text": ";"
|
|
2009
|
+
}
|
|
2010
|
+
],
|
|
2011
|
+
"isReadonly": false,
|
|
2012
|
+
"isOptional": false,
|
|
2013
|
+
"releaseTag": "Beta",
|
|
2014
|
+
"name": "providerType",
|
|
2015
|
+
"propertyTypeTokenRange": {
|
|
2016
|
+
"startIndex": 1,
|
|
2017
|
+
"endIndex": 2
|
|
2018
|
+
}
|
|
2019
|
+
},
|
|
2020
|
+
{
|
|
2021
|
+
"kind": "PropertySignature",
|
|
2022
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicAIConfig#serverEndpoint:member",
|
|
2023
|
+
"docComment": "",
|
|
2024
|
+
"excerptTokens": [
|
|
2025
|
+
{
|
|
2026
|
+
"kind": "Content",
|
|
2027
|
+
"text": "serverEndpoint?: "
|
|
2028
|
+
},
|
|
2029
|
+
{
|
|
2030
|
+
"kind": "Content",
|
|
2031
|
+
"text": "string"
|
|
2032
|
+
},
|
|
2033
|
+
{
|
|
2034
|
+
"kind": "Content",
|
|
2035
|
+
"text": ";"
|
|
2036
|
+
}
|
|
2037
|
+
],
|
|
2038
|
+
"isReadonly": false,
|
|
1651
2039
|
"isOptional": true,
|
|
1652
2040
|
"releaseTag": "Beta",
|
|
1653
2041
|
"name": "serverEndpoint",
|
|
@@ -2131,88 +2519,215 @@
|
|
|
2131
2519
|
"overloadIndex": 1,
|
|
2132
2520
|
"parameters": [
|
|
2133
2521
|
{
|
|
2134
|
-
"parameterName": "history",
|
|
2135
|
-
"parameterTypeTokenRange": {
|
|
2136
|
-
"startIndex": 1,
|
|
2137
|
-
"endIndex": 3
|
|
2138
|
-
},
|
|
2139
|
-
"isOptional": false
|
|
2522
|
+
"parameterName": "history",
|
|
2523
|
+
"parameterTypeTokenRange": {
|
|
2524
|
+
"startIndex": 1,
|
|
2525
|
+
"endIndex": 3
|
|
2526
|
+
},
|
|
2527
|
+
"isOptional": false
|
|
2528
|
+
},
|
|
2529
|
+
{
|
|
2530
|
+
"parameterName": "userMessage",
|
|
2531
|
+
"parameterTypeTokenRange": {
|
|
2532
|
+
"startIndex": 4,
|
|
2533
|
+
"endIndex": 5
|
|
2534
|
+
},
|
|
2535
|
+
"isOptional": false
|
|
2536
|
+
},
|
|
2537
|
+
{
|
|
2538
|
+
"parameterName": "options",
|
|
2539
|
+
"parameterTypeTokenRange": {
|
|
2540
|
+
"startIndex": 6,
|
|
2541
|
+
"endIndex": 7
|
|
2542
|
+
},
|
|
2543
|
+
"isOptional": true
|
|
2544
|
+
}
|
|
2545
|
+
],
|
|
2546
|
+
"isOptional": false,
|
|
2547
|
+
"isAbstract": false,
|
|
2548
|
+
"name": "streamChat"
|
|
2549
|
+
}
|
|
2550
|
+
],
|
|
2551
|
+
"implementsTokenRanges": [
|
|
2552
|
+
{
|
|
2553
|
+
"startIndex": 1,
|
|
2554
|
+
"endIndex": 2
|
|
2555
|
+
}
|
|
2556
|
+
]
|
|
2557
|
+
},
|
|
2558
|
+
{
|
|
2559
|
+
"kind": "Function",
|
|
2560
|
+
"canonicalReference": "@genesislcap/foundation-ai!anthropicRatesFor:function(1)",
|
|
2561
|
+
"docComment": "/**\n * Standard tier pricing per million tokens — https://docs.claude.com/en/docs/about-claude/pricing\n *\n * @remarks\n *\n * Backed by a total {@link https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type | Record} over `AnthropicModelId` rather than a chain of checks with a default. That is the whole point: adding a model to `SUPPORTED_ANTHROPIC_MODEL_IDS` without pricing it becomes a COMPILE error instead of a silent charge at whatever the fall-through happened to be — the exact failure this module's header warns about, and one a consumer has already been bitten by. The Gemini half of this file has always had the guarantee; this half now matches.\n *\n * @beta\n */\n",
|
|
2562
|
+
"excerptTokens": [
|
|
2563
|
+
{
|
|
2564
|
+
"kind": "Content",
|
|
2565
|
+
"text": "export declare function anthropicRatesFor(model: "
|
|
2566
|
+
},
|
|
2567
|
+
{
|
|
2568
|
+
"kind": "Reference",
|
|
2569
|
+
"text": "AnthropicModelId",
|
|
2570
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicModelId:type"
|
|
2571
|
+
},
|
|
2572
|
+
{
|
|
2573
|
+
"kind": "Content",
|
|
2574
|
+
"text": "): "
|
|
2575
|
+
},
|
|
2576
|
+
{
|
|
2577
|
+
"kind": "Reference",
|
|
2578
|
+
"text": "TokenRates",
|
|
2579
|
+
"canonicalReference": "@genesislcap/foundation-ai!TokenRates:interface"
|
|
2580
|
+
},
|
|
2581
|
+
{
|
|
2582
|
+
"kind": "Content",
|
|
2583
|
+
"text": ";"
|
|
2584
|
+
}
|
|
2585
|
+
],
|
|
2586
|
+
"fileUrlPath": "src/utils/token-cost.ts",
|
|
2587
|
+
"returnTypeTokenRange": {
|
|
2588
|
+
"startIndex": 3,
|
|
2589
|
+
"endIndex": 4
|
|
2590
|
+
},
|
|
2591
|
+
"releaseTag": "Beta",
|
|
2592
|
+
"overloadIndex": 1,
|
|
2593
|
+
"parameters": [
|
|
2594
|
+
{
|
|
2595
|
+
"parameterName": "model",
|
|
2596
|
+
"parameterTypeTokenRange": {
|
|
2597
|
+
"startIndex": 1,
|
|
2598
|
+
"endIndex": 2
|
|
2599
|
+
},
|
|
2600
|
+
"isOptional": false
|
|
2601
|
+
}
|
|
2602
|
+
],
|
|
2603
|
+
"name": "anthropicRatesFor"
|
|
2604
|
+
},
|
|
2605
|
+
{
|
|
2606
|
+
"kind": "Interface",
|
|
2607
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicTierConfig:interface",
|
|
2608
|
+
"docComment": "/**\n * What one tier is worth on Anthropic: the model, its output ceiling, and the two clocks.\n *\n * @beta\n */\n",
|
|
2609
|
+
"excerptTokens": [
|
|
2610
|
+
{
|
|
2611
|
+
"kind": "Content",
|
|
2612
|
+
"text": "export interface AnthropicTierConfig "
|
|
2613
|
+
}
|
|
2614
|
+
],
|
|
2615
|
+
"fileUrlPath": "src/tiers/ai-tiers.ts",
|
|
2616
|
+
"releaseTag": "Beta",
|
|
2617
|
+
"name": "AnthropicTierConfig",
|
|
2618
|
+
"preserveMemberOrder": false,
|
|
2619
|
+
"members": [
|
|
2620
|
+
{
|
|
2621
|
+
"kind": "PropertySignature",
|
|
2622
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicTierConfig#maxTokens:member",
|
|
2623
|
+
"docComment": "/**\n * `max_tokens` for every request on this tier. Part of the tier, not an optional extra: Anthropic requires the field and the transport defaults it to 4096, which truncates a large single-call file write mid-stream (`stop_reason: max_tokens`) and leaves the tool input unparseable. Values sit inside each model's documented output ceiling.\n */\n",
|
|
2624
|
+
"excerptTokens": [
|
|
2625
|
+
{
|
|
2626
|
+
"kind": "Content",
|
|
2627
|
+
"text": "maxTokens: "
|
|
2628
|
+
},
|
|
2629
|
+
{
|
|
2630
|
+
"kind": "Content",
|
|
2631
|
+
"text": "number"
|
|
2632
|
+
},
|
|
2633
|
+
{
|
|
2634
|
+
"kind": "Content",
|
|
2635
|
+
"text": ";"
|
|
2636
|
+
}
|
|
2637
|
+
],
|
|
2638
|
+
"isReadonly": false,
|
|
2639
|
+
"isOptional": false,
|
|
2640
|
+
"releaseTag": "Beta",
|
|
2641
|
+
"name": "maxTokens",
|
|
2642
|
+
"propertyTypeTokenRange": {
|
|
2643
|
+
"startIndex": 1,
|
|
2644
|
+
"endIndex": 2
|
|
2645
|
+
}
|
|
2646
|
+
},
|
|
2647
|
+
{
|
|
2648
|
+
"kind": "PropertySignature",
|
|
2649
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicTierConfig#model:member",
|
|
2650
|
+
"docComment": "",
|
|
2651
|
+
"excerptTokens": [
|
|
2652
|
+
{
|
|
2653
|
+
"kind": "Content",
|
|
2654
|
+
"text": "model: "
|
|
2655
|
+
},
|
|
2656
|
+
{
|
|
2657
|
+
"kind": "Reference",
|
|
2658
|
+
"text": "AnthropicModelId",
|
|
2659
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicModelId:type"
|
|
2660
|
+
},
|
|
2661
|
+
{
|
|
2662
|
+
"kind": "Content",
|
|
2663
|
+
"text": ";"
|
|
2664
|
+
}
|
|
2665
|
+
],
|
|
2666
|
+
"isReadonly": false,
|
|
2667
|
+
"isOptional": false,
|
|
2668
|
+
"releaseTag": "Beta",
|
|
2669
|
+
"name": "model",
|
|
2670
|
+
"propertyTypeTokenRange": {
|
|
2671
|
+
"startIndex": 1,
|
|
2672
|
+
"endIndex": 2
|
|
2673
|
+
}
|
|
2674
|
+
},
|
|
2675
|
+
{
|
|
2676
|
+
"kind": "PropertySignature",
|
|
2677
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicTierConfig#stallTimeoutMs:member",
|
|
2678
|
+
"docComment": "/**\n * Inactivity window on a stream that has started.\n */\n",
|
|
2679
|
+
"excerptTokens": [
|
|
2680
|
+
{
|
|
2681
|
+
"kind": "Content",
|
|
2682
|
+
"text": "stallTimeoutMs: "
|
|
2683
|
+
},
|
|
2684
|
+
{
|
|
2685
|
+
"kind": "Content",
|
|
2686
|
+
"text": "number"
|
|
2687
|
+
},
|
|
2688
|
+
{
|
|
2689
|
+
"kind": "Content",
|
|
2690
|
+
"text": ";"
|
|
2691
|
+
}
|
|
2692
|
+
],
|
|
2693
|
+
"isReadonly": false,
|
|
2694
|
+
"isOptional": false,
|
|
2695
|
+
"releaseTag": "Beta",
|
|
2696
|
+
"name": "stallTimeoutMs",
|
|
2697
|
+
"propertyTypeTokenRange": {
|
|
2698
|
+
"startIndex": 1,
|
|
2699
|
+
"endIndex": 2
|
|
2700
|
+
}
|
|
2701
|
+
},
|
|
2702
|
+
{
|
|
2703
|
+
"kind": "PropertySignature",
|
|
2704
|
+
"canonicalReference": "@genesislcap/foundation-ai!AnthropicTierConfig#timeoutMs:member",
|
|
2705
|
+
"docComment": "/**\n * Ceiling on the wait for the FIRST byte — a different clock from the stall one.\n */\n",
|
|
2706
|
+
"excerptTokens": [
|
|
2707
|
+
{
|
|
2708
|
+
"kind": "Content",
|
|
2709
|
+
"text": "timeoutMs: "
|
|
2140
2710
|
},
|
|
2141
2711
|
{
|
|
2142
|
-
"
|
|
2143
|
-
"
|
|
2144
|
-
"startIndex": 4,
|
|
2145
|
-
"endIndex": 5
|
|
2146
|
-
},
|
|
2147
|
-
"isOptional": false
|
|
2712
|
+
"kind": "Content",
|
|
2713
|
+
"text": "number"
|
|
2148
2714
|
},
|
|
2149
2715
|
{
|
|
2150
|
-
"
|
|
2151
|
-
"
|
|
2152
|
-
"startIndex": 6,
|
|
2153
|
-
"endIndex": 7
|
|
2154
|
-
},
|
|
2155
|
-
"isOptional": true
|
|
2716
|
+
"kind": "Content",
|
|
2717
|
+
"text": ";"
|
|
2156
2718
|
}
|
|
2157
2719
|
],
|
|
2720
|
+
"isReadonly": false,
|
|
2158
2721
|
"isOptional": false,
|
|
2159
|
-
"
|
|
2160
|
-
"name": "
|
|
2161
|
-
|
|
2162
|
-
],
|
|
2163
|
-
"implementsTokenRanges": [
|
|
2164
|
-
{
|
|
2165
|
-
"startIndex": 1,
|
|
2166
|
-
"endIndex": 2
|
|
2167
|
-
}
|
|
2168
|
-
]
|
|
2169
|
-
},
|
|
2170
|
-
{
|
|
2171
|
-
"kind": "Function",
|
|
2172
|
-
"canonicalReference": "@genesislcap/foundation-ai!anthropicRatesFor:function(1)",
|
|
2173
|
-
"docComment": "/**\n * Standard tier pricing per million tokens — https://docs.claude.com/en/docs/about-claude/pricing\n *\n * @remarks\n *\n * Backed by a total {@link https://www.typescriptlang.org/docs/handbook/utility-types.html#recordkeys-type | Record} over `AnthropicModelId` rather than a chain of checks with a default. That is the whole point: adding a model to `SUPPORTED_ANTHROPIC_MODEL_IDS` without pricing it becomes a COMPILE error instead of a silent charge at whatever the fall-through happened to be — the exact failure this module's header warns about, and one a consumer has already been bitten by. The Gemini half of this file has always had the guarantee; this half now matches.\n *\n * @beta\n */\n",
|
|
2174
|
-
"excerptTokens": [
|
|
2175
|
-
{
|
|
2176
|
-
"kind": "Content",
|
|
2177
|
-
"text": "export declare function anthropicRatesFor(model: "
|
|
2178
|
-
},
|
|
2179
|
-
{
|
|
2180
|
-
"kind": "Reference",
|
|
2181
|
-
"text": "AnthropicModelId",
|
|
2182
|
-
"canonicalReference": "@genesislcap/foundation-ai!AnthropicModelId:type"
|
|
2183
|
-
},
|
|
2184
|
-
{
|
|
2185
|
-
"kind": "Content",
|
|
2186
|
-
"text": "): "
|
|
2187
|
-
},
|
|
2188
|
-
{
|
|
2189
|
-
"kind": "Reference",
|
|
2190
|
-
"text": "TokenRates",
|
|
2191
|
-
"canonicalReference": "@genesislcap/foundation-ai!TokenRates:interface"
|
|
2192
|
-
},
|
|
2193
|
-
{
|
|
2194
|
-
"kind": "Content",
|
|
2195
|
-
"text": ";"
|
|
2196
|
-
}
|
|
2197
|
-
],
|
|
2198
|
-
"fileUrlPath": "src/utils/token-cost.ts",
|
|
2199
|
-
"returnTypeTokenRange": {
|
|
2200
|
-
"startIndex": 3,
|
|
2201
|
-
"endIndex": 4
|
|
2202
|
-
},
|
|
2203
|
-
"releaseTag": "Beta",
|
|
2204
|
-
"overloadIndex": 1,
|
|
2205
|
-
"parameters": [
|
|
2206
|
-
{
|
|
2207
|
-
"parameterName": "model",
|
|
2208
|
-
"parameterTypeTokenRange": {
|
|
2722
|
+
"releaseTag": "Beta",
|
|
2723
|
+
"name": "timeoutMs",
|
|
2724
|
+
"propertyTypeTokenRange": {
|
|
2209
2725
|
"startIndex": 1,
|
|
2210
2726
|
"endIndex": 2
|
|
2211
|
-
}
|
|
2212
|
-
"isOptional": false
|
|
2727
|
+
}
|
|
2213
2728
|
}
|
|
2214
2729
|
],
|
|
2215
|
-
"
|
|
2730
|
+
"extendsTokenRanges": []
|
|
2216
2731
|
},
|
|
2217
2732
|
{
|
|
2218
2733
|
"kind": "Function",
|
|
@@ -3019,136 +3534,315 @@
|
|
|
3019
3534
|
"startIndex": 1,
|
|
3020
3535
|
"endIndex": 2
|
|
3021
3536
|
},
|
|
3022
|
-
"isStatic": false,
|
|
3023
|
-
"isProtected": false,
|
|
3024
|
-
"isAbstract": false
|
|
3025
|
-
},
|
|
3537
|
+
"isStatic": false,
|
|
3538
|
+
"isProtected": false,
|
|
3539
|
+
"isAbstract": false
|
|
3540
|
+
},
|
|
3541
|
+
{
|
|
3542
|
+
"kind": "Property",
|
|
3543
|
+
"canonicalReference": "@genesislcap/foundation-ai!BudgetExhaustedError#otherVendorAvailable:member",
|
|
3544
|
+
"docComment": "/**\n * The proxy's own verdict on whether **any other** vendor it meters still has headroom, from the 402's `otherVendorAvailable`.\n *\n * The one field on this error a client cannot re-derive. A client can only infer \"another vendor is free\" from registry membership — which knows nothing about that vendor's remaining spend — so a `false` here is the only thing standing between the user and \"Switch to Gemini to keep going\" for a Gemini pot that is already empty. `undefined` means the proxy did not say (an older build), and the client is back to inferring.\n */\n",
|
|
3545
|
+
"excerptTokens": [
|
|
3546
|
+
{
|
|
3547
|
+
"kind": "Content",
|
|
3548
|
+
"text": "readonly otherVendorAvailable?: "
|
|
3549
|
+
},
|
|
3550
|
+
{
|
|
3551
|
+
"kind": "Content",
|
|
3552
|
+
"text": "boolean"
|
|
3553
|
+
},
|
|
3554
|
+
{
|
|
3555
|
+
"kind": "Content",
|
|
3556
|
+
"text": ";"
|
|
3557
|
+
}
|
|
3558
|
+
],
|
|
3559
|
+
"isReadonly": true,
|
|
3560
|
+
"isOptional": true,
|
|
3561
|
+
"releaseTag": "Beta",
|
|
3562
|
+
"name": "otherVendorAvailable",
|
|
3563
|
+
"propertyTypeTokenRange": {
|
|
3564
|
+
"startIndex": 1,
|
|
3565
|
+
"endIndex": 2
|
|
3566
|
+
},
|
|
3567
|
+
"isStatic": false,
|
|
3568
|
+
"isProtected": false,
|
|
3569
|
+
"isAbstract": false
|
|
3570
|
+
},
|
|
3571
|
+
{
|
|
3572
|
+
"kind": "Property",
|
|
3573
|
+
"canonicalReference": "@genesislcap/foundation-ai!BudgetExhaustedError#serverVendor:member",
|
|
3574
|
+
"docComment": "/**\n * The vendor the **proxy** says it refused, verbatim from the 402's `vendor`.\n *\n * A second opinion, not the first: {@link BudgetExhaustedError.vendorLabel} comes from the transport that was actually called and wins wherever it resolves. This one rescues attribution when the transport's label does not — a white-labelled or multiplexing gateway whose single transport fronts more than one upstream stamps one static label for all of them, and only the proxy knows which pot the request was actually booked against.\n */\n",
|
|
3575
|
+
"excerptTokens": [
|
|
3576
|
+
{
|
|
3577
|
+
"kind": "Content",
|
|
3578
|
+
"text": "readonly serverVendor?: "
|
|
3579
|
+
},
|
|
3580
|
+
{
|
|
3581
|
+
"kind": "Content",
|
|
3582
|
+
"text": "string"
|
|
3583
|
+
},
|
|
3584
|
+
{
|
|
3585
|
+
"kind": "Content",
|
|
3586
|
+
"text": ";"
|
|
3587
|
+
}
|
|
3588
|
+
],
|
|
3589
|
+
"isReadonly": true,
|
|
3590
|
+
"isOptional": true,
|
|
3591
|
+
"releaseTag": "Beta",
|
|
3592
|
+
"name": "serverVendor",
|
|
3593
|
+
"propertyTypeTokenRange": {
|
|
3594
|
+
"startIndex": 1,
|
|
3595
|
+
"endIndex": 2
|
|
3596
|
+
},
|
|
3597
|
+
"isStatic": false,
|
|
3598
|
+
"isProtected": false,
|
|
3599
|
+
"isAbstract": false
|
|
3600
|
+
},
|
|
3601
|
+
{
|
|
3602
|
+
"kind": "Property",
|
|
3603
|
+
"canonicalReference": "@genesislcap/foundation-ai!BudgetExhaustedError#spentUsd:member",
|
|
3604
|
+
"docComment": "/**\n * Spend already booked against that cap in USD, when the proxy reported it.\n */\n",
|
|
3605
|
+
"excerptTokens": [
|
|
3606
|
+
{
|
|
3607
|
+
"kind": "Content",
|
|
3608
|
+
"text": "readonly spentUsd?: "
|
|
3609
|
+
},
|
|
3610
|
+
{
|
|
3611
|
+
"kind": "Content",
|
|
3612
|
+
"text": "number"
|
|
3613
|
+
},
|
|
3614
|
+
{
|
|
3615
|
+
"kind": "Content",
|
|
3616
|
+
"text": ";"
|
|
3617
|
+
}
|
|
3618
|
+
],
|
|
3619
|
+
"isReadonly": true,
|
|
3620
|
+
"isOptional": true,
|
|
3621
|
+
"releaseTag": "Beta",
|
|
3622
|
+
"name": "spentUsd",
|
|
3623
|
+
"propertyTypeTokenRange": {
|
|
3624
|
+
"startIndex": 1,
|
|
3625
|
+
"endIndex": 2
|
|
3626
|
+
},
|
|
3627
|
+
"isStatic": false,
|
|
3628
|
+
"isProtected": false,
|
|
3629
|
+
"isAbstract": false
|
|
3630
|
+
},
|
|
3631
|
+
{
|
|
3632
|
+
"kind": "Property",
|
|
3633
|
+
"canonicalReference": "@genesislcap/foundation-ai!BudgetExhaustedError#vendorLabel:member",
|
|
3634
|
+
"docComment": "/**\n * Vendor label of the transport that was refused (e.g. `'Anthropic'`).\n */\n",
|
|
3635
|
+
"excerptTokens": [
|
|
3636
|
+
{
|
|
3637
|
+
"kind": "Content",
|
|
3638
|
+
"text": "readonly vendorLabel: "
|
|
3639
|
+
},
|
|
3640
|
+
{
|
|
3641
|
+
"kind": "Content",
|
|
3642
|
+
"text": "string"
|
|
3643
|
+
},
|
|
3644
|
+
{
|
|
3645
|
+
"kind": "Content",
|
|
3646
|
+
"text": ";"
|
|
3647
|
+
}
|
|
3648
|
+
],
|
|
3649
|
+
"isReadonly": true,
|
|
3650
|
+
"isOptional": false,
|
|
3651
|
+
"releaseTag": "Beta",
|
|
3652
|
+
"name": "vendorLabel",
|
|
3653
|
+
"propertyTypeTokenRange": {
|
|
3654
|
+
"startIndex": 1,
|
|
3655
|
+
"endIndex": 2
|
|
3656
|
+
},
|
|
3657
|
+
"isStatic": false,
|
|
3658
|
+
"isProtected": false,
|
|
3659
|
+
"isAbstract": false
|
|
3660
|
+
}
|
|
3661
|
+
],
|
|
3662
|
+
"extendsTokenRange": {
|
|
3663
|
+
"startIndex": 1,
|
|
3664
|
+
"endIndex": 2
|
|
3665
|
+
},
|
|
3666
|
+
"implementsTokenRanges": []
|
|
3667
|
+
},
|
|
3668
|
+
{
|
|
3669
|
+
"kind": "Function",
|
|
3670
|
+
"canonicalReference": "@genesislcap/foundation-ai!buildTierProviders:function(1)",
|
|
3671
|
+
"docComment": "/**\n * Builds one {@link AIProvider} per tier for a vendor, ready to register under the tier names agents resolve (`low` / `high` / `reasoning`).\n *\n * @remarks\n *\n * Each provider carries its tier's model, output ceiling (Anthropic) and both clocks, so no tier can silently fall back to the transport defaults — which is how a large tool write ends up truncated at 4096 tokens.\n *\n * @example\n * ```ts\n * registerAIProviders(\n * container,\n * buildTierProviders({ vendor: 'gemini', serverEndpoint: (v) => `/gwf/ai-service/${v}/chat` }),\n * { default: 'high' },\n * );\n * ```\n *\n * @beta\n */\n",
|
|
3672
|
+
"excerptTokens": [
|
|
3673
|
+
{
|
|
3674
|
+
"kind": "Content",
|
|
3675
|
+
"text": "export declare function buildTierProviders(options: "
|
|
3676
|
+
},
|
|
3677
|
+
{
|
|
3678
|
+
"kind": "Reference",
|
|
3679
|
+
"text": "BuildTierProvidersOptions",
|
|
3680
|
+
"canonicalReference": "@genesislcap/foundation-ai!BuildTierProvidersOptions:interface"
|
|
3681
|
+
},
|
|
3682
|
+
{
|
|
3683
|
+
"kind": "Content",
|
|
3684
|
+
"text": "): "
|
|
3685
|
+
},
|
|
3686
|
+
{
|
|
3687
|
+
"kind": "Reference",
|
|
3688
|
+
"text": "Record",
|
|
3689
|
+
"canonicalReference": "!Record:type"
|
|
3690
|
+
},
|
|
3691
|
+
{
|
|
3692
|
+
"kind": "Content",
|
|
3693
|
+
"text": "<"
|
|
3694
|
+
},
|
|
3695
|
+
{
|
|
3696
|
+
"kind": "Reference",
|
|
3697
|
+
"text": "AITierId",
|
|
3698
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierId:type"
|
|
3699
|
+
},
|
|
3700
|
+
{
|
|
3701
|
+
"kind": "Content",
|
|
3702
|
+
"text": ", "
|
|
3703
|
+
},
|
|
3704
|
+
{
|
|
3705
|
+
"kind": "Reference",
|
|
3706
|
+
"text": "AIProvider",
|
|
3707
|
+
"canonicalReference": "@genesislcap/foundation-ai!AIProvider:interface"
|
|
3708
|
+
},
|
|
3709
|
+
{
|
|
3710
|
+
"kind": "Content",
|
|
3711
|
+
"text": ">"
|
|
3712
|
+
},
|
|
3713
|
+
{
|
|
3714
|
+
"kind": "Content",
|
|
3715
|
+
"text": ";"
|
|
3716
|
+
}
|
|
3717
|
+
],
|
|
3718
|
+
"fileUrlPath": "src/tiers/build-tier-providers.ts",
|
|
3719
|
+
"returnTypeTokenRange": {
|
|
3720
|
+
"startIndex": 3,
|
|
3721
|
+
"endIndex": 9
|
|
3722
|
+
},
|
|
3723
|
+
"releaseTag": "Beta",
|
|
3724
|
+
"overloadIndex": 1,
|
|
3725
|
+
"parameters": [
|
|
3726
|
+
{
|
|
3727
|
+
"parameterName": "options",
|
|
3728
|
+
"parameterTypeTokenRange": {
|
|
3729
|
+
"startIndex": 1,
|
|
3730
|
+
"endIndex": 2
|
|
3731
|
+
},
|
|
3732
|
+
"isOptional": false
|
|
3733
|
+
}
|
|
3734
|
+
],
|
|
3735
|
+
"name": "buildTierProviders"
|
|
3736
|
+
},
|
|
3737
|
+
{
|
|
3738
|
+
"kind": "Interface",
|
|
3739
|
+
"canonicalReference": "@genesislcap/foundation-ai!BuildTierProvidersOptions:interface",
|
|
3740
|
+
"docComment": "/**\n * Options for {@link buildTierProviders}.\n *\n * @beta\n */\n",
|
|
3741
|
+
"excerptTokens": [
|
|
3026
3742
|
{
|
|
3027
|
-
"kind": "
|
|
3028
|
-
"
|
|
3029
|
-
|
|
3743
|
+
"kind": "Content",
|
|
3744
|
+
"text": "export interface BuildTierProvidersOptions "
|
|
3745
|
+
}
|
|
3746
|
+
],
|
|
3747
|
+
"fileUrlPath": "src/tiers/build-tier-providers.ts",
|
|
3748
|
+
"releaseTag": "Beta",
|
|
3749
|
+
"name": "BuildTierProvidersOptions",
|
|
3750
|
+
"preserveMemberOrder": false,
|
|
3751
|
+
"members": [
|
|
3752
|
+
{
|
|
3753
|
+
"kind": "PropertySignature",
|
|
3754
|
+
"canonicalReference": "@genesislcap/foundation-ai!BuildTierProvidersOptions#serverEndpoint:member",
|
|
3755
|
+
"docComment": "/**\n * The proxy endpoint every tier posts to — a string, or a function of the vendor for a caller that builds more than one vendor from one rule (see the example below).\n *\n * Always a server endpoint, never an API key: these providers are meant for an app whose keys stay on its server. An empty endpoint throws here rather than at the first turn.\n */\n",
|
|
3030
3756
|
"excerptTokens": [
|
|
3031
3757
|
{
|
|
3032
3758
|
"kind": "Content",
|
|
3033
|
-
"text": "
|
|
3759
|
+
"text": "serverEndpoint: "
|
|
3034
3760
|
},
|
|
3035
3761
|
{
|
|
3036
3762
|
"kind": "Content",
|
|
3037
|
-
"text": "
|
|
3763
|
+
"text": "string | ((vendor: "
|
|
3038
3764
|
},
|
|
3039
3765
|
{
|
|
3040
|
-
"kind": "
|
|
3041
|
-
"text": "
|
|
3042
|
-
|
|
3043
|
-
],
|
|
3044
|
-
"isReadonly": true,
|
|
3045
|
-
"isOptional": true,
|
|
3046
|
-
"releaseTag": "Beta",
|
|
3047
|
-
"name": "otherVendorAvailable",
|
|
3048
|
-
"propertyTypeTokenRange": {
|
|
3049
|
-
"startIndex": 1,
|
|
3050
|
-
"endIndex": 2
|
|
3051
|
-
},
|
|
3052
|
-
"isStatic": false,
|
|
3053
|
-
"isProtected": false,
|
|
3054
|
-
"isAbstract": false
|
|
3055
|
-
},
|
|
3056
|
-
{
|
|
3057
|
-
"kind": "Property",
|
|
3058
|
-
"canonicalReference": "@genesislcap/foundation-ai!BudgetExhaustedError#serverVendor:member",
|
|
3059
|
-
"docComment": "/**\n * The vendor the **proxy** says it refused, verbatim from the 402's `vendor`.\n *\n * A second opinion, not the first: {@link BudgetExhaustedError.vendorLabel} comes from the transport that was actually called and wins wherever it resolves. This one rescues attribution when the transport's label does not — a white-labelled or multiplexing gateway whose single transport fronts more than one upstream stamps one static label for all of them, and only the proxy knows which pot the request was actually booked against.\n */\n",
|
|
3060
|
-
"excerptTokens": [
|
|
3061
|
-
{
|
|
3062
|
-
"kind": "Content",
|
|
3063
|
-
"text": "readonly serverVendor?: "
|
|
3766
|
+
"kind": "Reference",
|
|
3767
|
+
"text": "AITierVendor",
|
|
3768
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierVendor:type"
|
|
3064
3769
|
},
|
|
3065
3770
|
{
|
|
3066
3771
|
"kind": "Content",
|
|
3067
|
-
"text": "string"
|
|
3772
|
+
"text": ") => string)"
|
|
3068
3773
|
},
|
|
3069
3774
|
{
|
|
3070
3775
|
"kind": "Content",
|
|
3071
3776
|
"text": ";"
|
|
3072
3777
|
}
|
|
3073
3778
|
],
|
|
3074
|
-
"isReadonly":
|
|
3075
|
-
"isOptional":
|
|
3779
|
+
"isReadonly": false,
|
|
3780
|
+
"isOptional": false,
|
|
3076
3781
|
"releaseTag": "Beta",
|
|
3077
|
-
"name": "
|
|
3782
|
+
"name": "serverEndpoint",
|
|
3078
3783
|
"propertyTypeTokenRange": {
|
|
3079
3784
|
"startIndex": 1,
|
|
3080
|
-
"endIndex":
|
|
3081
|
-
}
|
|
3082
|
-
"isStatic": false,
|
|
3083
|
-
"isProtected": false,
|
|
3084
|
-
"isAbstract": false
|
|
3785
|
+
"endIndex": 4
|
|
3786
|
+
}
|
|
3085
3787
|
},
|
|
3086
3788
|
{
|
|
3087
|
-
"kind": "
|
|
3088
|
-
"canonicalReference": "@genesislcap/foundation-ai!
|
|
3089
|
-
"docComment": "/**\n *
|
|
3789
|
+
"kind": "PropertySignature",
|
|
3790
|
+
"canonicalReference": "@genesislcap/foundation-ai!BuildTierProvidersOptions#tiers:member",
|
|
3791
|
+
"docComment": "/**\n * The table to build from. Defaults to {@link DEFAULT_AI_TIERS}.\n */\n",
|
|
3090
3792
|
"excerptTokens": [
|
|
3091
3793
|
{
|
|
3092
3794
|
"kind": "Content",
|
|
3093
|
-
"text": "
|
|
3795
|
+
"text": "tiers?: "
|
|
3094
3796
|
},
|
|
3095
3797
|
{
|
|
3096
|
-
"kind": "
|
|
3097
|
-
"text": "
|
|
3798
|
+
"kind": "Reference",
|
|
3799
|
+
"text": "AITiers",
|
|
3800
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITiers:interface"
|
|
3098
3801
|
},
|
|
3099
3802
|
{
|
|
3100
3803
|
"kind": "Content",
|
|
3101
3804
|
"text": ";"
|
|
3102
3805
|
}
|
|
3103
3806
|
],
|
|
3104
|
-
"isReadonly":
|
|
3807
|
+
"isReadonly": false,
|
|
3105
3808
|
"isOptional": true,
|
|
3106
3809
|
"releaseTag": "Beta",
|
|
3107
|
-
"name": "
|
|
3810
|
+
"name": "tiers",
|
|
3108
3811
|
"propertyTypeTokenRange": {
|
|
3109
3812
|
"startIndex": 1,
|
|
3110
3813
|
"endIndex": 2
|
|
3111
|
-
}
|
|
3112
|
-
"isStatic": false,
|
|
3113
|
-
"isProtected": false,
|
|
3114
|
-
"isAbstract": false
|
|
3814
|
+
}
|
|
3115
3815
|
},
|
|
3116
3816
|
{
|
|
3117
|
-
"kind": "
|
|
3118
|
-
"canonicalReference": "@genesislcap/foundation-ai!
|
|
3119
|
-
"docComment": "/**\n *
|
|
3817
|
+
"kind": "PropertySignature",
|
|
3818
|
+
"canonicalReference": "@genesislcap/foundation-ai!BuildTierProvidersOptions#vendor:member",
|
|
3819
|
+
"docComment": "/**\n * Which vendor's models to build.\n */\n",
|
|
3120
3820
|
"excerptTokens": [
|
|
3121
3821
|
{
|
|
3122
3822
|
"kind": "Content",
|
|
3123
|
-
"text": "
|
|
3823
|
+
"text": "vendor: "
|
|
3124
3824
|
},
|
|
3125
3825
|
{
|
|
3126
|
-
"kind": "
|
|
3127
|
-
"text": "
|
|
3826
|
+
"kind": "Reference",
|
|
3827
|
+
"text": "AITierVendor",
|
|
3828
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierVendor:type"
|
|
3128
3829
|
},
|
|
3129
3830
|
{
|
|
3130
3831
|
"kind": "Content",
|
|
3131
3832
|
"text": ";"
|
|
3132
3833
|
}
|
|
3133
3834
|
],
|
|
3134
|
-
"isReadonly":
|
|
3835
|
+
"isReadonly": false,
|
|
3135
3836
|
"isOptional": false,
|
|
3136
3837
|
"releaseTag": "Beta",
|
|
3137
|
-
"name": "
|
|
3838
|
+
"name": "vendor",
|
|
3138
3839
|
"propertyTypeTokenRange": {
|
|
3139
3840
|
"startIndex": 1,
|
|
3140
3841
|
"endIndex": 2
|
|
3141
|
-
}
|
|
3142
|
-
"isStatic": false,
|
|
3143
|
-
"isProtected": false,
|
|
3144
|
-
"isAbstract": false
|
|
3842
|
+
}
|
|
3145
3843
|
}
|
|
3146
3844
|
],
|
|
3147
|
-
"
|
|
3148
|
-
"startIndex": 1,
|
|
3149
|
-
"endIndex": 2
|
|
3150
|
-
},
|
|
3151
|
-
"implementsTokenRanges": []
|
|
3845
|
+
"extendsTokenRanges": []
|
|
3152
3846
|
},
|
|
3153
3847
|
{
|
|
3154
3848
|
"kind": "TypeAlias",
|
|
@@ -8787,6 +9481,30 @@
|
|
|
8787
9481
|
],
|
|
8788
9482
|
"extendsTokenRanges": []
|
|
8789
9483
|
},
|
|
9484
|
+
{
|
|
9485
|
+
"kind": "Variable",
|
|
9486
|
+
"canonicalReference": "@genesislcap/foundation-ai!DEFAULT_AI_TIERS:var",
|
|
9487
|
+
"docComment": "/**\n * The platform's default tier table.\n *\n * @remarks\n *\n * Frozen, because it is shared by every app in the process: {@link resolveAITiers} returns a fresh object for callers that override, and hands this back untouched for callers that do not.\n *\n * The models are the ones Genesis Create has been running these tiers on in production — except Anthropic's `reasoning`, moved to `claude-opus-4-8` (see its entry) — and they are a **benchmark result, not a preference**: re-bench before moving one. Two of the Gemini defaults carry a caveat recorded beside them, a preview model and an introductory rate. Two dates are already on the calendar for that: `gemini-3.8-flash` sits on an introductory rate that doubles on 2027-01-01 (at which point it is dearer on input than the model it replaced), and `token-cost.test.ts` fails the build that day; `ai-tiers.test.ts` fails alongside it saying the High tier is the thing to re-bench.\n *\n * Every model here must be in `SUPPORTED_*_MODEL_IDS` with a context limit and a price — pinned by tests, because an unpriced model silently bills at nothing.\n *\n * @beta\n */\n",
|
|
9488
|
+
"excerptTokens": [
|
|
9489
|
+
{
|
|
9490
|
+
"kind": "Content",
|
|
9491
|
+
"text": "DEFAULT_AI_TIERS: "
|
|
9492
|
+
},
|
|
9493
|
+
{
|
|
9494
|
+
"kind": "Reference",
|
|
9495
|
+
"text": "AITiers",
|
|
9496
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITiers:interface"
|
|
9497
|
+
}
|
|
9498
|
+
],
|
|
9499
|
+
"fileUrlPath": "src/tiers/ai-tiers.ts",
|
|
9500
|
+
"isReadonly": true,
|
|
9501
|
+
"releaseTag": "Beta",
|
|
9502
|
+
"name": "DEFAULT_AI_TIERS",
|
|
9503
|
+
"variableTypeTokenRange": {
|
|
9504
|
+
"startIndex": 1,
|
|
9505
|
+
"endIndex": 2
|
|
9506
|
+
}
|
|
9507
|
+
},
|
|
8790
9508
|
{
|
|
8791
9509
|
"kind": "Variable",
|
|
8792
9510
|
"canonicalReference": "@genesislcap/foundation-ai!DEFAULT_BUDGET_EXHAUSTED_MESSAGE:var",
|
|
@@ -9647,6 +10365,106 @@
|
|
|
9647
10365
|
],
|
|
9648
10366
|
"name": "geminiRatesFor"
|
|
9649
10367
|
},
|
|
10368
|
+
{
|
|
10369
|
+
"kind": "Interface",
|
|
10370
|
+
"canonicalReference": "@genesislcap/foundation-ai!GeminiTierConfig:interface",
|
|
10371
|
+
"docComment": "/**\n * What one tier is worth on Gemini.\n *\n * No `maxTokens`: `GeminiAIConfig` has no such field and the provider's own (much larger) default applies, so Gemini writes never hit the Anthropic wall above.\n *\n * @beta\n */\n",
|
|
10372
|
+
"excerptTokens": [
|
|
10373
|
+
{
|
|
10374
|
+
"kind": "Content",
|
|
10375
|
+
"text": "export interface GeminiTierConfig "
|
|
10376
|
+
}
|
|
10377
|
+
],
|
|
10378
|
+
"fileUrlPath": "src/tiers/ai-tiers.ts",
|
|
10379
|
+
"releaseTag": "Beta",
|
|
10380
|
+
"name": "GeminiTierConfig",
|
|
10381
|
+
"preserveMemberOrder": false,
|
|
10382
|
+
"members": [
|
|
10383
|
+
{
|
|
10384
|
+
"kind": "PropertySignature",
|
|
10385
|
+
"canonicalReference": "@genesislcap/foundation-ai!GeminiTierConfig#model:member",
|
|
10386
|
+
"docComment": "",
|
|
10387
|
+
"excerptTokens": [
|
|
10388
|
+
{
|
|
10389
|
+
"kind": "Content",
|
|
10390
|
+
"text": "model: "
|
|
10391
|
+
},
|
|
10392
|
+
{
|
|
10393
|
+
"kind": "Reference",
|
|
10394
|
+
"text": "GeminiModelId",
|
|
10395
|
+
"canonicalReference": "@genesislcap/foundation-ai!GeminiModelId:type"
|
|
10396
|
+
},
|
|
10397
|
+
{
|
|
10398
|
+
"kind": "Content",
|
|
10399
|
+
"text": ";"
|
|
10400
|
+
}
|
|
10401
|
+
],
|
|
10402
|
+
"isReadonly": false,
|
|
10403
|
+
"isOptional": false,
|
|
10404
|
+
"releaseTag": "Beta",
|
|
10405
|
+
"name": "model",
|
|
10406
|
+
"propertyTypeTokenRange": {
|
|
10407
|
+
"startIndex": 1,
|
|
10408
|
+
"endIndex": 2
|
|
10409
|
+
}
|
|
10410
|
+
},
|
|
10411
|
+
{
|
|
10412
|
+
"kind": "PropertySignature",
|
|
10413
|
+
"canonicalReference": "@genesislcap/foundation-ai!GeminiTierConfig#stallTimeoutMs:member",
|
|
10414
|
+
"docComment": "/**\n * Inactivity window on a stream that has started.\n */\n",
|
|
10415
|
+
"excerptTokens": [
|
|
10416
|
+
{
|
|
10417
|
+
"kind": "Content",
|
|
10418
|
+
"text": "stallTimeoutMs: "
|
|
10419
|
+
},
|
|
10420
|
+
{
|
|
10421
|
+
"kind": "Content",
|
|
10422
|
+
"text": "number"
|
|
10423
|
+
},
|
|
10424
|
+
{
|
|
10425
|
+
"kind": "Content",
|
|
10426
|
+
"text": ";"
|
|
10427
|
+
}
|
|
10428
|
+
],
|
|
10429
|
+
"isReadonly": false,
|
|
10430
|
+
"isOptional": false,
|
|
10431
|
+
"releaseTag": "Beta",
|
|
10432
|
+
"name": "stallTimeoutMs",
|
|
10433
|
+
"propertyTypeTokenRange": {
|
|
10434
|
+
"startIndex": 1,
|
|
10435
|
+
"endIndex": 2
|
|
10436
|
+
}
|
|
10437
|
+
},
|
|
10438
|
+
{
|
|
10439
|
+
"kind": "PropertySignature",
|
|
10440
|
+
"canonicalReference": "@genesislcap/foundation-ai!GeminiTierConfig#timeoutMs:member",
|
|
10441
|
+
"docComment": "/**\n * Ceiling on the wait for the FIRST byte — a different clock from the stall one.\n */\n",
|
|
10442
|
+
"excerptTokens": [
|
|
10443
|
+
{
|
|
10444
|
+
"kind": "Content",
|
|
10445
|
+
"text": "timeoutMs: "
|
|
10446
|
+
},
|
|
10447
|
+
{
|
|
10448
|
+
"kind": "Content",
|
|
10449
|
+
"text": "number"
|
|
10450
|
+
},
|
|
10451
|
+
{
|
|
10452
|
+
"kind": "Content",
|
|
10453
|
+
"text": ";"
|
|
10454
|
+
}
|
|
10455
|
+
],
|
|
10456
|
+
"isReadonly": false,
|
|
10457
|
+
"isOptional": false,
|
|
10458
|
+
"releaseTag": "Beta",
|
|
10459
|
+
"name": "timeoutMs",
|
|
10460
|
+
"propertyTypeTokenRange": {
|
|
10461
|
+
"startIndex": 1,
|
|
10462
|
+
"endIndex": 2
|
|
10463
|
+
}
|
|
10464
|
+
}
|
|
10465
|
+
],
|
|
10466
|
+
"extendsTokenRanges": []
|
|
10467
|
+
},
|
|
9650
10468
|
{
|
|
9651
10469
|
"kind": "Function",
|
|
9652
10470
|
"canonicalReference": "@genesislcap/foundation-ai!geminiTokenCost:function(1)",
|
|
@@ -12278,6 +13096,53 @@
|
|
|
12278
13096
|
],
|
|
12279
13097
|
"extendsTokenRanges": []
|
|
12280
13098
|
},
|
|
13099
|
+
{
|
|
13100
|
+
"kind": "Function",
|
|
13101
|
+
"canonicalReference": "@genesislcap/foundation-ai!resolveAITiers:function(1)",
|
|
13102
|
+
"docComment": "/**\n * The table an app should actually use: {@link DEFAULT_AI_TIERS} with `overrides` applied per field, so an app that wants one model moved says only that and keeps the platform's clocks and ceilings.\n *\n * @remarks\n *\n * An override field set to `undefined` is skipped, exactly as if it had been left out. The common caller passes an optional config value straight through (`{ high: { model: appConfig.model } }`), and copying `undefined` over the default would hand the transport no model at all — it then quietly falls back to its own default, with nothing logged.\n *\n * The result is frozen whether or not anything was overridden, so whether mutating it throws does not depend on what the caller passed. The default itself is returned untouched when there is nothing to override, and is never mutated, which matters because it is shared across every app in the process.\n *\n * @example\n * ```ts\n * // Keep everything, but run the reasoning tier on Fable.\n * const tiers = resolveAITiers({ anthropic: { reasoning: { model: 'claude-fable-5' } } });\n * ```\n *\n * @beta\n */\n",
|
|
13103
|
+
"excerptTokens": [
|
|
13104
|
+
{
|
|
13105
|
+
"kind": "Content",
|
|
13106
|
+
"text": "export declare function resolveAITiers(overrides?: "
|
|
13107
|
+
},
|
|
13108
|
+
{
|
|
13109
|
+
"kind": "Reference",
|
|
13110
|
+
"text": "AITierOverrides",
|
|
13111
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITierOverrides:interface"
|
|
13112
|
+
},
|
|
13113
|
+
{
|
|
13114
|
+
"kind": "Content",
|
|
13115
|
+
"text": "): "
|
|
13116
|
+
},
|
|
13117
|
+
{
|
|
13118
|
+
"kind": "Reference",
|
|
13119
|
+
"text": "AITiers",
|
|
13120
|
+
"canonicalReference": "@genesislcap/foundation-ai!AITiers:interface"
|
|
13121
|
+
},
|
|
13122
|
+
{
|
|
13123
|
+
"kind": "Content",
|
|
13124
|
+
"text": ";"
|
|
13125
|
+
}
|
|
13126
|
+
],
|
|
13127
|
+
"fileUrlPath": "src/tiers/ai-tiers.ts",
|
|
13128
|
+
"returnTypeTokenRange": {
|
|
13129
|
+
"startIndex": 3,
|
|
13130
|
+
"endIndex": 4
|
|
13131
|
+
},
|
|
13132
|
+
"releaseTag": "Beta",
|
|
13133
|
+
"overloadIndex": 1,
|
|
13134
|
+
"parameters": [
|
|
13135
|
+
{
|
|
13136
|
+
"parameterName": "overrides",
|
|
13137
|
+
"parameterTypeTokenRange": {
|
|
13138
|
+
"startIndex": 1,
|
|
13139
|
+
"endIndex": 2
|
|
13140
|
+
},
|
|
13141
|
+
"isOptional": true
|
|
13142
|
+
}
|
|
13143
|
+
],
|
|
13144
|
+
"name": "resolveAITiers"
|
|
13145
|
+
},
|
|
12281
13146
|
{
|
|
12282
13147
|
"kind": "Class",
|
|
12283
13148
|
"canonicalReference": "@genesislcap/foundation-ai!ResponseTruncatedError:class",
|