No project description provided
Project description
BigQuery Agents
This project implements a conversational agent powered by LangGraph and Google Vertex AI's Gemini model to troubleshoot BigQuery jobs. It utilizes custom tools to fetch job details and table schemas, enabling the agent to provide informed suggestions for fixing errors.
Features
- BigQuery Job Details Retrieval: Fetches details of a BigQuery job, including the query and any error messages.
- BigQuery Table Schema Retrieval: Retrieves the schema of a BigQuery table, including column names and data types.
- Error Analysis and Fix Suggestions: Analyzes job details and errors to suggest possible fixes, leveraging table schema information when necessary.
- Conversational Interface: Allows users to interact with the agent through a command-line interface.
- LangGraph State Management: Uses LangGraph to manage the conversation flow and state, including messages, job details, and table schemas.
- Mermaid Graph Visualization: Generates a Mermaid diagram of the LangGraph flow, saved as
graph.jpg.
Prerequisites
- Python 3.12+
- Google Cloud Platform (GCP) account with BigQuery enabled
PROJECT_IDenvironment variable set to your GCP project ID or hardcoded in the script.- Poetry for dependency management
Installation using pip
-
Install the pypi package:
pip install bigquery_agents
Installation via Github
-
Clone the repository:
git clone https://github.com/samkaradag/bigquery-agents.git cd bigquery-agents
-
Install dependencies using Poetry:
poetry install
Usage
-
Set your GCP project ID:
export PROJECT_ID="your-gcp-project-id"
Or change the PROJECT_ID variable inside the python script.
-
Authenticate with GCP:
gcloud auth application-default login
-
Run the agent using the
bq_fix:bq_fix
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file bigquery_agents-0.1.2.tar.gz.
File metadata
- Download URL: bigquery_agents-0.1.2.tar.gz
- Upload date:
- Size: 24.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.0.1 CPython/3.12.9 Darwin/24.3.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
702eac0cbfa312f5bc5bfe13510fa60d926e2927b0aa11e808dab912f2c5128e
|
|
| MD5 |
2f8958ed7462b3b2e94052b27e0f4e02
|
|
| BLAKE2b-256 |
a8f9f7151df3618a46b14306c9aea30e3a80f2091ea141e50a94462a7c1ce7a8
|
File details
Details for the file bigquery_agents-0.1.2-py3-none-any.whl.
File metadata
- Download URL: bigquery_agents-0.1.2-py3-none-any.whl
- Upload date:
- Size: 27.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.0.1 CPython/3.12.9 Darwin/24.3.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0060a5a37190f31b356339a7dffa60d3b5f0acd73ec7e5542118696fa8aaee96
|
|
| MD5 |
acd85f50647da2225963b5de316fd188
|
|
| BLAKE2b-256 |
7d4185cfa6f9bb2822175e357df91265dbdf1974cf502f5efd600599a84b2dee
|