Skip to content

Prompt Engine API #59

@Tylermarques

Description

@Tylermarques

We need to create a api that can return the relevant prompt text for given call.

This system should use postgres as the backend database, running within a docker container. The data for postgres should be mounted as a local volume so it persists.

The API should use FastAPI and uvicorn, and should also run in a docker container. There should be a /prompt endpoint that allows you to

  1. Retrieve the current prompt text for your user. You will need to provide Game_id, prompt_type (Enum of Order, System, or Negotiation). The API should authenticate the user, and given the authenticated user's ID, it should use that to look up the relevant prompt.
  2. Allow the creation of a new version of a prompt for a given Game, prompt_type combo for that given user. If the user has not created a prompt, it should return the default prompt for that specific type. The creation of a new prompt should increment a version number, and never delete old versions. When the user retrieve's a prompt, it should always show only the latest version of their prompt.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions