You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+40Lines changed: 40 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -368,6 +368,46 @@ HostedGPT requires these services to be running:
368
368
369
369
Every time you pull new changes down, kill `bin/dev` and then re-run it. This will ensure your local app picks up changes to Gemfile and migrations.
370
370
371
+
## Language models
372
+
373
+
Each User has their own list of Language Models they can use.
374
+
375
+
When a new User is created (when a person registers for the first time), they are initialized with a long list of models. This list is loaded from `models.yml`.
376
+
377
+
When an administrator upgrades their deployment of HostedGPT, they can update the available models for all users with a task `rails models:import`.
378
+
379
+
### Refreshing language models
380
+
381
+
There is a shared list of known LLM models for OpenAI, Anthropic, and Groq in `models.yml` and a Rake task to import them into all users:
382
+
383
+
```plain
384
+
rails models:import
385
+
```
386
+
387
+
### Update models.yml
388
+
389
+
The `models.yml` file in the root of the project is used by HostedGPT applications to refresh their local list of models.
390
+
391
+
To refresh the `models.yml` file using the models in local DB, run:
392
+
393
+
```plain
394
+
rails models:export
395
+
```
396
+
397
+
### Alternate export file
398
+
399
+
If you want to export the models in the local DB to another file, either `.json` or `.yaml`, pass in an argument:
400
+
401
+
```plain
402
+
rails models:export[tmp/models.json]
403
+
```
404
+
405
+
To import from another file, similarly provide the path as an argument:
406
+
407
+
```plain
408
+
rails models:import[tmp/models.json]
409
+
```
410
+
371
411
### Running tests
372
412
373
413
If you're set up with Docker you run `docker compose run base rails test`. Note that the system tests, which use a headless browser, are not able to run in Docker. They will be run automatically for you if you create a Pull Request against the project.
0 commit comments