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

feat: add optional json_output param to support JSON response #194

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

himynameisben
Copy link

Description

This pull request updates the generate_podcast and process_content function in client.py to include an optional parameter for returning a JSON dictionary with detailed output information. If the parameter is not used, the function retains its original behavior to ensure backward compatibility.

Changes Made

Updated the generate_podcast function to collect the paths of the transcript and audio files.
Modified the return value of the generate_podcast function to be a JSON string containing the paths to the transcript and audio files.

Example JSON Output

{
  "transcript_file": "path/to/transcript.txt",
  "audio_file": "path/to/audio.mp3"
}

Files Modified

client.py

Testing

Verified that the generate_podcast function returns the correct JSON output with the paths to the transcript and audio files.
Ensured that the function handles cases where only a transcript is generated or both transcript and audio are generated.

Please review the changes and provide feedback. Thank you!

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

Successfully merging this pull request may close these issues.

1 participant