Skip to content

Commit 076dcc4

Browse files
authored
Merge pull request google-gemini#51 from kinarr/sync-region-tags-for-all-samples
Sync region tags for all samples
2 parents 70ba616 + 4418dc6 commit 076dcc4

9 files changed

+15
-15
lines changed

go/configure_model_parameters.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import (
88
"google.golang.org/genai"
99
)
1010

11-
func ConfigureModel() (*genai.GenerateContentResponse, error) {
11+
func ConfigureModelParameters() (*genai.GenerateContentResponse, error) {
1212
// [START configure_model_parameters]
1313
ctx := context.Background()
1414
client, err := genai.NewClient(ctx, &genai.ClientConfig{

go/configure_model_parameters_test.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ import (
44
"testing"
55
)
66

7-
func TestConfigureModel(t *testing.T) {
8-
_, err := ConfigureModel()
7+
func TestConfigureModelParameters(t *testing.T) {
8+
_, err := ConfigureModelParameters()
99
if err != nil {
10-
t.Errorf("ConfigureModel returned an error.")
10+
t.Errorf("ConfigureModelParameters returned an error.")
1111
}
1212
}

go/embed.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import (
1010
"google.golang.org/genai"
1111
)
1212

13-
func EmbedContentBasic() error {
13+
func EmbedContent() error {
1414
// [START embed_content]
1515
ctx := context.Background()
1616
client, err := genai.NewClient(ctx, &genai.ClientConfig{

go/embed_test.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ import (
44
"testing"
55
)
66

7-
func TestEmbedContentBasic(t *testing.T) {
8-
err := EmbedContentBasic()
7+
func TestEmbedContent(t *testing.T) {
8+
err := EmbedContent()
99
if err != nil {
10-
t.Errorf("EmbedContentBasic returned an error.")
10+
t.Errorf("EmbedContent returned an error.")
1111
}
1212
}
1313

javascript/embed.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export async function embedContent() {
3434
}
3535

3636
export async function batchEmbedContents() {
37-
// [START batch_embed_content]
37+
// [START batch_embed_contents]
3838
// Make sure to include the following import:
3939
// import {GoogleGenAI} from '@google/genai';
4040
const ai = new GoogleGenAI({ apiKey: process.env.GEMINI_API_KEY });
@@ -49,6 +49,6 @@ export async function batchEmbedContents() {
4949
config: { outputDimensionality: 10 },
5050
});
5151
console.log(result.embeddings);
52-
// [END batch_embed_content]
52+
// [END batch_embed_contents]
5353
return result.embeddings;
5454
}

javascript/files.test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ import {
2727
filesGet,
2828
} from "./files.js";
2929

30-
describe("Files API Tests", () => {
30+
describe("files", () => {
3131
test("filesCreateText", async () => {
3232
const text = await filesCreateText();
3333
assert.ok(text && text.length > 0);

javascript/function_calling.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
import { GoogleGenAI, FunctionCallingConfigMode } from "@google/genai";
1919

20-
export async function functionCallingTest() {
20+
export async function functionCalling() {
2121
// [START function_calling]
2222
// Make sure to include the following import:
2323
// import {GoogleGenAI} from '@google/genai';

javascript/function_calling.test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ import { test, describe } from "node:test";
2020
import { functionCallingTest } from "./function_calling.js";
2121

2222
describe("function_calling", () => {
23-
test("functionCallingTest", async () => {
24-
const response = await functionCallingTest();
23+
test("functionCalling", async () => {
24+
const response = await functionCalling();
2525
// Check that the response text is non-empty.
2626
assert.ok(response.text.length > 0);
2727
});

python/configure_model_parameters.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717

1818
class UnitTests(absltest.TestCase):
1919

20-
def test_configure_model(self):
20+
def test_configure_model_parameters(self):
2121
# [START configure_model_parameters]
2222
from google import genai
2323
from google.genai import types

0 commit comments

Comments
 (0)