Skip to content

Commit

Permalink
docs
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkDaoust committed Oct 11, 2023
1 parent dbeca8e commit d3e8b29
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions google/generativeai/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -226,11 +226,11 @@ def create_tuned_model(
"""Launches a tuning job to create a TunedModel.
Since tuning a model can take significant time, this API doesn't wait for the tuning to complete.
Instead, it returns a `google.api_core.operation.Operation` object that lets you check on the status
of the tuning job, or wait for it to complete, and check the result.
Instead, it returns a `google.api_core.operation.Operation` object that lets you check on the
status of the tuning job, or wait for it to complete, and check the result.
After the job completes you can either find the resulting `TunedModel` object in `Operation.result()`
or `palm.list_tuned_models` or `palm.get_tuned_model(model_id)`.
After the job completes you can either find the resulting `TunedModel` object in
`Operation.result()` or `palm.list_tuned_models` or `palm.get_tuned_model(model_id)`.
```
my_id = "my-tuned-model-id"
Expand All @@ -252,6 +252,16 @@ def create_tuned_model(
*`glm.TuningExample`,
* {'text_input': text_input, 'output': output} dicts, or
* `(text_input, output)` tuples.
* A `Mapping` of `Iterable[str]` - use `input_key` and `output_key` to choose which
columns to use as the input/output
* A csv file (will be read with `pd.read_csv` and handles as a `Mapping`
above). This can be:
* A local path as a `str` or `pathlib.Path`.
* A url for a csv file.
* The url of a Google Sheets file.
* A JSON file - Its contents will be handled either as an `Iterable` or `Mapping`
above. This can be:
* A local path as a `str` or `pathlib.Path`.
id: The model identifier, used to refer to the model in the API
`tunedModels/{id}`. Must be unique.
display_name: A human-readable name for display.
Expand Down

0 comments on commit d3e8b29

Please sign in to comment.