Seed applies the embedded price seed to ai_model_prices table, replacing the price columns of any existing (provider, model) row and inserting new ones. Rows already in the table that no longer appear in the seed are left untouched, so historical entries persist across upstream model deprecations.
(ctx context.Context, db database.Store)
| 36 | // Rows already in the table that no longer appear in the seed are left |
| 37 | // untouched, so historical entries persist across upstream model deprecations. |
| 38 | func Seed(ctx context.Context, db database.Store) error { |
| 39 | return SeedFromBytes(ctx, db, seedJSON) |
| 40 | } |
| 41 | |
| 42 | // SeedFromBytes applies an arbitrary JSON seed. Most callers should use Seed, |
| 43 | // which applies the seed embedded in this binary; SeedFromBytes is exposed |