GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Add Cloud Natural Language API Java sample. by jerjou · Pull Request #275 · GoogleCloudPlatform/java-docs-samples

Conversation

@jerjou

@jerjou jerjou commented Jul 19, 2016

Copy link
Copy Markdown
Contributor

This sample shows how to use the Cloud Natural Language API to do entity
recognition. The client libraries are vendored in while we are in alpha.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Jul 19, 2016
@jerjou jerjou assigned lesv Jul 19, 2016
@jerjou
jerjou force-pushed the nl branch from cfe5f86 to d23cc35 Compare July 19, 2016 23:46
lesv
lesv reviewed Jul 19, 2016
View reviewed changes
Comment thread language/README.md
Please follow the [Set Up Your Project](https://cloud.google.com/natural-language/docs/getting-started#set_up_your_project)
steps in the Quickstart doc to create a project and enable the
Cloud Natural Language API. Following those steps, make sure that you
[Set Up a Service Account](https://cloud.google.com/natural-language/docs/common/auth#set_up_a_service_account),

@lesv lesv Jul 19, 2016

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This really isn't necessary in most instances. But I won't block on it.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@jerjou jerjou Jul 20, 2016

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I dunno - I feel like it's the most failsafe way to do things. The other methods of getting credentials have too many caveats attached to them :-/

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@lesv lesv Jul 20, 2016

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm a huge fan of gcloud for credentials and DefaultAuth.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@jerjou jerjou Jul 20, 2016

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here my (possibly outdated) understanding:

gcloud

  • auth login which works sometimes but fails subtly because it uses user auth on the cloudsdktool project instead of a service account that's attached to the project. Also you'll have to swap this out with a service account anyway once you go to production, if you're not on GCE/GAE.
  • auth activate-service-account which requires downloading a service account anyway, and what happens in your production scripts if you're not on GCE/GAE? I suppose you could have your machine run the gcloud command as part of setup? Seems like more overhead than setting an env variable..
  • In general, requires installing gcloud on every machine you run the code on (unless you're on GAE/GCE)

I assume by DefaultAuth you mean the default service account on GAE/GCE? Which is fine, unless you're not on GAE/GCE, in which case we have to mention that and explain what to do in that case, so it doesn't save any explanation space (though yes - if you are running on GAE/GCE, you can just skip that paragraph).

Point being - it's fine, but there's a lot of explaining and decision points around whether you're on GAE/GCE, that folks probably don't care about when they're looking at a sample like this, so it's simpler to just have one not-too-complex explanation that works in all instances :)

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@lesv lesv Jul 20, 2016

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gcloud beta auth application-default is the latest hotness.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@waprin waprin Jul 20, 2016

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Image of Yaktocat

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@waprin waprin Jul 20, 2016

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately doesn't seem to work :(

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@waprin waprin Jul 20, 2016

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should let Vijay know.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@lesv

lesv commented Jul 20, 2016

Copy link
Copy Markdown
Contributor

@tswast Can you enable the language api's for whatever project we run tests with?
LGTM

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@jerjou
jerjou force-pushed the nl branch from d23cc35 to 2b15150 Compare July 20, 2016 00:07
@jerjou

jerjou commented Jul 20, 2016

Copy link
Copy Markdown
Contributor Author

Removed unnecessary test dependency.
Also added NL api to the test project.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

lesv
lesv reviewed Jul 20, 2016
View reviewed changes
Comment thread language/analysis/pom.xml Outdated
<!-- For checking HTTP response codes. -->
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>3.1.0</version>

@lesv lesv Jul 20, 2016

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't a servlet app, so it's not required here.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@lesv

lesv commented Jul 20, 2016

Copy link
Copy Markdown
Contributor

LGTM - assuming things pass.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@tswast Jerjou Cheng
Add Cloud Natural Language API Java sample.
baf7df5
This sample shows how to use the Cloud Natural Language API to do entity
recognition. The client libraries are vendored in while we are in alpha.

Change-Id: I037901017d0ffb7ffc73cc78c43badaff1dffd3c
@jerjou
jerjou force-pushed the nl branch from 2b15150 to baf7df5 Compare July 20, 2016 00:23
@jerjou

jerjou commented Jul 20, 2016

Copy link
Copy Markdown
Contributor Author

Whoops. Removed the wrong dependency -_-

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@lesv

lesv commented Jul 20, 2016

Copy link
Copy Markdown
Contributor

LGTM once tests pass.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@jerjou
jerjou merged commit d7f1d7f into master Jul 20, 2016
@jerjou
jerjou deleted the nl branch July 20, 2016 00:40
@jerjou jerjou mentioned this pull request Jul 20, 2016
Add samples for natural language api. GoogleCloudPlatform/python-docs-samples#425
Merged
minherz pushed a commit that referenced this pull request Nov 9, 2022
@renovate-bot
chore(deps): update dependency com.google.cloud:libraries-bom to v13 (#…
034bde1
…275)

This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [com.google.cloud:libraries-bom](https://togithub.com/GoogleCloudPlatform/cloud-opensource-java) | major | `12.1.0` -> `13.0.0` |

---

### Renovate configuration

:date: **Schedule**: At any time (no schedule defined).

:vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

:recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

:no_bell: **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-errorreporting).
minherz pushed a commit that referenced this pull request Nov 10, 2022
@renovate-bot @minherz
chore(deps): update dependency com.google.cloud:libraries-bom to v13 (#…
4d5d717
…275)

This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [com.google.cloud:libraries-bom](https://togithub.com/GoogleCloudPlatform/cloud-opensource-java) | major | `12.1.0` -> `13.0.0` |

---

### Renovate configuration

:date: **Schedule**: At any time (no schedule defined).

:vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

:recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

:no_bell: **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-errorreporting).
minherz pushed a commit that referenced this pull request Nov 10, 2022
@renovate-bot @minherz
chore(deps): update dependency com.google.cloud:libraries-bom to v13 (#…
bdaaf65
…275)

This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [com.google.cloud:libraries-bom](https://togithub.com/GoogleCloudPlatform/cloud-opensource-java) | major | `12.1.0` -> `13.0.0` |

---

### Renovate configuration

:date: **Schedule**: At any time (no schedule defined).

:vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

:recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

:no_bell: **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-errorreporting).
charlieyu1996 pushed a commit that referenced this pull request Nov 10, 2022
@saumyasahu-bot @chingor13
samples: add Job Search v4 samples (#275)
62438ad
* Sample code for Jobs - V4

Sample code for Jobs v4 APIs.

* feat: Add Job Search v4 API

* Updated as per comment

* No more required.

samples/snippets/pom.xml will take care of specific version

* Migrated to parent folder

Maintaing v4 as the defacto version for now. Later it can be moved to version specific package if required.

* test: configure extra cts environment variables

* fixed listjobs test

fixed listjobs test

* fixed lint.

Co-authored-by: Jeff Ching <[email protected]>
This was referenced Nov 10, 2022
migrate code from googleapis/java-talent #7401
Closed
migrate code from googleapis/java-talent #7402
Merged
Shabirmean pushed a commit that referenced this pull request Nov 11, 2022
@renovate-bot
deps: update dependency com.google.cloud:google-cloud-bigquery to v2.…
aa7b621
…11.2 (#275)

[![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [com.google.cloud:google-cloud-bigquery](https://togithub.com/googleapis/java-bigquery) | `2.11.1` -> `2.11.2` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-bigquery/2.11.2/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-bigquery/2.11.2/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-bigquery/2.11.2/compatibility-slim/2.11.1)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-bigquery/2.11.2/confidence-slim/2.11.1)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>googleapis/java-bigquery</summary>

### [`v2.11.2`](https://togithub.com/googleapis/java-bigquery/blob/HEAD/CHANGELOG.md#&#8203;2112-httpsgithubcomgoogleapisjava-bigquerycomparev2111v2112-2022-05-18)

[Compare Source](https://togithub.com/googleapis/java-bigquery/compare/v2.11.1...v2.11.2)

</details>

---

### Configuration

📅 **Schedule**: At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, click this checkbox.

---

This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-contact-center-insights).
@Shabirmean Shabirmean mentioned this pull request Nov 11, 2022
samples: migrate code from googleapis/java-contact-center-insights #7411
Merged
9 tasks
Shabirmean pushed a commit that referenced this pull request Nov 11, 2022
@renovate-bot @Shabirmean
deps: update dependency com.google.cloud:google-cloud-bigquery to v2.…
8871336
…11.2 (#275)

[![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [com.google.cloud:google-cloud-bigquery](https://togithub.com/googleapis/java-bigquery) | `2.11.1` -> `2.11.2` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-bigquery/2.11.2/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-bigquery/2.11.2/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-bigquery/2.11.2/compatibility-slim/2.11.1)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-bigquery/2.11.2/confidence-slim/2.11.1)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>googleapis/java-bigquery</summary>

### [`v2.11.2`](https://togithub.com/googleapis/java-bigquery/blob/HEAD/CHANGELOG.md#&#8203;2112-httpsgithubcomgoogleapisjava-bigquerycomparev2111v2112-2022-05-18)

[Compare Source](https://togithub.com/googleapis/java-bigquery/compare/v2.11.1...v2.11.2)

</details>

---

### Configuration

📅 **Schedule**: At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, click this checkbox.

---

This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-contact-center-insights).
Shabirmean pushed a commit that referenced this pull request Nov 16, 2022
@galdawave @gcf-owl-bot
samples: add update intent code sample (#275)
c8f3e2f
* add update intent samples

* Fixed lint

* lint fix

* lint fix

* lint fix

* lint fix

* lint fix

* lint fix

* lint fix

* fixed failing test

* lint fix

* failing test fix

* Fix failing test

* fixed fialing test

* Added Agent Builder

* removed unused builder

* lint fix

* lint fix

* Fixed comments

* Updated main

* Lint fix

* removed return type

* Fix build error

* added exception

* fixed failing test

* added missing include

* Rebased

* 🦉 Updates from OwlBot

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
@Shabirmean Shabirmean mentioned this pull request Nov 16, 2022
samples: migrate code from googleapis/java-dialogflow-cx #7435
Merged
9 tasks
Shabirmean pushed a commit that referenced this pull request Nov 17, 2022
@galdawave @gcf-owl-bot @Shabirmean
samples: add update intent code sample (#275)
32d56f5
* add update intent samples

* Fixed lint

* lint fix

* lint fix

* lint fix

* lint fix

* lint fix

* lint fix

* lint fix

* fixed failing test

* lint fix

* failing test fix

* Fix failing test

* fixed fialing test

* Added Agent Builder

* removed unused builder

* lint fix

* lint fix

* Fixed comments

* Updated main

* Lint fix

* removed return type

* Fix build error

* added exception

* fixed failing test

* added missing include

* Rebased

* 🦉 Updates from OwlBot

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

@lesv lesv

Labels

cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

5 participants

@jerjou @lesv @waprin @googlebot @tswast
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.