Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support markdown output #6

Open
eburnette opened this issue Nov 19, 2023 · 4 comments
Open

Support markdown output #6

eburnette opened this issue Nov 19, 2023 · 4 comments

Comments

@eburnette
Copy link
Contributor

Try this prompt: "write a program to calculate pi". Currently it produces something like:

Here's a simple program in Python to compute the value of pi using the Leibniz formula: ```python def compute_pi(n): pi = 0 for i in range(n): pi += ((-1)**i) / (2*i + 1) pi *= 4

But what it should really do is format that program in a markdown code block, similar to chatgpt.

@uniconnector
Copy link
Owner

I just added a markdown output function, but it hasn't been debugged with the OpenAI API. There is a problem with the account here. Can you download and test it on your end?

@eburnette
Copy link
Contributor Author

It works:

image

but it needs to be styled and have a copy button more like this:

image

@uniconnector
Copy link
Owner

There are only two styles of this markdown component, but none of them have a copy button. Do you have any components that are more suitable to recommend or integrate directly into it?

@eburnette
Copy link
Contributor Author

I don't have a better component at this time.

BTW can you do something about the extra spacing around the output which the markdown component adds?

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants