Skip to main content

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_ID environment variable set to your GCP project ID or hardcoded in the script.
  • Poetry for dependency management

Installation

  1. Clone the repository:

    git clone <repository_url>
    cd <repository_directory>
    
  2. Install dependencies using Poetry:

    poetry install
    
  3. Set your GCP project ID:

    export PROJECT_ID="your-gcp-project-id"
    

    Or change the PROJECT_ID variable inside the python script.

  4. Authenticate with GCP:

    gcloud auth application-default login
    

Usage

Run the agent using the bq_fix script defined in poetry.toml:

poetry run bq_fix

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bigquery_agents-0.1.0.tar.gz (23.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

bigquery_agents-0.1.0-py3-none-any.whl (26.6 kB view details)

Uploaded Python 3

File details

Details for the file bigquery_agents-0.1.0.tar.gz.

File metadata

  • Download URL: bigquery_agents-0.1.0.tar.gz
  • Upload date:
  • Size: 23.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.0.1 CPython/3.12.9 Darwin/24.3.0

File hashes

Hashes for bigquery_agents-0.1.0.tar.gz
Algorithm Hash digest
SHA256 b735b5ae8cb7ae122f5a5bd62270d0825261d7253d84e91b086ac897a19f7fbe
MD5 fdeca835e8e2d4f5848a553b95bb469a
BLAKE2b-256 63b1803939a08bb452b6553b2a66fdb07d9a90f36ed70c4c155afade2cbfea06

See more details on using hashes here.

File details

Details for the file bigquery_agents-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: bigquery_agents-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 26.6 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

Hashes for bigquery_agents-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d6bfe5d51090c67e983033bd164187c8a4bda0227fcf0afbe3feceb149cdf7f6
MD5 ed1369572e0a26df520b0dbd63db4613
BLAKE2b-256 5a36a8c3224cca1d94e78588cd8a19bed6c70e0c9a1aeddbbfa93aa29a3b7bbe

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page