Skip to content

Commit ac5633a

Browse files
committed
feat: update llm provider and models
1 parent 4653485 commit ac5633a

File tree

1 file changed

+223
-13
lines changed

1 file changed

+223
-13
lines changed

aperag/migration/sql/model_configs_init.sql

Lines changed: 223 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
-- Model configuration initialization SQL script
2-
-- Generated directly from configuration data on 2025-08-08 10:40:53
2+
-- Generated directly from configuration data on 2025-10-14 14:05:20
33
-- This script populates llm_provider and llm_provider_models tables
44

55
BEGIN;
@@ -940,7 +940,7 @@ INSERT INTO llm_provider_models (
940940
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
941941
gmt_created, gmt_updated
942942
) VALUES (
943-
'openai', 'completion', 'gpt-5', 'openai', 400000, 400000, 128000, '["vision", "__autogen__"]'::jsonb,
943+
'openai', 'completion', 'gpt-5', 'openai', 272000, 272000, 128000, '["vision", "__autogen__"]'::jsonb,
944944
NOW(), NOW()
945945
)
946946
ON CONFLICT (provider_name, api, model) DO UPDATE SET
@@ -955,7 +955,7 @@ INSERT INTO llm_provider_models (
955955
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
956956
gmt_created, gmt_updated
957957
) VALUES (
958-
'openai', 'completion', 'gpt-5-2025-08-07', 'openai', 400000, 400000, 128000, '["vision", "__autogen__"]'::jsonb,
958+
'openai', 'completion', 'gpt-5-2025-08-07', 'openai', 272000, 272000, 128000, '["vision", "__autogen__"]'::jsonb,
959959
NOW(), NOW()
960960
)
961961
ON CONFLICT (provider_name, api, model) DO UPDATE SET
@@ -970,7 +970,7 @@ INSERT INTO llm_provider_models (
970970
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
971971
gmt_created, gmt_updated
972972
) VALUES (
973-
'openai', 'completion', 'gpt-5-chat', 'openai', 1047576, 1047576, 32768, '["vision", "__autogen__"]'::jsonb,
973+
'openai', 'completion', 'gpt-5-chat', 'openai', 272000, 272000, 128000, '["vision", "__autogen__"]'::jsonb,
974974
NOW(), NOW()
975975
)
976976
ON CONFLICT (provider_name, api, model) DO UPDATE SET
@@ -985,7 +985,7 @@ INSERT INTO llm_provider_models (
985985
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
986986
gmt_created, gmt_updated
987987
) VALUES (
988-
'openai', 'completion', 'gpt-5-chat-latest', 'openai', 400000, 400000, 128000, '["vision", "__autogen__"]'::jsonb,
988+
'openai', 'completion', 'gpt-5-chat-latest', 'openai', 128000, 128000, 16384, '["vision", "__autogen__"]'::jsonb,
989989
NOW(), NOW()
990990
)
991991
ON CONFLICT (provider_name, api, model) DO UPDATE SET
@@ -1000,7 +1000,7 @@ INSERT INTO llm_provider_models (
10001000
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
10011001
gmt_created, gmt_updated
10021002
) VALUES (
1003-
'openai', 'completion', 'gpt-5-mini', 'openai', 400000, 400000, 128000, '["vision", "__autogen__"]'::jsonb,
1003+
'openai', 'completion', 'gpt-5-mini', 'openai', 272000, 272000, 128000, '["vision", "__autogen__"]'::jsonb,
10041004
NOW(), NOW()
10051005
)
10061006
ON CONFLICT (provider_name, api, model) DO UPDATE SET
@@ -1015,7 +1015,7 @@ INSERT INTO llm_provider_models (
10151015
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
10161016
gmt_created, gmt_updated
10171017
) VALUES (
1018-
'openai', 'completion', 'gpt-5-mini-2025-08-07', 'openai', 400000, 400000, 128000, '["vision", "__autogen__"]'::jsonb,
1018+
'openai', 'completion', 'gpt-5-mini-2025-08-07', 'openai', 272000, 272000, 128000, '["vision", "__autogen__"]'::jsonb,
10191019
NOW(), NOW()
10201020
)
10211021
ON CONFLICT (provider_name, api, model) DO UPDATE SET
@@ -1030,7 +1030,7 @@ INSERT INTO llm_provider_models (
10301030
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
10311031
gmt_created, gmt_updated
10321032
) VALUES (
1033-
'openai', 'completion', 'gpt-5-nano', 'openai', 400000, 400000, 128000, '["vision", "__autogen__"]'::jsonb,
1033+
'openai', 'completion', 'gpt-5-nano', 'openai', 272000, 272000, 128000, '["vision", "__autogen__"]'::jsonb,
10341034
NOW(), NOW()
10351035
)
10361036
ON CONFLICT (provider_name, api, model) DO UPDATE SET
@@ -1045,7 +1045,52 @@ INSERT INTO llm_provider_models (
10451045
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
10461046
gmt_created, gmt_updated
10471047
) VALUES (
1048-
'openai', 'completion', 'gpt-5-nano-2025-08-07', 'openai', 400000, 400000, 128000, '["vision", "__autogen__"]'::jsonb,
1048+
'openai', 'completion', 'gpt-5-nano-2025-08-07', 'openai', 272000, 272000, 128000, '["vision", "__autogen__"]'::jsonb,
1049+
NOW(), NOW()
1050+
)
1051+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
1052+
custom_llm_provider = EXCLUDED.custom_llm_provider,
1053+
context_window = EXCLUDED.context_window,
1054+
max_input_tokens = EXCLUDED.max_input_tokens,
1055+
max_output_tokens = EXCLUDED.max_output_tokens,
1056+
tags = EXCLUDED.tags,
1057+
gmt_updated = NOW();
1058+
1059+
INSERT INTO llm_provider_models (
1060+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
1061+
gmt_created, gmt_updated
1062+
) VALUES (
1063+
'openai', 'completion', 'gpt-realtime', 'openai', 32000, 32000, 4096, '["__autogen__"]'::jsonb,
1064+
NOW(), NOW()
1065+
)
1066+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
1067+
custom_llm_provider = EXCLUDED.custom_llm_provider,
1068+
context_window = EXCLUDED.context_window,
1069+
max_input_tokens = EXCLUDED.max_input_tokens,
1070+
max_output_tokens = EXCLUDED.max_output_tokens,
1071+
tags = EXCLUDED.tags,
1072+
gmt_updated = NOW();
1073+
1074+
INSERT INTO llm_provider_models (
1075+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
1076+
gmt_created, gmt_updated
1077+
) VALUES (
1078+
'openai', 'completion', 'gpt-realtime-2025-08-28', 'openai', 32000, 32000, 4096, '["__autogen__"]'::jsonb,
1079+
NOW(), NOW()
1080+
)
1081+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
1082+
custom_llm_provider = EXCLUDED.custom_llm_provider,
1083+
context_window = EXCLUDED.context_window,
1084+
max_input_tokens = EXCLUDED.max_input_tokens,
1085+
max_output_tokens = EXCLUDED.max_output_tokens,
1086+
tags = EXCLUDED.tags,
1087+
gmt_updated = NOW();
1088+
1089+
INSERT INTO llm_provider_models (
1090+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
1091+
gmt_created, gmt_updated
1092+
) VALUES (
1093+
'openai', 'completion', 'gpt-realtime-mini', 'openai', 128000, 128000, 4096, '["__autogen__"]'::jsonb,
10491094
NOW(), NOW()
10501095
)
10511096
ON CONFLICT (provider_name, api, model) DO UPDATE SET
@@ -1406,7 +1451,7 @@ INSERT INTO llm_provider_models (
14061451
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
14071452
gmt_created, gmt_updated
14081453
) VALUES (
1409-
'anthropic', 'completion', 'claude-4-sonnet-20250514', 'anthropic', 200000, 200000, 64000, '["vision", "__autogen__"]'::jsonb,
1454+
'anthropic', 'completion', 'claude-4-sonnet-20250514', 'anthropic', 1000000, 1000000, 64000, '["vision", "__autogen__"]'::jsonb,
14101455
NOW(), NOW()
14111456
)
14121457
ON CONFLICT (provider_name, api, model) DO UPDATE SET
@@ -1466,7 +1511,37 @@ INSERT INTO llm_provider_models (
14661511
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
14671512
gmt_created, gmt_updated
14681513
) VALUES (
1469-
'anthropic', 'completion', 'claude-sonnet-4-20250514', 'anthropic', 200000, 200000, 64000, '["vision", "enable_for_collection", "enable_for_agent", "__autogen__"]'::jsonb,
1514+
'anthropic', 'completion', 'claude-sonnet-4-20250514', 'anthropic', 1000000, 1000000, 64000, '["vision", "enable_for_collection", "enable_for_agent", "__autogen__"]'::jsonb,
1515+
NOW(), NOW()
1516+
)
1517+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
1518+
custom_llm_provider = EXCLUDED.custom_llm_provider,
1519+
context_window = EXCLUDED.context_window,
1520+
max_input_tokens = EXCLUDED.max_input_tokens,
1521+
max_output_tokens = EXCLUDED.max_output_tokens,
1522+
tags = EXCLUDED.tags,
1523+
gmt_updated = NOW();
1524+
1525+
INSERT INTO llm_provider_models (
1526+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
1527+
gmt_created, gmt_updated
1528+
) VALUES (
1529+
'anthropic', 'completion', 'claude-sonnet-4-5', 'anthropic', 200000, 200000, 64000, '["vision", "__autogen__"]'::jsonb,
1530+
NOW(), NOW()
1531+
)
1532+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
1533+
custom_llm_provider = EXCLUDED.custom_llm_provider,
1534+
context_window = EXCLUDED.context_window,
1535+
max_input_tokens = EXCLUDED.max_input_tokens,
1536+
max_output_tokens = EXCLUDED.max_output_tokens,
1537+
tags = EXCLUDED.tags,
1538+
gmt_updated = NOW();
1539+
1540+
INSERT INTO llm_provider_models (
1541+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
1542+
gmt_created, gmt_updated
1543+
) VALUES (
1544+
'anthropic', 'completion', 'claude-sonnet-4-5-20250929', 'anthropic', 200000, 200000, 64000, '["vision", "__autogen__"]'::jsonb,
14701545
NOW(), NOW()
14711546
)
14721547
ON CONFLICT (provider_name, api, model) DO UPDATE SET
@@ -1868,6 +1943,21 @@ ON CONFLICT (provider_name, api, model) DO UPDATE SET
18681943
tags = EXCLUDED.tags,
18691944
gmt_updated = NOW();
18701945

1946+
INSERT INTO llm_provider_models (
1947+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
1948+
gmt_created, gmt_updated
1949+
) VALUES (
1950+
'gemini', 'completion', 'gemini/gemini-2.5-flash-lite-preview-09-2025', 'gemini', 1048576, 1048576, 65535, '["vision", "__autogen__"]'::jsonb,
1951+
NOW(), NOW()
1952+
)
1953+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
1954+
custom_llm_provider = EXCLUDED.custom_llm_provider,
1955+
context_window = EXCLUDED.context_window,
1956+
max_input_tokens = EXCLUDED.max_input_tokens,
1957+
max_output_tokens = EXCLUDED.max_output_tokens,
1958+
tags = EXCLUDED.tags,
1959+
gmt_updated = NOW();
1960+
18711961
INSERT INTO llm_provider_models (
18721962
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
18731963
gmt_created, gmt_updated
@@ -1898,6 +1988,21 @@ ON CONFLICT (provider_name, api, model) DO UPDATE SET
18981988
tags = EXCLUDED.tags,
18991989
gmt_updated = NOW();
19001990

1991+
INSERT INTO llm_provider_models (
1992+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
1993+
gmt_created, gmt_updated
1994+
) VALUES (
1995+
'gemini', 'completion', 'gemini/gemini-2.5-flash-preview-09-2025', 'gemini', 1048576, 1048576, 65535, '["vision", "__autogen__"]'::jsonb,
1996+
NOW(), NOW()
1997+
)
1998+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
1999+
custom_llm_provider = EXCLUDED.custom_llm_provider,
2000+
context_window = EXCLUDED.context_window,
2001+
max_input_tokens = EXCLUDED.max_input_tokens,
2002+
max_output_tokens = EXCLUDED.max_output_tokens,
2003+
tags = EXCLUDED.tags,
2004+
gmt_updated = NOW();
2005+
19012006
INSERT INTO llm_provider_models (
19022007
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
19032008
gmt_created, gmt_updated
@@ -2033,6 +2138,36 @@ ON CONFLICT (provider_name, api, model) DO UPDATE SET
20332138
tags = EXCLUDED.tags,
20342139
gmt_updated = NOW();
20352140

2141+
INSERT INTO llm_provider_models (
2142+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
2143+
gmt_created, gmt_updated
2144+
) VALUES (
2145+
'gemini', 'completion', 'gemini/gemini-flash-latest', 'gemini', 1048576, 1048576, 65535, '["vision", "__autogen__"]'::jsonb,
2146+
NOW(), NOW()
2147+
)
2148+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
2149+
custom_llm_provider = EXCLUDED.custom_llm_provider,
2150+
context_window = EXCLUDED.context_window,
2151+
max_input_tokens = EXCLUDED.max_input_tokens,
2152+
max_output_tokens = EXCLUDED.max_output_tokens,
2153+
tags = EXCLUDED.tags,
2154+
gmt_updated = NOW();
2155+
2156+
INSERT INTO llm_provider_models (
2157+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
2158+
gmt_created, gmt_updated
2159+
) VALUES (
2160+
'gemini', 'completion', 'gemini/gemini-flash-lite-latest', 'gemini', 1048576, 1048576, 65535, '["vision", "__autogen__"]'::jsonb,
2161+
NOW(), NOW()
2162+
)
2163+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
2164+
custom_llm_provider = EXCLUDED.custom_llm_provider,
2165+
context_window = EXCLUDED.context_window,
2166+
max_input_tokens = EXCLUDED.max_input_tokens,
2167+
max_output_tokens = EXCLUDED.max_output_tokens,
2168+
tags = EXCLUDED.tags,
2169+
gmt_updated = NOW();
2170+
20362171
INSERT INTO llm_provider_models (
20372172
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
20382173
gmt_created, gmt_updated
@@ -2379,6 +2514,36 @@ ON CONFLICT (provider_name, api, model) DO UPDATE SET
23792514
tags = EXCLUDED.tags,
23802515
gmt_updated = NOW();
23812516

2517+
INSERT INTO llm_provider_models (
2518+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
2519+
gmt_created, gmt_updated
2520+
) VALUES (
2521+
'xai', 'completion', 'xai/grok-4-fast-non-reasoning', 'xai', 2000000.0, 2000000.0, 2000000.0, '["__autogen__"]'::jsonb,
2522+
NOW(), NOW()
2523+
)
2524+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
2525+
custom_llm_provider = EXCLUDED.custom_llm_provider,
2526+
context_window = EXCLUDED.context_window,
2527+
max_input_tokens = EXCLUDED.max_input_tokens,
2528+
max_output_tokens = EXCLUDED.max_output_tokens,
2529+
tags = EXCLUDED.tags,
2530+
gmt_updated = NOW();
2531+
2532+
INSERT INTO llm_provider_models (
2533+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
2534+
gmt_created, gmt_updated
2535+
) VALUES (
2536+
'xai', 'completion', 'xai/grok-4-fast-reasoning', 'xai', 2000000.0, 2000000.0, 2000000.0, '["__autogen__"]'::jsonb,
2537+
NOW(), NOW()
2538+
)
2539+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
2540+
custom_llm_provider = EXCLUDED.custom_llm_provider,
2541+
context_window = EXCLUDED.context_window,
2542+
max_input_tokens = EXCLUDED.max_input_tokens,
2543+
max_output_tokens = EXCLUDED.max_output_tokens,
2544+
tags = EXCLUDED.tags,
2545+
gmt_updated = NOW();
2546+
23822547
INSERT INTO llm_provider_models (
23832548
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
23842549
gmt_created, gmt_updated
@@ -2409,6 +2574,51 @@ ON CONFLICT (provider_name, api, model) DO UPDATE SET
24092574
tags = EXCLUDED.tags,
24102575
gmt_updated = NOW();
24112576

2577+
INSERT INTO llm_provider_models (
2578+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
2579+
gmt_created, gmt_updated
2580+
) VALUES (
2581+
'xai', 'completion', 'xai/grok-code-fast', 'xai', 256000, 256000, 256000, '["__autogen__"]'::jsonb,
2582+
NOW(), NOW()
2583+
)
2584+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
2585+
custom_llm_provider = EXCLUDED.custom_llm_provider,
2586+
context_window = EXCLUDED.context_window,
2587+
max_input_tokens = EXCLUDED.max_input_tokens,
2588+
max_output_tokens = EXCLUDED.max_output_tokens,
2589+
tags = EXCLUDED.tags,
2590+
gmt_updated = NOW();
2591+
2592+
INSERT INTO llm_provider_models (
2593+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
2594+
gmt_created, gmt_updated
2595+
) VALUES (
2596+
'xai', 'completion', 'xai/grok-code-fast-1', 'xai', 256000, 256000, 256000, '["__autogen__"]'::jsonb,
2597+
NOW(), NOW()
2598+
)
2599+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
2600+
custom_llm_provider = EXCLUDED.custom_llm_provider,
2601+
context_window = EXCLUDED.context_window,
2602+
max_input_tokens = EXCLUDED.max_input_tokens,
2603+
max_output_tokens = EXCLUDED.max_output_tokens,
2604+
tags = EXCLUDED.tags,
2605+
gmt_updated = NOW();
2606+
2607+
INSERT INTO llm_provider_models (
2608+
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
2609+
gmt_created, gmt_updated
2610+
) VALUES (
2611+
'xai', 'completion', 'xai/grok-code-fast-1-0825', 'xai', 256000, 256000, 256000, '["__autogen__"]'::jsonb,
2612+
NOW(), NOW()
2613+
)
2614+
ON CONFLICT (provider_name, api, model) DO UPDATE SET
2615+
custom_llm_provider = EXCLUDED.custom_llm_provider,
2616+
context_window = EXCLUDED.context_window,
2617+
max_input_tokens = EXCLUDED.max_input_tokens,
2618+
max_output_tokens = EXCLUDED.max_output_tokens,
2619+
tags = EXCLUDED.tags,
2620+
gmt_updated = NOW();
2621+
24122622
INSERT INTO llm_provider_models (
24132623
provider_name, api, model, custom_llm_provider, context_window, max_input_tokens, max_output_tokens, tags,
24142624
gmt_created, gmt_updated
@@ -8946,6 +9156,6 @@ ON CONFLICT (provider_name, api, model) DO UPDATE SET
89469156

89479157
COMMIT;
89489158

8949-
-- Script completed. Generated on 2025-08-08 10:40:53
9159+
-- Script completed. Generated on 2025-10-14 14:05:20
89509160
-- Total providers: 9
8951-
-- Total models: 584
9161+
-- Total models: 598

0 commit comments

Comments
 (0)