angelxmoreno / angelxmoreno/PromptClasses

Create `regenerate` option AKA Message History

Open
#6 0 comments 0 reactions 0 assignees View on GitHub
enhancement help wanted
Dominant language
PHP
Stars
0
Forks
0
PR merge metrics
No merged PRs in 30d

Description

Currently, message history is not stored in any way. Every call to `AbstractPrompt::send()` essentially starts a new chat. On the [chatGpt web ui](https://chat.openai.com/) you can continue a conversation and refer to previous messages. Furthermore, you can say things like "Give me another example" or "Generate more".

It would be useful if the library offered the option to retain message history and thus, allow the option to "regenerate" a response.

I'm thinking something that implements the [Adapter pattern](https://refactoring.guru/design-patterns/adapter) similar to [CakePHP's Cache Engines](https://book.cakephp.org/4/en/core-libraries/caching.html#configuring-cache-engines).

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading AbstractPrompt::send() and tracing how each request is assembled and dispatched. Use the issue's Adapter pattern and CakePHP Cache Engines references to define the storage boundary. Done means the library can retain conversation messages across calls and support regenerating a response, with behavior documented and covered by tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.