Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/.OwlBot.lock.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@
# limitations under the License.
docker:
image: gcr.io/cloud-devrel-public-resources/owlbot-python-mono-repo:latest
digest: sha256:2429ab9ff5a11e75f63d1f440523f79b6d246815759f3c3185fbb36b6291b357
digest: sha256:6090b1049e2dc245fb9e7e95df094d15ab212b938e107d76f9d215bd1a8621bf
12 changes: 0 additions & 12 deletions packages/google-ai-generativelanguage/CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -239,18 +239,6 @@ Supported versions can be found in our ``noxfile.py`` `config`_.
.. _config: https://github.com/googleapis/google-cloud-python/blob/main/noxfile.py


We also explicitly decided to support Python 3 beginning with version 3.7.
Reasons for this include:

- Encouraging use of newest versions of Python 3
- Taking the lead of `prominent`_ open-source `projects`_
- `Unicode literal support`_ which allows for a cleaner codebase that
works in both Python 2 and Python 3

.. _prominent: https://docs.djangoproject.com/en/1.9/faq/install/#what-python-version-can-i-use-with-django
.. _projects: http://flask.pocoo.org/docs/0.10/python3/
.. _Unicode literal support: https://www.python.org/dev/peps/pep-0414/

**********
Versioning
**********
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright 2023 Google LLC
# Copyright 2022 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -13,5 +13,4 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#

__version__ = "0.2.1" # {x-release-please-version}
__version__ = "0.1.0" # {x-release-please-version}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright 2023 Google LLC
# Copyright 2022 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -13,5 +13,4 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#

__version__ = "0.2.1" # {x-release-please-version}
__version__ = "0.1.0" # {x-release-please-version}
Original file line number Diff line number Diff line change
Expand Up @@ -139,12 +139,7 @@ class GenerateMessageResponse(proto.Message):
This indicates which ``SafetyCategory``\ (s) blocked a
candidate from this response, the lowest ``HarmProbability``
that triggered a block, and the HarmThreshold setting for
that category. This indicates the smallest change to the
``SafetySettings`` that would be necessary to unblock at
least 1 response.

The blocking is configured by the ``SafetySettings`` in the
request (or the default ``SafetySettings`` of the API).
that category.
"""

candidates: MutableSequence["Message"] = proto.RepeatedField(
Expand Down Expand Up @@ -286,10 +281,10 @@ class Example(proto.Message):

Attributes:
input (google.ai.generativelanguage_v1beta2.types.Message):
An example of an input ``Message`` from the user.
Required. An example of an input ``Message`` from the user.
output (google.ai.generativelanguage_v1beta2.types.Message):
An example of what the model should output
given the input.
Required. An example of what the model should
output given the input.
"""

input: "Message" = proto.Field(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -223,14 +223,11 @@ class HarmBlockThreshold(proto.Enum):
BLOCK_ONLY_HIGH (3):
Content with NEGLIGIBLE, LOW, and MEDIUM will
be allowed.
BLOCK_NONE (4):
All content will be allowed.
"""
HARM_BLOCK_THRESHOLD_UNSPECIFIED = 0
BLOCK_LOW_AND_ABOVE = 1
BLOCK_MEDIUM_AND_ABOVE = 2
BLOCK_ONLY_HIGH = 3
BLOCK_NONE = 4

category: "HarmCategory" = proto.Field(
proto.ENUM,
Expand Down
3 changes: 1 addition & 2 deletions packages/google-ai-generativelanguage/noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -305,10 +305,9 @@ def docfx(session):

session.install("-e", ".")
session.install(
"sphinx==4.0.1",
"gcp-sphinx-docfx-yaml",
"alabaster",
"recommonmark",
"gcp-sphinx-docfx-yaml",
)

shutil.rmtree(os.path.join("docs", "_build"), ignore_errors=True)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
],
"language": "PYTHON",
"name": "google-ai-generativelanguage",
"version": "0.2.1"
"version": "0.1.0"
},
"snippets": [
{
Expand Down