microsoft / TypeChat

TypeChat is a library that makes it easy to build natural language interfaces using types.
https://microsoft.github.io/TypeChat/
MIT License
8.06k stars 379 forks source link

Python: Add Health Data example #162

Closed hillary-mutisya closed 6 months ago

hillary-mutisya commented 6 months ago

This change adds an example of a TypeChat translator with history. Specifically, the translator keeps the previous agent responses and adds them the prompt, allowing the model to take them into account. In the health data example, the agent helps the user fill out information on their health history, current conditions and medication. The agent asks clarifying questions and keeps track of the data provided in the course of a conversation. This example is ported from the TypeChat.Net implementation.

Note: This sample works best with GPT 4

pcdeadeasy commented 6 months ago

@hillary-mutisya are you planning to add the same example to TypeChat examples as well? Might be good to have that in there. I have a classification example too but I have not pushed in a PR. I have the classifier under bottish/typeagent as well.

hillary-mutisya commented 6 months ago

Good call @pcdeadeasy. I can look into adding this to the typescript examples.