Skip to content

hassancs91/Google-Gemeni-Consistent-JSON-Response

Repository files navigation

Consistent JSON with Language Models

License: MIT

Introduction

Working with language models like Google Gemini often results in inconsistent and unstructured JSON outputs. This project aims to solve this by implementing a 9 Step approuch to ensure a consistent JSON structure, this is beneficial for application development.

For more detailed information, please refer to my blog post on the project.

Features

  • Pydantic Model Integration: Utilize Pydantic models to define and validate JSON structure.
  • Optimized Prompt Engineering: Enhance language model prompts for more consistent responses.
  • JSON Extraction and Validation: Reliable methods to extract and validate JSON from model responses.

Example Application

Included is a 'Simple Blog Title Generator Tool' demonstrating the practical application of the project.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages