Code Monkey home page Code Monkey logo

ai-powered-study-planand-book-summarization's Introduction

AI-Powered Study Plan and Book Summarization

This repository contains two powerful AI-driven solutions: a prompt engineering template for generating personalized study plans and a hierarchical summarization system for condensing lengthy books into comprehensive summaries. Both solutions leverage advanced language models and prompt engineering techniques to deliver tailored and efficient outputs.

Table of Contents

Overview

This project combines two powerful AI solutions: a personalized study plan prompt and a book summarization system. The personalized study plan prompt generates tailored study plans for students based on their unique needs, strengths, and aspirations. The summarization system, on the other hand, condenses lengthy books into comprehensive summaries, addressing the token limit constraint of GPT-4.

Personalized Study Plan Prompt

Personalized Study Plan Prompt

Installation

To use this prompt, you'll need to have the following dependencies installed:

  • Python 3.10
  • LangChain
  • OpenAI GPT-4,Groq
  • PDF converter FPDF

You can install the required packages using pip:

pip install -r requirements.txt

Usage

  1. Clone this repository to your local machine.
  2. Import the necessary modules and load the prompt template.
  3. Provide the required student data as input variables.
  4. Generate the personalized study plan using the prompt template and your preferred language model.

For more detailed usage instructions, please refer to the Prompt Details section.

Prompt Details

The prompt details, including input variables, key components, and prompt engineering techniques, are explained in the prompt.ipynb file.

Prompt Engineering Techniques

The personalized study plan prompt incorporates the following prompt engineering techniques:

  • Task Decomposition
  • Descriptive Instructions
  • Example Generation
  • Grounding
  • Output Constraints
  • Purpose Clarification

For more information on these techniques and how they are implemented in the prompt, please refer to the prompt.ipynb file.

Summarization System

Summarization System

Key Features

  • Hierarchical Summarization: Utilizes a multi-level summarization approach to handle lengthy texts within the token limit.
  • ChatGPT and Groq Integration: Employs ChatGPT for initial chapter summaries and Groq for final comprehensive summaries.
  • Text Segmentation: Divides the book into smaller units for efficient processing and summary generation.
  • File Handling: Saves individual chapter summaries and combines them to form a final summary for easy access.

Usage

  1. Input: Provide the lengthy book in a compatible format (e.g., PDF, plain text).
  2. Execution: Run the provided Python script to initiate the summarization process.
  3. Output: Access the final comprehensive summary generated by the system.

Implementation Details

  • Chapter Summarization: Utilizes ChatGPT to summarize each chapter individually.
  • Comprehensive Summary: Employs Groq to generate a cohesive summary by combining the chapter summaries.
  • File Management: Organizes summaries into separate files for easy retrieval and reference.

Challenges and Solutions

  • Token Limit Constraint: Mitigated by breaking down the book into smaller units and progressively summarizing them.
  • Coherence and Consistency: Ensured through careful integration of chapter summaries into the final comprehensive summary.
  • API Rate Limits: Handled by implementing rate limiting mechanisms and optimizing API usage.

Next Steps

  • Explore further optimization techniques to enhance the efficiency and quality of summarization.
  • Incorporate user feedback mechanisms to refine and improve the summarization process.
  • Extend support for additional document formats and integration with external storage services.

Contributing

Contributions to this project are welcome. If you have any suggestions, bug reports, or feature requests, please open an issue or submit a pull request.

License

This project is licensed under the MIT License.

ai-powered-study-planand-book-summarization's People

Contributors

huzaifa7524 avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.