mirror of
https://github.com/hwchase17/langchain
synced 2024-11-10 01:10:59 +00:00
7734a2b5ab
updating the documentation to be consistent for Golden query tool and have a better introduction to the tool
35 lines
1.4 KiB
Plaintext
35 lines
1.4 KiB
Plaintext
# Golden
|
|
|
|
>[Golden](https://golden.com) provides a set of natural language APIs for querying and enrichment using the Golden Knowledge Graph e.g. queries such as: `Products from OpenAI`, `Generative ai companies with series a funding`, and `rappers who invest` can be used to retrieve structured data about relevant entities.
|
|
>
|
|
>The `golden-query` langchain tool is a wrapper on top of the [Golden Query API](https://docs.golden.com/reference/query-api) which enables programmatic access to these results.
|
|
>See the [Golden Query API docs](https://docs.golden.com/reference/query-api) for more information.
|
|
|
|
## Installation and Setup
|
|
- Go to the [Golden API docs](https://docs.golden.com/) to get an overview about the Golden API.
|
|
- Get your API key from the [Golden API Settings](https://golden.com/settings/api) page.
|
|
- Save your API key into GOLDEN_API_KEY env variable
|
|
|
|
## Wrappers
|
|
|
|
### Utility
|
|
|
|
There exists a GoldenQueryAPIWrapper utility which wraps this API. To import this utility:
|
|
|
|
```python
|
|
from langchain.utilities.golden_query import GoldenQueryAPIWrapper
|
|
```
|
|
|
|
For a more detailed walkthrough of this wrapper, see [this notebook](/docs/integrations/tools/golden_query.html).
|
|
|
|
### Tool
|
|
|
|
You can also easily load this wrapper as a Tool (to use with an Agent).
|
|
You can do this with:
|
|
```python
|
|
from langchain.agents import load_tools
|
|
tools = load_tools(["golden-query"])
|
|
```
|
|
|
|
For more information on tools, see [this page](/docs/modules/agents/tools/).
|