amosproj / amos2024ss06-health-ai-framework

Ailixir is an application that utilises LLMs and custom user input to generate AI agent prototypes specialised in fields such as health, economics, physics etc. The prototypes enable the user, which is an entrepreneur-developer, to compare the results produced by different LLMs.
MIT License
7 stars 1 forks source link

Enable the fetching of an initialisation prompt from Google Docs #214

Closed tubamos closed 1 day ago

tubamos commented 1 week ago

Domain

app backend

Description

General Intro

The initialisation prompt is administered by the entrepreneur-user who is “forming” and deploying different instances of the app to perform as different types of agents for common-users of different backgrounds.

The components for custom context (Jan / Dave) are supposed to be administered only by common-users who do not have access to the initialisation prompt (Google Docs) but are the receivers of the questions included in that prompt when they log in to the app instance that is tied to a specific prompt or when the initialisation prompt gets updated by the entrepreneur-user.

entrepreneur-user:

Creates and deploys different instances of the same app / pipeline. One instance is the one we are creating that has to do with lifestyle advice for persistent health problems. The initialisation prompt asks from common users to provide details about their medical background. food preferences etc. The entrepreneur user, in the future, could take the same app backbone and after changing a) the link to the google docs where the initialisation prompt is hosted b) the links to the embeddings DB c) some custom prompts which in our case are unfortunately not easily decoupled from the codebase they could turn the app backbone into essentially a different app which is let’s say for a common-user who is a biologist and does research on sth. of that field. The initialisation prompt, the embeddings and the custom prompts should be different at that case. This is not our job though for this project. We are only focusing on making a) the backbone so that the app can accommodate several common-user use cases (person with persistent health problems, biologist, economist…) and b) we create just one instance of these as a POC.

common-user:

The common-user lives in the walled garden that the entrepreneur-user have created for them. They receive an app that has been tailored for their needs without being able to turn the app into something else (unlike with the entrepreneur user). The common-user has the option to pass custom context (chatGPT style) to the LLM through the custom context fields that Jan / Dave have built.

An analogy: if the common user was a single docker container the entrepreneur-user would be kubernetes.


More specific about this task

Create a way to fetch text content from a Google Docs URL where a base prompt will be hosted. This base prompt will be tasked with gathering essential medical, nutritional and fitness data at the start of each interaction of the common-user with the model through the chat.

This functionality will allow the entrepreneur-user to update the prompt just by changing the content of this online google doc without dealing with code or reconfiguring / re-initialising / re-installing the app. There should be a way to retrieve the base prompt by this google docs url and pass it to the agent at the very beginning of each user interaction.

Google Docs has an API which can probalbly make this easier: https://developers.google.com/docs/api/reference/rest

User Story

Acceptance Criteria

Definition of Done